Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

void Impala::Core::VideoSet::IndexAnnotation::DoShots ( VideoSet vs,
int  fileId,
int  concept,
Mpeg7Doc mp7 
) [inline, private]

Definition at line 297 of file IndexAnnotation.h.

References Impala::Core::Table::AnnotationTable::AddNegative(), Impala::Core::Table::AnnotationTable::AddPositive(), Impala::Core::Table::AnnotationTable::AddSkip(), Impala::Core::VideoSet::Mpeg7Doc::FindShots(), Impala::Core::VideoSet::Segmentation::GetEnd(), Impala::Core::VideoSet::Segmentation::GetFirstShotVideo(), Impala::Core::VideoSet::Segmentation::GetNrShotsVideo(), Impala::Core::VideoSet::Segmentation::GetStart(), Impala::Core::Table::AnnotationTableSet::GetTable(), Impala::Core::VideoSet::Mpeg7Doc::IsNegativeAnno(), Impala::Core::VideoSet::Mpeg7Doc::IsPositiveAnno(), Impala::MakeQuidShot(), mAnnoShot, and mSegmentation.

Referenced by HandleNewFile().

00298     {
00299         Table::AnnotationTable* shotTable = mAnnoShot->GetTable(concept);
00300         int startShot = mSegmentation->GetFirstShotVideo(fileId);
00301         int endShot = startShot + mSegmentation->GetNrShotsVideo(fileId);
00302         for (int s=startShot ; s<endShot ; s++)
00303         {
00304             int startFrame = mSegmentation->GetStart(s);
00305             int endFrame = mSegmentation->GetEnd(s);
00306             std::vector<int> idx = mp7->FindShots(startFrame, endFrame);
00307 
00308             if (idx.size() > 0)
00309             {
00310                 Quid q = MakeQuidShot(vs->GetSetId(), fileId, s - startShot);
00311 
00312                 bool hasPos = false;
00313                 bool hasNeg = false;
00314                 for (int i=0 ; i<idx.size() ; i++)
00315                 {
00316                     if (mp7->IsPositiveAnno(idx[i]))
00317                         hasPos = true;
00318                     else if (mp7->IsNegativeAnno(idx[i]))
00319                         hasNeg = true;
00320                 }
00321 
00322                 if (hasPos)
00323                     shotTable->AddPositive(q);
00324                 else if (hasNeg)
00325                     shotTable->AddNegative(q);
00326                 else
00327                     shotTable->AddSkip(q);
00328             }
00329         }
00330     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:21:54 2011 for ImpalaSrc by  doxygen 1.5.1