Problems with transform matrix.

General questions about Indigo, the scene format, rendering etc...
Post Reply
7 posts • Page 1 of 1
User avatar
u3dreal
Posts: 346
Joined: Sun Jul 02, 2006 10:36 am

Problems with transform matrix.

Post by u3dreal » Wed Oct 25, 2006 9:04 am

Hi all i'm implementing Instances at the moment
and i'm a bit confused here...

it seems that i need the inverse matrix for the rotations to work correct
and for the scaling i need the normal matrix...

Any ideas Nick ??? Scaling seems to be the wrong way round with invers matrix.. any way to inverse the rotation in Indigo ??
Or could you give me more detail on how the indigo matrix works ??

Image

So far the transform and rotation works good with inverse matrix...

cheers
u3dreal ;)

User avatar
u3dreal
Posts: 346
Joined: Sun Jul 02, 2006 10:36 am

Post by u3dreal » Sat Oct 28, 2006 7:05 am

No help c'mon guys..

this would help everyone..

cheers

u3dreal ;)

User avatar
u3dreal
Posts: 346
Joined: Sun Jul 02, 2006 10:36 am

Post by u3dreal » Sat Oct 28, 2006 9:59 am

I use inverse matrix now and it works perfect with rotation and translation... but scale seems to be
the other way round .. when i scale the object down..indigo renders it bigger...

Any idea Nick ??

cheers

u3dreal ;)

User avatar
OnoSendai
Developer
Posts: 6244
Joined: Sat May 20, 2006 6:16 pm
Location: Wellington, NZ
Contact:

Post by OnoSendai » Sun Oct 29, 2006 6:18 pm

Hmm..
The matrix should be defined in row major order
http://en.wikipedia.org/wiki/Row-major_order

Any scale should be set with the <scale> element.

User avatar
u3dreal
Posts: 346
Joined: Sun Jul 02, 2006 10:36 am

Post by u3dreal » Sun Oct 29, 2006 11:15 pm

Thanks Nick...

i found the rotation is not presented the right way in the normal max matrix you have to extract that first...

Now it works ... :D

Image

But i came up with another question...

Is it necessary to go recalculate the tree for each
instance ?? Couldn't it be reloaded from disk ??

Or does the tree have to be build for every position of the instances ??

cheers

u3dreal ;)

User avatar
OnoSendai
Developer
Posts: 6244
Joined: Sat May 20, 2006 6:16 pm
Location: Wellington, NZ
Contact:

Post by OnoSendai » Sun Oct 29, 2006 11:27 pm

Yes, there is a different tree for each instance, because the verts are stored in world space.
Someday i'll implement proper internal instancing, where the verts are stored in object space. Then the tree and mesh will only be stored once in memory and in the tree cache.

User avatar
psor
1st Place Winner
Posts: 1295
Joined: Sun Jun 25, 2006 1:25 am
Location: Berlin
Contact:

Post by psor » Mon Oct 30, 2006 2:32 am

This is looking promissing u3dreal! And I hope Nick will give us 'real'
instance support in a future version ... hehe. ;D


take care
psor
"The sleeper must awaken"

Post Reply
7 posts • Page 1 of 1

Who is online

Users browsing this forum: No registered users and 14 guests