billboard trees don't turn.

Discussion in 'Track Modding' started by Mario Morais, Feb 25, 2012.

  1. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    I try to converte my trees to billboard, but don't turn. Any help?

    My settings:
    Shader: T1 Stamp vertex
    Geometry: Edit poly quads (no triangles)
    Gmotor instance: Screen-Aligned Quads- BB

    edited:

    Solution!
    -------------------------------------------------------------------
    ´Ok i resume all steps:

    - The object must be "Editable Poly"
    - Edit it in Element level.
    if the quad have a line remove it (Backspace key).
    - Change Reeference Coordinate to "local"
    - In vertex mode, select all vertex of the quad and change vertex alpha to 90.
    - Select one quad and press "Retriangulate"
    - Press "Edit Triangulation" and check:
    1- Z(red) local axis is the side of the face. If not rotate the quad by 180º.
    2- the dashed diagonal line is towards left / top to bottom / right. If not press "turn" button then click in dashed line.

    Picture



    For Gmotor instance: Picture

    Screen-Aligned Quads:
    [x] BB

    Shading:
    Smooth and Omni.

    Shadows:
    Caster and Textured

    Normals:
    Gmotor Tan: -1
    bin: -1

    I try pointy, but not natural..
     
    Last edited by a moderator: Feb 25, 2012
  2. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    i forget to change vertex alpha to 90 . :)

    But now i have a strange tree

    Screenshot
     
  3. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    The billboarding you're trying to use works for quads, i.e. billboarding that operates on a quad level rather than object level.
    As for the 90° issue, that's related to triangulation and vert numbering. I suggest a Turn operation on the diagonal edge. That will take care of the 90°, hoewever, the tree may now appear upside-down depending on the vertex numbers. Rotate the quad (Local) 180°.

    This may sound a bit technical, but you'll get the hang of it after a few attempts. It's something you have to do a few times before it becomes second nature :) .
     
  4. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    Thanks luc.

    But i can't fix it changing the pivot point in max?
    I do not want to rotate the polygons

    my max screenshot link
     
  5. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    An object has one pivot point. Now, when you tell the engine to billboard all (non-zero vertex alpha) quads, how can you define the pivot point :) ? You can change the quad pivot point in the exporter (the 'box-and-arrow' buttons). This changes the pivot for each quad according to the quad's base line. We can 'see' the baseline. The renderer can't, and needs a reference. That's why the polys need to be placed correctly. Vertex numbering (and triangulation) is the only way you can define this reference. The renderer will process each stamp/billboard quad the same way: it looks at the verts, and processes the quad billboarding. There is no other way for it to decide which side goes up etc :) .
     
  6. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    you i see now the triangulation.. is right-top / left-bottom :)

    i need to learn how to edit it.

    when i find the way who to fix. maybe write a MAXscript to help others.
     
  7. Luc Van Camp

    Luc Van Camp Track Team Staff Member

    Joined:
    Oct 4, 2010
    Messages:
    1,030
    Likes Received:
    15
    Edge submode, Turn button, click the edge :) .
     
  8. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    Thanks luc! yes i find. one quad don't have dotted line.!

    the max is weird! sometimes do not see the dotted line What is the best viewport settigns to see it?
     
  9. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    Last edited by a moderator: Feb 25, 2012
  10. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    Ok i resume all steps:

    - The object must be "Editable Poly"

    - Edit it in Element level.
    if the quad have a line remove it (Backspace key).

    - Change Reeference Coordinate to "local"

    - In vertex mode, select all vertex of the quad and change vertex alpha to 90.

    - Select one quad and press "Retriangulate"

    - Press "Edit Triangulation" and check:
    1- Z(red) local axis is the side of the face. If not rotate the quad by 180º.
    2- the dashed diagonal line is towards left / top to bottom / right. If not press "turn" button then click in dashed line.

    Picture



    For Gmotor instance: Picture

    Screen-Aligned Quads:
    [x] BB

    Shading:
    Smooth and Omni.

    Shadows:
    Caster and Textured


    Normals:
    Gmotor Tan: -1
    bin: -1

    I try pointy, but not natural.. :(
     
    Last edited by a moderator: Feb 25, 2012
  11. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    Now I have another problem .. Dozens of trees! I have to do one by one?? or remove, and clone?

    hmm would be a fantastic magic button [Convert Tree to BillBoard] ..
    :)
     
  12. mianiak

    mianiak Registered

    Joined:
    Oct 5, 2010
    Messages:
    691
    Likes Received:
    46
    I will pm you a process to fix this, if you make it into a script for me ;)
     
  13. kuato

    kuato Registered

    Joined:
    Oct 5, 2010
    Messages:
    32
    Likes Received:
    0
    If your trees are individual objects, you could just use a replace script and set your working billboard tree as the replacing object. You'll be done in 10 seconds.

    If your trees are grouped, then maybe writing a script that looks for intersecting planes and replaces the x-elements for quads. But that could be tricky if you have trees touching each other in your groups. It could turn out to be more work than just replacing the trees manually.
     
  14. feels3

    feels3 Member Staff Member

    Joined:
    Sep 4, 2011
    Messages:
    1,201
    Likes Received:
    142
    I have little problem with billboards.

    I did all steps from track technology.pdf

    - all vertex alpha set to 90
    - t1 stamp vertex shader
    - quad is triangulated from the top-left to the bottom right
    - pivot point set to the bottom for a 2d tree
    - reseted x-form

    Look at this, in 3dsmax tree looks fine but in rf2 is huge and deformed.

    [​IMG]

    [​IMG]

    [​IMG]
     
  15. mianiak

    mianiak Registered

    Joined:
    Oct 5, 2010
    Messages:
    691
    Likes Received:
    46
    Vert numbering? 1 top left 2 top right, 3 bottom left, 4 bottom right?
     
  16. feels3

    feels3 Member Staff Member

    Joined:
    Sep 4, 2011
    Messages:
    1,201
    Likes Received:
    142
    Yes, I did correct vert numbering.

    I did few more tests and each time tree is huge.
     
  17. Mario Morais

    Mario Morais Registered

    Joined:
    Oct 26, 2010
    Messages:
    1,465
    Likes Received:
    169
    I thing is the other side.
    Z(red) local axis is the side of the face. rotate the quad by 180º and you see the triangulate is wrong.
     
  18. feels3

    feels3 Member Staff Member

    Joined:
    Sep 4, 2011
    Messages:
    1,201
    Likes Received:
    142
    I tried and still nothing.

    Wrong triangulation changes only texture direction but tree is each time in huge scale.
     
  19. ethone

    ethone Registered

    Joined:
    Nov 30, 2011
    Messages:
    1,153
    Likes Received:
    37
    Can we presume you tried reset xform?
     
  20. mianiak

    mianiak Registered

    Joined:
    Oct 5, 2010
    Messages:
    691
    Likes Received:
    46
    I couldn't understand this right, did you flip the face to change the triangulation? Flipping the face doesn't fix the vert numbering. In poly submode, use edit triangulation or turn.

    Anyway, it would be much easier to find the issue if you could upload the model.

    Start a new project, import > merge > select your project and open it, then in the selection box, select the tree, click ok.
    Open material editor, use eye dropper, get the material from the tree and delete any submats not being used by the tree.
    Then save the project, zip it up and attach it to a post in here. You don't need the texture, just the max file.
     

Share This Page