Want to rotate the 3D image of the min3d library on a touch event

I got a sample min3d library sample and sample from google.com.

It works perfectly and even works with a modified image.

Now I want to rotate the .obj file with a touch event, for example, turning the car on a finger touch. Because it uses an animation object in the gl.rotation method, which is hard to understand. I have no idea how to do this, please provide me a solution ..

+6
source share
1 answer

You can add touch events as shown below.

 public boolean onTouchEvent(MotionEvent e) { //Your code goes here return true; } 

If you don’t know how to turn on touch events, you can follow this link https://code.google.com/p/min3d/issues/detail?id=70

0
source

Source: https://habr.com/ru/post/916999/


All Articles