Show Posts
|
|
Pages: 1 2 3 [4]
|
|
46
|
Crystal Space Development / Support / Loading multiple models sharing a single texture
|
on: January 20, 2006, 04:08:06 pm
|
|
I have found that when loading models from a library, if the models share the same texture, the first mesh loaded is the only one that gets displayed. Do i need to somehow 'free' the texture? Or do i need to create another separate texture file?
iMeshFactoryWrapper* wing1factory = engine->FindMeshFactory("thingpolySurface8"); csRef<iMeshWrapper> wing1mesh = engine->CreateMeshWrapper(wing1factory,"wing1",room,csVector3 (0, 0, 0)); wing1mesh->GetMovable()->UpdateMove(); iMeshFactoryWrapper* wing2factory = engine->FindMeshFactory("thingpolySurface9"); csRef<iMeshWrapper> wing2mesh = engine->CreateMeshWrapper(wing2factory,"wing2",room,csVector3(5,5,5)); wing2mesh->GetMovable()->UpdateMove();
in this order, wing1 gets displayed, but wing2 doesnt. If i switch the order, wing2 gets displayed but wing1 doesnt.
|
|
|
|
|
49
|
Crystal Space Development / Support / Re: Multi-part models
|
on: January 20, 2006, 03:29:59 pm
|
Thats great  It seems easy to add meshes to the hierarchical structure, but is it possible to remove them? ie: if i make each car part a child of the main car chassis can i remove parts from the structure when i want to detach them in game?
|
|
|
|
|
50
|
Crystal Space Development / Support / Multi-part models
|
on: January 20, 2006, 02:49:55 pm
|
|
I am working as part of a group to create a driving game using crystal space
I would like to make car models so that bits (eg bumpers, headlights) fall off the car when the car collides with an object in the game.
At the moment, the car is made up of separate meshes for each car part. Is there a way of somehow linking the meshes so that the car can be moved as a whole, but with the ability to "unlink" a mesh when the car collides with something, so that the part will fall off?
I would be interested to hear any suggestions as to how this might work, or if a different approach to the problem would be better.
regards, Kate Mallichan
|
|
|
|
|
52
|
Crystal Space Development / Support / Re: Would like help loading model from library
|
on: January 20, 2006, 01:57:27 pm
|
|
Ok, im getting there...
I now get errors similar to following for each texture, even though these files are present.
Could not open image file 'textures/outUVwingmirror.jpg' on VFS!
I also get an error
crystalspace.maploader.parse.library: Could not open library file 'factories/thingpolySurface9' on VFS!
for this one particular mesh, but not for the others (there are several in the library).
Any clue as to why this is happening?
thanks again for your help, Kate Mallichan
|
|
|
|
|
54
|
Crystal Space Development / Support / Would like help loading model from library
|
on: January 20, 2006, 12:59:07 pm
|
|
Hi there,
I am using blender to create levels and models. I have successfully used the blender2crystal blender plugin script to export a level, which I can then load and look round with walktest.
What I havent been able to do is to display a model that has been exported as a library using blender2crystal.
I read somwhere in the crystal space manual:
Making Models
Models of type Genmesh (see section Genmesh Mesh Object) can also be converted directly with Blend2cs or blender2crystal. To do this you need to mark the object in Blender as a genmesh object (see manual on how to do that) and then export as a library. In Crystal Space you can directly load that library as a single model.
I would like to know how I can directly load that library as a single model.
An example code snippet would be really helpful, I've been stuck on this for a while!
regards, Kate Mallichan
|
|
|
|
|
|