Magic Lantern Forum

General Discussion => General Chat => Topic started by: Kharak on February 09, 2022, 01:25:22 PM

Title: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Kharak on February 09, 2022, 01:25:22 PM
I know this is ML forum, but you guys normally know stuff about EXIF and Metadata and the BM Forum is really hard to get answers on anything that isn't the newest new new.

I bought the BMPCC (BlackMagic Pocket Cinema Camera) original or first edition what have you, the not-4K one. In package, never used at my local photo store for a good price and it shoots RAW, so I of course had to have it. And I've really been interested in the Super 16 look of lately and B4 Zooms and so on, so its a nice package.

I noticed that when playing the DNG's in MLRawViewer (which somehow works with Compressed DNG's from BM cameras) that the camera actually shoots 1952x1112 and not 1920x1080 as shown in Resolve and other software- Not a big Crop, but none the less a crop on an already heavily cropped camera. The DNG's contain metadata that tell the software, like Resolve to Crop to 1920x1080. See Exif. I don't know why, maybe for easier calculations or just to adhere to a standard, but I see no artifacts with the extra resolution.
I opened a DNG in Rawdigger Trial version and I have no idea what I am doing or if this is the right tool. But got the exif data. What I need help with, is a way to change or remove the crop, preferably on all the DNG's, like Batch uncrop if possibe or Change Metadata of all DNG's on the SD card.

So if someone could point me at the right tool or Command, I would be very happy.

Just some extra info, in my test I found out that the camera LCD shows the cropped 1920x1080 area and not the full 1952x1112 recorded resolution.



---- ExifTool ----
ExifTool Version Number      : 12.36
---- File ----
File Name                    : super16 raw_1_2022-02-10_1144_C0020_000000.dng
Directory                    : I:/super16 raw_1_2022-02-10_1144_C0020
File Size                    : 2020 KiB
File Modification Date/Time  : 2022:02:10 10:44:55+00:00
File Access Date/Time        : 2022:02:10 10:44:54+00:00
File Creation Date/Time      : 2022:02:10 10:44:55+00:00
File Permissions             : -rw-rw-rw-
File Type                    : DNG
File Type Extension          : dng
MIME Type                    : image/x-adobe-dng
Exif Byte Order              : Big-endian (Motorola, MM)
---- EXIF ----
Subfile Type                 : Full-resolution image
Image Width                  : 1952
Image Height                 : 1112
Bits Per Sample              : 12
Compression                  : JPEG
Photometric Interpretation   : Color Filter Array
Orientation                  : Horizontal (normal)
Samples Per Pixel            : 1
Planar Configuration         : Chunky
Tile Width                   : 976
Tile Length                  : 1112
Tile Offsets                 : 9216 1084480
Tile Byte Counts             : 1075262 984166
CFA Repeat Pattern Dim       : 2 2
CFA Pattern 2                : 1 2 0 1
TIFF-EP Standard ID          : 0 0 0 1
DNG Version                  : 1.2.0.0
Unique Camera Model          : Blackmagic Pocket Cinema Camera
Linearization Table          : (Binary data 20799 bytes, use -b option to extract)
Black Level Repeat Dim       : 1 1
Black Level                  : 256
White Level                  : 51080
Default Crop Origin          : 16 16
Default Crop Size            : 1920 1080
Color Matrix 1               : 1.31197 -0.49679 0.01156 -0.41723 1.44237 0.04528 0.06723 0.2171 0.72651
Color Matrix 2               : 1.00885 -0.27351 -0.08258 -0.48997 1.34441 0.11174 -0.06406 0.32997 0.53917
Camera Calibration 1         : 1 0 0 0 1 0 0 0 1
Camera Calibration 2         : 1 0 0 0 1 0 0 0 1
As Shot Neutral              : 0.6306 1 0.7728
Baseline Exposure            : 2.1
Camera Serial Number         : BC5D3219599F4337BFA39329B572099A
Calibration Illuminant 1     : Standard Light A
Calibration Illuminant 2     : D65
Time Codes                   : 11:44:55.00
Frame Rate                   : 24
---- Composite ----
CFA Pattern                  : [Green,Blue][Red,Green]
Image Size                   : 1952x1112
Megapixels                   : 2.2


Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Kharak on February 09, 2022, 02:34:23 PM
I forgot, if you want sample DNG's I will WeTransfer to you in PM.

