Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. How to link Intel Open Image Denoise to a Qt project?
Forum Updated to NodeBB v4.3 + New Features

How to link Intel Open Image Denoise to a Qt project?

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
4 Posts 3 Posters 440 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    SDOAJ
    wrote on 1 Feb 2022, 04:49 last edited by SDOAJ 2 Jan 2022, 05:24
    #1

    I'm trying to use Intel Open Image Denoise in a raytracer project, but I can't seem to link it properly. I downloaded the Windows precompiled binaries from the downloads page and placed them in my project directory, then I added the .lib file through the GUI for adding external libraries. It added these lines to my .pro file:

    win32: LIBS += -L$$PWD/oidn/lib/ -lOpenImageDenoise
    
    INCLUDEPATH += $$PWD/oidn/include
    DEPENDPATH += $$PWD/oidn/include
    

    With these, I was able to include the header with #include <OpenImageDenoise/oidn.hpp>, and the project was able to build. But when I tried the examples on the OIDN page, my project would crash immediately upon opening, going to the black console screen with Press <RETURN> to close this window... without any other console output. I found that commenting out all lines related to denoising (other than the include statement) allowed the program to run as normal. Including even one line, such as the first line oidn::DeviceRef device = oidn::newDevice();, causes the program to crash.

    I also tried making a completely new project and adding OIDN to that, but I ran into a separate issue there. I added the library the same way, but whenever I run the test project, I get this popup:

    1cd73ccb-8e85-461b-8ab4-d5488a85a28f-image.png

    I tried manually adding the .dll with LIBS += $$PWD/oidn/bin/OpenImageDenoise.dll, but it still didn't work.

    I also found this thread, but the poster there was compiling the source himself rather than downloading the prebuilt binaries, so it didn't seem applicable.

    With all that said, can anybody help with this issue? I'm relatively inexperienced with adding libraries to Qt projects, so it's entirely likely I missed something trivial.

    1 Reply Last reply
    0
    • C Offline
      C Offline
      Christian Ehrlicher
      Lifetime Qt Champion
      wrote on 1 Feb 2022, 05:52 last edited by
      #2

      You have to put the dll in your PATH

      Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
      Visit the Qt Academy at https://academy.qt.io/catalog

      S S 2 Replies Last reply 1 Feb 2022, 11:31
      0
      • C Christian Ehrlicher
        1 Feb 2022, 05:52

        You have to put the dll in your PATH

        S Offline
        S Offline
        SGaist
        Lifetime Qt Champion
        wrote on 1 Feb 2022, 11:31 last edited by
        #3

        Hi,

        @Christian-Ehrlicher said in How to link Intel Open Image Denoise to a Qt project?:

        You have to put the dll in your PATH

        To add to @Christian-Ehrlicher, do that in the Run part of the Project panel. No need to start modifying your system's PATH environment variable.

        Interested in AI ? www.idiap.ch
        Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        1
        • C Christian Ehrlicher
          1 Feb 2022, 05:52

          You have to put the dll in your PATH

          S Offline
          S Offline
          SDOAJ
          wrote on 1 Feb 2022, 18:11 last edited by
          #4

          @Christian-Ehrlicher @SGaist thank you so much! I did that and the project works now.

          1 Reply Last reply
          0

          1/4

          1 Feb 2022, 04:49

          • Login

          • Login or register to search.
          1 out of 4
          • First post
            1/4
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved