diff options
author | ulion <ulion@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-12-18 16:37:36 +0000 |
---|---|---|
committer | ulion <ulion@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2007-12-18 16:37:36 +0000 |
commit | dd0e0600275be8377a91aabb72cd28ad542117b7 (patch) | |
tree | 539ae41e11097109e4a52df242e3099cf1942da3 /libvo | |
parent | 5f8a2b37001d47072d1264985a178ce87c0256e4 (diff) | |
download | mpv-dd0e0600275be8377a91aabb72cd28ad542117b7.tar.bz2 mpv-dd0e0600275be8377a91aabb72cd28ad542117b7.tar.xz |
Use NSMakeRect and NSRect in correct way:
The third parameter is width, the fouth parameter is height.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@25452 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r-- | libvo/vo_macosx.m | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libvo/vo_macosx.m b/libvo/vo_macosx.m index 665f825869..1a19bb5580 100644 --- a/libvo/vo_macosx.m +++ b/libvo/vo_macosx.m @@ -693,12 +693,12 @@ static int control(uint32_t request, void *data, ...) if((d_height*aspectX)>(frame.size.height)) { padding = (frame.size.width - d_width*aspectY)/2; - textureFrame = NSMakeRect(padding, 0, d_width*aspectY+padding, d_height*aspectY); + textureFrame = NSMakeRect(padding, 0, d_width*aspectY, d_height*aspectY); } else { padding = ((frame.size.height) - d_height*aspectX)/2; - textureFrame = NSMakeRect(0, padding, d_width*aspectX, d_height*aspectX+padding); + textureFrame = NSMakeRect(0, padding, d_width*aspectX, d_height*aspectX); } } else @@ -723,9 +723,9 @@ static int control(uint32_t request, void *data, ...) glColor3f(1,1,1); glBegin(GL_QUADS); glTexCoord2f(upperLeft[0], upperLeft[1]); glVertex2i( textureFrame.origin.x-(vo_panscan_x >> 1), textureFrame.origin.y-(vo_panscan_y >> 1)); - glTexCoord2f(lowerLeft[0], lowerLeft[1]); glVertex2i( textureFrame.origin.x-(vo_panscan_x >> 1), textureFrame.size.height+(vo_panscan_y >> 1)); - glTexCoord2f(lowerRight[0], lowerRight[1]); glVertex2i( textureFrame.size.width+(vo_panscan_x >> 1), textureFrame.size.height+(vo_panscan_y >> 1)); - glTexCoord2f(upperRight[0], upperRight[1]); glVertex2i( textureFrame.size.width+(vo_panscan_x >> 1), textureFrame.origin.y-(vo_panscan_y >> 1)); + glTexCoord2f(lowerLeft[0], lowerLeft[1]); glVertex2i(textureFrame.origin.x-(vo_panscan_x >> 1), NSMaxY(textureFrame)+(vo_panscan_y >> 1)); + glTexCoord2f(lowerRight[0], lowerRight[1]); glVertex2i(NSMaxX(textureFrame)+(vo_panscan_x >> 1), NSMaxY(textureFrame)+(vo_panscan_y >> 1)); + glTexCoord2f(upperRight[0], upperRight[1]); glVertex2i(NSMaxX(textureFrame)+(vo_panscan_x >> 1), textureFrame.origin.y-(vo_panscan_y >> 1)); glEnd(); glDisable(CVOpenGLTextureGetTarget(texture)); |