ofRotate() question

Hi, I don’t understand why ofRotate(45, 0, 0, 0); rotates the object around the x-axis.
Here’s my test code.

void ofApp::draw(){

    ofSetColor(ofColor::red);
    ofTranslate(100, 100);
    ofRotate(45, 0, 0, 0);
    ofDrawRectangle(0, 0, 100, 100);
}

And this is the result I get.

Shouldn’t it not rotate at all since x,y,z is all set to 0?
It seems there’s no difference even if I change the value of ‘x’ to 1.

Is this a bug? I’m using OF 0.9.8 on Mac OSX.
Thanks in advance!

I believe ofRotate() calls glRotatef(), so this might be defined inside openGL.

If the rotation axis is of length 0, I would say the result is undefined (what did the user mean?). It’s something that should not happen.

My feeling is that if you expect this to happen, you should check for this condition in your code before calling ofRotate(). Checking if this happens inside OF for every call to rotate would make it slower, and not every user needs that check. It is common, and sometimes required, to use normalized vectors (length=1.0) for such operations.