Parallax effect

All topics about ZGameEditor goes here.

Moderator: Moderators

Post Reply
User avatar
jonaspm
Posts: 89
Joined: Fri Jul 06, 2012 3:51 pm
Contact:

Parallax effect

Post by jonaspm »

Hello everybody! long time since my last visit... sorry :S school!

Well, i come now to ask you if anyone know how to create a parallax effect in ZGE?

I think it's easy right? just place the 2D or 3D elements i want in their right position and change the Z value... right?

Thanks in advance to everyone!
User avatar
Kjell
Posts: 1883
Joined: Sat Feb 23, 2008 11:15 pm

Re: Parallax effect

Post by Kjell »

Hi jonaspm,
jonaspm wrote:just place the 2D or 3D elements i want in their right position and change the Z value... right?
Correct. As long as you use a perspective camera, you automatically get a parallax effect between elements that are placed at varying depths.

However, in case you want to use a orthographic camera you need to calculate / control the parallax effect yourself. Attached is a simple ( but clumsy ) example of that principle.

K
Attachments
Parallax.zgeproj
(45.38 KiB) Downloaded 398 times
User avatar
jonaspm
Posts: 89
Joined: Fri Jul 06, 2012 3:51 pm
Contact:

Post by jonaspm »

thanks Kjell! nice example!!!

thanks for your valuable help :)
Post Reply