Media Authoring
with Java API

tv.amwa.maj.iface
Interface SourceReferenceSegment

All Superinterfaces:
Component, InterchangeObject, Segment
All Known Subinterfaces:
DescriptiveClip, HTMLClip, SourceClip, TextClip
All Known Implementing Classes:
DescriptiveClip, HTMLClip, SourceClip, SourceReferenceSegment, TextClip

public interface SourceReferenceSegment
extends Segment

Specifies the representation of essence or other data described by a mob slot in a mob.

To reference a single channel of a multi-channel track from a mono track, the channel ids property is used with a single element in the array. To reference multiple channels of a multi-channel track from a multi-channel track, the channel ids property is used with multiple elements in the array.

To reference multiple mono tracks from a multi-channel track, the mono source slot ids property is used with multiple elements in the array.

See the section on naming conflicts in the package documentation.

Author:
Richard Cartwright
See Also:
SourceReferenceValue

Method Summary
 int[] getChannelIDs()
          For references to a multi-channel mob slot, returns the channel ids property of this source reference, which specifies the channels within that mob slot that are referenced.
 int getChannelIDsSize()
          Returns the number of elements of the channel ids array of this source reference.
 int[] getMonoSourceSlotIDs()
          For references from a multi-channel mob slot to multiple mono mob slots, returns the mono source slot ids property of this source reference, which specifies multiple mono mob slots that are referenced.
 int getMonoSourceSlotIDsSize()
          Returns the size of the mono source slot ids array.
 MobID getSourceID()
          Returns the source id of this source reference.
 int getSourceMobSlotID()
          Returns the mob slot id of this source reference.
 void setChannelIDs(int[] channelIDs)
          For references to a multi-channel mob slot, sets the channel ids property of this source reference, which specifies the channels within that mob slot that are referenced.
 void setMonoSourceSlotIDs(int[] monoSourceSlotIDs)
          For references from a multi-channel mob slot to multiple mono mob slots, sets the mono source slot ids property of this source reference, which specifies multiple mono mob slots that are referenced.
 void setSourceID(MobID sourceId)
          Set the source id of this source reference, which identifies the mob being referenced.
 void setSourceMobSlotID(int slotId)
          Sets the mob slot id of this source reference.
 
Methods inherited from interface tv.amwa.maj.iface.Segment
segmentOffsetToTC, segmentTCToOffset
 
Methods inherited from interface tv.amwa.maj.iface.Component
appendAttribute, appendAttribute, appendComment, appendComment, appendKLVData, countAttributes, countComments, countKLVData, getAttributes, getComments, getDataDefinition, getKLVData, getLength, removeAttribute, removeComment, removeKLVData, setDataDefinition, setLength
 
Methods inherited from interface tv.amwa.maj.iface.InterchangeObject
countProperties, createOptionalPropertyValue, disableGenerationTracking, enableGenerationTracking, getDefinition, getGeneration, getGenerationAUID, getProperties, getPropertyValue, isGenerationTracked, isPropertyPresent, omitOpionalProperty, setPropertyValue
 

Method Detail

getSourceID

MobID getSourceID()
                  throws PropertyNotPresentException

Returns the source id of this source reference. This is an optional property.

If the source id property is the zero mob id, the mob owning the source reference describes the original source. If this property is omitted, the reference is to another mob slot within the same mob.

Returns:
Source id of this source reference.
Throws:
PropertyNotPresentException - The optional source id property is not present in this source reference, implying that this is a reference to a mob slot within the same mob.
See Also:
SourceReferenceValue.getSourceID()

setSourceID

void setSourceID(MobID sourceId)

Set the source id of this source reference, which identifies the mob being referenced.

If the property has a value of the zero mob id, it means that the mob owning this source reference describes the original source. Set this optional property to null to omit and indicate that this reference is to another mob slot in the same mob.

For source clips, it is recommended that the setSourceReference() method is used to set the source id property in preference to this method.

Parameters:
sourceId - Source id of this source reference.
See Also:
SourceReferenceValue.setSourceID(MobID), MobID.getZeroMobID(), SourceClip.setSourceReference(SourceReferenceValue)

getSourceMobSlotID

