flat assembler
Message board for the users of flat assembler.

Index > Windows > How write stream in file?

Author
Thread Post new topic Reply to topic
Hellok



Joined: 24 Sep 2020
Posts: 3
Hellok
I am try use GDI+
I am need write my image to tmp file.
How I can use 'GdipSaveImageToStream' function to write image to file?

1) I am need create tmp file
2) I am need to write there image

I use

invoke GdipSaveImageToStream,[gdip_bitmap],?????,encoder_clsid,NULL

what I am need to insert instead of ?????. A handle of opened file?

P.S. function 'GdipSaveImageToFile' not suit for me, because it need file as constant.
Post 15 Oct 2020, 19:25
View user's profile Send private message Reply with quote
DimonSoft



Joined: 03 Mar 2010
Posts: 1006
Location: Belarus
DimonSoft
Hellok wrote:
P.S. function 'GdipSaveImageToFile' not suit for me, because it need file as constant.

AFAICT, it just promises not to change the string passed. Calculated pathname might work well. Unless you want to write the image data only as part of the temporary file (among other stuff), retrieving an IStream pointer from somewhere looks like an unnecessary overhead.
Post 15 Oct 2020, 20:46
View user's profile Send private message Visit poster's website Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2020, Tomasz Grysztar. Also on GitHub, YouTube, Twitter.

Website powered by rwasa.