images.gdiplus, windows.gdiplus, windows.streams: update for change to with-out-parameters

db4
Joe Groff 2011-08-27 15:53:07 -07:00
parent 9040ee37e0
commit baeb8a45fe
3 changed files with 6 additions and 6 deletions

View File

@ -23,17 +23,17 @@ SINGLETON: gdi+-image
: stream>gdi+-bitmap ( stream -- bitmap ) : stream>gdi+-bitmap ( stream -- bitmap )
stream>IStream &com-release stream>IStream &com-release
{ void* } [ GdipCreateBitmapFromStream check-gdi+-status ] { void* } [ GdipCreateBitmapFromStream check-gdi+-status ]
[ ] with-out-parameters &GdipFree ; with-out-parameters &GdipFree ;
: gdi+-bitmap-width ( bitmap -- w ) : gdi+-bitmap-width ( bitmap -- w )
{ UINT } [ GdipGetImageWidth check-gdi+-status ] { UINT } [ GdipGetImageWidth check-gdi+-status ]
[ ] with-out-parameters ; with-out-parameters ;
: gdi+-bitmap-height ( bitmap -- w ) : gdi+-bitmap-height ( bitmap -- w )
{ UINT } [ GdipGetImageHeight check-gdi+-status ] { UINT } [ GdipGetImageHeight check-gdi+-status ]
[ ] with-out-parameters ; with-out-parameters ;
: gdi+-lock-bitmap ( bitmap rect mode format -- data ) : gdi+-lock-bitmap ( bitmap rect mode format -- data )
{ BitmapData } [ GdipBitmapLockBits check-gdi+-status ] { BitmapData } [ GdipBitmapLockBits check-gdi+-status ]
[ clone ] with-out-parameters ; with-out-parameters ;
:: gdi+-bitmap>data ( bitmap -- w h pixels ) :: gdi+-bitmap>data ( bitmap -- w h pixels )
bitmap [ gdi+-bitmap-width ] [ gdi+-bitmap-height ] bi :> ( w h ) bitmap [ gdi+-bitmap-width ] [ gdi+-bitmap-height ] bi :> ( w h )

View File

@ -1640,7 +1640,7 @@ CONSTANT: standard-gdi+-startup-input
: (start-gdi+) ( startup-input -- token startup-output ) : (start-gdi+) ( startup-input -- token startup-output )
{ ULONG_PTR GdiplusStartupOutput } { ULONG_PTR GdiplusStartupOutput }
[ swapd GdiplusStartup check-gdi+-status ] [ ] with-out-parameters ; [ swapd GdiplusStartup check-gdi+-status ] with-out-parameters ;
: start-gdi+ ( -- token ) : start-gdi+ ( -- token )
standard-gdi+-startup-input (start-gdi+) drop ; inline standard-gdi+-startup-input (start-gdi+) drop ; inline
: stop-gdi+ ( token -- ) : stop-gdi+ ( token -- )

View File

@ -94,7 +94,7 @@ SPECIALIZED-ARRAY: uchar
S_OK S_OK
] with-hresult ; ] with-hresult ;
:: IStream-clone ( out-clone-stream -- hresult ) :: IStream-clone ( stream out-clone-stream -- hresult )
f out-clone-stream 0 void* set-alien-value f out-clone-stream 0 void* set-alien-value
STG_E_INVALIDFUNCTION ; STG_E_INVALIDFUNCTION ;