Culling failing on duplicated objects
2 posters
Culling failing on duplicated objects
In my app, some duplicated objects arenīt shown and itīs due to an incorrect dst value after the call to sio2ResourceCull function. We click on Center New in Blender to avoid culling problems but this is impossible with duplicated objects.
Can thid be the problem on the dst calculation with duplicated objects? How can I simulate this Center New with code?
Iīm stuck in this so any idea will be very helpfull.
Thanks in advance.
Can thid be the problem on the dst calculation with duplicated objects? How can I simulate this Center New with code?
Iīm stuck in this so any idea will be very helpfull.
Thanks in advance.
Re: Culling failing on duplicated objects
I don't totally understand your problem, but I thought I would mention that it's a very good practice to export your objects centered at the origin. Then do your translations in code.
Best,
-joshua
Best,
-joshua
meteors- Posts : 241
Join date : 2008-11-08
Location : Sunny Florida
Re: Culling failing on duplicated objects
Yeah, perhaps I didnīt explain it quite well. In my blender file I have an object centered at the origin. In the Iphone game itīs not in the camera range but I duplicate it periodically and change the position of that duplicated objects to be just in front of the camera.
Everything is allright until this point. Some of the duplicated objects are there but you canīt see it. Iīve been looking into this and Iīve found that the dst value calculation (in sio2ResourceCull) gives a wrong value (0.0) so the object is not rendered.
I was just asking myself (and the people in the forum ) what could be the reason of this wrong value and wheter this could be related to the center to the origin thing.
I hope itīs clear now.
Everything is allright until this point. Some of the duplicated objects are there but you canīt see it. Iīve been looking into this and Iīve found that the dst value calculation (in sio2ResourceCull) gives a wrong value (0.0) so the object is not rendered.
I was just asking myself (and the people in the forum ) what could be the reason of this wrong value and wheter this could be related to the center to the origin thing.
I hope itīs clear now.
Re: Culling failing on duplicated objects
A deeper trace shows some memory leaks. Iīll try to fix it.
Fixed leaks but not the problem
Fixed leaks.. Now instruments doesnīt show memory leaks in my code.
Object culling is fine but I still donīt see the object
Iīve debugged the code and itīs supposed to show, itīs running even texture rendering function but the object is not rendered. Itīs even invisible for physics so perhaps is a problem with rigid body but culling is calculated fine and object->dst value is correct.
Object culling is fine but I still donīt see the object
Iīve debugged the code and itīs supposed to show, itīs running even texture rendering function but the object is not rendered. Itīs even invisible for physics so perhaps is a problem with rigid body but culling is calculated fine and object->dst value is correct.
Re: Culling failing on duplicated objects
This is weird. If I set all the objects state to DISABLE_DEACTIVATION, the objects does not move but are shown. If I set it to ACTIVE_TAG, the obejcts are moving but some of them arenīt visible for the camera and the physics.
Any idea?
Any idea?
Similar topics
» duplicating objects at runtime and changing textures on the duplicated objects
» Objects failing to collide at high velocities, tunneling through floor etc.
» Testing and failing Object duplication
» rotating objects
» Culling and Bullet
» Objects failing to collide at high velocities, tunneling through floor etc.
» Testing and failing Object duplication
» rotating objects
» Culling and Bullet
Permissions in this forum:
You cannot reply to topics in this forum