Class: AVCompositionTrackSegment
- Inherits:
-
AVAssetTrackSegment
- Object
- NSObject
- AVAssetTrackSegment
- AVCompositionTrackSegment
Overview
An AVCompositionTrackSegment object represents a segment of an AVCompositionTrack object, comprising a URL, and track identifier, and a time mapping from the source track to the composition track.
Instance Attribute Summary (collapse)
-
- empty
readonly
Indicates whether the segment is empty.
-
- sourceTrackID
readonly
The track ID of the container file of the media presented by the track segment.
-
- sourceURL
readonly
The container file of the media presented by the track segment.
Attributes inherited from AVAssetTrackSegment
Class Method Summary (collapse)
-
+ compositionTrackSegmentWithTimeRange:
Returns a composition track segment that presents an empty track segment.
-
+ compositionTrackSegmentWithURL:trackID:sourceTimeRange:targetTimeRange:
Returns a composition track segment that presents a portion of a file referenced by a given URL.
Instance Method Summary (collapse)
-
- initWithTimeRange:
Initializes a track segment that presents an empty track segment.
-
- initWithURL:trackID:sourceTimeRange:targetTimeRange:
Initializes a track segment that presents a portion of a file referenced by a given URL.
Methods inherited from NSObject
#!, #!=, #!~, #, #==, #===, #=~, #Rational, #__callee__, #__method__, #__send__, #__type__, `, alloc, allocWithZone:, #autoContentAccessingProxy, autoload, autoload?, autorelease_pool, #awakeAfterUsingCoder:, binding, block_given?, caller, cancelPreviousPerformRequestsWithTarget:, cancelPreviousPerformRequestsWithTarget:selector:object:, catch, class, classFallbacksForKeyedArchiver, #classForCoder, #classForKeyedArchiver, classForKeyedUnarchiver, #clone, conformsToProtocol:, #copy, copyWithZone:, #dealloc, #define_singleton_method, description, display, #doesNotRecognizeSelector:, #dup, #enum_for, #eql?, #equal?, #extend, fail, #finalize, format, #forwardInvocation:, #forwardingTargetForSelector:, framework, #freeze, #frozen?, getpass, gets, global_variables, #init, initialize, #initialize_clone, #initialize_copy, #initialize_dup, #inspect, instanceMethodForSelector:, instanceMethodSignatureForSelector:, #instance_eval, #instance_exec, #instance_of?, #instance_variable_defined?, #instance_variable_get, #instance_variable_set, #instance_variables, instancesRespondToSelector:, isSubclassOfClass:, #is_a?, iterator?, #kind_of?, lambda, load, load_bridge_support_file, load_plist, local_variables, loop, #method, #methodForSelector:, #methodSignatureForSelector:, #methods, #mutableCopy, mutableCopyWithZone:, new, #nil?, open, p, #performSelector:onThread:withObject:waitUntilDone:, #performSelector:onThread:withObject:waitUntilDone:modes:, #performSelector:withObject:afterDelay:, #performSelector:withObject:afterDelay:inModes:, #performSelectorInBackground:withObject:, #performSelectorOnMainThread:withObject:waitUntilDone:, #performSelectorOnMainThread:withObject:waitUntilDone:modes:, print, printf, #private_methods, proc, #protected_methods, #public_method, #public_methods, #public_send, putc, puts, raise, rand, readline, readlines, #replacementObjectForCoder:, #replacementObjectForKeyedArchiver:, require, resolveClassMethod:, resolveInstanceMethod:, #respond_to?, #respond_to_missing?, select, #send, setVersion:, #singleton_methods, sprintf, srand, superclass, #taint, #tainted?, #tap, test, throw, #to_plist, #to_s, trace_var, trap, #trust, #untaint, untrace_var, #untrust, #untrusted?, version
Constructor Details
This class inherits a constructor from NSObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class NSObject
Instance Attribute Details
- (Boolean) empty (readonly)
Indicates whether the segment is empty. (read-only) An empty segment has a valid target time range but sourceURL is nil and the source start time is kCMTimeInvalid; all other fields are undefined.
- (CMPersistentTrackID) sourceTrackID (readonly)
The track ID of the container file of the media presented by the track segment. (read-only)
- (NSURL) sourceURL (readonly)
The container file of the media presented by the track segment. (read-only)
Class Method Details
+ (AVCompositionTrackSegment) compositionTrackSegmentWithTimeRange(timeRange)
Returns a composition track segment that presents an empty track segment. This method invokes initWithURL:trackID:sourceTimeRange:targetTimeRange: with a nil URL, a trackID of kCMPersistentTrackID_Invalid, a time mapping with source.start and source.duration equal to kCMTimeInvalid, and with a target equal to timeRange.This is the standard low-level representation of an empty track segment.
+ (AVCompositionTrackSegment) compositionTrackSegmentWithURL(URL, trackID:trackID, sourceTimeRange:sourceTimeRange, targetTimeRange:targetTimeRange)
Returns a composition track segment that presents a portion of a file referenced by a given URL. To specify that the segment be played at the asset’s normal rate, set source.duration == target.duration in the time mapping. Otherwise, the segment will be played at a rate equal to the ratio source.duration / target.duration.
Instance Method Details
- (Object) initWithTimeRange(timeRange)
Initializes a track segment that presents an empty track segment. This method invokes initWithURL:trackID:sourceTimeRange:targetTimeRange: with a nil URL, a trackID of kCMPersistentTrackID_Invalid, a time mapping with source.start and source.duration equal to kCMTimeInvalid, and with a target equal to timeRange.This is the standard low-level representation of an empty track segment.
- (Object) initWithURL(URL, trackID:trackID, sourceTimeRange:sourceTimeRange, targetTimeRange:targetTimeRange)
Initializes a track segment that presents a portion of a file referenced by a given URL. To specify that the segment be played at the asset’s normal rate, set source.duration == target.duration in the time mapping. Otherwise, the segment will be played at a rate equal to the ratio source.duration / target.duration.