1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
|
/*
* libmm-fileinfo
*
* Copyright (c) 2000 - 2011 Samsung Electronics Co., Ltd. All rights reserved.
*
* Contact: Haejeong Kim <backto.kim@samsung.com>
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
#include "mm_debug.h"
#include "mm_file_utils.h"
EXPORT_API
void mmfile_format_print_contents (MMFileFormatContext *in)
{
if (in) {
debug_msg ("formatType = %d\n", in->formatType);
debug_msg ("commandType = %d\n", in->commandType);
debug_msg ("duration = %d\n", in->duration);
debug_msg ("videoTotalTrackNum = %d\n", in->videoTotalTrackNum);
debug_msg ("audioTotalTrackNum = %d\n", in->audioTotalTrackNum);
debug_msg ("nbStreams = %d\n", in->nbStreams);
debug_msg ("audioStreamId = %d\n", in->audioStreamId);
debug_msg ("videoStreamId = %d\n", in->videoStreamId);
if (in->videoTotalTrackNum > 0 && in->streams[MMFILE_VIDEO_STREAM]) {
debug_msg ("VstreamType = %d\n", in->streams[MMFILE_VIDEO_STREAM]->streamType);
debug_msg ("VcodecId = %d\n", in->streams[MMFILE_VIDEO_STREAM]->codecId);
debug_msg ("VbitRate = %d\n", in->streams[MMFILE_VIDEO_STREAM]->bitRate);
debug_msg ("VframePerSec = %d\n", in->streams[MMFILE_VIDEO_STREAM]->framePerSec);
debug_msg ("Vwidth = %d\n", in->streams[MMFILE_VIDEO_STREAM]->width);
debug_msg ("Vheight = %d\n", in->streams[MMFILE_VIDEO_STREAM]->height);
debug_msg ("VnbChannel = %d\n", in->streams[MMFILE_VIDEO_STREAM]->nbChannel);
debug_msg ("VsamplePerSec = %d\n", in->streams[MMFILE_VIDEO_STREAM]->samplePerSec);
}
if (in->audioTotalTrackNum > 0 && in->streams[MMFILE_AUDIO_STREAM]) {
debug_msg ("AstreamType = %d\n", in->streams[MMFILE_AUDIO_STREAM]->streamType);
debug_msg ("AcodecId = %d\n", in->streams[MMFILE_AUDIO_STREAM]->codecId);
debug_msg ("AbitRate = %d\n", in->streams[MMFILE_AUDIO_STREAM]->bitRate);
debug_msg ("AframePerSec = %d\n", in->streams[MMFILE_AUDIO_STREAM]->framePerSec);
debug_msg ("Awidth = %d\n", in->streams[MMFILE_AUDIO_STREAM]->width);
debug_msg ("Aheight = %d\n", in->streams[MMFILE_AUDIO_STREAM]->height);
debug_msg ("AnbChannel = %d\n", in->streams[MMFILE_AUDIO_STREAM]->nbChannel);
debug_msg ("AsamplePerSec = %d\n", in->streams[MMFILE_AUDIO_STREAM]->samplePerSec);
}
}
}
EXPORT_API
void mmfile_format_print_tags (MMFileFormatContext *in)
{
if (in) {
if (in->title) debug_msg ("title = %s\n", in->title);
if (in->artist) debug_msg ("artist = %s\n", in->artist);
if (in->author) debug_msg ("author = %s\n", in->author);
if (in->composer) debug_msg ("composer = %s\n", in->composer);
if (in->album) debug_msg ("album = %s\n", in->album);
if (in->copyright) debug_msg ("copyright = %s\n", in->copyright);
if (in->comment) debug_msg ("comment = %s\n", in->comment);
if (in->genre) debug_msg ("genre = %s\n", in->genre);
if (in->year) debug_msg ("year = %s\n", in->year);
if (in->recDate) debug_msg ("recDate = %s\n", in->recDate);
debug_msg ("tagTrackNum = %d\n", in->tagTrackNum);
debug_msg ("artworksize = %d\n", in->artworkSize);
if (in->artwork) debug_msg ("artwork = %p\n", in->artwork);
if (in->classification) debug_msg ("classification = %s\n", in->classification);
}
}
EXPORT_API
void mmfile_format_print_frame (MMFileFormatFrame *in)
{
if (in) {
debug_msg ("in->bCompressed = %d\n", in->bCompressed);
debug_msg ("in->frameData = %p\n", in->frameData);
debug_msg ("in->frameHeight = %d\n", in->frameHeight);
debug_msg ("in->frameWidth = %d\n", in->frameWidth);
debug_msg ("in->frameSize = %d\n", in->frameSize);
debug_msg ("in->configLenth = %d\n", in->configLenth);
debug_msg ("in->configData = %p\n", in->configData);
}
}
EXPORT_API
void mmfile_codec_print (MMFileCodecContext *in)
{
if (in) {
debug_msg ("codecType = %d\n", in->codecType);
debug_msg ("codec id = %d\n", in->codecId);
}
}
|