@SlotID
int getSourceMobSlotID()

Returns the mob slot id of this source reference. If the source id property is the the zero mob id, the source mob slot id should be 0.

Returns:
Mob slot id of this source reference.
See Also:
SourceReferenceValue.getSourceSlotID()

setSourceMobSlotID

void setSourceMobSlotID(@SlotID
                        int slotId)
                        throws IllegalArgumentException

Sets the mob slot id of this source reference. If the source id property is the the zero mob id, the source mob slot id should be 0.

Parameters:
slotId - Mob slot id of this source reference.
Throws:
IllegalArgumentException - The given source mob slot id is negative.
See Also:
SourceReferenceValue.setSourceSlotID(int)

setChannelIDs

void setChannelIDs(@UInt32Array
                   int[] channelIDs)

For references to a multi-channel mob slot, sets the channel ids property of this source reference, which specifies the channels within that mob slot that are referenced. Set this optional property to null to omit it and indicate that all channels in the referenced mob slot are referenced in the same order.

The number of channel ids shall equal the number of channels being described the mob slot containing the source reference, e.g. 1 element for a mono audio slot, 6 elements for a 5.1 multi-channel audio slot.

Parameters:
channelIDs - Array of channel IDs to set for the source reference.

getChannelIDs

@UInt32Array
int[] getChannelIDs()
                    throws PropertyNotPresentException

For references to a multi-channel mob slot, returns the channel ids property of this source reference, which specifies the channels within that mob slot that are referenced. This optional property is omitted to indicate that all channels in the referenced mob slot are referenced in the same order.

The number of channel ids shall equal the number of channels being described the mob slot containing the source reference, e.g. 1 element for a mono audio slot, 6 elements for a 5.1 multi-channel audio slot.

Returns:
Array of channel ids for this source reference.
Throws:
PropertyNotPresentException - The optional channel ids property is not present in this source reference.

getChannelIDsSize

@UInt32
int getChannelIDsSize()
                      throws PropertyNotPresentException

Returns the number of elements of the channel ids array of this source reference. For references to a multi-channel mob slot, the channel ids property specifies the channels within that mob slot that are referenced. This is an optional property.

Returns:
Number of elements of the channel ids array of the source reference.
Throws:
PropertyNotPresentException - The optional channel ids property is not present in this source reference.

setMonoSourceSlotIDs

void setMonoSourceSlotIDs(@UInt32
                          int[] monoSourceSlotIDs)

For references from a multi-channel mob slot to multiple mono mob slots, sets the mono source slot ids property of this source reference, which specifies multiple mono mob slots that are referenced. Set this optional property to null to omit it and specify that this is a single-channel reference.

The number of elements in the mono source slot ids array shall equal the number of channels being described by the mob slot containing this source reference, e.g. 6 elements for a 5.1 multi-channel audio mob slot.

Parameters:
monoSourceSlotIDs - Array of mono source slot ids for this source reference.

getMonoSourceSlotIDs

@UInt32
int[] getMonoSourceSlotIDs()
                           throws PropertyNotPresentException

For references from a multi-channel mob slot to multiple mono mob slots, returns the mono source slot ids property of this source reference, which specifies multiple mono mob slots that are referenced. This is an optional property that is omitted to specify that this is a single-channel reference.

The number of elements in the mono source slot ids array shall equal the number of channels being described by the mob slot containing this source reference, e.g. 6 elements for a 5.1 multi-channel audio mob slot.

Returns:
Array of mono source slot ids of this source reference.
Throws:
PropertyNotPresentException - This optional mono source slot ids property is not present in this source reference.

getMonoSourceSlotIDsSize

@UInt32
int getMonoSourceSlotIDsSize()
                             throws PropertyNotPresentException

Returns the size of the mono source slot ids array. For references from a multi-channel mob slot to multiple mono mob slots, the mono source slot ids property specifies multiple mono mob slots that are referenced. This is an optional property.

Returns:
Size of the mono source slot ids array.
Throws:
PropertyNotPresentException - The optional mono source slot ids property is not present for this source reference.

Media Authoring
with Java API

(c) 2007-2008 Richard Cartwright, all rights reserved. Subject to the terms of the AAF SDK Public Source License.