dcraw problems with Panasonic Lumix DMC-LX3 in low light?

Discussion in 'Panasonic Lumix' started by ted, Dec 15, 2009.

  1. ted

    ted Guest

    I have a Panasonic Lumix DMC-LX3 as a general purpose camera and am very
    pleased with it. The camera has settings such that it will either create
    a .jpg on the fly *or* create a .jpg *and* save a "raw" .rw2 file as well.

    As I use Unix-ish systems, I have never played with the Windows software
    that came with the camera, but the free open-source prgram "dcraw" is
    able to read the .rw2 files and write them as .ppm files which I can then
    make into .jpgs myself with cjpeg.

    Anyway. With standard daylight shots, I am usually more pleased with
    the jpgs I get from the "dcraw" process than those the camera creates itself.
    It's not dramatic, but they are just slightly more pleasing to my eye.

    However, I have recently taken two sets of photos at night with a tripod
    and several second exposures. In theses cases, the jpgs produced by the
    camera are quite a bit better than what I get from the raw files. I've
    tried a number of different settings to dcraw (-W turned out to be quite
    important, but still doesn't do the whole trick) but still haven't produced
    anything as good as the camera jpgs and I'm curious if I'm missing something.

    Here are three files from a recent night time trip to a local sculpture
    garden's Christmas light program:

    http://www.tednolan.net/misc/lumix/p1080248-camera.jpg
    http://www.tednolan.net/misc/lumix/p1080248-dcraw.jpg
    http://www.tednolan.net/misc/lumix/p1080248.rw2

    The first is the JPEG produced by the camera itself.

    The second is the JPEG I made with dcraw -W & cjpeg -q 95

    The third is the raw file itself.

    If you look at the pedestal and feet of the statue, the foot is clearly better
    defined in the camera jpg. Also if you look at the color and highlights on
    the statue's legs, those are clearly better in the camera jpeg as well.

    Any thoughts as how to replicate the look of the camera jpeg from the raw
    file with dcraw?

    Ted
     
    ted, Dec 15, 2009
    #1
    1. Advertisements

  2. Try applying an unsharp mask to the dcraw shot.
    You might also try to apply some noise supressing software, I
    believe the camera uses such for the JPEG.

    -Wolfgang
     
    Wolfgang Weisselberg, Dec 15, 2009
    #2
    1. Advertisements

  3. ted

    ted Guest

    Thanks, I'll give it a try.

    Ted
     
    ted, Dec 15, 2009
    #3
  4. ted

    Martin Brown Guest

    Which has almost certainly had an element of sharpening or unsharp mask
    applied in the camera. You can probably find some control of sharpness
    in the darker recesses of the menu system if you look hard enough.

    Softness show up strongly on high contrast sharp edges. The image is a
    bit odd in that it has been stripped with no embedded information or
    thumbnails. But it has a custom quantisation table that suggests it is
    ex-camera. The q-table is roughly equivalent to IJG q=98 by the way.

    So you lost a bit of detail and had a smaller file size below for that
    reason too. But most of the difference is due to the fact that the image
    has a significant linear dependency between adjacent pixels.
    Apply a small amount of unsharp masking to get the edges to your liking.
    Overdo it and the edges will ring, but the right amount will give the
    result you are looking for. 3 pixel, 60% is a starting point.

    Camera makers know that sharpness sells so most P&S are rigged for
    slightly overcooked sharpening by default.

    Regards,
    Martin Brown
     
    Martin Brown, Dec 15, 2009
    #4
  5. ted

    ray Guest

    Rather a round-about way to get there. Try ufraw. It uses the same dcraw
    conversion engine and allows you to do simple editing - change the white
    balance, exposure, etc. and output a jpg.
    Excellent case for ufraw - you can adjust exposures, etc. on the fly, see
    what it does, undo, try another, adjust a little more, whatever. It
    should make your editing much better.

    I've tried to look at your raw file in ufraw and it does not handle it
    properly, but then I probably don't have the latest version (Debian
    stable). You may be able to build it with your version of dcraw which
    handles that format.

    Since I was not able to check, I can't verify, but there is a good chance
    you're losing some of the detail in the jpeg conversion. With ufraw, if
    you get it to go, you can do your changes on the full data rather than
    trying to pull info back out of the jpeg.
     
    ray, Dec 15, 2009
    #5
  6. ted

    ray Guest

    As mentioned, I could not get my version of ufraw to directly read your
    file. But I was able to use the Adobe DNG converter under WINE to convert
    to a DNG which ufraw could handle.
     
    ray, Dec 15, 2009
    #6
  7. ted

    ray Guest

    I'm sure it is. What part of 'stable' is it you don't understand?
     
    ray, Dec 15, 2009
    #7
  8. ted

    ray Guest

    I don't need it for what I normally do. I did this only to show the OP it
    could be done in a variety of ways.
     
    ray, Dec 15, 2009
    #8
  9. ted

    ted Guest

    I'll take a look at it though I have shell scripts to do all the work,
    so it's not really round-about for me.


    Ted
     
    ted, Dec 16, 2009
    #9
  10. ted

    ted Guest

    I will definitely investigate ufraw!

    Ted
     
    ted, Dec 16, 2009
    #10
  11. ted

    ted Guest

    Yeah, come to think of it, that image has been roatated from landscape
    to portrait with jpegtran which doesn't lose any image detail (ie, it does
    not decode and recode the jpg) but which does lose EXIF info.
     
    ted, Dec 16, 2009
    #11
  12. ted

    Martin Brown Guest

    If you are doing that you may as well let it optimise the Huffman
    coefficients in the lossless encoder step to get a smaller file.

    Few cameras do it because it takes two passes over the coefficient data
    and is slower, but on a PC the time difference would not be noticeable.

    Regards,
    Martin Brown
     
    Martin Brown, Dec 16, 2009
    #12
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.