Raw Format to JPEG Save not work.

Developers
2014-03-11
2014-03-16
  • Kalpesh Chhatrala

    I tried to open Nikon (NEF) file and try to save as JPEG but it saved as 0 byte.

    then i tried as PNG file its saved correct file but took around 1.25 minute to generate.

    JPG Save Code.

    FreeImageAPI.FreeImage.Save(FreeImageAPI.FREE_IMAGE_FORMAT.FIF_JPEG, handle,@"c:\test\FreeImage.jpg", FreeImageAPI.FREE_IMAGE_SAVE_FLAGS.JPEG_OPTIMIZE);

    can we improve speed or save it as jpg ?

    thanks

    Kalpesh

     
  • Hervé Drolon

    Hervé Drolon - 2014-03-16

    First, note that the JPEG format cannot save 48-bit images (while the PNG format can).
    Next, for RAW images only, you could try the RAW_PREVIEW flag in order to get the JPEG image usually included inside the RAW file (using this flag will return a 24-bit image converted from the 48-bit RAW image if no JPEG is available). Then, you will be able to save your image as JPEG.
    This should improve the loading speed.

    Hervé

     

Log in to post a comment.