News:

Masm32 SDK description, downloads and other helpful links
Message to All Guests
NB: Posting URL's See here: Posted URL Change

Main Menu

is it possible to link in data file

Started by daydreamer, May 13, 2020, 05:13:40 AM

Previous topic - Next topic

daydreamer

Maybe Similar to static library,with some tiny proc that LEA to data to be used
Preferably bitmap data, to be read, not the kind of bitmap resource with handle to bitblt it,but pointer so can read data to map?
Maybe load as hex,save as binary options in QE can help?

my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

Vortex

Hello,

You can check this example :

http://masm32.com/board/index.php?topic=4642.msg49923#msg49923

jj2007

invoke FindResource, 0, ResID, RT_RCDATA ; get resource handle
xchg eax, ebx ; hRes
push rv(SizeofResource, 0, ebx) ; size in bytes
invoke LoadResource, 0, ebx ; returns pointer to content in eax


Demo (source & exe attached):
GuiParas equ "Embedded image", w500, h200, icon Lens
include \masm32\MasmBasic\Res\MbGui.asm
Event Paint
  GuiImage 123, fit
GuiEnd


This is the content of the rc file: 123 RCDATA "\\Masm32\\examples\\exampl04\\car\\car.jpg"

hutch--

As long as it is in 32 bit, use the "fda.exe" or "fda32.exe" that comes with masm32 to make an object module.

daydreamer

my none asm creations
https://masm32.com/board/index.php?topic=6937.msg74303#msg74303
I am an Invoker
"An Invoker is a mage who specializes in the manipulation of raw and elemental energies."
Like SIMD coding

TimoVJL

assembler with INCBIN is a good option.

PellesC users have an AddiIn for that, File2Obj
May the source be with you