Page 13 of 15

Posted: Mon Aug 13, 2007 2:26 pm
by hybrid
IIRC the static parts of LWO are pretty well supported by my loader. I have several loaders available, most will need some proper debugging of array usage etc, because they were written for Irrlicht 0.14 or earlier originally. Problems with the existing loaders distracted my work from these loaders, but they are working with lots of models I downloaded from several places for testing purposes.

Posted: Mon Aug 13, 2007 10:59 pm
by vermeer
that's nice as LWO tends to be ok supported in many tools, like OBJ.

Question, hybrid...I read that you say there's no smoothing groups in irrlicht...But there are indeed vertex normals, arent they? The visual result is the same, though...I mean: I have never made a projects in irrlicht, but yes tests, and seems to me that surfaces can appears smoothed, and having the hard edges where I did put them...Ie, b3d format I think showed this also...

In an obj, I see to ways to appear smoothing info: an "s" rpeceding a bunch of faces, formng that an smoothing group, and...the mentioned "VN" vertices, which I understood are vertex normals...Is this correct in the 'programming world' ?

vertex normals and smooth groups, at least in artist jergon, are same thing in visual result, just different techniques to apply hard edges/smoothing areas...

Posted: Mon Aug 13, 2007 11:17 pm
by hybrid
Yes, Irrlicht uses vertex normals, so the normals can be smoothed. And yes, .obj has 's' for smoothing groups (with 0 or off for no smoothing) and 'vn' as vertex normals. The latter overwrite the smoothing groups if both are existing (which was the error in the .obj file in the ogre comparison). The problem of the Irrlicht loaders is that both .obj and .3ds use the notion of smoothing groups and both are not supported in Irrlicht. also this can be remedied with a 3d modeller with .obj it's a bad thing. Moreover, the file formats use vertex replication more often than necessary, so it might be useful to fix both things...

Posted: Tue Aug 14, 2007 3:44 pm
by vermeer
I see...really good explanation...Been some time wondering about some of those details...It all boils to not have used irrlicht in practice I guess, only hepled in some projects with art or pipelines.

So, quite good, as vertex normals are easy to output from a long collection of tools, indeed, the majority of converters and art packages do so, instead of "smooth groups". B3d/md5/lwo/obj (my favourites, actually) should have no issue.

Posted: Tue Aug 14, 2007 10:02 pm
by alexionne
hybrid wrote:IIRC the static parts of LWO are pretty well supported by my loader. I have several loaders available, most will need some proper debugging of array usage etc, because they were written for Irrlicht 0.14 or earlier originally. Problems with the existing loaders distracted my work from these loaders, but they are working with lots of models I downloaded from several places for testing purposes.
Hi!

As you already saw, I took your LWO loader and started working on it. I plan to add: VMAD support (already working on it), vertex colors (shouldn't bee too hard), non-uv mappings (planar, cylindrical, spherical -> automatic texture coordinates generation), smoothing (as far as I can see, vertex normals are taken from face normals), and ... well, that would just enough for the beginning :)

After that, I hope to implement some nice LWS loader for skeletal animation support.

I just have a question, what do you mean by that "most will need some proper debugging of array usage"?

Keep up with good work! :-)

Posted: Tue Aug 14, 2007 10:59 pm
by hybrid
I wrote all this stuff before the allocator stuff was added. Before this, you could use either array.reallocate or array.set_used. With the allocators in place there was some trouble with the loaders. That's why they were not immediately integrated. This might be fixed in irrArray now, but I'm not sure. Moreover, some mem leaks showed up in some loaders I tested in the mean time.
For the additional stuff: I'm planning for some meshbuffer enhancements and usability additions. These will provide methods to recalculate normals of buffers, and maybe it would be possible to add the mapping stuff there as well. So just be sure to use meshbuffers whereever possible.

Posted: Wed Aug 15, 2007 8:25 am
by alexionne
Thanks for the hints.

Posted: Wed Aug 29, 2007 6:49 am
by gheft
hi luke,
I've been testing this out with the dwarf.x model trying to make a ragdoll and I just can't move the joints at all. I've tried setPosition, setAbsoluteTransformation, setRotation, nothing works, is there something else I need to do?

I got getPosition working but for some reason it only returns the correct position after I call
mesh->getJointNode()
smgr->drawAll()
so it does work, but it would be more straightforward if I could get joint positions by calling getJointNode() right after creating the mesh

Posted: Wed Aug 29, 2007 10:30 am
by Luke
I just can't move the joints at all.
yeah I need to write some docs,

when setting up the mesh call:

node->setJointMode(2); //to tell it you don't want to animate the joints on render

then sometime before rendering the scene call:

node->animateJoints(); //to animate the joints (but you won't need to with a ragdoll)

then before rendering you can move the joints around.

it may seem weird, but this gives you full control over the joints.
I got getPosition working but for some reason it only returns the correct position after I call
it seems the non-animated joint positions are non right on your mesh (or gotten from the x loader), you could call node->animateJoints(); before getting the positions.

Posted: Thu Aug 30, 2007 5:31 pm
by MasterGod
Will the new animation system could read 3ds format animations?

Posted: Thu Aug 30, 2007 6:40 pm
by christianclavet
Hi, There is a link if you will need to improve the:
LWO-->Objects Mesh
LWS--->>Scene script

loaders, for Irrlicht.

The SDK page from Newtek. You will get all the information there to parse the files:
http://www.newtek.com/lightwave/developers/

Posted: Thu Aug 30, 2007 7:39 pm
by hybrid
No, the new animation system does not support any new formats. Addition of new formats or new features of supported formats will be made after the merge.
So in case someone wants to develop new loaders or animation support: Use the SkinnedMesh branch and test it. Develop new code concerning meshes for the branch as the API will be used for core Irrlicht very soon.

Posted: Fri Aug 31, 2007 7:58 am
by szerg
ey, i got the engine from the svn then i compiled it....
what are the new functions/ syntax modifications since v1.3.1 ? :oops:

Edit:
Anyways.. is it possible now to get the joints local and global matrices and whatever a joint has?

SkinnedMesh betatest phase 1

Posted: Fri Aug 31, 2007 3:51 pm
by hybrid
Ok, I have built MeshViewer binaries using the SkinnedMesh branch for Windows and Linux. In case you don't want to recompile the whole branch and create your own apps this allows for beta testing the new code. Just unzip the archice into your Irrlicht directory (from either SDK or SVN). It creates a new directory bin/SkinnedMesh/ where the binary is located. This is necessary since I don't want to overwrite existing Irrlicht.dlls, but the app needs the media folder.
You can get the files here:
http://parsys.informatik.uni-oldenburg. ... indows.zip
http://parsys.informatik.uni-oldenburg. ... _Linux.zip

To be used with animated meshes everyone has lying around. Please test as many meshes as possible. Report any problems back here, but also positive feedback is important (mayye not for every mesh then as we hope that it works with quite some :wink: ). We are planning to merge the branch soon, so help us find bugs ASAP.

Posted: Fri Aug 31, 2007 7:58 pm
by Ico
Two strange things (WinXP Home, GF 7800 GTX):

- I can't use keyboard keys to navigate the directory list (i.e. press K to go to the first entry starting with K). This works using svn examples (updated 1 or 2 days ago).

- Program crashes (without any new console line/output) if I try to load a simple b3d file containing only a simple quad - no animation (works perfect in my svn build - custom program and meshviewer example).

Mesh download: http://files.filefront.com/quadb3d/;844 ... einfo.html