![](../../Home/Icons/Home.gif)
![](../icons/UpCNM.gif)
![](../icons/CNMContext.gif)
![](../../Home/Icons/Search.gif)
Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
TModel
Inherited By:
None.
Purpose:
TMediaModel is derived from TModel and polymorphically holds a media sequence. This class is used to encapsulate the different media data types, which can be either a movie, audio, MIDI, or graphic (video) sequence. TMediaModel provides the basis for embedding the sequence in a compound document. The media document can be opened or launched in the Workspace or on the command line using RunDocument.
CreateSelection provides only basic support for making selections (it returns a selection on the entire media model). More sophisticated selection options will be available in the future.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
None.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
Other Considerations:
None.
- TMediaModel (TMediaSequence * sequenceToAdopt, const TMediaComponentType & type)
- TMediaModel (const TMediaModel &)
- TMediaModel ()
Interface Category:
API.
Purpose:
- Constructor that creates a new TMediaModel object from a pointer to a TMediaSequence object and a reference to the media component type object.
- Copy constructor.
- Default constructor.
Calling Context:
- Call this function directly.
- Called to copy an object.
- Called by the stream-in operators and derived classes.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TMediaModel ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::operator=
TMediaModel & operator =(const TMediaModel &)
Interface Category:
API.
Purpose:
Assignment operator.
Calling Context:
Called when an object is assigned to another compatible object.
Parameters:
Return Value:
A non-const reference to the left-hand side object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::Hash
virtual long Hash () const
Interface Category:
API.
Purpose:
Returns the hash value that uniquely identifies this object within its type. Hash values are used to build dictionaries of objects.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns the hash value that uniquely identifies this object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::operator==
bool operator ==(const TMediaModel &) const
Interface Category:
API.
Purpose:
Tests for equality between the specified TMediaModel object and this TMediaModel object.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns true if both objects are equal; otherwise, returns false.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::operator!=
bool operator != (const TMediaModel &) const
Interface Category:
API.
Purpose:
Tests for inequality between the specified TMediaModel object and this TMediaModel object.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns true if both objects are different; otherwise, returns false.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::operator>>=
virtual TStream & operator >>=(TStream &) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data.
Parameters:
- TStream & -The stream the object streams itself out to.
Return Value:
Returns a reference to the stream the object streams itself out to.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::operator<<=
virtual TStream & operator <<= (TStream &)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data.
Parameters:
- TStream & -The stream the object streams itself in from.
Return Value:
Returns a reference to the stream the object streams itself in from.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::CreateSelection
virtual TModelSelection * CreateSelection () const
Interface Category:
API.
Purpose:
Returns a selection on the entire model, which is the whole media sequence. At a later date, it will allow a subrange of the media sequence to be selected.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a pointer to the TModelSelection object that references the selected media sequence or model.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::AdoptSequence
virtual void AdoptSequence (TMediaSequence *)
Interface Category:
API.
Purpose:
Deletes the current sequence and then adopts the new sequence.
Calling Context:
Call this function directly.
Parameters:
- TMediaSequence * -A pointer to the media sequence that is to be added.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::OrphanSequence
virtual TMediaSequence * OrphanSequence ()
Interface Category:
API.
Purpose:
Returns a media sequence that had been previously adopted. The currently referenced media sequence is released or is set to NIL.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a pointer to the media sequence that is orphaned.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::GetSequence
virtual const TMediaSequence * GetSequence () const
Interface Category:
API.
Purpose:
Returns a reference to the media sequence.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns a pointer to the media sequence object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::GetMediaComponentType
virtual const TMediaComponentType & GetMediaComponentType () const
Interface Category:
API.
Purpose:
Returns the media type of the media model.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns the media component type constant.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::GetStorageMechanism
virtual TStorageMechanism * GetStorageMechanism() const
Interface Category:
API.
Purpose:
Returns the storage mechanism in use for the currently referenced model or media sequence.
Calling Context:
Call this function directly.
Parameters:
Return Value:
Returns the TStorageMechanism object for storing the media component model.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::StartUsingStorageMechanism
virtual void StartUsingStorageMechanism(TStorageMechanism *)
Interface Category:
API.
Purpose:
Starts the storage process to the specified storage mechanism that is in use for the currently referenced model or media sequence.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Member Function: TMediaModel::StopUsingStorageMechanism
virtual void StopUsingStorageMechanism(const TStorageMechanism &)
Interface Category:
API.
Purpose:
Stops the storage process for the currently referenced model or media sequence.
Calling Context:
Call this function directly.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.