Man / VIDEO FILTERS / divtc


※末尾「deghost=<value>」の意味不詳。


divtc[=options]

インタレ解除済み映像の逆テレシネ。
3:2-pulldown テレシネ処理された映像で、フィールドの片方が欠けていたり、あるいは、片方のフィールドを残して、もう片方を補完するようなインタレ解除をされていたりする場合、4フレーム毎に複製フレームが入るガクガクした映像になる。
このフィルタは、そうした複製フレームを検出し、オリジナルのフィルムフレームレートを復元するためのもの。
このフィルタを使う場合、-ofpsは入力素材の4/5を指定し、divtcが全てのフレームを見られるように、softskipをフィルタチェインの後ろに置く事。
使い方には2種類のモードがある:
1パスモード。デフォルト。使い方は簡単。デメリットは瞬間的にガクガクする事がある点。テレシネフェーズでフレームがロストしてるとか編集がマズいとかだとこうなる
2パスモード。前述のガクガク回避。1stパスで映像全体を分析してフェーズ変化の情報を取り、正確な位置でシンクロさせる。
ここで言う「パス」はエンコードの「パス」とはベツモノ。
実際のエンコード前にdivtcの1stパスを別に実施しないといけない。出力ファイルは捨てる。この時にCPUのパワーロスを避けるには、

-nosound -ovc raw -o /dev/null

さらに高速化するには、divtcの後ろにcrop=2:2:0:0などと付けても良い。
その後、実際のエンコードにはdivtcの2ndパスを使う。
エンコーダでマルチパスをするなら、全部divtcの2ndパスを使う事。
オプションは以下:

pass=1|2

2パスモードの指定

file=<filename>

2pass log ファイル名(default: "framediff.log").

threshold=<value>

(default: 0.5)。テレシネパターン検出の最小閾値。映像の中の極めて暗いところやすごく動きの少ない部分から、間違ったパターンを認識してしまうの避けるのに使う。

window=<numframes>

(default: 30)。パターン発見の為にサーチをかける過去のフレーム数。このオプションは1パスモード専用。
大きい程、信頼性が高くなる。が、小さいほうが、テレシネフェーズでの応答速度が速い。
2パスモードは現在、固定フレーム数しか見ない。これは過去〜未来フレームにまたがる。

phase=0|1|2|3|4

(default: 0)。テレシネフェーズの初期値指定。1パスモード専用。
2パスモードは未来フレームも見るので、最初から正しいフェーズを使うが、1パスは最初は推測に頼る他ない。フェーズを発見した後はそれを使うが、それまでの区間、このオプションで映像のガタツキを除去できる。2パスモードの1stパスもこれを使うので、1stパスの出力をとって置けば、決まったフェーズ判定が取ってある事になる。

deghost=<value>

(default: 0)。ゴースト除去の閾値。
範囲は1パスモードは、0-255
2パスモードは、-255-255
0以外で、ゴースト除去モードに入る。
フィールドブレンドを使ってインタレ解除された映像素材に使う。
デゴーストはブレンドされたフレームの圧縮アーティファクト*1を増幅するため、直前フレームとの差異が、このパラメータの値以下のピクセルにはデゴーストをかけない。その閾値。

(※以下未完)

原文
Inverse telecine for deinterlaced video. If 3:2-pulldown telecined video has lost one of the fields or is deinterlaced using a method that keeps one field and interpolates the other, the result is a juddering video that has every fourth frame du- plicated. This filter is intended to find and drop those duplicates and restore the original film framerate. When using this filter, you must speci- fy -ofps that is 4/5 of the fps of the input file and place the softskip later in the filter chain to make sure that divtc sees all the frames. Two dif- ferent modes are available: One pass mode is the default and is straightforward to use, but has the disadvantage that any changes in the telecine phase (lost frames or bad edits) cause momentary judder until the filter can resync again. Two pass mode avoids this by analyzing the whole video beforehand so it will have forward knowledge about the phase changes and can resync at the exact spot. These passes do not correspond to pass one and two of the encoding process. You must run an extra pass using divtc pass one before the actual encoding throwing the resulting video away. Use -nosound -ovc raw -o /dev/null to avoid wasting CPU power for this pass. You may add something like crop=2:2:0:0 after divtc to speed things up even more. Then use divtc pass two for the actual encoding. If you use multiple encoder passes, use divtc pass two for all of them. The options are:

pass=1|2

Use two pass mode.

file=<filename>

Set the two pass log filename (default: "framediff.log").

threshold=<value>

Set the minimum strength the telecine pat- tern must have for the filter to believe in it (default: 0.5). This is used to avoid recognizing false pattern from the parts of the video that are very dark or very still.

window=<numframes>

Set the number of past frames to look at when searching for pattern (default: 30). Longer window improves the reliability of the pattern search, but shorter window im- proves the reaction time to the changes in the telecine phase. This only affects the one pass mode. The two pass mode currently uses fixed window that extends to both fu- ture and past.

phase=0|1|2|3|4

Sets the initial telecine phase for one pass mode (default: 0). The two pass mode can see the future, so it is able to use the correct phase from the beginning, but one pass mode can only guess. It catches the correct phase when it finds it, but this option can be used to fix the possible juddering at the beginning. The first pass of the two pass mode also uses this, so if you save the output from the first pass, you get constant phase result.

deghost=<value>

Set the deghosting threshold (0-255 for one pass mode, -255-255 for two pass mode, de- fault 0). If nonzero, deghosting mode is used. This is for video that has been deinterlaced by blending the fields togeth- er instead of dropping one of the fields. Deghosting amplifies any compression arti- facts in the blended frames, so the parame- ter value is used as a threshold to exclude those pixels from deghosting that differ from the previous frame less than specified value. If two pass mode is used, then neg- ative value can be used to make the filter analyze the whole video in the beginning of pass-2 to determine whether it needs deghosting or not and then select either zero or the absolute value of the parame- ter. Specify this option for pass-2, it makes no difference on pass-1.




FrontPage
MPlayer
Manuals
Documents
カテゴリ

■GENERAL
MEMO
LINK
雑談所
最近の更新
popular

■Other Tools
ffmpeg
mkvmerge
mp4box
MPEG Streamclip
QTCoffee
x264cli

■About
About Wiki

edit


blog


本日1
昨日0
累積2628


*1 所産、結果、工芸品、妖精現実さんでもそのまま「アーティファクト」