Changeset 54828 in vbox
- Timestamp:
- Mar 18, 2015 11:43:37 AM (10 years ago)
- svn:sync-xref-src-repo-rev:
- 99030
- Location:
- trunk/src/VBox
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VBoxSDL/Framebuffer.cpp
r52574 r54828 337 337 } 338 338 339 STDMETHODIMP VBoxSDLFB::COMGETTER(PixelFormat) ( ULONG*pixelFormat)339 STDMETHODIMP VBoxSDLFB::COMGETTER(PixelFormat) (BitmapFormat_T *pixelFormat) 340 340 { 341 341 if (!pixelFormat) … … 656 656 ULONG ulBitsPerPixel = 0; 657 657 ULONG ulBytesPerLine = 0; 658 ULONG ulPixelFormat = 0;658 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 659 659 660 660 mpSourceBitmap->QueryBitmapInfo(&pAddress, … … 663 663 &ulBitsPerPixel, 664 664 &ulBytesPerLine, 665 & ulPixelFormat);665 &bitmapFormat); 666 666 667 667 if ( mGuestXRes == ulWidth -
trunk/src/VBox/Frontends/VBoxSDL/Framebuffer.h
r52574 r54828 76 76 STDMETHOD(COMGETTER(BitsPerPixel))(ULONG *bitsPerPixel); 77 77 STDMETHOD(COMGETTER(BytesPerLine))(ULONG *bytesPerLine); 78 STDMETHOD(COMGETTER(PixelFormat)) ( ULONG*pixelFormat);78 STDMETHOD(COMGETTER(PixelFormat)) (BitmapFormat_T *pixelFormat); 79 79 STDMETHOD(COMGETTER(HeightReduction)) (ULONG *heightReduction); 80 80 STDMETHOD(COMGETTER(Overlay)) (IFramebufferOverlay **aOverlay); -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIFrameBuffer.cpp
r54805 r54828 181 181 STDMETHOD(COMGETTER(BitsPerPixel))(ULONG *puBitsPerPixel); 182 182 STDMETHOD(COMGETTER(BytesPerLine))(ULONG *puBytesPerLine); 183 STDMETHOD(COMGETTER(PixelFormat))( ULONG*puPixelFormat);183 STDMETHOD(COMGETTER(PixelFormat))(BitmapFormat_T *puPixelFormat); 184 184 STDMETHOD(COMGETTER(HeightReduction))(ULONG *puHeightReduction); 185 185 STDMETHOD(COMGETTER(Overlay))(IFramebufferOverlay **ppOverlay); … … 658 658 } 659 659 660 STDMETHODIMP UIFrameBufferPrivate::COMGETTER(PixelFormat)( ULONG*puPixelFormat)660 STDMETHODIMP UIFrameBufferPrivate::COMGETTER(PixelFormat)(BitmapFormat_T *puPixelFormat) 661 661 { 662 662 if (!puPixelFormat) 663 663 return E_POINTER; 664 *puPixelFormat = pixelFormat();664 *puPixelFormat = (BitmapFormat_T)pixelFormat(); 665 665 return S_OK; 666 666 } … … 1181 1181 ULONG ulBitsPerPixel = 0; 1182 1182 ULONG ulBytesPerLine = 0; 1183 ULONG ulPixelFormat = 0;1183 KBitmapFormat bitmapFormat = KBitmapFormat_Opaque; 1184 1184 m_sourceBitmap.QueryBitmapInfo(pAddress, 1185 1185 ulWidth, … … 1187 1187 ulBitsPerPixel, 1188 1188 ulBytesPerLine, 1189 ulPixelFormat);1189 bitmapFormat); 1190 1190 Assert(ulBitsPerPixel == 32); 1191 1191 -
trunk/src/VBox/Main/idl/VirtualBox.xidl
r54809 r54828 1330 1330 <enum 1331 1331 name="BitmapFormat" 1332 uuid=" 2526302a-cd88-4491-8637-ae50b9804fbc"1332 uuid="afb2bf39-8b1e-4f9f-8948-d1b887f83eb0" 1333 1333 > 1334 1334 <desc> … … 1345 1345 <const name="BGR" value="0x20524742"> 1346 1346 <desc> 1347 Generic BGR format. Pixel layout depends on the number of bits per pixel. 1347 Generic BGR format without alpha channel. 1348 Pixel layout depends on the number of bits per pixel: 1349 <ul> 1350 <li> 1351 <b>32</b> - bits 31:24 undefined, bits 23:16 R, bits 15:8 G, bits 7:0 B. 1352 </li> 1353 1354 <li> 1355 <b>16</b> - bits 15:11 R, bits 10:5 G, bits 4:0 B. 1356 </li> 1357 </ul> 1348 1358 </desc> 1349 1359 </const> … … 1366 1376 <desc> 1367 1377 PNG image. 1378 </desc> 1379 </const> 1380 <const name="JPEG" value="0x4745504A"> 1381 <desc> 1382 JPEG image. 1368 1383 </desc> 1369 1384 </const> … … 15506 15521 <interface 15507 15522 name="IDisplaySourceBitmap" extends="$unknown" wsmap="suppress" 15508 uuid=" b00907f7-d85e-4dce-b1a6-16a2d91b0269"15523 uuid="0b78daeb-f52f-43b9-99e8-4a3c226cbe2d" 15509 15524 > 15510 15525 <attribute name="screenId" type="unsigned long" readonly="yes"/> … … 15516 15531 <param name="bitsPerPixel" type="unsigned long" dir="out"/> 15517 15532 <param name="bytesPerLine" type="unsigned long" dir="out"/> 15518 <param name=" pixelFormat" type="unsigned long" dir="out"/>15533 <param name="bitmapFormat" type="BitmapFormat" dir="out"/> 15519 15534 </method> 15520 15535 … … 15550 15565 <interface 15551 15566 name="IFramebuffer" extends="$unknown" 15552 uuid=" 735365aa-544d-415c-a25b-a5ea913d63f3"15567 uuid="dd07f843-be2e-4cae-83fe-8bf5d33c80e9" 15553 15568 wsmap="managed" 15554 15569 > … … 15573 15588 </attribute> 15574 15589 15575 <attribute name="pixelFormat" type=" unsigned long" readonly="yes">15590 <attribute name="pixelFormat" type="BitmapFormat" readonly="yes"> 15576 15591 <desc> 15577 15592 Frame buffer pixel format. It's one of the values defined by <link -
trunk/src/VBox/Main/include/DisplayImpl.h
r54582 r54828 532 532 ULONG *aBitsPerPixel, 533 533 ULONG *aBytesPerLine, 534 ULONG *aPixelFormat);534 BitmapFormat_T *aBitmapFormat); 535 535 536 536 int initSourceBitmap(unsigned aScreenId, DISPLAYFBINFO *pFBInfo); … … 549 549 ULONG ulBitsPerPixel; 550 550 ULONG ulBytesPerLine; 551 ULONG ulPixelFormat;551 BitmapFormat_T bitmapFormat; 552 552 }; 553 553 -
trunk/src/VBox/Main/src-client/ConsoleVRDPServer.cpp
r54231 r54828 1097 1097 ULONG ulBitsPerPixel = 0; 1098 1098 ULONG ulBytesPerLine = 0; 1099 ULONG ulPixelFormat = 0;1099 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 1100 1100 1101 1101 hr = server->maSourceBitmaps[uScreenId]->QueryBitmapInfo(&pAddress, … … 1104 1104 &ulBitsPerPixel, 1105 1105 &ulBytesPerLine, 1106 & ulPixelFormat);1106 &bitmapFormat); 1107 1107 1108 1108 if (SUCCEEDED(hr)) -
trunk/src/VBox/Main/src-client/DisplayImpl.cpp
r54616 r54828 933 933 ULONG ulBitsPerPixel = 0; 934 934 ULONG ulBytesPerLine = 0; 935 ULONG ulPixelFormat = 0;935 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 936 936 937 937 hr = pSourceBitmap->QueryBitmapInfo(&pAddress, … … 940 940 &ulBitsPerPixel, 941 941 &ulBytesPerLine, 942 & ulPixelFormat);942 &bitmapFormat); 943 943 if (SUCCEEDED(hr)) 944 944 { … … 2407 2407 ULONG ulBitsPerPixel = 0; 2408 2408 ULONG ulBytesPerLine = 0; 2409 ULONG ulPixelFormat = 0;2409 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 2410 2410 2411 2411 HRESULT hrc = pFBInfo->pSourceBitmap->QueryBitmapInfo(&pAddress, … … 2414 2414 &ulBitsPerPixel, 2415 2415 &ulBytesPerLine, 2416 & ulPixelFormat);2416 &bitmapFormat); 2417 2417 if (SUCCEEDED(hrc)) 2418 2418 { … … 2546 2546 ULONG ulBitsPerPixel = 0; 2547 2547 ULONG ulBytesPerLine = 0; 2548 ULONG ulPixelFormat = 0;2548 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 2549 2549 2550 2550 HRESULT hrc = pFBInfo->pSourceBitmap->QueryBitmapInfo(&pAddress, … … 2553 2553 &ulBitsPerPixel, 2554 2554 &ulBytesPerLine, 2555 & ulPixelFormat);2555 &bitmapFormat); 2556 2556 if (SUCCEEDED(hrc)) 2557 2557 { … … 2758 2758 ULONG ulBitsPerPixel = 0; 2759 2759 ULONG ulBytesPerLine = 0; 2760 ULONG ulPixelFormat = 0;2760 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 2761 2761 2762 2762 obj->QueryBitmapInfo(&pAddress, … … 2765 2765 &ulBitsPerPixel, 2766 2766 &ulBytesPerLine, 2767 & ulPixelFormat);2767 &bitmapFormat); 2768 2768 2769 2769 mpDrv->IConnector.pu8Data = pAddress; … … 3785 3785 ULONG ulBitsPerPixel = 0; 3786 3786 ULONG ulBytesPerLine = 0; 3787 ULONG ulPixelFormat = 0;3787 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 3788 3788 3789 3789 HRESULT hrc = pFBInfo->pSourceBitmap->QueryBitmapInfo(&pAddress, … … 3792 3792 &ulBitsPerPixel, 3793 3793 &ulBytesPerLine, 3794 & ulPixelFormat);3794 &bitmapFormat); 3795 3795 if (SUCCEEDED(hrc)) 3796 3796 { -
trunk/src/VBox/Main/src-client/DisplaySourceBitmapImpl.cpp
r51436 r54828 58 58 m.ulBitsPerPixel = 0; 59 59 m.ulBytesPerLine = 0; 60 m. ulPixelFormat = 0;60 m.bitmapFormat = BitmapFormat_Opaque; 61 61 62 62 int rc = initSourceBitmap(uScreenId, pFBInfo); … … 100 100 ULONG *aBitsPerPixel, 101 101 ULONG *aBytesPerLine, 102 ULONG *aPixelFormat)102 BitmapFormat_T *aBitmapFormat) 103 103 { 104 104 HRESULT hr = S_OK; … … 110 110 *aBitsPerPixel = m.ulBitsPerPixel; 111 111 *aBytesPerLine = m.ulBytesPerLine; 112 *a PixelFormat = m.ulPixelFormat;112 *aBitmapFormat = m.bitmapFormat; 113 113 114 114 return hr; … … 130 130 ULONG ulBitsPerPixel = 0; 131 131 ULONG ulBytesPerLine = 0; 132 ULONG ulPixelFormat = 0;132 BitmapFormat_T bitmapFormat = BitmapFormat_Opaque; 133 133 134 134 if (pFBInfo->pu8FramebufferVRAM && pFBInfo->u16BitsPerPixel == 32) … … 141 141 ulBitsPerPixel = pFBInfo->u16BitsPerPixel; 142 142 ulBytesPerLine = pFBInfo->u32LineSize; 143 ulPixelFormat = 0;143 bitmapFormat = BitmapFormat_BGR; 144 144 m.pu8Allocated = NULL; 145 145 } … … 153 153 ulBitsPerPixel = 32; 154 154 ulBytesPerLine = ulWidth * 4; 155 ulPixelFormat = 0;155 bitmapFormat = BitmapFormat_BGR; 156 156 157 157 m.pu8Allocated = (uint8_t *)RTMemAlloc(ulBytesPerLine * ulHeight); … … 173 173 m.ulBitsPerPixel = ulBitsPerPixel; 174 174 m.ulBytesPerLine = ulBytesPerLine; 175 m. ulPixelFormat = ulPixelFormat;175 m.bitmapFormat = bitmapFormat; 176 176 } 177 177
Note:
See TracChangeset
for help on using the changeset viewer.