我知道GDI位图是图形设备接口,DIB是设备无关位图,但是偶不知道本质的区别。
请高手详细指教,小弟不才,多谢!!!

解决方案 »

  1.   

    Read my book, read my book, read my book.1) DDB is device dependent. One device may know it, another device may not know it. DIB is public format, everyone can access it.2) DDB image data is hidden by device driver, normally stored in kernel mode, could be stored on display card. DIB is stored in user mode memory when loaded into memory.3) DDB consumes kernel mode memory, which has low limit.4) DDB costs on GDI handle, another GDI handle for memory.5) DDB can be writtend to through a memory DC. GDI does not support rendering into a DIB, only from.6) You have more formats control over DIB....Do not use DDB unless you want to display the same bitmap over and over again, and performance is critical; or you want to do something special with 1-bit per pixel DDB.