Transcoding problem

Need help? Post your questions here.

Moderator: moderators

Transcoding problem

Postby DM-UK » Wed Sep 20, 2006 10:54 pm

I've only just come across this application, and so far it seems to be very nice, I do however have a big problem with it :(

I am using apple lossless files, which I transcode with a command line utility. I have managed to compile and get it working properly on windows, so far I have sucessfully integrated apple lossless with the Jinzora jukebox.

The issue (I've not done much with java - so its a bit of a guess) is the stdin/stdout mode. When I was first compiling the source (http://craz.net/programs/itunes/alac.html) I had to alter the file mode to binary for stdin/out otherwise any files output from the command line would only be static.

I assume that during the transcode in java that there is a non binary stream somewhere, I am using the same settings and execubles to transcode via stdin/out with php. This uses alaccommand | lamecommand with an exec().

I'm not quite sure how to work it out, so if any ideas are welcome.

David
DM-UK
 
Posts: 2
Joined: Wed Sep 20, 2006 10:38 pm

Postby sindre_mehus » Thu Sep 21, 2006 7:23 am

Hi David,

It's a bit unclear to me whether it worked or not after you changed stdin/stdout to binary. Also, it seems to me that binary mode is supposed to be used on Windows. From main.c:

Code: Select all
#ifdef WIN32
    setmode(fileno(stdout), O_BINARY);
    setmode(fileno(stdin), O_BINARY);
#endif


Anyway, if you only get static noise, it's most likely wrong byte order (little-endian vs big-endian). Did you try to add the "-x" option to LAME? It swaps the byte order.

By the way, I only use binary streams in the Java transcoding engine.

Hope this helps,
Sindre
User avatar
sindre_mehus
 
Posts: 1955
Joined: Tue Nov 29, 2005 6:19 pm
Location: Oslo, Norway

Postby DM-UK » Thu Sep 21, 2006 8:15 am

oops!

I've just noticed that when I reused the default m4a setting I forgot to remove the -x from the lame command line! :oops:

Problem solved :)

David
DM-UK
 
Posts: 2
Joined: Wed Sep 20, 2006 10:38 pm


Return to Help

Who is online

Users browsing this forum: No registered users and 14 guests