PC Review
Forums
Newsgroups
Microsoft DotNet
Microsoft Dot NET Compact Framework
bmp = new Bitmap(FilePath); and OOM CF 2.0
Forums
Newsgroups
Microsoft DotNet
Microsoft Dot NET Compact Framework
bmp = new Bitmap(FilePath); and OOM CF 2.0
![]() |
bmp = new Bitmap(FilePath); and OOM CF 2.0 |
|
|
Thread Tools | Rate Thread |
|
|
#1 |
|
Guest
Posts: n/a
|
I have an ICOP board that has 128 onboard RAM.
When I call bmp = new Bitmap(FilePath); and the jpg that it is loading is over 500K I get an out of Memory error. I can load this larger jpg using ImageViewer or browing to it with IE without errors. This happens in debug mode and when I create a release build and run the exe directly on the device Why is this happening? Any suggestions on fixing this? I tried GC.Collect() before loading the bmp and that did not help. |
|
|
|
#2 |
|
Guest
Posts: n/a
|
500K JPEG can easily take out all available virtual memory (which is limited
to 32 Mb on CE) while uncompressed. Please make sure _uncompressed_ size is not too big. Also please make sure you're disposing of all bitmaps after use before loading new images. -- Best regards, Ilya This posting is provided "AS IS" with no warranties, and confers no rights. *** Want to find answers instantly? Here's how... *** 1. Go to http://groups-beta.google.com/group...framework?hl=en 2. Type your question in the text box near "Search this group" button. 3. Hit "Search this group" button. 4. Read answer(s). "Tomppa" <tomppa@g-m-a-i-l.com> wrote in message news:uikiMLzGGHA.3532@TK2MSFTNGP14.phx.gbl... >I have an ICOP board that has 128 onboard RAM. > > When I call bmp = new Bitmap(FilePath); and the jpg that it is loading is > over 500K I get an out of Memory error. > > I can load this larger jpg using ImageViewer or browing to it with IE > without errors. > > This happens in debug mode and when I create a release build and run the > exe directly on the device > > Why is this happening? Any suggestions on fixing this? I tried > GC.Collect() before loading the bmp and that did not help. > |
|
![]() |
|
| Thread Tools | |
| Rate This Thread | |
|
|

Main Page 

