Manual Object Error on re-drawing test


22-11-2010 16:18:42

Hi, i have a code which draws some targets with variable settings, and i need draw them in runtime and convert to mesh,
but there is a problem:
when a setting has been changed by user i must re-draw a new mesh from manual object in runtime, there is no problem till yet but
when user does it frequently it gives this error:

i think maybe hardware buffer is overloading but i am not sure,
maybe i should draw them using directly hardwarebuffermanager?

after every new mesh creating i am clearing the old mesh and manualobject by using following code:
(Target is my manualobject)



29-11-2010 20:51:02

This is no nice error and I have no idea about the reason.
Maybe there is a warning or error in the ogre.log file?

To create such pictures maybe you can use Overlays (2D on screen) or Billboards (flat 2D object in 3D world).
By this you can load images from files. If you need flexibility for your target pictures, you can create them by multiple layers with different scale.
Just as an idea ...


02-12-2010 16:05:44

Hi beauty and tnx for your answer and advices,
when this error occurs i have checked ogre.log too but if i remember correctly it didnt give any clue too,
but then i have solved this error using instead of using Target.ConvertToMesh(MeshName + ".mesh") ( i was using MeshName + ".mesh" directly), i have used
MeshSerializer _MeshSerializer = new MeshSerializer();
_MeshSerializer.ExportMesh(Target.ConvertToMesh(MeshName + ".mesh"), "..\\Debug\\Media\\Targets\\3D\\Meshes\\" + MeshName+".mesh");

then problem has been solved by this way, hope it helps someone and tnx again.