ADOBE PREMIERE PRO: Tutorials Forum Articles Podcasts Basics Forum Creative Cloud Debate

Creating an C++ App for Scratch and dust removal. Feature requests are welcomed

COW Forums : Adobe Premiere Pro

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Dave BabbCreating an C++ App for Scratch and dust removal. Feature requests are welcomed
by on Sep 13, 2015 at 6:45:27 pm
Last Edited By Dave Babb on Sep 13, 2015 at 10:37:48 pm

Good Afternoon Community,

I am new to the board, but a retired software engineer (C/C++). I'm 60 now.

In my first post I asked about the best practice to remove dust and scratches. I received a post with a lot of pointers. And are they expensive. The ones that aren't are marginally functional.

So...I am going to write one of my own. While in development, it will be released under the GPL. Undecided how to relase when it's done.

I've already got in place the abstraction layer so that I don't have to deal with file format issues, compression, Big-Endian/Little-Endian, etc. Now it's algorithm time. Because my background is in engineering, I'm approaching this more like an engineer than an artist (forgive please).

Based upon my own personal needs, I have a base algorithm. This algo comes from looking at the raw video data in hex. And I was able to come up the algo below based upon what I was seeing in the abstracted raw video data itself.

The program will (for now) be a stand-alone app that works on exported image sequences that are numbered. Once it is polished and working, then I'll read the API's for the major Editors and create a plugin.

Right now I have three parts to my algo. I welcome input and feature requests from others.

a) User will be able to define difference range for light spots (scratches)
b) User will be able to define difference range for looking for dark spots (dust)
c) User will be able to define span of frames (default == 3), range 3 to 10. This should differentiate intended film features from the anomalies in old film.
d) User will be able to tell the software to parse vertically or horizontally.

I am targeting this program to be specific to repair dust specs, scratches, and dead camera pixels. This is NOT going to be a de-noiser.

The software will use the user's input above to define spots and scratches, then the spot/scratch will be filled in with the color surrounding the spot/scratch.

I'm approaching this more like an engineer than an artist (forgive please). I am going to parse the raw video data one scan line at a time (horizontal or vertically, users choice)


Additional input from those more experienced than I in editing are solicited, and welcomed..


Sincerely and respectfully,


Dave


Return to posts index

Chris WrightRe: Creating an C++ App for Scratch and dust removal. Feature requests are welcomed
by on Sep 14, 2015 at 8:00:12 am

i respect anyone diving head first into such a massive project. its always interesting to me to see people solve their own problems. Now, I don't claim to be an expert algorithm person but it seems to me that first, before you start any scratch removal, you'll need to de-flicker/auto white balance the image first.

I made a automatic deflicker that removes flicker, shadow pulsing, saturation, contrast, and auto white balance. It's free here, perhaps it might give you some ideas.
ae cs3
https://f1.creativecow.net/6154/auto-white-balance-cs3-and-up


Return to posts index

Dave BabbRe: Creating an C++ App for Scratch and dust removal. Feature requests are welcomed
by on Sep 14, 2015 at 4:11:32 pm

Great point..I guess I forgot to mention that I had already used APP to process the video and get it in finished form, including color balance...

Do you have any comments on my methodologies that I posted? Features requests that are obvious that I am missing like failing to post that the app would have a radius adjustment!


Thanks!

Dave


Return to posts index


Chris WrightRe: Creating an C++ App for Scratch and dust removal. Feature requests are welcomed
by on Sep 14, 2015 at 4:44:01 pm

to be completely honest, the number of sliders will depend entirely on how automatic the program is.

like with my program, I promised myself, unless it was 98% automatic, I wouldn't do it. no way mr. keyframe!

for example, is there a thickness slider or will it auto detect hair vs scratches? major scratches would need data from larger/smaller distance frame looking ahead. You'll either have a super adaptive program or one that has 20 sliders. The only thing I can think of besides motion adaptive, is multiple passes for different kinds of things, like sub-pass 1, subpass 2 etc. I could be completely off base here as I haven't touched coding it with a 10 foot pole.

another thought:
You'll probably need to integrate scene detection unless the user is required to parse camera edits themselves and stabilization.


Return to posts index

Dave BabbRe: Creating an C++ App for Scratch and dust removal. Feature requests are welcomed
by on Sep 14, 2015 at 5:52:20 pm

Thank you!

I hadn't thought about scene detection, but from my documented approach, and the data structure that I will be storing the "frame buffers" in...it will be easy to detect that.

I hadn't thought about that and I appreciate it!

Thank You!

Dave

PS: The sliders/values/adjusters will all operate in real time. The app currently displays the unfiltered frame on the left, and the filtered frame on the right. The program allows a person to click next until their finger falls off, or click auto, to parse the rest of the film sequence with the current settings. My algo already handles scratches, and hairs, and spots, and takes appropriate actions for each.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2016 CreativeCOW.net All Rights Reserved
[TOP]