Skip to content

Latest commit

 

History

History
36 lines (27 loc) · 1.67 KB

51.md

File metadata and controls

36 lines (27 loc) · 1.67 KB

FFV1-SLICE-slice_xywh

Name

Slice position and size must be contained in the slices array.

Definition

slice_x+slice_w must be less than num_h_slices.
slice_y+slice_h must be less than num_v_slices.

Note

slice_x alone is also tested, must be less than num_h_slices.
slice_y alone is also tested, must be less than num_v_slices.

Reproducibility

Get FFmpeg source code, configure it, then:

mv libavcodec/ffv1enc.c ffv1enc.c
sed -e 's/put_symbol(c, state, (fs->slice_x     +1)\*f->num_h_slices \/ f->width   , 0);/put_symbol(c, state, 9, 0);/g' ffv1enc.c > libavcodec/ffv1enc.c
make
./ffmpeg -f lavfi -i "color=c=black:size=2x2" -vframes 1 -pix_fmt gray8 -write_crc32 0 -c:v ffv1 -level 3 -slices 1 FFV1-SLICE-slice_xywh_x_v3.mkv
sed -e 's/put_symbol(c, state, (fs->slice_y     +1)\*f->num_v_slices \/ f->height  , 0);/put_symbol(c, state, 9, 0);/g' ffv1enc.c > libavcodec/ffv1enc.c
make
./ffmpeg -f lavfi -i "color=c=black:size=2x2" -vframes 1 -pix_fmt gray8 -write_crc32 0 -c:v ffv1 -level 3 -slices 1 FFV1-SLICE-slice_xywh_y_v3.mkv
sed -e 's/put_symbol(c, state, (fs->slice_width +1)\*f->num_h_slices \/ f->width -1, 0);/put_symbol(c, state, 9, 0);/g' ffv1enc.c > libavcodec/ffv1enc.c
make
./ffmpeg -f lavfi -i "color=c=black:size=2x2" -vframes 1 -pix_fmt gray8 -write_crc32 0 -c:v ffv1 -level 3 -slices 1 FFV1-SLICE-slice_xywh_w_v3.mkv
sed -e 's/put_symbol(c, state, (fs->slice_height+1)\*f->num_v_slices \/ f->height-1, 0);/put_symbol(c, state, 9, 0);/g' ffv1enc.c > libavcodec/ffv1enc.c
make
./ffmpeg -f lavfi -i "color=c=black:size=2x2" -vframes 1 -pix_fmt gray8 -write_crc32 0 -c:v ffv1 -level 3 -slices 1 FFV1-SLICE-slice_xywh_h_v3.mkv
mv ffv1enc.c libavcodec/ffv1enc.c