本文整理汇总了C++中IAAFMob::SetCreateTime方法的典型用法代码示例。如果您正苦于以下问题:C++ IAAFMob::SetCreateTime方法的具体用法?C++ IAAFMob::SetCreateTime怎么用?C++ IAAFMob::SetCreateTime使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类IAAFMob
的用法示例。
在下文中一共展示了IAAFMob::SetCreateTime方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: CreateAAFFile
static HRESULT CreateAAFFile(
aafWChar * pFileName,
aafUID_constref fileKind,
testRawStorageType_t rawStorageType,
aafProductIdentification_constref productID)
{
IAAFFile * pFile = NULL;
bool bFileOpen = false;
IAAFHeader * pHeader = NULL;
IAAFDictionary* pDictionary = NULL;
IAAFMob *pMob = NULL;
IAAFMob *pMob2 = NULL;
IAAFMob2 *pMobInterface2 = NULL;
IAAFTimelineMobSlot *newSlot = NULL;
IAAFStaticMobSlot *newStaticSlot=NULL;
IAAFEventMobSlot *newEventSlot=NULL;
IAAFSegment *seg = NULL;
IAAFSourceClip *sclp = NULL;
IAAFEvent *event=NULL;
IAAFComponent* pComponent = NULL;
IAAFClassDef *pcdEventMeta=NULL;
IAAFClassDef *pcdEvent=NULL;
IAAFClassDef *pcdEventConcrete=NULL;
HRESULT hr = S_OK;
aafNumSlots_t numMobs;
aafUInt32 bufLen = 0;
aafUInt32 bytesRead = 0;
aafUInt32 numComments = 0;
aafUInt32 numFound = 0;
aafWChar name[500];
aafWChar value[500];
IEnumAAFTaggedValues *enumTaggedVal = NULL;
IAAFTaggedValue *taggedVal = NULL;
IAAFMobSlot *mSlot = NULL;
IAAFFiller *filler = NULL;
IAAFKLVData *pKLVData = NULL;
IAAFTypeDef* pBaseType = NULL;
IAAFSourceReference *pSourceRef = NULL;
IAAFTimecode *pTimecode = NULL;
aafTimecode_t timecode;
int i;
try
{
// Remove the previous test file if any.
RemoveTestFile(pFileName);
// Create the file.
checkResult(CreateTestFile( pFileName, fileKind, rawStorageType, productID, &pFile ));
bFileOpen = true;
// We can't really do anthing in AAF without the header.
checkResult(pFile->GetHeader(&pHeader));
// Get the AAF Dictionary so that we can create valid AAF objects.
checkResult(pHeader->GetDictionary(&pDictionary));
CAAFBuiltinDefs defs (pDictionary);
//Make the first mob
long test;
// Create a concrete subclass of Mob
checkResult(defs.cdMasterMob()->
CreateInstance(IID_IAAFMob,
(IUnknown **)&pMob));
checkResult( pMob->QueryInterface(IID_IAAFMob2,(void**)&pMobInterface2));
checkResult(pMob->SetMobID(MOBTestID));
checkExpression(pMob->GetNameBufLen(&bufLen) == AAFRESULT_PROP_NOT_PRESENT, AAFRESULT_TEST_FAILED);
checkExpression(pMob->GetName(name, 0) == AAFRESULT_PROP_NOT_PRESENT, AAFRESULT_TEST_FAILED);
checkExpression(pMob->SetName(NULL) == AAFRESULT_NULL_PARAM, AAFRESULT_TEST_FAILED);
checkResult(pMob->SetName(mobName));
checkResult(pMob->SetCreateTime(creationTimeStamp));
checkResult(pMob->SetModTime(modificationTimeStamp));
// Add some slots
for(test = 1; test < 6; test++)
{
checkResult(defs.cdSourceClip()->
CreateInstance(IID_IAAFSourceClip,
(IUnknown **)&sclp));
checkResult(sclp->QueryInterface(IID_IAAFSourceReference, (void **)&pSourceRef));
checkResult(pSourceRef->SetSourceID(MOBTestID3));
checkResult(sclp->QueryInterface(IID_IAAFComponent, (void **)&pComponent));
checkResult(pComponent->SetDataDef(defs.ddkAAFPicture()));
checkResult(sclp->QueryInterface (IID_IAAFSegment, (void **)&seg));
aafRational_t editRate = { 0, 1};
checkResult(pMob->AppendNewTimelineSlot (editRate,
seg,
test+1,
slotNames[test],
0,
&newSlot));
//.........这里部分代码省略.........