Hi everybody!
Is there any 3D Studio loader, which supports
animations (not just one animation)?
If so, please reply my where i can get it.
Thanks in advance!
Emil Alonzo
Hi everybody!
Is there any 3D Studio loader, which supports
animations (not just one animation)?
If so, please reply my where i can get it.
Thanks in advance!
Emil Alonzo
http://www.newdawnsoftware.com/resources/xith3d
animation seems abit slow and gets worse the more frames it plays in an animation. lags out abit… then when it gets back to frame 1 it speeds up again
but the src is there
Thanks, it did work!
I will try and look at the code to see if I could improve somrthing 8)
well i think the problem is in the for loop under:
packages:
org.newdawn.xith3d.threeds.model.PosTransform
org.newdawn.xith3d.threeds.model.RotTransform
org.newdawn.xith3d.threeds.model.ScaleTransform
in the call ‘setTime’.
for (int i=0;i<frames.size();i++) {
firstFrame = (PosFrame) frames.get(i);
if (i != frames.size()-1) {
nextFrame = (PosFrame) frames.get(i+1);
if ((time >= firstFrame.time) && (time < nextFrame.time)) {
break;
}
} else {
nextFrame = (PosFrame) frames.get(0);
}
}
it seems to scan all the frames in the files animation. so it gets incromently slower the more frames you have.
not sure of a work around mind.
How many frames are we talking about here?
I’d be surprised if that was the bottleneck unless we’re talking about 1000s of frames.
Have you tried profiling? (yes, yes, I know, its my code I should sort it out but I have a slight RSI problem right now)
Kev
yep thousands + frames. not so many keyframes mind prob around 100 at most ever…
im just downloading OptimizeIt so i can make build a profile…
heres the profiler output:
http://www.topresultmate.com/xith3d/newdawn_profile.jpg
Seems to hang out in RotTransform.
With an animation of around 8 keyframes
Certainly looks that way, what hideous code did I leave in there.
Kev
:):):):):):):):):):):):):):):)
:)* CLAP CLAP CLAP CLAP CLAP
!! OH- KEV MAY DO A FIX !!
CLAP CLAP CLAP CLAP CLAP *
:):):):):):):):):):):):):):):)
Alright, assuming my hand is in any workable state tonight I’ll take a look tonight.
But only because of all the smileys
Kev
PS. Does anyone else have a list of things they need to see sorted out (I’m not adding new features, just fixes)
only things i have found over the months using the loader is getName(); returns nothing for me,
thought it should return the name of the shape matching the name i gave it in the modeler.
and the animation thing- ditching the loop would be cool. i would like to have alot of objects
animating at the same time
also texture loading- if i load a lot of shapes with textures the way textures are loaded in the
loader- it tends to run out of memory. i changed it to use getMipMap() (think its using disk caching) but then
transparent textures (png) didnt work strange thing is a changed it back and it started working
ok… so not sure if this was a xith3d bug that was fixed.
but animations being nicer would make my day
It seems I can’t even get a model on the screen anymore
Going to be hard to fix anything…
Kev
do u want one of my 3ds files?
Na, I’ve got piles of 3DS models now, just nothing showing up from the test app. I guess Xith must have changed significantly since I last tried it.
Kev
im using a build from the 29th of April.
All works here still.
i could upload the xith3d.jar for u?
Nope, back on track now!
Kev
sweet
New version uplaoded. It might be better, it might break a bit. PLEASE backup an old version before downloading this one…
Kev
In 3D Studio, is it possible to have e.g two animations in the same file?
Or do you need to have e.g Character Studio?
Thanks,
Emil Alonzo
2 animations? sorry i dont understand.
do u mean u want to shapes to animate? one doing
one thing the other doing somthing else. if so then yes
would be pointless if u couldnt do this.
but i would think about how u want to make objects for
a game world. i make component parts of a model then
animate them parts. after that i bring them into Xith3D
and connect them up separate files (IO is fast if u
ask me- for somthing like loading).
if u make say 10 shockwave explosion effects
then 10 explosion centers along with 10 models of stuff
that looks like smashed up parts animating. Next you
bring them parts into Xith and mix them together
(maybe even changing he colors in Xith3d to add more
complexerty. u end up with alot of combinations.
if u make them as final done deals u end up with only 10
this is also cool with making characters. make them
separate parts if u can.
history: Quake did this along time back