Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

loading DNG in blender, somehow relate to oiio(?) #1584

Closed
gree303 opened this issue Dec 13, 2016 · 9 comments
Closed

loading DNG in blender, somehow relate to oiio(?) #1584

gree303 opened this issue Dec 13, 2016 · 9 comments

Comments

@gree303
Copy link

gree303 commented Dec 13, 2016

Problem

I'm trying to run Blender with DNG support. Jens V. and Sambler were both able to figure this out and get it working. Somehow, I can't get my head around this. But it has something todo with oiio/libtiff/ols(?)

So, after recompiling oiio and blender (*including samblers patch) - the dng's won't be visible at all.
Blender won't crash and is showing a blank frame within the VSE preview window.

I've tried several versions of the latest blender *2.76/2.77/2.78. Either I'm getting the blank preview frame OR it results in a crash. Jens is talking about OLS; not sure what this is all about.

If someone is willing to help or test - please download the following footage; DNG Test-Sequence

  • Open Blender
  • Switch into Video Editing Mode
  • In the Sequencer add the image sequence
  • Can you see any images? If yes; are they in full resolution?

Please let me know what system you are running and which libs you have loaded.
Thanks.

System

Debian 8 / Bunsenlabs
Blender 2.76 or 2.77 or 2.78

@lgritz
Copy link
Collaborator

lgritz commented Dec 16, 2016

I tried the current OIIO master and just loaded your whole frame sequence in 'iv', and it worked just fine. So I think the OIIO side of it is basically sound.

Which version of OIIO are you using? Since proper reading of DNG files depends on libraw, which version of libraw are you using and are you actually sure that you built OIIO with libraw support turned on? Because if it's disabled or libraw is not found at build time, it will simply not have proper dng support compiled in.

@gree303
Copy link
Author

gree303 commented Dec 20, 2016

Thanks for the note.
I've tried opening it with 'iv' and it does work without a problem.
But loading it in Blender/VSE results in a blank/transparent frame or blender crashes (daily build).

libraw10 (0.16.0-9+deb8u2)
libkdcraw-data (4:4.14.0-1)
libkdcraw23 (4:4.14.0-1)
openimageio-tools (1.4.14~dfsg0-1) // this is the default debian version

Further I've tried building the actual oiio with libraw support - also without luck.
Any clue what I'm doing wrong?

Could you also test if it does work within blender? Many thanks.

@gree303
Copy link
Author

gree303 commented Dec 20, 2016

Update: Based on jensverwiebe suggestion it does work using Blender 2.65a and renaming DNG to PSD. I tested it and can confirm it works.

@gree303 gree303 closed this as completed Dec 20, 2016
@lgritz
Copy link
Collaborator

lgritz commented Dec 20, 2016

Renaming DNG to PSD? What?

Why would that work?

@wrosecrans
Copy link
Contributor

I am not super familiar with Blender internals, but if Blender is only using OIIO as one of many image reader libraries, and only trying to open certain images using OIIO, it would make sense. (Much the way OIIO itself will try with LibTiff, then with OpenEXR, etc, based first on guessing with the file extension and then by brute force.) I am pretty sure that having a file named with a .psd extension is just forcing Blender to try using OIIO to read the file, then OIIO goes into the fallback brute force mode to attempt to find a valid reader plugin after the PSD reader fails. If it's named .dng, Blender is simply following some other code path that isn'y under OIIO control. That explains why the first of OP's links is about LibTIFF complaining it can't read the file correctly. "TIFFReadDirectory: Warning, Unknown field with tag 33421 (0x828d) encountered. "

@lgritz
Copy link
Collaborator

lgritz commented Dec 20, 2016

So, are you suggesting that OIIO's ability to read dng is fine, but Blender has some other (higher priority) dng-reading code path that's broken, so the net result of misnaming the file is to put it on the OIIO code path?

Or is it the other way around, and renaming it is taking it off a broken OIIO path?

@wrosecrans
Copy link
Contributor

I haven't read any Blnder code to see exactly what's happening, so this is speculation. But my hypothesis is that since iv can read the image, OIIO is fine and renaming the file gives it to OIIO rather than taking it away from OIIO.

In terms of ticket-triage, right now there's no specific evidence of a bug in OIIO.

@gree303
Copy link
Author

gree303 commented Jan 1, 2017

Changing the DNG to PSD extension does show the DNG within blender. But it is slow. Testing a DNG.PSD sequence isn't as fast as loading the same sequence as DNG in other software packages.

Any idea how to fix this or adding a native DNG support to it?
Happy New-Year :)

@gree303 gree303 reopened this Jan 1, 2017
@lgritz
Copy link
Collaborator

lgritz commented Dec 24, 2018

Closing, since this has gone uncommented for a while and nobody gave any specific evidence that it was a problem on the OIIO side.

@lgritz lgritz closed this as completed Dec 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants