Determine audio file play time from size

Hello!
I have a mp3 file and i want to determine it's play time from it's length. Is this thing possible? Could anyone point me in the right direction?
Thanks in advance!
Cheers!
Radu

Thanks you both for your replies!
I posted yesterday late in the evening and my brain didn't work quite well :)). After i've read your posts today, i realized that i will be using mplayer in slave mode to play the audio file, and a quick google search showed me that mplayer offers a way to retreive the play time of any audio/video file (in seconds). Tested it today and it works! So i guess my question has been answered.
Thanks again
Cheers!
Radu

Similar Messages

  • Why don't some audio files play back in enhanced iBook?

    I recently bought an enhanced iBook in iTunes for my iPad and most of the audio files play.  A few do not when I click on them. The player goes blank (disappears) and nothing happens. Does anyone have a solution?

    In iTunes, select all the songs/files you want to stay where they are.
    Right click - get info.
    Tick *Remember position* and set it Yes.
    You can do individual songs or a bunch at once.

  • Random audio file playing

    Hi!  I've been having random audio files playing on my RAZR.  It sounds like a video that automatically starts playing on websites.  However, I'm not on the browser, have windows open, or even using the phone.  I unlock the phone and there's nothing in the notification bar.  No apps are open on the home screen. 
    My Alarm Clock Plus app will sometimes play an alarm after I've turned it off.  Because there's nothing in the notification bar to stop the music, I have to shut down my phone to stop it.  This may be an app bug but has anyone had random audio files playing?

        Hi Es80
    It sounds like that phone is possessed! Let's get this fixed! It sounds like it may be an application error. Please power the device on in safe mode and retest. Here's how:http://bit.ly/QfA8MZ
    Please let me know if the issues persists.
    Thank you
    JoeL_VZW
    Please follow us on twitter @vzwsupport

  • How do you start 2+ audio files playing at the same time?

    I am trying to play 2 audio files at the same time, but I cannot figure out how to start them playing at the same time without latency issues.
    If someone can please explain the process for doing this using Audio Queue Services, I will forever be in your debt.
    This is for iPhone, but I was getting no love in those forums on this issue.

    Thanks for your reply. Apple's iPhone Application Programming Guide states the Following:
    *Playing Multiple Sounds Simultaneously*
    To play multiple sounds simultaneously, create one playback audio queue object for each sound. For each audio queue, schedule the first buffer of audio to start at the same time using the AudioQueueEnqueueBufferWithParameters function.
    This leads me to believe that it is possible. I have just not been able to get them to play precisely the same time, there is always delay.

  • Getting audio file properties (length and size)

    Hi,
    when I load a screen I have two labels. One should display me the audio file length (in seconds) and the other the size (in MB).
    But I cant get it to work. The labels just show me '(null)' all the time.
    What am I missing here?
    @interface AudioViewController : UIViewController {
    NSString *size;
    NSString *length;
    IBOutlet UILabel *audioSize;
    IBOutlet UILabel *audioLength;
    -(UInt32)audioFileSize: (AudioFileID)fileDescriptor
    //Get file size
    UInt64 outDataSize = 0;
    UInt32 thePropSize = sizeof(UInt64);
    OSStatus result = AudioFileGetProperty(fileDescriptor, kAudioFilePropertyAudioDataByteCount, &thePropSize, &outDataSize);
    if(result != 0) NSLog(@"cannot find file size");
    NSLog(@"file size: %@", result);
    return (UInt32)outDataSize;
    //Get file length
    NSTimeInterval seconds;
    UInt32 propertySize = sizeof(seconds);
    OSStatus err = AudioFileGetProperty(fileDescriptor, kAudioFilePropertyEstimatedDuration, &propertySize, &seconds);
    if(err != 0) NSLog(@"cannot find file length");
    NSLog(@"file length: %f", seconds);
    size = [NSString stringWithFormat:@"%i", outDataSize];
    length = [NSString stringWithFormat:@"%f", seconds];
    - (void)viewWillAppear: (BOOL)animated {
    audioSize.text = [NSString stringWithFormat: @"%@", size];
    audioLength.text = [NSString stringWithFormat: @"%@", length];
    Thanks for your help!

    you should not attach sounds to timelines if you want precise control of your sounds, and use actionscript. 
    that said, your sound will play if you assign its sync property to event, instead of stream.

  • Corrupt audio file prevents me from opening Logic project file

    Hello,
    I've been running Logic 8 for a couple years off my MacBook and have never encountered any significant problems of file corruption until recently.
    The issue I encountered is this:
    I've been producing a lengthy track in an on-going Logic project file for some time and after completing a recording session I saved and started deleting excess track copies to clean up my arrange window. Upon doing so Logic unexpectedly crashed.
    After attempting to reopen the project file, it started its normal process of loading its respective audio files, but now it hangs on one particular audio file indefinitely (I'll refer to it as 'audio file x' for ease of reference), freezing and crashing Logic as a result. All of this project file's auto backup files are also incapable of being opened without giving me the same result and crashing Logic.
    I have no way of opening this project file and getting at my most recent saved sequence!
    I've tried removing this corrupt 'audio file x' from the project's audio folder and dragging it to the desktop, but this had no effect and I still can't open any recent version of the project file.
    Older saved copies of the current project file do still open though (most likely because they were saved prior to the corruption caused by this suspect 'audio file x.') When opening an earlier iteration of the project, I get a message '1 invalid audio region found' (I assume referring to the corrupt suspect 'audio file x' that I removed to the desktop) but the project file is still able to open.
    I realize I could import the audio files from the most recent version of the crashed file to an older project version and reconstruct things back to the way they were, but it would take me a lot of time and I'm hoping there may be some way to recover the un-openable project file by getting it to stop looking for this corrupted 'audio file x' on startup.
    When I click 'show package contents' of the Logic Project file, I notice two items labeled 'displayState' and 'documentData.' From my troubleshooting I've come to the basic understanding that the 'documentData' file contains all the sequence data and settings for its respective Logic Project file.
    I think the 'document data' of the unopenable project file in question may be corrupt because whenever I replace it with the 'document data' from an earlier Project file version, the file is able to open. This doesn't do me much good though, because it's document data from an earlier iteration of the project and I need to be able to get at the current sequence I had right before my file crashed.
    Is there anyway to open a project file without letting it load its audio files? Or is there anyway I could get inside the 'document data' file to delete the reference/pathway in its audio bin to the corrupt 'audio file x' its hanging on?
    Any insights would be greatly appreciated. I'm hoping there's some way I won't have to repeat a couple days worth of work. Thanks for your help!

    stooby3535 wrote:
    After further troubleshooting I've realized that the suspicious audio file that prevents the project file from opening is actually not corrupted itself. I can still play the audio file in other media software like Quicktime, etc. with no problem.
    This leads me to believe the problem opening the project file lies solely with the corrupted 'documentData' file.
    Does anyone have any ideas about how I could somehow open this project file and delete the reference of the troublesome audio file from the project's audio bin?
    Well... it really sounds like the project itself is corrupted, that's one of the reasons all project files won't load from a certain point on.
    Try this.
    Reboot the Mac.
    Open the Applications folder and boot Logic from it's icon.
    As soon as the Logic Logo/graphic window appears on the screen hold down the control key. You will see a message pop up that says something like "Launch the Core Audio Driver" there will be yes/no choice available... select NO.
    Go to the File menu and selct "open" go find your project file and see if it will open. If it does.. delete the audio file in question... however.. I would also look at any plugins you recently installed and are possibly using in this project...this sounds more like a plugin problem rather than an audio file problem, but that's just a gut feeling.
    Anyway, if it opens delete whatever you suspect and save under a different name.
    Reboot Logic and see if it can load the project.
    pancenter-

  • Change the volume of one audio file played in icm script

    Hello,
    Using the play external script element to simply play queue music (recorded as 10 minutes long), is there a way to adjust the volume of the audio being played within the script without having to re-record that specific audio file?
    95% of our static audio is recorded fine and plays at the appropriate volume, but we have new queue music coming in all the time (with sales info, annoncements, etc.) that is different in volume from time to time and it would be nice to have an adjustment filter for playing that specific audio file and then adjust back to the default (if needed) afterward.
    This would be much easier than asking our vendor to re-record over and over again until tested right.
    Anything possible with this? Or would there be something on CVP that could control volume for one specific audio file?
    Thanks for any info,
    Greg

    Even if CVP could control the volume on individual files (It can't, as far as I know), you're better off normalizing the file in Audacity as David mentioned. Having some server modify things on the fly is just wasting resources, why not adjust the file? Audacity is free and open source.
    We record our voice prompts using a Unity Connections Voicemail box... Not the cleanest solution, but it works well for us as we have small global contact centers all in different regions, with different voices for each center. I make a habit of running all of my files through Audacity before putting them on media servers - otherwise I would potentially have prompts recorded at different times having different volumes depending on how "the voice" and Unity were doing that day, not to mention all the pops and clicks from using a sub-optimal recording solution.  Normalize and the Envelope Tool are my best friends.
    -Jameson

  • How do I make a ringtone with GarageBand for my iPhone from rights-protected AAC audio files I purchased from iTunes?

    When I try to import some songs I purchased from iTunes into GarageBand so I can create a customer ringtone a window pops open stating that I cannot import a rights-protected AAC audio file?  I bought the song from iTunes and can play it on my iPhone iPod application.  Does not make sense except from a mercenary perspective why I cannot create  a custom ringtone from the song and play it on my iPhone when the phone rings.  Is there a solution?

    You cannot use DRM protected songs for this as they are drm protected to stop you from doing this.
    Any itunes plus ( all itunes music sold over the past couple of years or so) can be used to make ringtones.

  • How can I control whether or not an audio files plays when a slide starts?

    I am putting together a course and have a welcome audio that plays automatically when the user begins the course. Since that slide has a list of the modules that will be in the course, I would also like to use it as one navigation option - click the "Menu" link on any slide and return to this page.
    The problem: Every time the page is hit the audio plays.
    The question: How can I set the audio so it only plays the first time the page is entered but not again?
    I have created a variable called "PlayWelcomeAudio" and set it to "Y" initially, then have an Advanced Action script that changes the variable to "N" when it is clicked (progress through the course is linear so there is only one option available to the user at this point. Clicking that link opens the next page and sets "PlayWelcomeAudio" to "N".
    I can see that the variable has been set correctly (when I start it is "Y" and when I come back it is "N") but I'm not seeing anyplace where I can set the audio file so it doesn't play.
    I tried setting cpCmndMute to "1" but that didn't work because it is apparently a global setting and I didn't get any audio playing anywhere after that.
    I'm not looking to pause the timeline or anything like that. I just want the audio to play the first time but not the second and subsequent times that page is hit.
    Thoughts? Suggestions?
    Thanks.
    Michael

    Attach your welcome audio to an object that is not seen (e.g. a highlight box set to 0%) and use your Advanced Actions and variables to HIDE this object ON SLIDE ENTER if the user returns to the same Menu slide at a later point in the course module.
    This should mean that the first time the user gets to that slide, the audio will play.  But all subsequent times they return to that slide, the object will be immediately hidden on entering the slide, which will mean that the audion does not play and all the user sees are the menu options.
    Your alternate strategy would be to have two slides that look almost the same.  The first one has the audio, and the second one doesn't.  Your TOC item for Menu, and any other links in the project that point to the Menu, would go to the second slide without audio.  The user will be none the wiser as long as you work out the navigation.

  • I need to copy audio files and projects from logic to an external hard as my MBPis nearly full and my external hard drive has packed up with all my files on it, any suggestions on how do I copy 200GB from my MBP to a new external HD

    I Use logic and back my audio file and projects on an external HD ,this has now packed up . I have all the files in the MBP , but need to copy them to a new external HD, I have only 10GB left on my machine , how do I copy 200GB from my machine to a new External HD.
    any helpful full advice would be appreciated.
    angus

    Yes, just drag and drop them into the drive..
    How long will it take? Hard to say without knowing the type and speed of the drives in question.. and even then it's hard to estimate... but does time really matter?
    The fact you only have 10 Gigs left will/may slow the process down but it wont/shouldn't stop it...
    If needed.. just drag and drop some of the files at a time.. not all of them.
    Remember that copying files doesn't delete them from the original drive... You will still need to delete them yourself after they are copied over and empty the trash....
    However....
    When you saved these projects in Logic (Pro X?) did you save them using the include audio files option?
    If not, then when you move the audio files used in these projects... Logic will not know where they are to reload them........ and that will cause you issues.
    So.. if you didn't...
    I would use this method instead...
    Logic Pro X: Move, copy, and convert audio files

  • Why is my iTunes insisting on 'determining audio volume' every time?

    I upgraded to iTunes 9 a few weeks back and seemingly from that point onwards my iTunes application wants to 'determine audio volume' on a great number of tracks as soon as the program is launched.
    The setting is unticked in Preferences on iTunes and on the iPod I synch with.
    I don't want it to be doing this, especially as I'm quite happy to manually change this level if I feel its required, but can find no way of preventing it, aside from clicking on the 'x' in the top window whenever it starts - which is becoming tiresome.
    I've tried deleting the cache file in Library > Caches and also starting up in Safe Mode and then opening again in normal mode but all to no avail.
    Help!!!

    Make sure you have also unticked sound check in the burn settings dialog you get when you burn a playlist to disc.

  • Dumb question. Why won't my audio files play in AE?

    Suddenly, my audio files will not play in AE.

    You'll need to elaborate -- that's not much to go on.
    What KIND of audio files are these?  Are they a different kind than you've used previously?
    Since AE has a tough time playing just about anything, please describe in detail how you're playing them.
    And it wouldn't hurt to know what has changed on your machine before you ran into this problem.

  • Audio file plays in my  itunes but restarts my ipod

    I downloaded some audio files that play perfectly in my itunes but when I click on the middle button of my ipod to choose song to play, it restarts my ipod. All other files I have play in both my itunes and ipod perfectly. Thanks for help!

    You don't have to check Manually manage music and videos, but if you want to add songs and video to the iPhone by dragging them to the iPhone in iTunes, that checkbox needs to be checked.  Otherwise, you can use the Music tab (next to the Summary tab) to set up automatic syncing, based on playlists, artists, albums, and/or genres, which for me is the more convenient way to load an iPod or iPhone.  I usually do it using playlists (that have only the songs I want on my Pod).
    I don't know what's going on with that one Amazon download.  I've downloaded songs from Amazon before, and have not encountered any problems.  I haven't done so recently, so maybe I'll find something free (they have a lot of free downloads compared to the iTunes Store) and give it a try, to see if I have the same problem.
    As a workaround, you can try converting the song file.  First, open iTunes preferences and click on the General tab.  Then, click Import Settings.  Make sure it is set to AAC Encoder and iTunes Plus (which should be the default settings).  This setting will encode (if you "rip" any music CDs), or convert song files, to the format used by iTunes Store downloads, which is 256 kbps ACC.
    Select the Amazon download with the problem your iTunes music library listing.  Go up to the menu bar.  Under Advanced, select Create AAC Version.  (You can also select that command by right-clicking on song.)
    This will convert the song file to AAC format.  The original MP3 file will still be there, but you will also have an AAC version.  You should be able to sync an AAC song file created by iTunes to your iPhone.
    NOTE:  When you do this, you are converting one compressed audio format to another compressed audio format, so there may be a small loss in sound quality.  The difference is probably not noticeable when listening on an iPod or iPhone using "earbuds."  When listening to the song on the computer, you should use the original song file.

  • Random audio file plays

    Randomly a audio file from a you tube video that my son watched about Transformer toys will play. I can close out all applications and the audio is still playing. Any ideal on where to look for this file? I am sure there is a key stroke or something that its programed to, i just can't seem to figure it out. HELP!

    Reset Safari.
    Click Safari in the menu bar.
    From the drop down select "Reset Safari".
    Click "Reset".
    Empty Caches
    Safari > Preference > Advanced
    Checkmark the box for "Show Develop menu in menu bar".
    Develop menu will appear in the Safari menu bar.
    Click Develop and select "Empty Caches" from the dropdown.

  • MP3 audio file plays well in some browsers, but not all

    I have inserted a media file (MP3 audio file) on a web page to play when clicked.  The play bar shows up and plays perfectly in Chrome just the way I want it. In Explorer the play bar is HUGE and it plays, but repositions itself on the page due to it's large size.  In Safari or Opera the play bar either doesn't play anything or doesn't even show upon the page.  Does anyone have a ny idea what's going on or have a solution? 
    http://www.starcatcluster.com/revue.html

    #1 You must use an HTML5 doc type. Your doc type is XHTML which doesn't support <audio> tags.
    #2  To work in all browsers, you need to include an alternate file type -- either OGG or WMA.  Opera & pre-FF21 browsers do not support MP3/mpeg files.
    http://audio.online-convert.com/convert-to-ogg
    #3 Don't use folder/filenames with spaces on the web.  Rename your media files to Mixdown_with_Vocalists.mp3 (no spaces). 
    #4  Paste this code into a new, blank document.  It should work in all devices:
    <!doctype html>
    <html lang="en">
    <head>
    <meta charset="utf-8">
    <title>HTML5 Document</title>
    <!--[if lt IE 9]>
    <script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->
    </head>
    <body>
    <audio  controls="controls"  title="Listen to Litterbox Lounge song">
          <source src="Mixdown_with_Vocalists.mp3" type="audio/mpeg" />
          <source src="Mixdown_with_Vocalists.ogg" type="audio/ogg" />
    If you see this, you're using an outdated browser that doesn't support audio.
        </audio>
    </body>
    </html>

Maybe you are looking for

  • HT1947 Remote for ipad landscape orientation not working in ios 7

    Remote for ipad landscape orientation not working in ios 7

  • Creating a new apple id for my wife

    I currently have one Apple ID and run iTunes on a Windows 7 PC. This is synced to 2 iPhones, 2 iPads and 2 iPods as well as 2 Apple TV's. All the Apps purchased, updated and shared between all the devices are controlled using iTunes depending on whos

  • Connection Pooling in EJBContainer if Driver already implements

    Hi, Can anybody explain the mechanism in an EJBContainer if the Driver for a particular database already implements the Connection pooling ie JDBC2.0X feature. Does the EJBContainer utilize the already pooled connections or the Container uses it own

  • Here is how to enable full screen mode for AIR Mac Desktop Apps

    I just discovered that with a very simple native extension method, I can enable full screen mode for AIR Mac Desktop Applications. This gets you the full screen icon in the top right, and it works perfectly with no changes to my code. (Obviously only

  • Mutiple Objects , single file append

    Hi, I am getting UUIDs using the following Command: get-wmiobject Win32_ComputerSystemProduct  | Select-Object -ExpandProperty UUID (http://www.waynehoggett.com/2009/08/get-local-computer-uuidguid-using.html) how I can store the output on a network s