Ask a Question related to Macromedia Director 3D, Design and Development.
-
Glorfind3l #1
W3D structure...
Hi
My big problem is that I have some deformations that are already defined by
vertices index, and their moves...
But these deformations are defined for a mesh in a standard 3d format (.obj,
..ase, .max ... etc)
And they don't work again on the mesh when I export it in W3D format...
I see some strange results... for example, a box, in a standard 3d format, is
defined by eight vertex (which is logic...) ... the same box, when I export it
in W3D and print its vertexlist in Director, has 24 vertices...
I am a little bit lost... suggestion/idea and more are welcome
Glorfind3l Guest
-
Class::Struct - want to access structure within structure
I want to access a structure within a structure. Below is what I had in mind. Please help. #!/perl/bin/perl use Class::Struct; struct Step... -
Add to Structure
I'm a structures newbie. I need to know how to 1) Determine if a structure already exists 2) If not, create it. If yes, add to it. I've got... -
Complex Structure
Hey guys, I've created a reservation app that checks multiple dates against a calendar and if the dates are available inserts them into a table.... -
what is this data structure?
Hi, I don't know how to work with this data structure: my @array = ((a => 'appple'), (b => 'tree'), (c => 'chair')); when I do: -
Invoice Structure?
Hi Group Just trying to get some thoughts on the best / efficient way to handle this type of invoicing or some ways you may have handled this. ... -
Medion #2
Re: W3D structure...
First, the W3D format doesn't store per-vertex animation. You can only animate
the position/rotation/scaling of models and bones.
The vertexlist you are seeing from the #meshdeform modifier is like that
because, internally, director uses indexed lists. Such lists allow vertices to
be definied by a single index per vertex, and that same index is used to read
from a vertexlist, a normallist and a texture coordinatelist.
As example, you have a triangle that is definied as [23, 45, 12], this means
vertex[1] will use vertexlist[23], normallist[23] and texturecoordinatelist[23].
In the case of your cube, you have 8 vertices, each face, while sharind
vertices, might not share normals, and can have a different normal per vertex
and a different texture coordinatelist. Since each vertex will use a single
index, all lists must have the same amount of items, so duplicates will be
created in the smaller lists.
Back to your problem, if you want vertex animation to export, you'll need to:
1) Choose another file format
2) Load the file and parse it using your own scripts in director (use a file
like .ASE, that supports ASCII formatting)
3) Build the model into the 3D sprite using newMesh() (see documentation on
how to use it - it's pretty usefull)
4) Write your own vertex animation code.
It's not really all that hard, and it really depends on your ability in being
able to parse the file format you choose, so you can use it's information to
build a mesh. Doing your own vertex animation can be a breeze, because Director
allows arithimetical operations between lists, so all you need is to generate a
vertexlist for each keyframe, and you can interpolate between keyframes more or
less like this:
meshResource.vertexlist = keyframeList[1]*0.5 + keyframeList[2]*0.5
That'll interpolate 50% between keyframeList[1] and keyframeList[2]. Of
course, this trick is only usable if you build the mesh yourself, so the
vertexlist ordering will be always the same.
Since W3D is a compressed format, the vertex ordering changes when you export
the file with minor changes, so deformations will not work as intended.
Medion Guest
-
necromanthus #3
Re: W3D structure...
This is because are listed the vertices for each face.
For a box there're 6 faces (amazing discovery ... LOL).
6 x 4 = 24 vertices .
that's all ...
[q]Originally posted by: Glorfind3l
I see some strange results... for example, a box, in a standard 3d format, is
defined by eight vertex (which is logic...) ... the same box, when I export it
in W3D and print its vertexlist in Director, has 24 vertices...[/q]
necromanthus Guest



Reply With Quote

