Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Apple Final Cut Pro Legacy Time Unit Calculation

  • Time Unit Calculation

    Posted by Pie Mal on June 3, 2013 at 8:14 pm

    I am trying to customize a fcpxml and cant tell what unit of measurement the “duration” tag indicates:

    What is “2917.699951”?

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE fcpxml>

    Pie Mal replied 6 years, 1 month ago 4 Members · 8 Replies
  • 8 Replies
  • Michael Gissing

    June 3, 2013 at 10:49 pm

    My guess is samples in kHz. Is the clip 60 seconds approx? If you divide the number by 48 it is just over 60 seconds. That is assuming a sample rate of 48kHz.

    Also the clip is mp3, a codec badly handled by FCP. It should have been converted to aif or wav 16 or 24 bit 48khz before editing.

  • Pie Mal

    June 4, 2013 at 2:50 am

    Thanks for the post.

    The duration of this whole track is actually 25:06 min

    I think you’re on to something though, I’m thinking that number is somehow related to the frame/bit rate. These XMLs are meant for tagging video at a particular point in time (relative to audio). If you have any further insight as to the formula I would use to deduce the actual point in time (preferably in units of seconds/milliseconds/minutes) that would be awesome.

    Thanks!

  • Pie Mal

    June 4, 2013 at 2:59 am

    Here is another example of one of a video track:

    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE fcpxml>
    <fcpxml version="1.0">
    <project>
    <resources>
    <format id="f1" frameDuration="1/29s" width="640.000000" height="480.000000"/>
    <asset id="r1" name="1985-11-10-Berkeley_part_2.m4v" uid="O2wWMxasJdyRavHND5dJ" src="video/1985/1985-11-10-Berkeley_part_2.m4v" start="0/29s" duration="136647/29s" hasVideo="1" hasAudio="1" audioSources="1" audioChannels="2" audioRate="48000.000000"/>
    </resources>
    <clip name="1985-11-10-Berkeley_part_2.m4v" start="0/29s" duration="136647/29s" format="f1">
    <video ref="r1" start="0/29s" duration="136647/29s" offset="0/29s">
    <audio lane="-1" ref="r1" start="0/29s" duration="136647/29s" offset="0/29s" role="dialogue"/>
    </video>
    <marker start="43703/29s" duration="1/29s" value="final thought"/>
    </clip>
    </project>
    </fcpxml>

  • Pie Mal

    June 4, 2013 at 3:09 am

    okay so…from developer documentation, this only partially answers my question but a start:

    “Time values are expressed as a rational number of seconds with a 64-bit numerator and a 32-bit denominator. Frame rates for NTSC-compatible media, for example, use a frame duration of “1001/30000s” (29.97 fps) or “1001/60000s” (59.94 fps). If a time value is equal to a whole number of seconds, the fraction may be reduced into whole seconds (for example, “5s”).”

    I found this by googling “fcpxml audio tag” and clicking on the pdf

  • Michael Gissing

    June 4, 2013 at 4:01 am

    Being a video edit XML I imagine that there is a formula based on frame rate. I know broadcast wav timecode data is based purely on number of samples from a zero point. I am guessing it is for FCPX as roles are mentioned.

    However I have no real skill in this area apart from some involvement in beta testing and software development with some audio companies.

  • Nick Meyers

    June 4, 2013 at 11:51 am

    if you ask at the apple developer site, you will definitely get your answer.

    nick

  • Milivoj Ivkovic

    February 1, 2018 at 2:36 pm

    Many years later, maybe it’s still worth replying in case others stumble onto this post.

    In .fcpxml files, the start, offset and duration numbers are real-time seconds (as hinted to by the “s” at the end). They are not related to framerate. You only need the framerate if you need to convert these times to a frame number or to standard timecode which uses frames.

    An example from a title in a .fcpxml file:


    </p> <p>The start time is 11789/25 seconds = 471.56 seconds.<br /> At 25 FPS, that is a timecode of "00:07:51:14".<br /> The duration 29/5s expressed in timecode at 25 FPS is "00:00:05:20".

  • Pie Mal

    April 5, 2020 at 1:14 pm

    Still more years later that Reply was helpful thanks a lot Milivoj Ivkovic

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy