Changeset 4034 for trunk/src/gdi32/dibsect.cpp
- Timestamp:
- Aug 18, 2000, 8:14:59 PM (25 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/gdi32/dibsect.cpp
r3755 r4034 1 /* $Id: dibsect.cpp,v 1.3 6 2000-06-26 10:27:45sandervl Exp $ */1 /* $Id: dibsect.cpp,v 1.37 2000-08-18 18:14:57 sandervl Exp $ */ 2 2 3 3 /* 4 4 * GDI32 DIB sections 5 5 * 6 * Copyright 1998 Sander van Leeuwen (sandervl@xs4all.nl)6 * Copyright 1998-2000 Sander van Leeuwen (sandervl@xs4all.nl) 7 7 * Copyright 1998 Patrick Haller 8 8 * … … 131 131 132 132 dibinfo.dshSection = handle; 133 dibinfo.dsOffset = 0; // TODO: put the correct value here (if createdibsection with file handle)133 dibinfo.dsOffset = dwOffset; 134 134 135 135 if(iUsage == DIB_PAL_COLORS || pbmi->biBitCount <= 8) … … 555 555 dprintf(("Sync destination dibsection %x (%x)", handle, hdc)); 556 556 557 //todo: rgb 565 to 555 conversion if bpp == 16558 if(GetBitCount() == 16) {559 dprintf(("WARNING: need to convert RGB 565 to RGB 555!!"));560 }561 562 557 BITMAPINFO2 *tmphdr = (BITMAPINFO2 *)malloc(os2bmphdrsize); 563 558 memcpy(tmphdr, pOS2bmp, os2bmphdrsize); … … 582 577 tmphdr); 583 578 } 579 if(dibinfo.dsBitfields[1] == 0x3E0) {//RGB 555? 580 dprintf(("DIBSection::sync: convert RGB 565 to RGB 555")); 581 582 destBuf = GetDIBObject() + nYdest*dibinfo.dsBm.bmWidthBytes; 583 584 if(CPUFeatures & CPUID_MMX) { 585 RGB565to555MMX((WORD *)destBuf, (WORD *)destBuf, (nDestHeight*dibinfo.dsBm.bmWidthBytes)/sizeof(WORD)); 586 } 587 else RGB565to555((WORD *)destBuf, (WORD *)destBuf, (nDestHeight*dibinfo.dsBm.bmWidthBytes)/sizeof(WORD)); 588 } 584 589 free(tmphdr); 585 590 if(rc != nDestHeight) {
Note:
See TracChangeset
for help on using the changeset viewer.