Logo Search packages:      
Sourcecode: libtheora version File versions

int theora_comment_query_count ( theora_comment tc,
char *  tag 

look up the number of instances of a tag

tc an initialized theora_comment structure
tag the tag to look up
the number on instances of a particular tag. Call this first when querying for a specific tag and then interate over the number of instances with separate calls to theora_comment_query() to retrieve all instances in order.

Definition at line 84 of file comment.c.

References theora_comment::comments, theora_comment_query_count(), and theora_comment::user_comments.

Referenced by theora_comment_query_count().

  int i,count=0;
  int taglen = strlen(tag)+1; /* +1 for the = we append */
  char *fulltag = _ogg_malloc(taglen+1);
  strcat(fulltag, "=");

    if(!tagcompare(tc->user_comments[i], fulltag, taglen))
  return count;

Generated by  Doxygen 1.6.0   Back to index