So I found ExiftoolGUI https://exiftool.org/forum/index.php?topic=2750.0 I actually thought this was ML forum  :-*

But I can't figure out how to use it, maybe I should join that forum..
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Deadcode on February 09, 2022, 03:55:11 PM
The crop factor of 2.88x is calculated with the 1920x1080 resolution, however the difference is barely 2%.
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Kharak on February 09, 2022, 04:18:20 PM
Yes, but the extra vertical resolution is proportionally higher than its corresponding horizontal resolution. So if you set up a 16x9 Project and you have the full sensor width resolution (1952) you gain extra Vertical wiggle room for stabilization. Something I have been a profound user of with 5D3's 3:2 1920x1280 resolution. When tracking headshots and you want that headline to stay close to the top border, it is an amazing tool for controlling your compositions or for post stabilization.

After playing with different Exiftool GUI's, I think I need to get a command for Exiftool(-k) and somehow remove DefaultCropSize. The GUI ones don't seem to be able to do that, even tried removing all Metadata and that did not remove anything.
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Danne on February 09, 2022, 05:57:28 PM
Provide a dng example in your post. Better than sending privately.
You need to find syntax using exiftool. If you get it to work with exiv2 it´s even faster to change.
Here is one example using exiftool changing the as shot neutral tag:
exiftool "-AsShotNeutral=0.4757272085 1 0.6440925123" M20-1539_frame_1.dng -overwrite_original
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: ArcziPL on February 09, 2022, 06:37:01 PM
Quote from: Kharak on February 09, 2022, 04:18:20 PMThe GUI ones don't seem to be able to do that
Select a file
Click on "Exif" button on the right panel
Find and right click "Default Crop Origin" field and select "Add tag to workspace"
Do the same for "Default Crop Size"
Click on "Workspace" button on the right panel
Select "Default Crop Origin", change the value in the edit field on the very bottom to 0 0, press Enter, click "Save" button
Select "Default Crop Size", change the value in the edit field to 1952 1112, press Enter, click "Save" button

Your DNG should be modified now.

For batch processing you should use the command line option of exiftool
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Kharak on February 10, 2022, 09:40:11 AM
Thank you all for looking in to this.

I had some issues with my cloud yesterday, here they are: https://drive.protonmail.com/urls/W1XSGHAEVC#Wn4Gtp4spxRD
Its 12 frames cut out, you can look at the printed dots in the notepad and see the crop/uncrop.

I will try your suggestions now.

EDIT:

@ArcziPL The GUI does not work, the Save button remains greyed out. Is the metadata locked somehow? is that possible?

@Danne I tried using that Exiftool command, but replacing with "-defaultcropsize" instead, but I probably need something else to -overwrite_original with.. I am so dumb with this stuff.
Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Levas on February 10, 2022, 11:47:02 AM
Not an expert with exiftool, but learned some useful commands on this forum  :P

The command line you're looking for is:
exiftool -IFD0:DefaultCropSize="1952 1112" *.dng

Use this command, while being located in the directory were the dng files are.

The above command keeps the originals, doesn't overwrite stuff.

If all works well, and you want to overwrite originals:
  exiftool -IFD0:DefaultCropSize="1952 1112" -overwrite_original *.dng

Not sure why the IFD0 part has to be used, but it is common, some standard layer naming in exifs or something  ???

Title: Re: Need Help: BMPCC (Original) - Get full resolution from DNG
Post by: Kharak on February 10, 2022, 12:54:57 PM
That did the trick, you're an expert to me! Thank you.

exiftool -IFD0:DefaultCropSize="1952 1112" *.dng

exiftool -IFD0:DefaultCropOrigin="0 0" *.dng

I put the command in ExiftoolGUI and it changed the Metadata of all the DNG's in the folder. I had to also change DefaultCropOrigin to 0 0 to make the DNG's viewable in Windows Photo Viewer and Photos and probably other software.

And thanks to everyone else for helping out!