#150 Seg fault on "Save HDR Preview"

Program (114)
Andrew G

Select "File" --> "Save HDR Preview" and segfault

Running the optimized release build with debugging under GDB:

Program received signal SIGSEGV, Segmentation fault.
MainWindow::saveHdrPreview (this=0x996670)
at /home/andrewg/src/luminance-hdr/luminance-hdr-2.2.1/src/MainWind/MainWindow.cpp:623
623 QString outfname = getLdrFileNameFromSaveDialog(ldr_name + "_" + hdr_v->getFileNamePostFix() + ".jpg", this);

(gdb) print hdr_v
$1 = (HdrViewer *) 0x0
(gdb) print g_v
$2 = <value optimized="" out="">

As an aside, I can figure out no way to save the HDR image. Sure "Save As" is more than happy to save the LDR, but I can't figure out a way to save the HDR image.

In MainWindow::fileSaveAs(), I can't figure out how to make g_v->isHDR() TRUE.


  • Franco Comida

    Franco Comida - 2012-09-12

    You must select the tab containing the HDR to save the preview.
    In void MainWindow::saveHdrPreview() put

    if (!g_v->isHDR()) return;


    GenericViewer g_v = (GenericViewer)m_tabwidget->currentWidget();

    to avoid crashes

    Also the "Save HDR preview entry should be disabled when an LDR is displayed.

    Anyway why don't you use the latest version?

  • Franco Comida

    Franco Comida - 2012-10-08

    The issue you reported has been fixed in the git repository.
    The next release will include this fix.
    thank you for reporting.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks