home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.pascal
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!cs.utexas.edu!torn!news.ccs.queensu.ca!mast.queensu.ca!dmurdoch
- From: dmurdoch@mast.queensu.ca (Duncan Murdoch)
- Subject: Re: Raw Data
- Message-ID: <dmurdoch.267.721492484@mast.queensu.ca>
- Lines: 21
- Sender: news@knot.ccs.queensu.ca (Netnews control)
- Organization: Queen's University
- References: <05TqTB1w165w@tsoft.sf-bay.org> <1992Nov6.163908.19859@sbcs.sunysb.edu> <1992Nov11.134914.27768@lth.se>
- Date: Wed, 11 Nov 1992 14:34:44 GMT
-
- In article <1992Nov11.134914.27768@lth.se> d92bo@efd.lth.se (Bengt Oehman) writes:
- >The correct way to handle this is the following:
- >At the DOS-prompt, use BINOBJ to convert binary data into a procedure.
- >eg.
- > "c:\tp>binobj mydata.bin mydata.obj imagedata"
- >
- >where mydata.bin is your binary picture, mydata.obj is the object file to
- >be linked into your program, and imagedata the name of the procedure which
- >contains the data.
-
- That's probably the fastest way to do it, but it's not necessarily the
- best. It takes up RAM all the time, even when you're not using it. It's
- sometimes better to store the data in a resource file, and attach the
- resource file to your .EXE. Then you can load all the images you need on
- to the heap, display them from there in rapid succession, and then delete
- them - so there's no cost in memory when you don't need them. If speed
- wasn't a big concern, you could load them directly from the resource file
- into video ram, but this would probably look pretty ugly.
-
- Duncan Murdoch
- dmurdoch@mast.queensu.ca
-