Hi list,
I didn't find a possibility to write table values as floats to a binary file, although I am almost sure this should exist in standard pd. I know I could use soundfiler but I don't want the header, just raw floats.
Any help appreciated, Matthias
hi
"Matthias Blau" blau_m@web.de wrote
I didn't find a possibility to write table values as floats to a binary file, although I am almost sure this should exist in standard pd. I know I could use soundfiler but I don't want the header, just raw floats.
what do you mean by raw floats? bytes as numbers from 0 to 255? if i understand you right, i had once a similar problem: i wanted to write a binary file byte by byte. finally i did it with soundfiler, because i couldnt find a better solution. since you cannot write 8-bit files with soundfiler, i had to convert two values (0-255) into one value (0-65536), scale it to -1 - 1, write it into an array, then save it as a 16bit wav-file. to get rid of the 44 byte long wav-header, i used the command:
dd if=input.wav ibs=44 skip=1 of=output
the disadvantage of this method is, that you can only write files that have an even number of bytes, and that you need a command outside of pd. please let me know, if you find a better solution.
roman
___________________________________________________________ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de
hi
"carmen" ix@replic.net wrote:
dd if=input.wav ibs=44 skip=1 of=output
is there not a setting(for soundfiler/writesf) to skip the header on write? there definitely is for read..
it might be -raw or something..
please, tell me, if there is such a possibility. the helpfile of [soundfiler] just mentions -raw for reading, but not for writing. nevertheless i tried it, but it didn't work.
if there isn't a such feature now, this would be a nice feature request...
roman