Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: FLAC enc/dec errors (split) (Read 5366 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

FLAC enc/dec errors (split)

Quote
hmm....I have had huge problems making flacs with the latest encoder. I got a lot of currupted files though they were playable.

I've had no bug reports like that for flac-1.1.0, can you host one somewhere so I can take a look?

Josh

FLAC enc/dec errors (split)

Reply #1
Quote
Quote
hmm....I have had huge problems making flacs with the latest encoder. I got a lot of currupted files though they were playable.

I've had no bug reports like that for flac-1.1.0, can you host one somewhere so I can take a look?

Josh

I will see if I can reproduce the problem.
I got multiple errors while encoding and just gave up.

FLAC enc/dec errors (split)

Reply #2
Quote
Quote
Quote
hmm....I have had huge problems making flacs with the latest encoder. I got a lot of currupted files though they were playable.

I've had no bug reports like that for flac-1.1.0, can you host one somewhere so I can take a look?

Josh

I will see if I can reproduce the problem.
I got multiple errors while encoding and just gave up.

I'm sorry, but I can't reproduce the original problems I had. I did however run into other problems.
Quote
D:\test\flac>flac -8 "006 09. Nobody Loves You (When You're Down And Out).wav"

flac 1.1.0, Copyright © 2000,2001,2002,2003 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY.  This is free software, and you are
welcome to redistribute it under certain conditions.  Type `flac' for details.

options: -P 4096 -b 4608 -m -l 12 -e -q 0 -r 0,6
006 09. Nobody Loves You (When You're Down And Out).wav: 0% complete, ratio=0,45
006 09. Nobody Loves You (When You're Down And Out).wav: 1% complete, ratio=0,22
006 09. Nobody Loves You (When You're Down And Out).wav: 1% complete, ratio=0,23
006 09. Nobody Loves You (When You're Down And Out).wav: 2% complete, ratio=0,24
006 09. Nobody Loves You (When You're Down And Out).wav: 3% complete, ratio=0,24
006 09. Nobody Loves You (When You're Down And Out).wav: 3% complete, ratio=0,25
006 09. Nobody Loves You (When You're Down And Out).wav: 4% complete, ratio=0,26
006 09. Nobody Loves You (When You're Down And Out).wav: 4% complete, ratio=0,28
006 09. Nobody Loves You (When You're Down And Out).wav: 5% complete, ratio=0,29
006 09. Nobody Loves You (When You're Down And Out).wav: 6% complete, ratio=0,30
006 09. Nobody Loves You (When You're Down And Out).wav: 6% complete, ratio=0,32

it goes on like this till the end. It only happened on this file amongst the 20 files or so I tested.

-------------------------------

I was able to find the file that originally caused the problems... and the original error:
Quote
right through this_mixdown.wav: ERROR initializing encoder 
state = 18:FLAC__STREAM_ENCODER_FATAL_ERROR_WHILE_WRITING



But right now I get other errors instead.
Encoding:
Quote
options: -P 4096 -b 4608 -m -l 12 -e -q 0 -r 0,6
right through this_mixdown.wav: wrote 18312816 bytes, ratio=0,524
ERROR: for encoding a raw file you must specify a value for --endian, --sign, --
channels, --bps, and --sample-rate

I don't know if this is important but the file seems fine.

Also I get this error when I decode:
Quote
right through this_mixdown.flac: done

test.wav: ERROR initializing decoder
          state = 2:FLAC__FILE_DECODER_ERROR_OPENING_FILE

....and it doesn't write a decoded file.

FLAC enc/dec errors (split)

Reply #3
@Jan S.

I believe the file which streams all the lines down the screen is simply because the  encoding line can't fit in your cmd.exe windows properly, try increasing the window size or it's buffer or try the file again with a shorter name. I seem to remember this was the problem, it's purely asthetical though, it has no effect on quality.

As for the others, im busy on the last day of my university final year project write up so i'll have a look at those  some other time.

Cheers,
Kristian

FLAC enc/dec errors (split)

Reply #4
Quote
I believe the file which streams all the lines down the screen is simply because the  encoding line can't fit in your cmd.exe windows properly, try increasing the window size or it's buffer or try the file again with a shorter name. I seem to remember this was the problem, it's purely asthetical though, it has no effect on quality.

I can conferm that that is the reason for the first error.
It's the 2rd file that is the real problem though.

FLAC enc/dec errors (split)

Reply #5
Is the .wav file a valid .wav with a proper header. It seems the encoder is unable to determine it's information from the wav hence it asks:

ERROR: for encoding a raw file you must specify a value for --endian, --sign, --channels, --bps, and --sample-rate

Have you tried opening this file in a wav editor and how was it created in the first place?

I presume because it doen't understand this information, it defaults to some values or doesn't store any values, hence it needs these to decode the file.

Can you post the .wav if its not to big?

Cheers,

KRistian

EDIT -- also try -F to force decoding through errors!!!

FLAC enc/dec errors (split)

Reply #6
I send you a link (PM)...it's 16mb though.
Originally it was made with cool edit pro...it's a song I helped a friend record.
I don't have the original wav anymore but I have an ape file.
I tried encoding from a file decode with foobar diskwriter and a file decoded with mac.exe; same result.

FLAC enc/dec errors (split)

Reply #7
@ Jan S.

I got the file and decoded to .wav using foobar2000.

i then ran:



Code: [Select]
flac Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\Documents and Settings\Kristian  Tippins\Desktop>flac "001 right through this
_mixdown.wav"

flac 1.1.0, Copyright (C) 2000,2001,2002,2003 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY.  This is free software, and you are
welcome to redistribute it under certain conditions.  Type `flac' for details.

options: -P 4096 -b 4608 -m -l 8 -q 0 -r 3,3
001 right through this_mixdown.wav: wrote 18405497 bytes, ratio=0.527

C:\Documents and Settings\Kristian  Tippins\Desktop>


No errors, there.

I then decoded it:
Code: [Select]
C:\Documents and Settings\Kristian  Tippins\Desktop>flac -d "001 right through t
his_mixdown.flac"

flac 1.1.0, Copyright © 2000,2001,2002,2003 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY.  This is free software, and you are
welcome to redistribute it under certain conditions.  Type `flac' for details.

001 right through this_mixdown.flac: done

C:\Documents and Settings\Kristian  Tippins\Desktop>


No errors there.

what was the exact command line you used?

Cheers,

Kristian

FLAC enc/dec errors (split)

Reply #8
Quote
D:\test>flac "right through this_mixdown.wav" "right through this_mixdown.flac"
-5

flac 1.1.0, Copyright © 2000,2001,2002,2003 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY.  This is free software, and you are
welcome to redistribute it under certain conditions.  Type `flac' for details.

options: -P 4096 -b 4608 -m -l 8 -q 0 -r 3,3
right through this_mixdown.wav: wrote 18403316 bytes, ratio=0,527
ERROR: for encoding a raw file you must specify a value for --endian, --sign, --
channels, --bps, and --sample-rate
Type "flac" for a usage summary or "flac --help" for all options

D:\test>flac "right through this_mixdown.flac" "right through this_mixdown.wav"
-d

flac 1.1.0, Copyright © 2000,2001,2002,2003 Josh Coalson
flac comes with ABSOLUTELY NO WARRANTY.  This is free software, and you are
welcome to redistribute it under certain conditions.  Type `flac' for details.

right through this_mixdown.flac: done
right through this_mixdown.wav: *** Got error code 0:FLAC__STREAM_DECODER_ERROR_
STATUS_LOST_SYNC
right through this_mixdown.wav: *** Got error code 0:FLAC__STREAM_DECODER_ERROR_
STATUS_LOST_SYNC

FLAC enc/dec errors (split)

Reply #9
I tried encoding at -8 as i noticed thats what you used.

I think i have found your problem.
It encoded fine as i have shown, however,if the filename.flac already exists and you try running that back through flac.exe, eg if you run "flac -8 filename.flac" by accident, it gives the error you had, and the file is then corrupt, gives the error you had again.

Could this have been your error?? Flac.exe doesn't prompt to overwrite a file, so you may have simply typed in the wrong command line!

If this is to obvious, im sorr, i don't mean to be condescending!


Cheers,

Kristian

FLAC enc/dec errors (split)

Reply #10
Possibly broken hardware - see this thread.

FLAC enc/dec errors (split)

Reply #11
Where did your posts vanish to Jan S. Im not going mad am i?????       

Krazy Kristian

FLAC enc/dec errors (split)

Reply #12
Quote
Where did your posts vanish to Jan S. Im not going mad am i?????       

He split the threads.

FLAC enc/dec errors (split)

Reply #13
You forgot the -o to specify the output file. I think flac can take several input files in one go. You encoded file.wav to file.flac and then flac tried to encode file.flac again!!!!

D:\test>flac "right through this_mixdown.wav" -o "right through this_mixdown.flac" -5

Cheers,

Kristian

FLAC enc/dec errors (split)

Reply #14
you are right.
It was just me being stupid. 
Vey strange that it only happened with this one file though...