View Issue Details

IDProjectCategoryView StatusLast Update
0000553Cinelerra-GG[All Projects] Featurepublic2021-02-15 00:51
ReporterMatN Assigned ToPhyllisSmith  
Status assignedResolutionopen 
PlatformX86_64OSMint XFCEOS Version20.1
Product Version 
Target VersionFixed in Version 
Summary0000553: CinGG does not recognise audio format FLAC.
DescriptionAppImage 2020-02-07 newer-distros
Importing an audio in FLAC format results in an empty audio track. A recording in OGG format works fine. This recording is made by Gnome-sound-recorder, to replace the bad quality audio from the camera's microphone.
It Is easy to convert FLAC to WAV, but should CinGG not support it?
Steps To ReproduceSee description
TagsNo tags attached.




2021-02-15 00:51

manager   ~0004646

Well, I think that to be a legitimate flac file it should be constructed as such - otherwise why have standards at all.
It would be better if Cinelerra could put an error message on the terminal window stating a problem rather than what it is doing.
So we should leave this open in case some eager programmer shows up to add an error message.

MONO info:
1 audio stream
aud0 (0), id 0x01500c:
audio1-1 flac s16 44100 0bits
0+0 smpl 0.00 secs 0:00:00.00 *************************

1 audio stream
aud0 (0), id 0x01500c:
audio1-2 flac s16 44100 0bits
9062784+0 smpl 205.51 secs 0:03:25.51 *************************


2021-02-14 21:46

reporter   ~0004645

Ah, I just missed your earlier note. Maybe you are right, because the Audacity written file shows 'duration" . There is no field like that in STREAMINFO, but there is a field "Total samples in stream" that is probably used to compute the duration, given the sampling rate (which is present in the failing file).
Anyway, it looks like sound-recorder does not properly write STREAMINFO, some fields can only be done after the whole file is done but that is not problem as it is at a know place and a known size.


2021-02-14 21:38

manager   ~0004644

Last edited: 2021-02-14 21:59

View 2 revisions

Oh, that is great that you figured it out!
Does it have Duration now? Or can you send the output of mediainfo and/or ffprobe on the new file?



2021-02-14 21:36

reporter   ~0004643

It is likely related to the missing MD5 checksum, which in the original file is all zero's . I used Audacity, set up for 16 bit mode (not 32 bit floating point), imported the failing flac file into it, and exported it without any changes other than the file name. Now "flac -t" does not complain about MD5, and CinGG loads and plays it fine.
The next question is, the mandatory structure STREAMINFO is present, but the MD5 field is empty. I do not know yet what the spec says about it. If it is mandatory, then CinGG should maybe give an error as to why is does not load the file on the timeline.


2021-02-14 21:34

manager   ~0004642

Last edited: 2021-02-14 21:36

View 2 revisions

For some reason, I doubt that it is that simple. These 2 sample files, 1 works and 1 doesn't, are really very different in their characteristics as shown by:

./ffprobe /root/Downloads/Mono_44kb.flac
Input #0, flac, from '/root/Downloads/Mono_44kb.flac':
    ENCODER : Sound Recorder
    TITLE : /home/mat/Recordings/Clip 1
    DATE : 2021-02-14T10:58:53+0100
  Duration: N/A, start: 0.000000, bitrate: N/A
    Stream #0:0: Audio: flac, 44100 Hz, mono, s16

./ffprobe "/proj/samples/flac/When I Grow Up.flac"
Input #0, flac, from '/proj/samples/flac/When I Grow Up.flac':
  Duration: 00:03:25.51, start: 0.000000, bitrate: 928 kb/s
    Stream #0:0: Audio: flac, 44100 Hz, stereo, s16
    Side data:
      replaygain: track gain - -7.430000, track peak - 0.000023, album gain - -7.430000, album peak - 0.000023,

BUT I notice that the Mono has no "Duration" and that may be why CinelerraGG does not like it.



2021-02-14 20:07

reporter   ~0004641

I noticed that "flac -t" on the file reports that there is no MD5 info. Each flac file must contain a streaminfo block, one field of which is the MD5 sum of the audio data.
See . Do not know if this is causing the problem, will see tomorrow if I it is possible to add it manually.


2021-02-14 17:42

manager   ~0004640

Last edited: 2021-02-14 18:21

View 4 revisions

FFplay (ffmpeg) has no problem playing MatN's sample from the command line. But I notice when using mediainfo that the "Writing library" for the one that worked was: libFLAC 1.1.0 (UTC 2003-01-26) but for the Mono was: GStreamer encoded vorbiscomment .

I did try changing in Settings->Preferences, the "Probe Order" to force flac, or cr2, or vorbis, or others to try loading it first but still no luck.

Also checked to make sure are using the latest flac library which is 1.3.2 and we are.
So the problem must be the interface between CinelerraGG and ffmpeg.



2021-02-14 15:21

manager   ~0004639

Your FLAC file is imported into CinGG and LMB --> Info reads the data correctly. However, it is not possible to load it on the timeline or even in the Viewer window.
On the terminal I have this message:

FFStream::decode: Retry limit

Other FLACs downloaded randomly from the internet all work without problems.


2021-02-14 10:29

reporter   ~0004638

I have made new recordings, in mono and stereo, both show the same problem, so I have attached the smaller mono version only.
I load the file in a fresh AppImage as "replace current project" . Audacity plays it fine, the "file" cmd on the file shows nothing unexpected, exporting the file from Audacity to .wav format make the .wav file load fine in CinGG.
With the flac file, I do see quite a few errors in the terminal I start the AppImage from.
File is 44.1 kHz, 16 bits signed.

Mono_44kb.flac (725,329 bytes)


2021-02-14 04:30

reporter   ~0004635

seems to work fine here too (self-compiled CinGG from 8th Feb). Be sure to check 'Resources->Media', if you have default load strategy 'Only create resources'. If you set it to 'replace current project' - file will appear on timeline (replacing anything that was there) on load. Otherwise you just drag it from 'Resources->Media' on timeline ....


2021-02-13 18:21

manager   ~0004633

Here is the link to test file:


2021-02-13 18:10

manager   ~0004632

Last edited: 2021-02-13 18:21

View 2 revisions

Perhaps there is a problem with the flac file. I tested this one both using the usual binary and with appimage (newer) and it played for me. Did I miss something?
# mediainfo "When I Grow Up.flac"
Complete name : When I Grow Up.flac
Format : FLAC
Format/Info : Free Lossless Audio Codec
File size : 22.7 MiB
Duration : 3 min 25 s
Overall bit rate mode : Variable
Overall bit rate : 928 kb/s
Album replay gain : -7.43 dB
Album replay gain peak : 1.000000

Format : FLAC
Format/Info : Free Lossless Audio Codec
Duration : 3 min 25 s
Bit rate mode : Variable
Bit rate : 928 kb/s
Channel(s) : 2 channels
Channel layout : L R
Sampling rate : 44.1 kHz
Bit depth : 16 bits
Compression mode : Lossless
Replay gain : -7.43 dB
Replay gain peak : 1.000000
Stream size : 22.7 MiB (100%)
Writing library : libFLAC 1.1.0 (UTC 2003-01-26)

Test file too big to send here. Check the next note for link.

Issue History

Date Modified Username Field Change
2021-02-13 15:58 MatN New Issue
2021-02-13 18:10 PhyllisSmith Note Added: 0004632
2021-02-13 18:11 PhyllisSmith Assigned To => PhyllisSmith
2021-02-13 18:11 PhyllisSmith Status new => feedback
2021-02-13 18:21 PhyllisSmith Note Added: 0004633
2021-02-13 18:21 PhyllisSmith Note Edited: 0004632 View Revisions
2021-02-14 04:30 Andrew-R Note Added: 0004635
2021-02-14 10:29 MatN File Added: Mono_44kb.flac
2021-02-14 10:29 MatN Note Added: 0004638
2021-02-14 10:29 MatN Status feedback => assigned
2021-02-14 15:21 Andrea_Paz Note Added: 0004639
2021-02-14 17:42 PhyllisSmith Note Added: 0004640
2021-02-14 18:18 PhyllisSmith Note Edited: 0004640 View Revisions
2021-02-14 18:19 PhyllisSmith Note Edited: 0004640 View Revisions
2021-02-14 18:21 PhyllisSmith Note Edited: 0004640 View Revisions
2021-02-14 20:07 MatN Note Added: 0004641
2021-02-14 21:34 PhyllisSmith Note Added: 0004642
2021-02-14 21:36 PhyllisSmith Note Edited: 0004642 View Revisions
2021-02-14 21:36 MatN Note Added: 0004643
2021-02-14 21:38 PhyllisSmith Note Added: 0004644
2021-02-14 21:46 MatN Note Added: 0004645
2021-02-14 21:59 PhyllisSmith Note Edited: 0004644 View Revisions
2021-02-15 00:51 PhyllisSmith Note Added: 0004646