Forum: Win32/Win64 API (native code)
Delphi
by Andreas L.,
24. Jan 2013
Mit TBitmap.Dormant := True kann ich jetzt auf das Bild auch außerhalb der GetThumbFromCache-Funktion zugreifen. Leider bekomme ich eine Zugriffsverletzung in der Zeile bs := P1; der procedure FlipBitmap:
Debugger:
P1 $3F00
i 0
j 0
p2 nil
BytesPerLine 256
Forum: Win32/Win64 API (native code)
Delphi
by Andreas L.,
18. Jan 2013
So sieht die Interface-Deklaration aus:
{$EXTERNALSYM ISharedBitmap}
ISharedBitmap = interface(IUnknown)
function GetSharedBitmap(out phbm: HBITMAP): HRESULT; stdcall;
function GetSize(out pSize: TSize): HRESULT; stdcall;
function GetFormat(out pat: WTS_ALPHATYPE): HRESULT; stdcall;
function InitializeBitmap(hbm: HBITMAP; wtsAT: WTS_ALPHATYPE): HRESULT;
Forum: Win32/Win64 API (native code)
Delphi
by Andreas L.,
17. Jan 2013
Hat denn keiner eine Idee?
Forum: Win32/Win64 API (native code)
Delphi
by Andreas L.,
15. Jan 2013
Hi,
ich möchte mit dem Interface IThumbnailCache das gecachte Thumbnail für ein Bild ermitteln. Dazu habe ich folgende Funktion geschrieben:
function GetThumbFromCache(AFileName: string; var hBmp: HBITMAP; AMaxSize: Integer = 120): HRESULT;
var
thumbcache: IThumbnailCache;
sharedbmp: ISharedBitmap;
shellitem: IShellItem;