Skip to content
This repository has been archived by the owner on Jul 22, 2018. It is now read-only.

Why is the D1X explicitely disabled? #23

Closed
pedrocr opened this issue Jun 25, 2014 · 6 comments
Closed

Why is the D1X explicitely disabled? #23

pedrocr opened this issue Jun 25, 2014 · 6 comments

Comments

@pedrocr
Copy link
Contributor

pedrocr commented Jun 25, 2014

The Nikon D1X is set as supported="no" in cameras.xml. I had a look and it seems it works fine. The only problem with it appears to be that the sensor has non-square pixels so to get a proper image it needs to be scaled 2x on the y dimension:

http://www.dpreview.com/reviews/nikond1x/

That scaling needs to happen after all the raw processing and demosaic. So from the point of view of raw processing rawspeed is already doing the right thing. Indeed in darktable the image already appears properly (but unscaled) with rawspeed and a broken purple with libraw. Shouldn't it be the app's responsibility to scale the image after processing. I guess rawspeed could help by providing the metadata for the needed scaling but not much more.

@klauspost
Copy link
Owner

The reason, as I remember it is, that it basically gives a different result than dcraw. I want to minimize the difference between them, and since it (even at the time I started writing RS) is a very old camera, I just decided to ignore it than spend too much time on it, since Nikon luckily dropped that path of development.

@pedrocr
Copy link
Contributor Author

pedrocr commented Jul 4, 2014

The result it gives is what's in the file, a half height image that needs to be scaled up after demosaic. dcraw does that upscale. I don't think rawspeed does any demosaic itself, and if it does, at least darktable certainly doesn't use it, so it's usually up to the app to scale up the image.

rawspeed should definitely provide the app with the metadata it needs to apply the operation. We need to think of an interface to do this as it's also an issue with the fuji cameras that need rotation after demosaic. I suppose adding that info to cameras.xml and providing it through the existing metadata interface would be our best bet.

@LibRaw
Copy link

LibRaw commented Jul 4, 2014

There are a lot of D1X files in archives.
So, generally speaking, it is better to decode it and provide aspect ratio to RawSpeed users.

The same thing with some very old Kodak files (DC50 or DC120, cannot remember). But the image is compressed in horizontal direction.

@pedrocr
Copy link
Contributor Author

pedrocr commented Jul 4, 2014

@LibRaw I assume you mean decode the raw data and pass on the metadata on what to do to it after demosaic (2x scale up in this case). That's the only thing you can do when the app wants the raw bayer data and not a RGB image.

@LibRaw
Copy link

LibRaw commented Jul 5, 2014

I agree. The only way to deal with bayer-processing upper layer is to return bayer array as-is and provide aspect ratio data for use after demosaic.

@klauspost
Copy link
Owner

Should be fixed with #49

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants