Ask a Question related to Macromedia Director 3D, Design and Development.

  1. #1

    Default 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

  2. Similar Questions and Discussions

    1. 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...
    2. 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...
    3. 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....
    4. 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:
    5. 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. ...
  3. #2

    Default 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

  4. #3

    Default 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

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139