This site is no longer active and is available for archival purposes only. Registration and login is disabled.

EasyCE Bugs to be aware of!


EasyCE Bugs to be aware of!

Postby brendan » Jan 31, 2003 @ 3:20am

User avatar
brendan
pm Insider
 
Posts: 451
Joined: Oct 23, 2001 @ 2:51am
Location: Hobart, Australia


Postby Jim » Feb 1, 2003 @ 11:53pm

a better method might be to preprocess the targa file to the foramt you want then use them as resources, no buffer needed then or file loading.

cheers
jim.
User avatar
Jim
pm Member
 
Posts: 97
Joined: Feb 8, 2002 @ 5:03pm
Location: London


Postby brendan » Feb 2, 2003 @ 12:07am

User avatar
brendan
pm Insider
 
Posts: 451
Joined: Oct 23, 2001 @ 2:51am
Location: Hobart, Australia


About resources

Postby golan_trevize_x » Feb 2, 2003 @ 8:20am

Jim,

Just wanted to ask about what you mentioned - using resources. How is it done in eVC++? I once gave it a go a while back, but had a lot of trouble making it work.

eg. Say I have a gzipped file. Currently in my program, I'm using the gzopen command to open that file, which is stored in a directory along with my program on the PocketPC. Now, there is also a gzopenfrommem function which accepts a const long (presumably a pointer to the memory).

So is there a way I can put my gzipped file into a resource and then make it open this way? The LoadResource function returns a HANDLE, but I'm not sure what to do from there.

Thanks for any help!

Nathan
golan_trevize_x
pm Member
 
Posts: 67
Joined: Nov 23, 2001 @ 7:36pm
Location: Melbourne, Australia


Postby golan_trevize_x » Feb 2, 2003 @ 8:26am

Actually, I can't seem to find the implementation for gzopenfrommem. Maybe it's been taken out in the WindowsCE port of the zlib library that I'm using.
golan_trevize_x
pm Member
 
Posts: 67
Joined: Nov 23, 2001 @ 7:36pm
Location: Melbourne, Australia


Postby golan_trevize_x » Feb 3, 2003 @ 1:52am

Sorry for the triple post here. I have figured out how to read gzip files from a resource loaded into memory. Basically I'm using the slightly lower level function uncompress, which is part of zlib.

For more information about this, there's a thread back in Nov/Dec 2002 you can look at. Just do a search for "zlib" on the forums.

(I had to make my own gzip "format" which begins with two longs, the uncompressed size and the compressed size, followed by the compressed data as a byte stream. I found a DLL implementation of zlib, so was able to create a little program in VB which zips up a file into this simple format.)
golan_trevize_x
pm Member
 
Posts: 67
Joined: Nov 23, 2001 @ 7:36pm
Location: Melbourne, Australia


Postby brendan » Feb 7, 2003 @ 3:40am

User avatar
brendan
pm Insider
 
Posts: 451
Joined: Oct 23, 2001 @ 2:51am
Location: Hobart, Australia


Return to Windows Mobile


Sort


Forum Description

A discussion forum for mobile device developers on the Windows Mobile platform. Any platform specific topics are welcome.

Moderators:

Dan East, sponge, Digby, David Horn, Kevin Gelso, RICoder

Forum permissions

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 post attachments in this forum