Lighting problem in deferred rendering

Started by
13 comments, last by Zaoshi Kaba 9 years, 9 months ago

Awesome!

Im afraid my knowledge of matrices is very limited, maybe someone with a better overview of the concept can help you. I wouldnt want to pass wrong information to you.

-MIGI0027

FastCall22: "I want to make the distinction that my laptop is a whore-box that connects to different network"

Blog about... stuff (GDNet, WordPress): www.gamedev.net/blog/1882-the-cuboid-zone/, cuboidzone.wordpress.com/

Advertisement

Ok smile.png thanks for your help, you put me on the line.

if somebody knows for the matrices !...

Without going into theory/details: when it comes to matrices A * B != B * A. If your matrix is different (row vs column) then multiplication order is reversed, you can also reverse it by transposing all matrices.

Ok but here I perform the multiplication in the same order, with the same matrix but transposed once and the other time not transposed, so I don't understand why it works here and with the same processing not ?


// these two are equivalent
output.RTposition = mul( input.position, transposedView ); // transposing reverses order
output.RTposition = mul( view, input.position ); // judging by your projViewWorld matrix this is correct order

// if those lines are correct, then this one is wrong order
output.RTnormal = mul( input.normal, view );

This topic is closed to new replies.

Advertisement