Shift perspective on a 2D sketch? or if not posible, easily convert to 3D?


#1

Hi,

I got this 2s array grid of sliding circles: https://codepen.io/giorgiomartini/pen/MzGmwW?editors=0010

Its inspired by this poster:


as u can see in the poster, it has perspecive… is there a way to tilt/shift perspective in a 2D sketch, to get this effect?

If not… whats an easy way to convert a 2d sketch like this one to a 3d one where i can tilt the persective?

Thanks


#2

You need to change your renderer to WEBGL to have an 3D environment. Then you can use rotateX(); (https://p5js.org/reference/#/p5/rotateX) to tilt your circles.


#3

Thans Sara! that was an easy fix! :slight_smile: