Search found 2 matches
- Sun Jan 12, 2014 5:05 am
- Forum: Programming Discussion
- Topic: Camera rotation problems (SOLVED)
- Replies: 2
- Views: 2801
Re: Camera rotation problems (SOLVED)
I am a fucking moron. This code totally works. I just forgot to scale the textures. I am not a smart man. void CCamera::mapWorldToScreen(COutput & output, float worldX, float worldY, float* screenX, float* screenY) { static float degToRad = 57.29577; float sinAng = sin(rotation/degToRad); float ...
- Sat Jan 11, 2014 6:18 pm
- Forum: Programming Discussion
- Topic: Camera rotation problems (SOLVED)
- Replies: 2
- Views: 2801
Camera rotation problems (SOLVED)
I have been designing/coding a 2D side scroller for a while now. I am now adding the functionality of rotating the camera. I use the below method to get the position of where each game object should be rendered relative to the camera position (posX and posY). void CCamera::mapWorldToScreen(COutput &...