Archived

This topic is now archived and is closed to further replies.

lib3ds animation

This topic is 5986 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hi guys i have a problem with loading animations from a .3ds-file using lib3ds. i load a file with animation with the lib3ds_open() function, but when i look at the returned structure i cant see any animation data! somewhere i have read that it is possible to load animations with lib3ds... someone who can tell me how? is there a special function for that? and how do i use the animation data? my second question: how does lighting in computergames work? i have used the d3d-lighting in a spaceshooter, but there are only 8 light sources allowed?! in some games there are more lights used i think... 8 lights arent enough for many laserbeams and explosions! thanks for any help!

Share this post


Link to post
Share on other sites
no-one in real life has every object illuminated by every light source.... in general you have all the static lights precalculated with a light map... then you add to that the dynamic lights in the scene. And in general, you only illuminate objects with light sources, that are near enough to have a large impact on that object... so 8 light sources, means 8 dynamic light sources, calculated per polygon... so they don''t have to be the same eight as are used to illuminate another polygon, or object. ie you can pick the 8 nearest light sources to each object, or choose a fixed radius, and only consider light sources, within that radius of the object you with to illuminate.... in reality, you may find that many games use far less that 8 light sources per object, as this could be slow, as it requires a dot product, per vertex, per light source.

Share this post


Link to post
Share on other sites
thanks for your help

so all i need is a smart and fast function to find the important lights...ok!
i know about lightmaps but in a space game theres no use for this.(i think...)

nice... i only need one more person to solve the 3ds-anim-problem!

Share this post


Link to post
Share on other sites