Quantcast
Channel: beginners - openFrameworks
Viewing all articles
Browse latest Browse all 4929

ofEasyCam with gui

$
0
0

@pandereto wrote:

Using ofEasyCam find dificult to get precise movements because when the mouse i want to rotate only one axis and is very hard to do, so i thinked using gui parameters to interact with the camera.

I tried using setPosition, setOrientation but with those it do not work the same as with the mouse, i mean to translate and rotate.

What methods i need to implement with gui to mimic mouse interaction?.

I tried this way but not the result i expected… i hope im explaining myself right

    ofQuaternion rotX, rotY, rotZ;
    
    rotX.makeRotate(orientationX, ofVec3f(1,0,0));
    rotY.makeRotate(orientationY, ofVec3f(0,1,0));
    rotZ.makeRotate(orientationZ, ofVec3f(0,0,1));
    
    
    cam.setPosition(posX, posY, posZ);
    //cam.lookAt(ofVec3f(0, 0, 0));
    cam.setOrientation(rotX * rotY * rotZ);

Posts: 1

Participants: 1

Read full topic


Viewing all articles
Browse latest Browse all 4929

Trending Articles