Jump to content

Petition for Samsung NX1 hack


kidzrevil
 Share

Recommended Posts

20 hours ago, lucabutera said:

Hello. Someone says he wrote a program to rebuild color sampling 4.2.0 in a real 4.4.4.
I'm not a programmer or hackers, or anyone good as @ottok or @kinoseed can see better what is it?

Thank you

https://forum.doom9.org/showthread.php?t=173005&page=6

https://github.com/Khanattila/KNLMeansCL/releases

Icqh01Q000000.png

Looked a bit into it, basically you can't "reintroduce" lost details, but you may interpolate some information.
Isn't this essentially what just about any "remove JPEG artifacts"  algorithm does?

Link to comment
Share on other sites

3 hours ago, kinoseed said:

Looked a bit into it, basically you can't "reintroduce" lost details, but you may interpolate some information.
Isn't this essentially what just about any "remove JPEG artifacts"  algorithm does?

What you say is correct, but all the programs that I use to eliminate macroblocking and artifacts, blur the image to "soften" the color, this algorithm instead also recovers the definition lost by the compression.
Certainly it is hard to think of a recovery of 4.4.4 sampling but have a more realistic 4.2.2 would not hurt!

Link to comment
Share on other sites

I use this script for downscaling to 1080p 10-bit. It was done by karl from Personal View:

Quote

ffmpeg -i "input.mp4" -filter_complex 'format=pix_fmts=yuv444p10le,extractplanes=y+u+v[y][v]; scale=w=3840:h=2160:in_range=full:flags=print_info+neighbor+bitexact [us]; [v] scale=w=3840:h=2160:in_range=full:flags=print_info+neighbor+bitexact [vs]; [y][us][vs]mergeplanes=0x001020:yuv444p,scale=w=1920:h=1080:flags=print_info+bicubic+full_chroma_inp+full_chroma_int' -sws_dither none  -q 0 -quant_mat hq -c:v prores_ks -profile:v 4 -c:a copy  -c:s copy -c:d copy  -map 0 "output.mov"

  It works with 0-255.

Link to comment
Share on other sites

1 hour ago, lucabutera said:

What you say is correct, but all the programs that I use to eliminate macroblocking and artifacts, blur the image to "soften" the color, this algorithm instead also recovers the definition lost by the compression.
Certainly it is hard to think of a recovery of 4.4.4 sampling but have a more realistic 4.2.2 would not hurt!

this will probably not eliminate macroblocks, as ti is not simply a sub-sampling artifact (I think).
if you try a filter which removes MPEG/JPEG compression, it should do the same, right?
You should easily (if you already have Avisynth) be able to test it, using the plugin, so just compare the results and check how it measures with the mpeg-denoiser of your choice.

Link to comment
Share on other sites

On 12.1.2017 at 7:48 PM, lucabutera said:

Hello. Someone says he wrote a program to rebuild color sampling 4.2.0 in a real 4.4.4.
I'm not a programmer or hackers, or anyone good as @ottok or @kinoseed can see better what is it?

Thank you

https://forum.doom9.org/showthread.php?t=173005&page=6

https://github.com/Khanattila/KNLMeansCL/releases

Looks similar to those AVISynth scripts were you can convert 420 or 411 to 444 full RGB but yeah its not "real" 444 has details cannot be reintroduced in fact you loose information in the process no matter what.

Only through downscaling can you obtain details.

Link to comment
Share on other sites

I tried to use a HDR script that switches iso. I only tried to change it 1 times per second and still it stops/crashes the recording very quickly. I was planning to try switching with a gap of 0.04 but didn't since the slow one crashed immediately.

I measured how much an ISO change usually takes and it linux tool time gave a sys reading of 0.02 sec to 0.06 sec. My skills aren't enough to diagnose why it crashed the recording.

Link to comment
Share on other sites

Here's what I tried. It changes the iso from 100 to 800 after one sec. Correct value should be the 1/framerate, I think. But even with 1 sec it crashes when recording video.

#!/bin/bash
while true
do
    /usr/bin/st cap capdtm setusr 5 0x50001
    sleep 1
    /usr/bin/st cap capdtm setusr 5 0x5000a
    sleep 1
done

Link to comment
Share on other sites

As I said, the only persons that could be able to discuss on this matter are Otto K and Kino Seed (since the third one, Vasile, went MIA). Try to contact them with your idea and see if they can help. It's an interesting approach, but I doubt it's the best one considering that high ISO in NX1, for video, is subject to high NR.

Link to comment
Share on other sites

3 hours ago, Blah Blah said:

Here's what I tried. It changes the iso from 100 to 800 after one sec. Correct value should be the 1/framerate, I think. But even with 1 sec it crashes when recording video.

#!/bin/bash
while true
do
    /usr/bin/st cap capdtm setusr 5 0x50001
    sleep 1
    /usr/bin/st cap capdtm setusr 5 0x5000a
    sleep 1
done

Do you try to shot in 640x480 in vga or mjpeg to see if the problem is the bitrate?

Link to comment
Share on other sites

6 hours ago, Blah Blah said:

Here's what I tried. It changes the iso from 100 to 800 after one sec. Correct value should be the 1/framerate, I think. But even with 1 sec it crashes when recording video.

#!/bin/bash
while true
do
    /usr/bin/st cap capdtm setusr 5 0x50001
    sleep 1
    /usr/bin/st cap capdtm setusr 5 0x5000a
    sleep 1
done

I am no means an expert but I dont think "while true" statements are a good idea and could be the reason it is crashing.

Another problem with your script is from what I remember from along time ago (more than 5 years) I believe sleep requires and integer so it cannot be 1/frame-rate witch points to a bigger problem with your approach. This is not something you should really be doing with a script. This should be a compiled program in something like C++.

I think OttoK wrote some posts on Github about compiling programs for the NX1.

Link to comment
Share on other sites

Honestly, I didn't comment as I don't get what you are trying to achieve with the script.

There is HDR script for stills - check the manual.

Changing the ISO will not change the exposure unless you have it in "Manual" exposure, and the script will loop endlessly. I guess later you will pull frames for HDR?
Can't tell you the exact reason for the crash, i may be that commands try to execute before the previous is complete, there may be error in your commands (I have not checked them), so check each one by itself if it works, than add enough time between them, so they get enough time to complete (remember you are *not* setting the change-duration; As it is handled internally by the camera, you can only wait until it completes).
imho, you will get much better result if you shoot stills

Link to comment
Share on other sites

12 hours ago, Blah Blah said:

Yeah, I was testing in manual mode. I just tried something suggested on this thread for hdr video: changing iso for every other frame during video recording and combining them for hdr. Magic Lantern has a mode like that.

that script is far of the target, however the approach is faulty too.

Notice that changing ISO is not instantaneous, and gradually goes to the target. So all you need is to start with ISO100 and set ISO800, while recording video, and that will accomplish that you are after.

Link to comment
Share on other sites

4 minutes ago, Daniel Galli said:

i have heard about something here that if you get a 4k 4:2:0 you can convert to 1080p 4:2:2 what about that?

Yes 1080p to 444 more like through downscaling.
You can downscale and get more information just fine, but adding more shadow information is impossible at the moment, the program has to be so intelligent it literally has to know what is there but never really is present in the video footage to begin with.

There is actually a near program I have for downscaling footage, its called ClipToolz Convert V2 and its free the V3 and V4 are paid ones. 

http://hdcinematics.com/

ClipToolz-Convert-V2.msi

Link to comment
Share on other sites

4 minutes ago, SMGJohn said:

Yes 1080p to 444 more like through downscaling.
You can downscale and get more information just fine, but adding more shadow information is impossible at the moment, the program has to be so intelligent it literally has to know what is there but never really is present in the video footage to begin with.

There is actually a near program I have for downscaling footage, its called ClipToolz Convert V2 and its free the V3 and V4 are paid ones. 

http://hdcinematics.com/

ClipToolz-Convert-V2.msi

and you use it on your everyday workflow? 
you record with some settings to get max information?

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...