It is, indeed, a memory problem.

One thing you can try is to reduce the amount of processing done. Try removing aiProcess_JoinIdenticalVertices and aiProcess_SortByPType and see if that makes a difference.

Cheers,
-Ken


On Tue, Jun 3, 2014 at 2:29 PM, Francesco Corucci <f.corucci@gmail.com> wrote:

Hi guys,

I am moving the first steps with the assimp library in the Qt 5.3 environment (and with 3D stuff in general). What I need to do is to load the CAD model of a robot and animate it (from simple rotations to display robot's attitude, to moving some joints in a robotic arm).

Following this tutorial I was able to correctly load .obj files downloaded from the web.

I have then tried with my models: starting from a Solid Works model (.SLDASM) I exported in .STL, and then with MeshLab in .obj.

The program works fine when dealing with a simple model (few parts), but when I try to load a more complex one (a whole robot, with lot of parts) I get this error:

Using OpenGL 3.3 context
Error loading file: (assimp:) std::bad_alloc

I imagine this is related to memory (maybe the model is too big?).

What I would like to ask you is: any idea on how can I solve this?
Any suggestion? I guess simplifying the model could be an option, but maybe I can avoid this, so I am asking you.

Thank you very much guys

Cheers,


Francesco





------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Assimp-discussions mailing list
Assimp-discussions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/assimp-discussions