errors when decoding MLV by ffmpeg

Started by Cliver, August 17, 2023, 02:56:53 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Cliver

Hi all,

My goal is extracting video frames from MLV files. ffmpeg seems to support MVL. However, there are issues.
So, I'm looking for clarifications/tips on the following questions:

1) frames extracted by ffmpeg from MLV files have very low illumination relative to the respective frames by MLV-App.
What is the reason for this?

2) some MLV files cause ffmpeg to break on one of the following errors:
error#1: no index entries found
error#2: Decoding requested, but no decoder found for: none
How can these errors be fixed?

Thank you!

names_are_hard

The ffmpeg code for working with mlv wasn't written by ML team, so you're asking in the wrong place - you probably need to ask ffmpeg (or check their source, it's available).

You don't need to use ffmpeg to work with mlv files, so, if frame extraction is your end goal, there should be an easier way.

Cliver

Quote from: names_are_hard on August 17, 2023, 03:04:13 PM
You don't need to use ffmpeg to work with mlv files, so, if frame extraction is your end goal, there should be an easier way.

The whole project is a command line tool for conversion of MLV to other popular formats. Extracting frames from MLV is a subtask of it which would suffice because frames can be fed to ffmpeg to produce the required output.

What would you suggest to implement it? It can be either a ready-made tool with free license or an open source code which can be adapted for the task.

names_are_hard

Okay.  MLVFS already exists and does transparent MLV to CDNG conversion, possibly that's all you need: https://www.magiclantern.fm/forum/index.php?topic=13152.0

MLVApp is open source and can convert to multiple other formats.  It's not CLI, but adding CLI options would be useful and likely not too hard.

There's modules/mlv_rec/mlv_dump, which has many options (I haven't used this tool, just know it exists):


Usage: ./mlv_dump [options] <inputfile>
Parameters:
  -o output_file      write video data into a MLV file
  -v                  verbose output
  --version           print version information
  --batch             format output message suitable for batch processing
  --relaxed           do not exit on every error, skip blocks that are erroneous
  --no-audio          for DNG output WAV not saved, for MLV output WAVI/AUDF blocks are not included in destination MLV

-- DNG output --
  --dng               output frames into separate .dng files. set prefix with -o
  --no-cs             no chroma smoothing (default)
  --cs2x2             2x2 chroma smoothing
  --cs3x3             3x3 chroma smoothing


Many options trimmed, it's pages of possible flags!  Best to check yourself.