Commit 6fe3ed8d authored by Alex Baines's avatar Alex Baines

add template + medium to metadata

parent f1e39e05
......@@ -24,6 +24,10 @@ typedef struct {
char** annotators;
size_t annotator_count;
char* template;
char* medium;
} HMML_VideoMetaData;
typedef struct {
......
......@@ -5,7 +5,7 @@
#include "stb_sb.h"
#include "hmmlib.h"
const struct HMML_Version hmml_version = { 0, 1, 0 };
const struct HMML_Version hmml_version = { 0, 2, 0 };
typedef struct {
int line;
......@@ -119,6 +119,8 @@ RB \]
<VIDEO>title{S}= { yyextra->attr = V_(title); BEGIN(V_ATTR); }
<VIDEO>vod_platform{S}= { yyextra->attr = V_(vod_platform); BEGIN(V_ATTR); }
<VIDEO>id{S}= { yyextra->attr = V_(id); BEGIN(V_ATTR); }
<VIDEO>template{S}= { yyextra->attr = V_(template); BEGIN(V_ATTR); }
<VIDEO>medium{S}= { yyextra->attr = V_(medium); BEGIN(V_ATTR); }
<VIDEO>co\-host{S}= { yyextra->attr = V_(co_hosts); BEGIN(V2_ATTR); }
<VIDEO>guest{S}= { yyextra->attr = V_(guests); BEGIN(V2_ATTR); }
<VIDEO>annotator{S}= { yyextra->attr = V_(annotators); BEGIN(V2_ATTR); }
......@@ -320,6 +322,8 @@ void hmml_free(HMML_Output* hmml){
free(hmml->metadata.title);
free(hmml->metadata.vod_platform);
free(hmml->metadata.id);
free(hmml->metadata.template);
free(hmml->metadata.medium);
sb_each(i, hmml->metadata.co_hosts) free(*i);
sb_each(i, hmml->metadata.guests) free(*i);
......@@ -350,7 +354,7 @@ Index* index_find(Index* base, const char* text){
void hmml_dump(HMML_Output* hmml){
if(!hmml){
puts("(null");
puts("(null)");
return;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment