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

Problem loading a larger image


Problem loading a larger image

Postby Slim » Oct 19, 2004 @ 9:47am

Has anybody had any trouble to load a large image with LoadImage(_T(pic.jpg)) of about 300-400 KB and then blit it to screen?

I have tried on different images of different sizes and the limit seems to be around the size mentioned above. The larger images won't load at all and I know that I have enough memory on my device.

Any solution to my problem?

/Slim
Slim
pm Member
 
Posts: 17
Joined: Aug 30, 2004 @ 3:04pm
Location: Sweden


Postby BIGBEN » Oct 19, 2004 @ 10:44am

Be sure to use non-progressive jpeg's.
User avatar
BIGBEN
pm Member
 
Posts: 281
Joined: Mar 18, 2003 @ 10:18pm
Location: Saint-Petersburg, Russia


Postby Kzinti » Oct 19, 2004 @ 2:23pm

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


Postby Slim » Oct 19, 2004 @ 2:40pm

Slim
pm Member
 
Posts: 17
Joined: Aug 30, 2004 @ 3:04pm
Location: Sweden


Postby Slim » Oct 21, 2004 @ 1:35pm

Thierry, I'm not sure if it's the imgdecmp that causes the problem. I tried to debug and the app hangs every time

Surface* surface = new Surface( bitmap.bmWidth, bitmap.bmHeight );

is called. If the width and height are big then the app will hang. Is there a limit to

PHAL::Surface::Create( width, height )?

/Slim
Slim
pm Member
 
Posts: 17
Joined: Aug 30, 2004 @ 3:04pm
Location: Sweden


Postby Slim » Oct 21, 2004 @ 2:14pm

On a second thought, it could be both the imgdecmp.lib and the PHAL::CreateSurface that cause the problems.

If I load a large picture the app hangs at:

HRESULT hr = ::DecompressImageIndirect( &dii );

If I just create a large surface by calling

display->CreateSurface(width, height);

the app hangs at:

PHAL::Surface::Create( width, height )

hmm...
/Slim
Slim
pm Member
 
Posts: 17
Joined: Aug 30, 2004 @ 3:04pm
Location: Sweden


Postby Kzinti » Oct 21, 2004 @ 4:41pm

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


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