콘텐츠로 바로가기

now0930 일지

이런저런 생각

  • 홈
  • 비공개
  • 강좌
  • 잔여 작업 조회
  • 위치

ffmpeg으로 VOB를 MP4로 인코딩하기

아래 사이트에서 참조.
https://www.internalpointers.com/post/convert-vob-files-mkv-ffmpeg

ffmpeg \
  -analyzeduration 100M -probesize 100M \
  -i output.vob \
  -map 0:1 -map 0:3 -map 0:4 -map 0:5 -map 0:6 \
  -metadata:s:a:0 language=ita -metadata:s:a:0 title="Italian stereo" \
  -metadata:s:a:1 language=eng -metadata:s:a:1 title="English stereo" \
  -metadata:s:s:0 language=ita -metadata:s:s:0 title="Italian" \
  -metadata:s:s:1 language=eng -metadata:s:s:1 title="English" \
  -codec:v libx264 -crf 21 \
  -codec:a libmp3lame -qscale:a 2 \
  -codec:s copy \
  output.mkv

Let me dissect it:

  • -analyzeduration 100M -probesize 100M — keep this one so that FFmpeg is able to find hidden streams;
  • -i output.vob — the input file;
  • -map 0:1 -map 0:3 -map 0:4 -map 0:5 -map 0:6 — here I’m mapping the streams, namely I’m telling FFmpeg to keep Stream 0:1, Stream 0:3, Stream 0:4, Stream 0:5, Stream 0:6 and put them in the output file in that specific order;
  • -metadata[…] — this is used to give streams a title and other additional information, specifically to audio tracks (s:a:0 and s:a:1 where a stands for audio) and subtitles (s:s:0 and s:s:1 where s stands for subtitles);
  • -codec:v libx264 -crf 21 — defines the video codec in use and the constant rate factor (crf), namely the quality level. This method allows the encoder to keep a constant quality level, regardless the output file size: 0 is lossless, 23 is default, and 51 is worst possible. The sane range is between 18 and 28;
  • -codec:a libmp3lame -qscale:a 2 — defines the audio codec in use and the quality level: 0-3 will produce transparent results, 4 (default) should be close to perceptual transparency, 6-9 produces an “acceptable” quality. Using numbers from 0 to 9 means that the audio track will be encoded in variable bitrate (vbr) mode: smaller files, better quality;
  • -codec:s copy — s stands for subtitles: copy them as they are;
    output.mkv — the output file.

Bonus point: if your machine supports it, add the flag -threads N to enable multi-threading and give the encoding a boost. Replace N with the number of your CPU cores.

이 글 공유하기:

  • Tweet
발행일 2017-11-18글쓴이 이대원
카테고리 생활코딩 태그 encodeing, ffmpeg, vob

댓글 남기기응답 취소

이 사이트는 Akismet을 사용하여 스팸을 줄입니다. 댓글 데이터가 어떻게 처리되는지 알아보세요.

글 내비게이션

이전 글

국제법을 알아야 논쟁할 수 있는 것들

다음 글

환관과 궁녀

2025 5월
일 월 화 수 목 금 토
 123
45678910
11121314151617
18192021222324
25262728293031
4월    

최신 글

  • common mode, differential mode 2025-05-11
  • signal conditioner, 신호 처리기 2025-05-10
  • strain gage 2025-05-09
  • 칼만 필터 2025-05-01
  • positioner(I/P) 2025-04-26

카테고리

  • 산업계측제어기술사
  • 삶 자국
    • 책과 영화
    • 투자
  • 생활코딩
    • LEGO
    • ROS
    • tensorflow
  • 전기기사
  • 피아노 악보

메타

  • 로그인
  • 엔트리 피드
  • 댓글 피드
  • WordPress.org

페이지

  • 소개
  • 잔여 작업 조회
    • 작업 추가
    • 작업의 사진 조회
    • 작업 수정 페이지
  • 사진
    • GPS 입력된 사진
    • 사진 조회
  • 위치
    • 하기 휴가 방문지
    • 해외 출장

태그

android bash c docker driver FSM gps java kernel LEGO linux mysql network program opcua open62541 plc programmers python raspberry reinforcementLearning ros state space system program tensorflow transfer function 경제 미국 민수 삼국지 세계사 실기 에너지 역사 유전자 일본 임베디드 리눅스 전기기사 조선 중국 채윤 코딩 테스트 통계 한국사 한국어

팔로우하세요

  • Facebook
now0930 일지
WordPress로 제작.