Inverting position of the camera

I have some shapes in my program that I need to put inside an ofEasyCam.

The shapes without a camera when drawn to the screen appear fine but as soon as put I them side cam.begin() - cam.end(), the shapes become inverted vertically. The camera also translates the position of the origin to the center but that’s solvable.

How do I get my objects straight as they would have drawn normally on screen (when there would be no cam)? I feel inverting the camera itself somehow to make the objects look straight is a better to do than to apply 4x4 matrix multiplication to all the objects inside, but I am not sure how to go about achieving that with the camera (ofEasyCam)

try this

  
camera.begin();  
	ofScale(1, -1, 1);  
//your stuff here  
camera.end();  

I already did that and I get exact results that I want with setScale(-1, -1, 1); However, the X-axis gets inverted.
When I do setScale(1,-1,1) , some things in my application that are drawn on the screen get messed up and I have not been able to figure out a reason. Is there any way, I could meddle with Y-axis part for the inversion and not touch X-axis as in setScale.

Just to tell, what’s happening if I do setScale(1,-1,1);
I am using Arcball example here: https://sites.google.com/site/ofauckland/examples/12-textured-sphere-example

The draw method in my application is:

  
  
void draw(){  
ofPushMatrix();  
  
        ofRotateX(-90);  
        //ofRotateY(90);  
  
        //Sphere light image  
        ofPushStyle();  
        glEnable(GL_CULL_FACE);  
        glCullFace(GL_FRONT);  
        ofSetColor(255,255,255);  
        sphereImage.getTextureReference().bind();  
        gluSphere(quadric, 300, 100, 100);  
        ofPopStyle();  
        sphereImage.unbind();  
  
        //Sphere dark image  
  
        ofPushStyle();  
        ofSetColor(0,0,128);  
        sphereImage.getTextureReference().bind();  
        gluSphere(quadric, 298, 100, 100);  
  
        glCullFace(GL_BACK);  
        gluSphere(quadric, 298, 100, 100);  
        ofPopStyle();  
  
        //Sphere light image  
        ofPushStyle();  
        ofSetColor(255,255,255);  
        sphereImage.getTextureReference().bind();  
        gluSphere(quadric, 300, 100, 100);  
        ofPopStyle();  
        sphereImage.unbind();  
        glDisable(GL_CULL_FACE);  
  
        ofPopMatrix();  
}  
  

The internal sphere disappears when I do setScale(1,-1,1);
Any ideas?

this might be due to culling. i believe negative scaling flips the order of vertices so a front face is now a back face. if you swap glCullFace(GL_FRONT) with glCullFace(GL_BACK) it should work.