![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
i need to know the size of an image without reading the whole file. any ideas where to start? i assume some p/invoke would be needed :/ i need this because loading whole images into memory takes lots of time. and when you have lets say 300 of them, 6Mpix each it may take ages. |
|
hi, i need to know the size of an image without reading the whole file. any ideas where to start? i assume some p/invoke would be needed :/ i need this because loading whole images into memory takes lots of time. and when you have lets say 300 of them, 6Mpix each it may take ages. |
#3
| |||
| |||
|
|
i need to know the size of an image without reading the whole file. any ideas where to start? i assume some p/invoke would be needed :/ i need this because loading whole images into memory takes lots of time. and when you have lets say 300 of them, 6Mpix each it may take ages. There are many image formats. The size of the image when loaded will only be known after the image has been decoded. This is especially true for any image that is compressed. Until the decoder finishes the decompression, there is no way to know the size of the image. what about shell? explorer is pretty quick when it comes to reading |
#4
| |||
| |||
|
|
what about shell? explorer is pretty quick when it comes to reading image size (and thumbnail). maybe i could use some of the shell32 features? i've seen great thumbnail image extractor (using shell) on vbaccelerator. i thought that there would be some way to use the same technique to obtain only image size. unfortunately my knowledge is rather limited when it comes to shell programming :/ |
|
Michael Phillips, Jr. wrote: i need to know the size of an image without reading the whole file. any ideas where to start? i assume some p/invoke would be needed :/ i need this because loading whole images into memory takes lots of time. and when you have lets say 300 of them, 6Mpix each it may take ages. There are many image formats. The size of the image when loaded will only be known after the image has been decoded. This is especially true for any image that is compressed. Until the decoder finishes the decompression, there is no way to know the size of the image. what about shell? explorer is pretty quick when it comes to reading image size (and thumbnail). maybe i could use some of the shell32 features? i've seen great thumbnail image extractor (using shell) on vbaccelerator. i thought that there would be some way to use the same technique to obtain only image size. unfortunately my knowledge is rather limited when it comes to shell programming :/ |
#5
| |||
| |||
|
|
The image decoder reads the signature first, then the headers and finally the image itself. The headers will reveal the width and height not the size of the image when decoded. now i'm confused. or maybe my original post was confusing :/ the data i |
#6
| |||
| |||
|
|
now i'm confused. or maybe my original post was confusing :/ the data i need is in fact image's width and height. so the question is can it or can not be done in some fast way (ie using shell32)? |
|
Michael Phillips, Jr. wrote: The image decoder reads the signature first, then the headers and finally the image itself. The headers will reveal the width and height not the size of the image when decoded. now i'm confused. or maybe my original post was confusing :/ the data i need is in fact image's width and height. so the question is can it or can not be done in some fast way (ie using shell32)? |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |