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

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

Definition at line 326 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().

00327     {
00328         Table::AnnotationTable* shotTable = mAnnoShot->GetTable(concept);
00329         int startShot = mSegmentation->GetFirstShotVideo(fileId);
00330         int endShot = startShot + mSegmentation->GetNrShotsVideo(fileId);
00331         for (int s=startShot ; s<endShot ; s++)
00332         {
00333             int startFrame = mSegmentation->GetStart(s);
00334             int endFrame = mSegmentation->GetEnd(s);
00335             std::vector<int> idx = mp7->FindShots(startFrame, endFrame);
00336 
00337             if (idx.size() > 0)
00338             {
00339                 Quid q = MakeQuidShot(vs->GetSetId(), fileId, s - startShot);
00340 
00341                 bool hasPos = false;
00342                 bool hasNeg = false;
00343                 for (int i=0 ; i<idx.size() ; i++)
00344                 {
00345                     if (mp7->IsPositiveAnno(idx[i]))
00346                         hasPos = true;
00347                     else if (mp7->IsNegativeAnno(idx[i]))
00348                         hasNeg = true;
00349                 }
00350 
00351                 if (hasPos)
00352                     shotTable->AddPositive(q);
00353                 else if (hasNeg)
00354                     shotTable->AddNegative(q);
00355                 else
00356                     shotTable->AddSkip(q);
00357             }
00358         }
00359     }

Here is the call graph for this function:


Generated on Fri Mar 19 11:29:32 2010 for ImpalaSrc by  doxygen 1.5.1