Getting file header size and image size

Hi all,
Now that the AVI file type won't work for me, I have to do some of that functionality myself.
I can use the function to Get File Size, and the size is returned in bytes, so far so good.
I figured I could calculate the image size by taking the resolution, multiply X and Y, that gives me the number of pixels.
Then multiply pixels by bit depth, to get the number of bits, divide by 8 for the number of bytes.
Since bit depth is 8, the number of bytes will be exact (and the same as the number of pixels).
When I did the math, and divided by the file size, it didn't come to a round number, and was a larger number than the number of images I could display.
I figured there is probably additional information stored with each image, but I don't know how to adjust for that.
There may be byte clustering happening, making each image larger than the actual byte count would indicate.
And, there is probably file header info, but not sure where to get that.
I looked through the IMAQ functions, and didn't see one about getting the image size (I did see the one that returns resolution, but I have that data already).
Any suggestions on how I can calculate how many images are in my binary file?
And, how to get the byte sizes I need to be able to set the file pointer correctly to get an image out of the middle of the file?
Thank you for any suggestions,
Jeff

If I understand correctly You have binary file with multiple images inside and You want to extract that images?
Depending on image type You can search by tags where image begins and ends: http://www.impulseadventure.com/photo/jpeg-decoder.html and extract.

Similar Messages

  • Cs4 small jpeg file shows as large image size

    Hi I am using Photoshop CS4 and I am trying to downsize images shot from my camera to less than 1 mb, by shifting the quality of the jpeg slider to the left in the save as menu.
    Once I've done that when I open the newly reduced jpeg file again, and I go to the image Size, it shows as 25 Mb,
    This started happening after I reinstalled the Cs4 Creative Suite to my computer.
    What can I do, as when I tried to upload the images, ebay said they were too large, ie the file size of the image didnt get reduced at all.
    Is it possible to fix this as I have reinstalled the software twice, and I still get the same problem,
    thanks

    Is it possible to fix this as I have reinstalled the software twice, and I still get the same problem
    I think the problem is not at all Photoshop’s.
    When you degrade an image by reducing the jpg quality the number of pixels does not change so the uncompressed image (as indicated for the opened file in Photoshop’s Image Size dialog) naturally has the old size.
    What are ebay’s image requirements? Do they mention some maximum width/height in pixels?

  • Resize Video, both the file size and actual size

    Hi All,
    I am very new to Adobe Premiere (CS3). I have had it for a while but not needed to use until now. A client of mine has sent me a video that he wants on his website. But it’s 150M and 1280 * 720. Can anyone help me out with how I can resize both the file size and actual size to say 800 * 450 so it can stream it via the net?
    Like I said very new to this,
    Cheers,
    Mike.

    The first thing you need to do is determine just what KIND of file you were sent, so you may start a project that matches the file
    Read Bill Hunt on a file type as WRAPPER http://forums.adobe.com/thread/440037?tstart=0
    What is a CODEC... a Primer http://forums.adobe.com/thread/546811?tstart=0
    What CODEC is INSIDE that file? http://forums.adobe.com/thread/440037?tstart=0
    I don't do streaming video, so you should search the help file... I **think** what you want out is a Flash file, but that is only after you know what you are going to load into the CS3 timeline

  • Hi there! So I am using Lightroom 3 on a pc and I have ran into an issue when exporting images. The DPI and image size (in inches) that I am selecting during the export process. For example I just exported a collection and set the dpi to 180 and the size

    Hi there! So I am using Lightroom 3 on a pc and I have ran into an issue when exporting images. The DPI and image size (in inches) that I am selecting during the export process. For example I just exported a collection and set the dpi to 180 and the size to 7 inches on the long edge. My exported result is 457 dpi and sized at 3200x2134 pixels.. Any ideas on why this is happening and what I can do to correct it?

    The DPI setting in a digital image has no meaning at all. You need to learn how to calculate what you need in your exported image. The only measurement in a digital image that has any meaning is the number of pixels in each direction. It doesn't matter what you set that DPI to (actually it's PPI or pixels per inch). The image will have the same number of pixels regardless of the setting. If you need an image that is 5 x 7" (for example) at 200 PPI then you would want an image that measured:
    5 x 200 = 1000 pixels
    7 x 200 = 1400 pixels
    So you would need an image that is 1000 x 1400 pixels to have a 5 x 7" image at 200 PPI. The reason your exported image had such a high PPI setting is because you specified the number of inches you wanted the image to be. And there were enough pixels in the image that it calculated out to be that high PPI setting.
    I apologize, I don't explain this very well. But you need to learn to do the math to determine how large you really want your exported images to be.

  • Get the font names and image names in QXD

    Hi,
    How to get the font names and image name in Quarkxpress document file using java?.
    Is any third party packages for getting font n image names in QXD?
    thanks,
    nithya

    rtuck,
    I believe this may solve it:
    Open System Preferences and go to Accessibility. Next, select Display from the source list along the left, then check the box labelled Reduce transparency.
    It was first presented in this post #15 by TheUlser:
    https://forums.adobe.com/message/6854594#6854594

  • DB Size and TAble size Estimation

    Hi all
    Please tell mehelp link or spredsheet to estimation DB Size and TAble size Estimate
    Regards

    Please tell mehelp link or spredsheet to estimation
    DB Size and TAble size EstimateWhat size are you looking for?
    1) Estimate of physical disk space used by an existing database schema?
    2) Estimate of how much physical disk space will be required for some arbitrary data in order to create a new database?
    Something else?
    You need to be clear with your requirements

  • I customize my paper size and print size and am then viewing a photo on my screen. I print it out and it chops off about 5% of all edges of my original photo on the screen. Why does it do that? It is driving me crazy. I use an Epson Photo 2200 printer.

    I customize my paper size and print size and am then viewing a photo on my screen. I print it out and it chops off about 5% of all edges of my original photo on the screen. Why does it do that? It is driving me crazy. I use an Epson Photo 2200 printer

    What print and paper sizes are you using?  Are you trying to print a borderless print?  Does your printer support borderless for that particular size?  Are you printing to the custom stock size or to a larger stock size?
    OT

  • Did Lion's iTunes remove the video menu options to increase size and reduce size?

    Did Lion's iTunes remove the video menu options to increase size and reduce size?
    Is the ability to shrink or expand the video window from a menu item now really gone? 

    Itunes has not changed in Lion in this regard, you can still go to fullscreen from the menu, and use your input device to make the video window larger and smaller. does that help?

  • Adobe Illustrator print size and view size not fixed. Helped !

    Hi, currently i am facing some problem about my actual view size and print size.
    This is my actual view size :
    This is my printed size :
        Why after i printed out the size is not fit? i am using Adode Illustrator CS6 and my page size is A4 size. Any solution for this? Please help, thank !
        Best Regards.

    Hi Manish,
    Thank for the reply ! i am using Adobe Reader X to print out.
    Here is my print setting.

  • What are FIXED SIZE and VARIABLE SIZE

    Hi what FIXED SIZE and VARIABLE SIZE stands for when starting oracle instance?
    thanks in advance

    read this
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:365088445659
    Aman....

  • MY RAM IS 12GB  HOW WOULD YOU SUGGEST SHMMAX SIZE AND SGA SIZE

    Hi Export
    MY RAM IS 12GB HOW WOULD YOU SUGGEST SHMMAX SIZE AND SGA SIZE.
    thanks

    afzal wrote:
    my ram 12gb
    database size 70gb
    windows 2003
    harddisk 500gbHow large is your SGA now??
    Do you have a performance problem yet ??
    Is the problem a global problem in the whole database, or are there just some queries that are slow ??
    What db version are you using ??
    What other applications are using this server ??
    How many users are using this database ??
    Tuning is very much dependent on the application/situation and database type.
    I would like to suggest you start looking at AWR or Statspack.
    HTH
    FJ Franken
    My Blog: http://managingoracle.blogspot.com

  • I'm trying to get the image to print correct size.  i've tried center image, fit to media image,  and they all come out the same size...smaller than the size in "image size".  is this an Epson problem or Photoshop problem.  Thanks!

    I just got a new printer...Epson R3000...but have had this problem before.  It's probably a simple fix, but I can't figure it out.  I'm asking for printing on 8.5 x 11 and the image comes out 6.5 x 9.5 every time.  Help please!  And thanks!

    The Epson site stated that the R3000 printer can print borderless however the quality will suffer in the expanded print area. Borderless is not supported on some heavy paper.  To me the means your better off limiting you images size to the standard print area. There will be magins about 1/8" on the four  sides so the print area on 8.5"x11" paper is 8.26" x 10.76"....
    Take note of the print size set by the epson driver it may change depending on the paper type set. Note my first epson 4800 setup where I set 8.5" x 11" sheet paper from tray into the printer setting the driver set a smaller size for the paper which was reflected into the Photoshop Print preview. It shows paper is 8.499" x 10.999 with a small unprintable area across the top....
    Paper
    Use paper under normal conditions:
    Temperature: 59 to 77 °F (15 to 25 °C)
    Humidity: 40 to 60% RH
    Note:
    Since the quality of any particular brand or type of paper may be changed by the manufacturer at any time, Epson cannot guarantee the quality of any non-Epson brand or type of paper. Always test a sample of paper stock before purchasing large quantities or printing large jobs.
    Single-sheets
    Size
    A4 (8.3 × 11.7 inches)
    A6 (4.1 × 5.8 inches)
    Letter (8.5 × 11 inches)
    Legal (8.5 × 14 inches)
    4 × 6 inches
    5 × 7 inches
    8 × 10 inches
    11 × 14 inches
    12 × 12 inches
    Half Letter (5.5 × 8.5 inches)
    B (11 × 17 inches)
    A3 (11.7 × 16.5 inches)
    Super B (13 × 19 inches)
    Paper types
    Plain paper
    Special papers distributed by Epson
    Thickness
    0.003 to 0.004 inch (0.08 to 0.11 mm) in the sheet feeder
    0.012 to 0.051 inch (0.3 to 1.3 mm) in the manual feed tray
    Weight
    17 lb (64 g/m2) to 24 lb (90 g/m2)
    Printable Area
    Note:
    When printing borderless, quality may decline in the expanded printable area. Borderless printing is not supported with poster board.
    Sheets
    Top: 0.12 inch (3 mm) minimum
    Left: 0.12 inch (3 mm) minimum
    Right: 0.12 inch (3 mm) minimum
    Bottom: 0.12 inch (3 mm) minimum
    Roll Paper
    Standard margins
    Borderless printing margins
    CD/DVDs
    Caution:
    Avoid printing in the clear plastic areas of your discs to prevent staining the disc with ink.

  • Drag and Drop and Image Size

    I need to be able to drag and drop images but I need them to be a certain size when I drag them out of an Aperture project. For various reasons, I don't want to use the export function. Only drag and drop will be efficient for the workflow that I"m planning. Problem is, the pixel dimension is not wide enough when I test it by pulling an image on to the desktop.
    My ultimate goal is drag them, sized and ready to go, and drop them onto a web browser upload page. I don't want to fumble with the extra steps of exporting them to another folder on the desktop and then upload the images from that folder to the browser.
    So does anybody know how or if it's possible to control the drag and drop SIZE /DIMENSION of an image?

    The drag and drop size is determined by your preview settings. What actually gets "dragged & dropped" is the preview, not the master file. You can control the quality and size of the preview in the Aperture preferences.

  • Premiere Pro CS4: Output Issue - codec and image size

    I am having an issue when outputing a video file from Prem Pro to Media Encoder.  The dimensions of the input video are the usual 720x576.  The output I need is 390x390 to match my project.  By choosing the Sorenson 3 video codec I am able to adjust the size from 720x576 to 390x390.  However, it also applies black bars to the top and bottom of the image.  I don't want this.  If I choose the DV PAL video codec the black bars are removed in the output but I do not have control over the image size.
    In Prem Pro 1.5 the media encoder allowed for this and I was able to create a cropped video image (390x390) without black bars.  By selecting the zoom option the image was fitted into the window size.  There is no zoom option in CS4 in Media Encoder.  This is very frustrating!
    Any help would be appreciated...
    Thanks, Neil

    This is odd indeed, and I cannot recall having read of such. The tips were just the general things that one normally checks out, when there are audio issues, so nothing specific to this behavior.
    Now, as a test, you might want to try ASIO4ALL, linked in the article above. Usually, it will get audio, where the Realtek, or Creative driver will not. Again, this is as a test, just to see if by-passing the Realtek driver will help. Do not forget to set the Audio Hardware ASIO to ASIO4ALL in Input and Output. Then test. If it has zero affect, then just uninstall it, and change the setting back.
    Good luck, and wish I had more to help,
    Hunt
    PS - other than mechanical/electrical things like the audio chip heating up and a connection failing, I just cannot think of something that would cause this behavior. Maybe download and run SpeedFan, a great little free utility, and monitor the temps for all components with sensors.

  • Very confused about ppi, resolution, and image size...

    I have read so much on these things and even posted along these lines here and there, but remain totally confused.
    Say the size of my pictures is around 2000 x 3000. Once I download them to PSE, the resolution is 72ppi. Is this default and could I/should I change this?
    I generally do four things with my pictures.
    First I edit them.
    Next I email to family members.
    Then I order prints (99% are 5x7 or smaller)
    Finally I store them (on computer with CD backup).
    Now, space is a bigger concern than quality since I print small prints generally. So what would be my best options for saving my files, but getting very nice prints?
    Right now, once I edit, I save my files in .jpg, baseline "optimized" at 72ppi. Only following the computer defaults though, not because I think this is best. Would I be better off saving in TIFF or is this not necessary?
    Any links with further info would be appreciated also.
    Thank you,
    Amy

    Amy,
    1. I just took a picture today, and when I look in Image>resize>image size the dimensions are as follows:
    W=2288px H=1712px W=31.778" H=23.778" @72px/in. resolution
    When I change resolution to 325 px/in., W=7.04" H=5.268"
    As the resolution is increased, the dimensions decrease. This is what is called an inverse relation.
    Why did I change to 325px/in? Because for printing it is desirable to have a resolution of 240-300 px/in, or so. Also, note that this resolution gives me almost a perfect 5x7 size format, and one can crop off the excess readily. If one desires 4x6 size, one can crop to that dimension.
    2. I enhance the pictures next, leaving sharpening for the last step
    3. I save primarily in PSD and/or JPEG. Both PSD and TIFF allow one to retain layers, are lossless, and thus one avoids degradation with sequential editing. JPEG is is a compression format which conserves disk space (in comparison to PSD and TIFF), and is most likely required for your e-mail and your photo finisher. I save some of the JPEG files. I usually elect baseline optimized, and the JPEG allows me to elect quality 8, which is good for my purpose and results in a manageable file size.
    4. Right after I download my picture files from the camera, I burn them to a CD (i.e. before I do anything else), and right after I finish the final edits I burn them to CD as well. This is my "film", if you will. If the computer fails or if I should accidentally delete a file from disk, I still have it available.
    I am sure that others will post, but that is my current work flow.
    Ken

Maybe you are looking for

  • Managing Styles in Pages 5

    Hi, two questions regarding paragraph style management: 1. Is it possible to combine numbering/bullets (list styles) with paragraph styles? Imo numbering should naturally be a styling element of a paragraph just like font size, weight etc... 2. For a

  • File Sender Communication channel with error

    Hi,   One of the File sender CC is in red but shows "Functioning". But in the Process Detail section it just showing 5/10/11 2:24:00 AM d28c6542-0d7e-453b-1d96-9e0a18159315 Retry interval started. Length: 60.0 seconds   5/10/11 2:24:00 AM            

  • Deploy without ws-addressing

    Hi. I have process (who hasn't) and I have trouble with deployed WSDL. In deployed WSDL I found this <schema> <import namespace="http://schemas.xmlsoap.org/ws/2003/03/addressing" schemaLocation="http://192.168.0.96:8888/orabpel/xmllib/ws-addressing.x

  • Special Batch Rename; remove trailing characters and make sequential

    Hello, I'm looking to make an Automator droplet which Accepts a handful of files Removes the last three characters while preserving the extension Applies a trailing set of numbers to make the files sequential In my googling, I have found several work

  • Sql Query Error (9i) nested select with OleDB

    I have the following query which works fine when used with Sqlplus, but fails when called from within crytal reports (using an OleDB connection). I saw an open Oracle bug number 3025605 on some website, but haven't been able to look up any additional