Open sorvani opened 4 years ago
Try
ffmpeg -i Natsunagu-01.mkv -y -acodec copy -vcodec libx265 -c:s copy -pix_fmt yuv420p -map 0:0 -map 0:1 -metadata:s:a:1 title="Japanese AAC LC (Stereo)" -map 0:2 -metadata:s:0:2 title=English -metadata:s:0:2 DISPOSITION:default=0 -map 0:3 -preset medium -x265-params crf=19:allow-non-conformance:ref=8:bframes=8:rd=6:me=star:b-adapt=2:qg-size=64:rc-lookahead=40:scenecut=45:weightb=1:psy-rd=2.0: /tmp/h265ize/Natsunagu-01.encoding-in-progress.mkv
and let me know if that works. That's the command h265ize is using.
First it said
/tmp/h265ize/Natsunagu-01.encoding-in-progress.mkv: No such file or directory
So I created the h265ize subfolder in /tmp
$ mkdir /tmp/h265ize
Then it gave this
[matroska @ 0x55dfe4ab9600] Invalid stream specifier: 0:2.
Full error:
$ ffmpeg -i Natsunagu-01.mkv -y -acodec copy -vcodec libx265 -c:s copy -pix_fmt yuv420p -map 0:0 -map 0:1 -metadata:s:a:1 title="Japanese AAC LC (Stereo)" -map 0:2 -metadata:s:0:2 title=English -metadata:s:0:2 DISPOSITION:default=0 -map 0:3 -preset medium -x265-params crf=19:allow-non-conformance:ref=8:bframes=8:rd=6:me=star:b-adapt=2:qg-size=64:rc-lookahead=40:scenecut=45:weightb=1:psy-rd=2.0: /tmp/h265ize/Natsunagu-01.encoding-in-progress.mkv
ffmpeg version 4.2.2 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 10 (GCC)
configuration: --prefix=/usr --bindir=/usr/bin --datadir=/usr/share/ffmpeg --docdir=/usr/share/doc/ffmpeg --incdir=/usr/include/ffmpeg --libdir=/usr/lib64 --mandir=/usr/share/man --arch=x86_64 --optflags='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection' --extra-ldflags='-Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld ' --extra-cflags=' ' --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-version3 --enable-bzlib --disable-crystalhd --enable-fontconfig --enable-frei0r --enable-gcrypt --enable-gnutls --enable-ladspa --enable-libaom --enable-libdav1d --enable-libass --enable-libbluray --enable-libcdio --enable-libdrm --enable-libjack --enable-libfreetype --enable-libfribidi --enable-libgsm --enable-libmp3lame --enable-nvenc --enable-openal --enable-opencl --enable-opengl --enable-libopenjpeg --enable-libopus --enable-libpulse --enable-librsvg --enable-libsrt --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libvorbis --enable-libv4l2 --enable-libvidstab --enable-libvmaf --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-libzimg --enable-libzvbi --enable-avfilter --enable-avresample --enable-postproc --enable-pthreads --disable-static --enable-shared --enable-gpl --disable-debug --disable-stripping --shlibdir=/usr/lib64 --enable-libmfx --enable-runtime-cpudetect
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, matroska,webm, from 'Natsunagu-01.mkv':
Metadata:
encoder : libebml v1.3.10 + libmatroska v1.5.2
creation_time : 2020-02-03T17:37:17.000000Z
Duration: 00:04:00.06, start: 0.000000, bitrate: 1766 kb/s
Stream #0:0: Video: h264 (Main), yuv420p(tv, bt709, progressive), 1280x720 [SAR 1:1 DAR 16:9], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
Metadata:
BPS-eng : 1551044
DURATION-eng : 00:03:59.990000000
NUMBER_OF_FRAMES-eng: 5754
NUMBER_OF_BYTES-eng: 46529396
_STATISTICS_WRITING_APP-eng: mkvmerge v43.0.0 ('The Quartermaster') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2020-02-03 17:37:17
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:1(jpn): Audio: aac (LC), 48000 Hz, stereo, fltp (default)
Metadata:
BPS-eng : 197907
DURATION-eng : 00:04:00.064000000
NUMBER_OF_FRAMES-eng: 11253
NUMBER_OF_BYTES-eng: 5938795
_STATISTICS_WRITING_APP-eng: mkvmerge v43.0.0 ('The Quartermaster') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2020-02-03 17:37:17
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:2(eng): Subtitle: ass (default) (forced)
Metadata:
BPS-eng : 93
DURATION-eng : 00:03:55.380000000
NUMBER_OF_FRAMES-eng: 56
NUMBER_OF_BYTES-eng: 2758
_STATISTICS_WRITING_APP-eng: mkvmerge v43.0.0 ('The Quartermaster') 64-bit
_STATISTICS_WRITING_DATE_UTC-eng: 2020-02-03 17:37:17
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
Stream #0:3: Attachment: ttf
Metadata:
filename : NotoSans-Bold.ttf
mimetype : application/x-truetype-font
[matroska @ 0x55dfe4ab9600] Invalid stream specifier: 0:2.
Last message repeated 1 times
Came back to this today because I am getting tired of Handbrake.
Same issue. Currently on Fedora 32.
If I remove the data for 0:2 form the ffmpeg command the encode runs.
I removed this: -map 0:2 -metadata:s:0:2 title=English -metadata:s:0:2 DISPOSITION:default=0
ffmpeg -i Amachan_030.mkv -y -acodec copy -vcodec libx265 -filter:v crop=1264:720:6:0 -c:s copy -pix_fmt yuv420p -map 0:0 -map 0:1 -metadata:s:a:1 title="Japanese AAC LC (Stereo)" -map 0:2 -metadata:s:0:2 title=English -metadata:s:0:2 DISPOSITION:default=0 -preset medium -x265-params crf=19:allow-non-conformance:ref=8:bframes=8:rd=6:me=star:b-adapt=2:qg-size=64:rc-lookahead=40:scenecut=45:weightb=1:psy-rd=2.0: ./Amachan_030.encoding-in-progress.mkv
results in
Input #0, matroska,webm, from 'Amachan_030.mkv':
Metadata:
title : あまちゃん
encoder : libebml v1.3.0 + libmatroska v1.4.0
creation_time : 2013-08-07T23:49:20.000000Z
Duration: 00:15:00.00, start: 0.000000, bitrate: 3770 kb/s
Stream #0:0: Video: h264 (High), yuv420p(progressive), 1280x720, SAR 1:1 DAR 16:9, 29.97 fps, 29.97 tbr, 1k tbn, 59.94 tbc (default)
Stream #0:1(jpn): Audio: aac (LC), 48000 Hz, stereo, fltp (default)
Stream #0:2(eng): Subtitle: subrip (default)
[matroska @ 0x563711029640] Invalid stream specifier: 0:2.
Last message repeated 1 times
Removing the data for stream 0:2
ffmpeg -i Amachan_030.mkv -y -acodec copy -vcodec libx265 -filter:v crop=1264:720:6:0 -c:s copy -pix_fmt yuv420p -map 0:0 -map 0:1 -metadata:s:a:1 title="Japanese AAC LC (Stereo)" -preset medium -x265-params crf=19:allow-non-conformance:ref=8:bframes=8:rd=6:me=star:b-adapt=2:qg-size=64:rc-lookahead=40:scenecut=45:weightb=1:psy-rd=2.0: ./Amachan_030.encoding-in-progress.mkv
results in
Try master branch version.
npm install FallingSnow/h265ize --global
h265ize --version
Versions:
Test run
A stand alone ffmpeg worked though.