mirror of
https://github.com/mpv-player/mpv
synced 2025-01-20 21:07:29 +01:00
printf->mp_msg
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@20727 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
8bf07b6682
commit
39d80427bb
@ -28,6 +28,7 @@
|
||||
|
||||
#include "rmff.h"
|
||||
#include "xbuffer.h"
|
||||
#include "mp_msg.h"
|
||||
|
||||
/*
|
||||
#define LOG
|
||||
@ -294,7 +295,7 @@ static rmff_fileheader_t *rmff_scan_fileheader(const char *data) {
|
||||
fileheader->object_version=BE_16(&data[8]);
|
||||
if (fileheader->object_version != 0)
|
||||
{
|
||||
printf("warning: unknown object version in .RMF: 0x%04x\n",
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "warning: unknown object version in .RMF: 0x%04x\n",
|
||||
fileheader->object_version);
|
||||
}
|
||||
fileheader->file_version=BE_32(&data[10]);
|
||||
@ -312,7 +313,7 @@ static rmff_prop_t *rmff_scan_prop(const char *data) {
|
||||
prop->object_version=BE_16(&data[8]);
|
||||
if (prop->object_version != 0)
|
||||
{
|
||||
printf("warning: unknown object version in PROP: 0x%04x\n",
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "warning: unknown object version in PROP: 0x%04x\n",
|
||||
prop->object_version);
|
||||
}
|
||||
prop->max_bit_rate=BE_32(&data[10]);
|
||||
@ -339,7 +340,7 @@ static rmff_mdpr_t *rmff_scan_mdpr(const char *data) {
|
||||
mdpr->object_version=BE_16(&data[8]);
|
||||
if (mdpr->object_version != 0)
|
||||
{
|
||||
printf("warning: unknown object version in MDPR: 0x%04x\n",
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "warning: unknown object version in MDPR: 0x%04x\n",
|
||||
mdpr->object_version);
|
||||
}
|
||||
mdpr->stream_number=BE_16(&data[10]);
|
||||
@ -379,7 +380,7 @@ static rmff_cont_t *rmff_scan_cont(const char *data) {
|
||||
cont->object_version=BE_16(&data[8]);
|
||||
if (cont->object_version != 0)
|
||||
{
|
||||
printf("warning: unknown object version in CONT: 0x%04x\n",
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "warning: unknown object version in CONT: 0x%04x\n",
|
||||
cont->object_version);
|
||||
}
|
||||
cont->title_len=BE_16(&data[10]);
|
||||
@ -414,7 +415,7 @@ static rmff_data_t *rmff_scan_dataheader(const char *data) {
|
||||
dh->object_version=BE_16(&data[8]);
|
||||
if (dh->object_version != 0)
|
||||
{
|
||||
printf("warning: unknown object version in DATA: 0x%04x\n",
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "warning: unknown object version in DATA: 0x%04x\n",
|
||||
dh->object_version);
|
||||
}
|
||||
dh->num_packets=BE_32(&data[10]);
|
||||
@ -440,7 +441,7 @@ rmff_header_t *rmff_scan_header(const char *data) {
|
||||
chunk_type = BE_32(ptr);
|
||||
if (chunk_type != RMF_TAG)
|
||||
{
|
||||
printf("rmff: not an real media file header (.RMF tag not found).\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_ERR, "rmff: not an real media file header (.RMF tag not found).\n");
|
||||
free(header);
|
||||
return NULL;
|
||||
}
|
||||
@ -457,7 +458,7 @@ rmff_header_t *rmff_scan_header(const char *data) {
|
||||
|
||||
if (ptr[0] == 0)
|
||||
{
|
||||
printf("rmff: warning: only %d of %d header found.\n", i, header->fileheader->num_headers);
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "rmff: warning: only %d of %d header found.\n", i, header->fileheader->num_headers);
|
||||
break;
|
||||
}
|
||||
|
||||
@ -481,7 +482,7 @@ rmff_header_t *rmff_scan_header(const char *data) {
|
||||
chunk_size=34; /* hard coded header size */
|
||||
break;
|
||||
default:
|
||||
printf("unknown chunk\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "unknown chunk\n");
|
||||
hexdump(ptr,10);
|
||||
chunk_size=1;
|
||||
break;
|
||||
@ -518,7 +519,7 @@ rmff_header_t *rmff_scan_header_stream(int fd) {
|
||||
index+=(chunk_size-8);
|
||||
break;
|
||||
default:
|
||||
printf("rmff_scan_header_stream: unknown chunk");
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "rmff_scan_header_stream: unknown chunk");
|
||||
hexdump(buf+index-8, 8);
|
||||
chunk_type=DATA_TAG;
|
||||
}
|
||||
@ -759,12 +760,12 @@ void rmff_fix_header(rmff_header_t *h) {
|
||||
int num_streams=0;
|
||||
|
||||
if (!h) {
|
||||
printf("rmff_fix_header: fatal: no header given.\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_ERR, "rmff_fix_header: fatal: no header given.\n");
|
||||
return;
|
||||
}
|
||||
|
||||
if (!h->streams) {
|
||||
printf("rmff_fix_header: warning: no MDPR chunks\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "rmff_fix_header: warning: no MDPR chunks\n");
|
||||
} else
|
||||
{
|
||||
streams=h->streams;
|
||||
@ -795,13 +796,13 @@ void rmff_fix_header(rmff_header_t *h) {
|
||||
num_headers++;
|
||||
header_size+=50;
|
||||
} else
|
||||
printf("rmff_fix_header: warning: no PROP chunk.\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "rmff_fix_header: warning: no PROP chunk.\n");
|
||||
|
||||
if (h->cont) {
|
||||
num_headers++;
|
||||
header_size+=h->cont->size;
|
||||
} else
|
||||
printf("rmff_fix_header: warning: no CONT chunk.\n");
|
||||
mp_msg(MSGT_STREAM, MSGL_WARN, "rmff_fix_header: warning: no CONT chunk.\n");
|
||||
|
||||
if (!h->data) {
|
||||
#ifdef LOG
|
||||
|
Loading…
Reference in New Issue
Block a user