comparison utils.c @ 776:47c7fa7c2e7c libavformat

changing a few AV_LOG_DEBUG to AV_LOG_INFO
author michael
date Sun, 29 May 2005 11:44:21 +0000
parents c5077fdab490
children 694320ffdda0
comparison
equal deleted inserted replaced
775:c5077fdab490 776:47c7fa7c2e7c
2375 int is_output) 2375 int is_output)
2376 { 2376 {
2377 int i, flags; 2377 int i, flags;
2378 char buf[256]; 2378 char buf[256];
2379 2379
2380 av_log(NULL, AV_LOG_DEBUG, "%s #%d, %s, %s '%s':\n", 2380 av_log(NULL, AV_LOG_INFO, "%s #%d, %s, %s '%s':\n",
2381 is_output ? "Output" : "Input", 2381 is_output ? "Output" : "Input",
2382 index, 2382 index,
2383 is_output ? ic->oformat->name : ic->iformat->name, 2383 is_output ? ic->oformat->name : ic->iformat->name,
2384 is_output ? "to" : "from", url); 2384 is_output ? "to" : "from", url);
2385 if (!is_output) { 2385 if (!is_output) {
2386 av_log(NULL, AV_LOG_DEBUG, " Duration: "); 2386 av_log(NULL, AV_LOG_INFO, " Duration: ");
2387 if (ic->duration != AV_NOPTS_VALUE) { 2387 if (ic->duration != AV_NOPTS_VALUE) {
2388 int hours, mins, secs, us; 2388 int hours, mins, secs, us;
2389 secs = ic->duration / AV_TIME_BASE; 2389 secs = ic->duration / AV_TIME_BASE;
2390 us = ic->duration % AV_TIME_BASE; 2390 us = ic->duration % AV_TIME_BASE;
2391 mins = secs / 60; 2391 mins = secs / 60;
2392 secs %= 60; 2392 secs %= 60;
2393 hours = mins / 60; 2393 hours = mins / 60;
2394 mins %= 60; 2394 mins %= 60;
2395 av_log(NULL, AV_LOG_DEBUG, "%02d:%02d:%02d.%01d", hours, mins, secs, 2395 av_log(NULL, AV_LOG_INFO, "%02d:%02d:%02d.%01d", hours, mins, secs,
2396 (10 * us) / AV_TIME_BASE); 2396 (10 * us) / AV_TIME_BASE);
2397 } else { 2397 } else {
2398 av_log(NULL, AV_LOG_DEBUG, "N/A"); 2398 av_log(NULL, AV_LOG_INFO, "N/A");
2399 } 2399 }
2400 if (ic->start_time != AV_NOPTS_VALUE) { 2400 if (ic->start_time != AV_NOPTS_VALUE) {
2401 int secs, us; 2401 int secs, us;
2402 av_log(NULL, AV_LOG_DEBUG, ", start: "); 2402 av_log(NULL, AV_LOG_INFO, ", start: ");
2403 secs = ic->start_time / AV_TIME_BASE; 2403 secs = ic->start_time / AV_TIME_BASE;
2404 us = ic->start_time % AV_TIME_BASE; 2404 us = ic->start_time % AV_TIME_BASE;
2405 av_log(NULL, AV_LOG_DEBUG, "%d.%06d", 2405 av_log(NULL, AV_LOG_INFO, "%d.%06d",
2406 secs, (int)av_rescale(us, 1000000, AV_TIME_BASE)); 2406 secs, (int)av_rescale(us, 1000000, AV_TIME_BASE));
2407 } 2407 }
2408 av_log(NULL, AV_LOG_DEBUG, ", bitrate: "); 2408 av_log(NULL, AV_LOG_INFO, ", bitrate: ");
2409 if (ic->bit_rate) { 2409 if (ic->bit_rate) {
2410 av_log(NULL, AV_LOG_DEBUG,"%d kb/s", ic->bit_rate / 1000); 2410 av_log(NULL, AV_LOG_INFO,"%d kb/s", ic->bit_rate / 1000);
2411 } else { 2411 } else {
2412 av_log(NULL, AV_LOG_DEBUG, "N/A"); 2412 av_log(NULL, AV_LOG_INFO, "N/A");
2413 } 2413 }
2414 av_log(NULL, AV_LOG_DEBUG, "\n"); 2414 av_log(NULL, AV_LOG_INFO, "\n");
2415 } 2415 }
2416 for(i=0;i<ic->nb_streams;i++) { 2416 for(i=0;i<ic->nb_streams;i++) {
2417 AVStream *st = ic->streams[i]; 2417 AVStream *st = ic->streams[i];
2418 avcodec_string(buf, sizeof(buf), &st->codec, is_output); 2418 avcodec_string(buf, sizeof(buf), &st->codec, is_output);
2419 av_log(NULL, AV_LOG_DEBUG, " Stream #%d.%d", index, i); 2419 av_log(NULL, AV_LOG_INFO, " Stream #%d.%d", index, i);
2420 /* the pid is an important information, so we display it */ 2420 /* the pid is an important information, so we display it */
2421 /* XXX: add a generic system */ 2421 /* XXX: add a generic system */
2422 if (is_output) 2422 if (is_output)
2423 flags = ic->oformat->flags; 2423 flags = ic->oformat->flags;
2424 else 2424 else
2425 flags = ic->iformat->flags; 2425 flags = ic->iformat->flags;
2426 if (flags & AVFMT_SHOW_IDS) { 2426 if (flags & AVFMT_SHOW_IDS) {
2427 av_log(NULL, AV_LOG_DEBUG, "[0x%x]", st->id); 2427 av_log(NULL, AV_LOG_INFO, "[0x%x]", st->id);
2428 } 2428 }
2429 av_log(NULL, AV_LOG_DEBUG, ": %s\n", buf); 2429 av_log(NULL, AV_LOG_INFO, ": %s\n", buf);
2430 } 2430 }
2431 } 2431 }
2432 2432
2433 typedef struct { 2433 typedef struct {
2434 const char *abv; 2434 const char *abv;