I've been playing around with the skeleton app that comes with the rreMicrophone external, with a view to using the external in my own app.
The audio format defaults to Linear PCM and the output file has a .aud extension (which the iPad does not recognise). I can change the extension to .aiff after the file has been produced and it will play OK, but it does not work if I change the extension in the script.
What I want to do is produce recordings in aac format, and it works OK if I change the output file extension (in the Start button script) to aac, and also manually select AAC from the pull down menu in the app. I want to change the audio format via script, but if I put the command rreMicrophoneSetAudioFormat 2 in the preOpenCard script it is ignored. I have tried "2" for the parameter but it makes no difference.
I'd appreciate advice on what I need to do.
TIA
Don
Changing format by script in rreMicrophone
Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller
-
- Livecode Opensource Backer
- Posts: 99
- Joined: Thu Aug 04, 2011 10:32 am
- Location: Albany, Western Australia
Re: Changing format by script in rreMicrophone
OK, I resolved the problem by using the following:
put "MP4-AAC" into tFormat
rreMicrophoneSetAudioFormat tFormat
For some reason the parameter has to be in a variable because neither MP4-AAC nor "MP4-AAC" works.
Originally I was using the number (2) corresponding to the value for MP4-AAC shown in the C Code. But not being a C programmer I obviously misconstrued that.
Cheers
Don
put "MP4-AAC" into tFormat
rreMicrophoneSetAudioFormat tFormat
For some reason the parameter has to be in a variable because neither MP4-AAC nor "MP4-AAC" works.
Originally I was using the number (2) corresponding to the value for MP4-AAC shown in the C Code. But not being a C programmer I obviously misconstrued that.
Cheers
Don