12/11/2023 0 Comments Purebasic import jpgMy goal is to create a more decent resource compiler mixing the tools existent in Bome Restorator, Reshacker, Resource Tuner and RosAsm´s Form Wizard. I can´t dedicate too much time on this editor right now, because i´m fixing several issues in RosAsm resources routines 1st. I did a iconeditor dll already, but it is only for 16 colors yet and it is still somewhat limited. So i can try to understand better how to properçly handle icons inside a executable (For RosAsm resource editor, i mean). I´m currently working on this example to give a test: I used to play with it a long time ago to create or edit icons, but now all i need is understand what are the standard sizes that windows can handle on icons inside a executable file (or a dll) and how to use gdiplus to manipulate it´s pixels, convert a bmp, png etc to icon (and vice-versa) and also keep the transparency and ability to handle the different formats inside the same icon (either a. So is there a limitation of the icon sizes and formats ? (i suppose, they always must remains squared, right ?)Īlso, using diplus it is said to we get the HIcon to create the proper transparent background when converting it to bitmap, as in:īut.how to create the proper hcion from an ".ico" file loaded ? And what will happens if the ".ico" file contains more then 1 icon format ? Can i use LoadImageA for this purpose or i can use gdiplus to an alternate way to load and convert this ?Īnd also.later, once this icon isseu ios fixed or created, can this be done on the same way with cursors or cursors works completely different ?Ĭall BmpDrawToDC eax, 'USER32.EndPaint' BmpDrawToDC:Ĭall 'GDI32.CreateCompatibleDC' | mov eaxĬall 'GDI32.SelectObject' 'User32.GetClientRect' 'GDI32.BitBlt' 0, 0, 0, 0, &SRCCOPYĬall 'GDI32.RestoreDC' 'GDI32.DeleteDC' Steve. This is a slightly modified version of ] task.Ī simple "C" function add_n in add_n.I already suceeded to import images in many formats using gdi+ and also grabbing their pixel data, formats etc and export to webp, png, tiff, bmp etc using Marinus and JJ´s techniquesġ - Load an icon file (including icons that have more then 1 format/size)Ģ - Get their contents (pixeldata and also the transparency mask if existent)ģ - Show it on screen, and with it´s contents, place them on the proper Resources section to create the RT_ICON and related RT_GROUP_ICON structures.Ĥ - Export it back as icon (and whatever other formats as well)įrom M$ is said that icons have fixed sizes and bpps, so only allowing formats such as:īut.i already saw icons in formats such as 72x72. Works on Linux with GNU gcc and gfortran 5.1.1 LDoSomething := GetProcAddress(lLibraryHandle, 'DoSomething') LLibraryHandle := LoadLibrary('MYLIB.DLL') procedure DoSomething external 'MYLIB.DLL' delayed Loads library on first call to DoSomething. procedure DoSomething external 'MYLIB.DLL' Import std.stdio, std.c.windows.windows Įxtern ( Windows ) UINT GetDoubleClickTime() : string #+sbcl (sb - posix:getenv "DISPLAY" ) CL-USER> (cffi: load - foreign - library "libX11.so" )ĬL-USER> (cffi:foreign - funcall "XOpenDisplay" If you want to help to improve and eventually enable this page, Incorrect code, conceptual problems, or other severe issues. This means it might contain formatting issues,
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |