PDA

View Full Version : Conditional filtering idea: Mark() and IsMarked()


mf
30th October 2003, 16:56
Lots of anime raws have screwed up scenechanges (though most encoders simply ignore them cause it's too much work to fix), so I have to manually check it all, and then replace them. The checking isn't so hard, but the replacing is. I have to create a Trim() and Splice() line for every frame replaced. So my idea is to be able to do this:
Mark(1234)
Mark(1432)
etc, and then use IsMarked() as a conditional filter to replace every marked frame with the following frame.

So I ask in the name of the l33t encoders who replace ugly frames, please implement this! :D

Thanks. :)

Edit: In the meantime I've fixed it with this:
function RWNext(clip clip, int frame) {

replacement = clip.Trim(frame+2, frame+2)
before = clip.Trim(0, frame)
after = clip.Trim(frame+2, 0)

final = before+replacement+after
return final

}
Of course, that doesn't mean a Mark() function isn't a welcome addition to AVISynth :D.

PS: 777 posts! I'm holy now :D.

scharfis_brain
30th October 2003, 18:09
why THAT complicated?

just use:
deleteframe(x).duplicateframe(x)

mf
30th October 2003, 18:34
Originally posted by scharfis_brain
why THAT complicated?

just use:
deleteframe(x).duplicateframe(x)
Err.. :D Is there something like that? :p :o

:rolleyes: Silly me ;).

gizmotech
30th October 2003, 21:33
Or you could even just freezeframe the scene change.

freezeframe(frame-1,frame,frame+1)

/me thinks mr. script boy should go read the manual a little more closely.

Gizmo.

mf
30th October 2003, 23:12
Originally posted by gizmotech
Or you could even just freezeframe the scene change.

freezeframe(frame-1,frame,frame+1)

/me thinks mr. script boy should go read the manual a little more closely.

Gizmo.
Mr. Script boy? Now that's a funny one.
1) I only read the manual when I need to look something up
2) Using RWNext works just as fine
3) Looking up alternative methods would have cost me more time than quickly writing a function
4) I don't like programming or scripting at all, I only do it when I need something done for which I can't get someone else to do it for me.
5) There's still uses to be found for my idea - I bet in a few days/weeks I'll bump into it and that's when it'll be nice to have something like this.

Point 4 above may sound harsh/egoistic, but I'm bad at scripting so it does make sense. And I can't even program at all. Oh and I don't recall you giving back anything to the community.