Changeset 3718
- Timestamp:
- 2008-09-16 02:33:49 (3 months ago)
- Files:
-
- liboggz/trunk/src/liboggz/metric_internal.c (modified) (1 diff)
- liboggz/trunk/src/liboggz/oggz_auto.c (modified) (2 diffs)
- liboggz/trunk/src/liboggz/oggz_private.h (modified) (2 diffs)
- liboggz/trunk/src/liboggz/oggz_read.c (modified) (2 diffs)
- liboggz/trunk/src/liboggz/oggz_write.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
liboggz/trunk/src/liboggz/metric_internal.c
r838 r3718 159 159 160 160 *granulerate_n = stream->granulerate_n; 161 *granulerate_d = stream->granulerate_d ;161 *granulerate_d = stream->granulerate_d / OGGZ_AUTO_MULT; 162 162 163 163 return 0; liboggz/trunk/src/liboggz/oggz_auto.c
r3717 r3718 63 63 #define INT32_BE_AT(x) _be_32((*(ogg_int32_t *)(x))) 64 64 #define INT64_LE_AT(x) _le_64((*(ogg_int64_t *)(x))) 65 66 #define OGGZ_AUTO_MULT 1000Ull67 65 68 66 static int … … 1112 1110 1113 1111 int 1114 oggz_auto_get_granulerate (OGGZ * oggz, ogg_packet * op, long serialno, 1115 void * user_data) 1112 oggz_auto_read_bos_page (OGGZ * oggz, ogg_page * og, long serialno, 1113 void * user_data) 1114 { 1115 int content = 0; 1116 1117 content = oggz_stream_get_content(oggz, serialno); 1118 if (content < 0 || content >= OGGZ_CONTENT_UNKNOWN) { 1119 return 0; 1120 } else if (content == OGGZ_CONTENT_SKELETON && !ogg_page_bos(og)) { 1121 return auto_fisbone(oggz, serialno, og->body, og->body_len, user_data); 1122 } else { 1123 return oggz_auto_codec_ident[content].reader(oggz, serialno, og->body, og->body_len, user_data); 1124 } 1125 } 1126 1127 int 1128 oggz_auto_read_bos_packet (OGGZ * oggz, ogg_packet * op, long serialno, 1129 void * user_data) 1116 1130 { 1117 1131 int content = 0; liboggz/trunk/src/liboggz/oggz_private.h
r3390 r3718 45 45 #include "oggz_dlist.h" 46 46 47 #define OGGZ_AUTO_MULT 1000Ull 48 47 49 typedef struct _OGGZ OGGZ; 48 50 typedef struct _OggzComment OggzComment; … … 284 286 285 287 int 286 oggz_auto_get_granulerate (OGGZ * oggz, ogg_packet * op, long serialno, 288 oggz_auto_read_bos_page (OGGZ * oggz, ogg_page * og, long serialno, 289 void * user_data); 290 int 291 oggz_auto_read_bos_packet (OGGZ * oggz, ogg_packet * op, long serialno, 287 292 void * user_data); 288 293 liboggz/trunk/src/liboggz/oggz_read.c
r3424 r3718 415 415 ) 416 416 { 417 oggz_auto_ get_granulerate(oggz, op, serialno, NULL);417 oggz_auto_read_bos_packet (oggz, op, serialno, NULL); 418 418 } 419 419 … … 525 525 /* identify stream type */ 526 526 oggz_auto_identify_page (oggz, &og, serialno); 527 528 /* read bos data */ 529 if (oggz->flags & OGGZ_AUTO) 530 oggz_auto_read_bos_page (oggz, &og, serialno, NULL); 527 531 } 528 532 else if (oggz_stream_get_content(oggz, serialno) == OGGZ_CONTENT_ANXDATA) liboggz/trunk/src/liboggz/oggz_write.c
r3446 r3718 291 291 292 292 if (!stream->metric && (oggz->flags & OGGZ_AUTO)) { 293 oggz_auto_ get_granulerate(oggz, op, serialno, NULL);293 oggz_auto_read_bos_packet (oggz, op, serialno, NULL); 294 294 } 295 295