[Mojo2] How to rotate a canvas as to achieve mode7-like effect?

PixelPaladin

New member
CX Code Contributor
3rd Party Module Dev
Joined
Aug 27, 2017
Messages
110
A mode7 like effect is not possible with just a matrix rotation. The matrix used by mojo is an affine transformation matrix. What SNES did was applying the matrix for each scan line. This means that you need to draw a part of your ground image for each scan line which can result in a slowdown for high resolutions. So the better / more elegant way to achieve this effect would be to write a mode7 shader.
 

nullterm

New member
Joined
Jun 21, 2017
Messages
20
Yeah you need a shader, either doing 3D vertex transforms (easiest) or mapping screen coordinates back thru 3D space to texture coordinates (harder).

Or go full OpenGL and write your own rendering pipeline and shaders.
 
Top Bottom