Forum Groups
  All forums
    Help & Feedback
      Questions
      Work in progress
      Finished Art
      Non-Max related
    Community
      Offtopic
      News
    Hardware
    Photography


Featured Threads
  inspiration alert!!!
(36 replies)
  Indespensible MaxScripts, Plugins and 3rd Party Tools
(37 replies)
  The allmighty FREE Resources Thread !
(17 replies)
  spam alert!!!
(4886 replies)
  Maxforums member photo gallery index
(114 replies)
  Maxforums Member Tutorials
(89 replies)
  three cheers to maxforums...
(240 replies)
  101 Things you didnt know in Max...
(198 replies)
  A Face tutorial from MDB101 :D
(95 replies)
  Maxforums.org Members Gallery
(516 replies)
  SON OF POST YOURSELF
(637 replies)
  Dub's Maxscript Tutorial Index
(119 replies)

Maxunderground news unavailable

How I check if model's y aix is pointting up using maxscript?
show user profile  Hua*MuLan~
Actually , I have some idear,but I'd like to find some methods that are more convenient.
Every day is a new day

MSN:qq343294964@hotmail.com

read 495 times
3/10/2009 10:45:10 AM (last edit: 3/10/2009 10:45:10 AM)
show user profile  advance-software
See : http://en.wikipedia.org/wiki/Dot_product

[Geometric interpretation section]

a = (0,1,0) - world space up vector.
b = your model's up vector (normalized), in world space.

a.b = cos theta

theta = acos(a.b)

if theta is less than 90 degrees, the model's y axis is pointing up.

If you mean straight up, just grab the model's up vector in world space, normalize it & see if it's (0,1,0) ... theta will be zero in the above calculation.

I don't know maxscript, but that's the maths.
read 489 times
3/10/2009 10:57:23 AM (last edit: 3/10/2009 1:31:59 PM)
show user profile  Hua*MuLan~
Actually , I have some trouble these days becanse someon want me to design a script to check if the scene "+Y = up ". I failed to unstanding what it really mean until now .So my opportunity to a firm work as T.A. also lost . It may mean that Y axis point straight up , I think.
Every day is a new day

MSN:qq343294964@hotmail.com

read 466 times
3/10/2009 11:22:12 AM (last edit: 3/10/2009 11:22:12 AM)
show user profile  Hua*MuLan~
I will have a try to see if I can design a script using the maths method which u give me .thanx
Every day is a new day

MSN:qq343294964@hotmail.com

read 460 times
3/10/2009 11:29:56 AM (last edit: 3/10/2009 11:29:56 AM)
show user profile  Hua*MuLan~
I 'd like to get the position of a vertex in the model's local space . And then transform it into world space .I think if the vertex's Y_axis value(A) in local space has the same sign (all + or all -) with the value(B) in world space , it should point up , and more if B = A + value of model's Y_axis . it should straight up . Am I right?
Every day is a new day

MSN:qq343294964@hotmail.com

read 454 times
3/10/2009 11:48:18 AM (last edit: 3/10/2009 11:48:18 AM)
show user profile  advance-software
No. You need to consider direction vectors, not points.

Consider a triangle laying on the plane y=0 . All the points have y-coordinates of zero.
You cannot deduce from the point data whether the model faces up or down.
You need to consider the transformation matrices & extract out up vectors.

3D maths is a bit tricky. It takes a while to get your head around it, but its not so hard.

read 445 times
3/10/2009 12:10:16 PM (last edit: 3/10/2009 1:40:37 PM)
#Maxforums IRC
Open chat window


Support Maxforums.org