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

LoadImage(const uint8_t* pBegin, const uint8_t* pEnd )


LoadImage(const uint8_t* pBegin, const uint8_t* pEnd )

Postby BIGBEN » Oct 12, 2004 @ 1:17pm

User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby Kzinti » Oct 12, 2004 @ 4:37pm

Kzinti
pm Member
 
Posts: 3238
Joined: Jan 13, 2002 @ 5:23am


Postby BIGBEN » Oct 12, 2004 @ 5:02pm

User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby BIGBEN » Oct 12, 2004 @ 5:08pm

User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby BIGBEN » Oct 12, 2004 @ 5:13pm

And, of course my in.gif is only 1006 bytes. So buffer [32000] is enogh (and the third variant works, when I use other that doest - they also load not only incomplite image it is also have a wrong pallet)
User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby Kzinti » Oct 12, 2004 @ 5:29pm

Kzinti
pm Member
 
Posts: 3238
Joined: Jan 13, 2002 @ 5:23am


Postby BIGBEN » Oct 12, 2004 @ 5:50pm

:D Yes.
But as I've mentioned above I need to build up one file containing some tile set, for example office.dat.
And then to load images form it (not all but only needed).
Sure to load them I'll need to use this:
inSurf = LoadImage(pDisplay, &buffer[x], &buffer[y] );

Of course now I use the easy one LoadImage( _T("some.gif") ), but I draw now some more tiles, and it would be not only safety, but also useful(some of them less than a 1024 bytes) to store them in one data file.
And please don't say me about intresources or one big surface. :lol:

Have you tested your function:
Surface* LoadImage( const uint8_t* pBegin, const uint8_t* pEnd );
from an image.h file.

If yes, then what code you used for testing and, I suppose, loading an image?
User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby Kzinti » Oct 12, 2004 @ 6:03pm

Kzinti
pm Member
 
Posts: 3238
Joined: Jan 13, 2002 @ 5:23am


Postby BIGBEN » Oct 12, 2004 @ 7:10pm

User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby BIGBEN » Oct 15, 2004 @ 5:26pm

After searching the net about structure of data files I found that it is useful to put my data in one file with a stepoffbits value in the header of the file, for fast access to the real data just from reading the first 16 bits of the header. Everything works perfect. :)
Thank you Thierry for your advice not to use buffering when it is absolutely not necessary )
And BTW, if you like shooters another one is coming, it is an action RPG advanture game. (I'm developing it around a year) It is called !PYROMANIA! and coming soon (I hope) :D
User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby Kzinti » Oct 15, 2004 @ 6:11pm

Kzinti
pm Member
 
Posts: 3238
Joined: Jan 13, 2002 @ 5:23am


Postby Guest » Oct 15, 2004 @ 8:48pm

Guest
 


Postby BIGBEN » Oct 16, 2004 @ 9:07pm

User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Return to PocketFrog & PocketHAL


Sort


Forum Description

SDKs for fast and robust device-independent access to Pocket PC display hardware.

Moderators:

sponge, Kzinti

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

cron