Changeset 23796 in vbox
- Timestamp:
- Oct 15, 2009 12:41:14 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/VBoxFBQuartz2D.cpp
r19817 r23796 52 52 { 53 53 Log (("Quartz2D: Creating\n")); 54 resizeEvent (new VBoxResizeEvent (FramebufferPixelFormat_Opaque, 55 NULL, 0, 0, 640, 480)); 54 55 VBoxResizeEvent event(FramebufferPixelFormat_Opaque, 56 NULL, 0, 0, 640, 480); 57 resizeEvent (&event); 56 58 } 57 59 … … 179 181 CGImageRef subImage; 180 182 if (!mView->pauseShot().isNull()) 181 subImage = CGImageCreateWithImageInRect (::darwinToCGImageRef (&mView->pauseShot()), CGRectMake (mView->contentsX(), mView->contentsY(), mView->visibleWidth(), mView->visibleHeight())); 183 { 184 CGImageRef pauseImg = ::darwinToCGImageRef (&mView->pauseShot()); 185 subImage = CGImageCreateWithImageInRect (pauseImg, CGRectMake (mView->contentsX(), mView->contentsY(), mView->visibleWidth(), mView->visibleHeight())); 186 CGImageRelease (pauseImg); 187 } 182 188 else 183 189 subImage = CGImageCreateWithImageInRect (mImage, CGRectMake (mView->contentsX(), mView->contentsY(), mView->visibleWidth(), mView->visibleHeight())); … … 215 221 CGContextEndTransparencyLayer (ctx); 216 222 #endif 223 CGImageRelease (subImage); 217 224 } 218 225 else … … 226 233 CGImageRef subImage; 227 234 if (!mView->pauseShot().isNull()) 228 subImage = CGImageCreateWithImageInRect (::darwinToCGImageRef (&mView->pauseShot()), ::darwinToCGRect (is)); 235 { 236 CGImageRef pauseImg = ::darwinToCGImageRef (&mView->pauseShot()); 237 subImage = CGImageCreateWithImageInRect (pauseImg, ::darwinToCGRect (is)); 238 CGImageRelease (pauseImg); 239 } 229 240 else 230 241 subImage = CGImageCreateWithImageInRect (mImage, ::darwinToCGRect (is)); … … 247 258 /* At this point draw the real vm image */ 248 259 CGContextDrawImage (ctx, ::darwinFlipCGRect (::darwinToCGRect (ir), viewRect.size.height), subImage); 260 261 CGImageRelease (subImage); 249 262 } 250 263 } … … 276 289 { 277 290 // printf ("VRAM\n"); 278 CGColorSpaceRef cs = CGColorSpaceCreateDeviceRGB();279 291 /* Create the image copy of the framebuffer */ 280 292 CGDataProviderRef dp = CGDataProviderCreateWithData (NULL, aEvent->VRAM(), aEvent->bitsPerPixel() / 8 * mWdt * mHgt, NULL);
Note:
See TracChangeset
for help on using the changeset viewer.