Hello, I noticed that file.Write was recently updated to allow for PNGs and various other image types to we written.
I wasn't really able to figure out how this can be done though, since file.Write seems to want text content.
I was just wondering how someone should go about writing an image file based on a web image or texture.
Thanks.
You can do this with [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/render/Capture]render.Capture[/url]. Check out the example on that page, it's not [i]exactly[/i] what you want but it's very close.
On the topic though, I have a question myself (to other people): [b]it is possible to save an HDR screenshot format, for example TIFF, after rendering it into an [url=http://wiki.garrysmod.com/page/render/GetSuperFPTex]HDR render target[/url]?[/b]
Use [url]http://wiki.garrysmod.com/page/file/Open[/url] with wb mode. Then [url]http://wiki.garrysmod.com/page/File/Write[/url]. File objects can also be used to read/write raw data types too.
Sorry, you need to Log In to post a reply to this thread.