Welcome to WebmasterWorld Guest from

Forum Moderators: not2easy

Message Too Old, No Replies

Performance, Pixels and Quality of image

iterating through pixels via autoCad .net api



10:23 pm on Apr 3, 2008 (gmt 0)

5+ Year Member

Hello: I'm currently developing software with AutoCad and .net apis.
At the moment, I'm working on a piece where the user selects a black and white bmp and the script loops through all the pixels and draws a point where the pixel is black.

The problem is is that it's loading really slow. I've researched this via .net and feel that I have done everything possible to maximize performance of my code; therefore, I would like to know if there's a way to reformat and or save my bitmap w/out compromizing the quality and cause the size to be smaller? - probably not...but I would like to know from people who work with graphics.

Thank you for your help,


7:44 am on Apr 4, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

What kind of content does the image have? For example if you took a screenshot of this forum and saved as .gif it will produce perfect reproduction and at a very small file size assuming you have the proper software with the correct settings. Rough guess would be 100X smaller in file size comaped to .BMP

The reason is that that this page has very little color and doesn't have any gradients like shadows. Most of it is large contiguous blocks of color. Aside from the logo up in the left there probably isn't much more that 25 colors, take the logo out and you could even reduce the file size more by reducing the 256 color pallet to what is needed.

gif is only 256 colors so if your image requires more it won't reproduce perfectly.


4:36 pm on Apr 4, 2008 (gmt 0)

5+ Year Member

Thanks for the response. I believe all the images will have very little color; in fact, we could save a black and white...because color is unimportant. I'm guessing - from what you're saying that this would really help speed things up?

thanks again for the response.


3:20 am on Apr 5, 2008 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member

Certainly speed it up if they have to download the image. just as quick sample I took screenshot of this page. This includes the title bar and the task bar which is going to add quite a bit to the overall size because of the varying colors, comes out to about 144K using the best settings I have which aren't even necessary for images with large blocks of color, sizes will vary with .gif depending on the content but large blocks of single colors make relatively small images.

The .bmp comes in about 3.5 MB. Both at resolution of 1280x960. It's not just a little savings but a lot of savings.


Featured Threads

Hot Threads This Week

Hot Threads This Month