| 31 | // ---------------------------------------------------------------------------------------------------- |
| 32 | |
| 33 | void Gear::draw() |
| 34 | { |
| 35 | if( ! mImageTex ) |
| 36 | return; |
| 37 | |
| 38 | float pointsPerMeter = SceneController::getPointsPerMeter(); |
| 39 | |
| 40 | Rectf imageDest( - mRadius, - mRadius, mRadius, mRadius ); |
| 41 | |
| 42 | vec2 pos = vec2( mBody->GetPosition().x, mBody->GetPosition().y ) * pointsPerMeter; |
| 43 | float t = mBody->GetAngle(); |
| 44 | |
| 45 | gl::ScopedModelMatrix modelScope; |
| 46 | gl::translate( pos ); |
| 47 | gl::rotate( t ); |
| 48 | gl::draw( mImageTex, imageDest ); |
| 49 | } |
| 50 | |
| 51 | // ---------------------------------------------------------------------------------------------------- |
| 52 | // MARK: - Wall |
nothing calls this directly
no test coverage detected