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