Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

QTTimeRangeFromString



I am having trouble taking user input and converting it to a QTTimeRange, storing that value and applying it to a Movie object.
The user input would be formatted like: 
movieStartPoint:  "00:00:05"
movieEndPoint:  "00:00:15"

I followed the documentation: the string is assumed to be in the form “hours:minutes:seconds.frames:: hours:minutes:seconds.frames”.
    NSString *theRangeString = [NSString stringWithFormat: @"%@.00:: %@.00", [movieStartPoint stringValue], [movieEndPoint stringValue]];
    QTTimeRange theRange = QTTimeRangeFromString(theRangeString);
    NSString *theRangeValue = QTStringFromTimeRange(theRange);
   [myDictionary setAttribute: @"timeRange" withValue: theRangeValue];

   NSLog(@"\r%@\r%@", theRangeString, theRangeValue);

The print output:
00:00:05.00:: 00:00:15.00
0:00:00:00.00/1000000~-43:01:10:29.787974/1000000

The conversion from "theRange" to "theRangeValue"  using QTStringFromTimeRange(theRange); is incorrect

Any advice?
-Rich
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
QuickTime-API mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quicktime-api/email@hidden

This email sent to email@hidden



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.