annotate dsicin.c @ 1931:69c6eb14fdfc libavformat

improve ac3_probe by counting consecutive frames
author jbr
date Sun, 18 Mar 2007 19:32:22 +0000
parents a782462e2497
children 1a3c9056982a
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1378
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
1 /*
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
2 * Delphine Software International CIN File Demuxer
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
3 * Copyright (c) 2006 Gregory Montoir (cyx@users.sourceforge.net)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
4 *
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
5 * This file is part of FFmpeg.
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
6 *
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
7 * FFmpeg is free software; you can redistribute it and/or
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
8 * modify it under the terms of the GNU Lesser General Public
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
9 * License as published by the Free Software Foundation; either
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
10 * version 2.1 of the License, or (at your option) any later version.
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
11 *
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
12 * FFmpeg is distributed in the hope that it will be useful,
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
15 * Lesser General Public License for more details.
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
16 *
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
17 * You should have received a copy of the GNU Lesser General Public
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
18 * License along with FFmpeg; if not, write to the Free Software
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
20 */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
21
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
22 /**
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
23 * @file dsicin.c
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
24 * Delphine Software International CIN file demuxer
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
25 */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
26
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
27 #include "avformat.h"
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
28
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
29
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
30 typedef struct CinFileHeader {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
31 int video_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
32 int video_frame_width;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
33 int video_frame_height;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
34 int audio_frequency;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
35 int audio_bits;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
36 int audio_stereo;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
37 int audio_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
38 } CinFileHeader;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
39
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
40 typedef struct CinFrameHeader {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
41 int audio_frame_type;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
42 int video_frame_type;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
43 int pal_colors_count;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
44 int audio_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
45 int video_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
46 } CinFrameHeader;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
47
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
48 typedef struct CinDemuxContext {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
49 int audio_stream_index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
50 int video_stream_index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
51 CinFileHeader file_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
52 int64_t audio_stream_pts;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
53 int64_t video_stream_pts;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
54 CinFrameHeader frame_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
55 int audio_buffer_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
56 } CinDemuxContext;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
57
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
58
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
59 static int cin_probe(AVProbeData *p)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
60 {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
61 if (p->buf_size < 18)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
62 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
63
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
64 /* header starts with this special marker */
1673
a782462e2497 rename BE/LE_8/16/32 to AV_RL/B_8/16/32
alex
parents: 1378
diff changeset
65 if (AV_RL32(&p->buf[0]) != 0x55AA0000)
1378
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
66 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
67
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
68 /* for accuracy, check some header field values */
1673
a782462e2497 rename BE/LE_8/16/32 to AV_RL/B_8/16/32
alex
parents: 1378
diff changeset
69 if (AV_RL32(&p->buf[12]) != 22050 || p->buf[16] != 16 || p->buf[17] != 0)
1378
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
70 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
71
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
72 return AVPROBE_SCORE_MAX;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
73 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
74
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
75 static int cin_read_file_header(CinDemuxContext *cin, ByteIOContext *pb) {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
76 CinFileHeader *hdr = &cin->file_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
77
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
78 if (get_le32(pb) != 0x55AA0000)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
79 return AVERROR_INVALIDDATA;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
80
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
81 hdr->video_frame_size = get_le32(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
82 hdr->video_frame_width = get_le16(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
83 hdr->video_frame_height = get_le16(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
84 hdr->audio_frequency = get_le32(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
85 hdr->audio_bits = get_byte(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
86 hdr->audio_stereo = get_byte(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
87 hdr->audio_frame_size = get_le16(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
88
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
89 if (hdr->audio_frequency != 22050 || hdr->audio_bits != 16 || hdr->audio_stereo != 0)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
90 return AVERROR_INVALIDDATA;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
91
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
92 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
93 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
94
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
95 static int cin_read_header(AVFormatContext *s, AVFormatParameters *ap)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
96 {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
97 int rc;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
98 CinDemuxContext *cin = (CinDemuxContext *)s->priv_data;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
99 CinFileHeader *hdr = &cin->file_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
100 ByteIOContext *pb = &s->pb;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
101 AVStream *st;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
102
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
103 rc = cin_read_file_header(cin, pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
104 if (rc)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
105 return rc;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
106
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
107 cin->video_stream_pts = 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
108 cin->audio_stream_pts = 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
109 cin->audio_buffer_size = 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
110
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
111 /* initialize the video decoder stream */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
112 st = av_new_stream(s, 0);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
113 if (!st)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
114 return AVERROR_NOMEM;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
115
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
116 av_set_pts_info(st, 32, 1, 12);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
117 cin->video_stream_index = st->index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
118 st->codec->codec_type = CODEC_TYPE_VIDEO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
119 st->codec->codec_id = CODEC_ID_DSICINVIDEO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
120 st->codec->codec_tag = 0; /* no fourcc */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
121 st->codec->width = hdr->video_frame_width;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
122 st->codec->height = hdr->video_frame_height;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
123
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
124 /* initialize the audio decoder stream */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
125 st = av_new_stream(s, 0);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
126 if (!st)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
127 return AVERROR_NOMEM;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
128
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
129 av_set_pts_info(st, 32, 1, 22050);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
130 cin->audio_stream_index = st->index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
131 st->codec->codec_type = CODEC_TYPE_AUDIO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
132 st->codec->codec_id = CODEC_ID_DSICINAUDIO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
133 st->codec->codec_tag = 0; /* no tag */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
134 st->codec->channels = 1;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
135 st->codec->sample_rate = 22050;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
136 st->codec->bits_per_sample = 16;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
137 st->codec->bit_rate = st->codec->sample_rate * st->codec->bits_per_sample * st->codec->channels;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
138 st->codec->block_align = st->codec->channels * st->codec->bits_per_sample;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
139
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
140 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
141 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
142
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
143 static int cin_read_frame_header(CinDemuxContext *cin, ByteIOContext *pb) {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
144 CinFrameHeader *hdr = &cin->frame_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
145
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
146 hdr->video_frame_type = get_byte(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
147 hdr->audio_frame_type = get_byte(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
148 hdr->pal_colors_count = get_le16(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
149 hdr->video_frame_size = get_le32(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
150 hdr->audio_frame_size = get_le32(pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
151
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
152 if (url_feof(pb) || url_ferror(pb))
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
153 return AVERROR_IO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
154
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
155 if (get_le32(pb) != 0xAA55AA55)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
156 return AVERROR_INVALIDDATA;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
157
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
158 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
159 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
160
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
161 static int cin_read_packet(AVFormatContext *s, AVPacket *pkt)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
162 {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
163 CinDemuxContext *cin = (CinDemuxContext *)s->priv_data;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
164 ByteIOContext *pb = &s->pb;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
165 CinFrameHeader *hdr = &cin->frame_header;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
166 int rc, palette_type, pkt_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
167
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
168 if (cin->audio_buffer_size == 0) {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
169 rc = cin_read_frame_header(cin, pb);
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
170 if (rc)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
171 return rc;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
172
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
173 if ((int16_t)hdr->pal_colors_count < 0) {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
174 hdr->pal_colors_count = -(int16_t)hdr->pal_colors_count;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
175 palette_type = 1;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
176 } else {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
177 palette_type = 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
178 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
179
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
180 /* palette and video packet */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
181 pkt_size = (palette_type + 3) * hdr->pal_colors_count + hdr->video_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
182
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
183 if (av_new_packet(pkt, 4 + pkt_size))
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
184 return AVERROR_NOMEM;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
185
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
186 pkt->stream_index = cin->video_stream_index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
187 pkt->pts = cin->video_stream_pts++;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
188
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
189 pkt->data[0] = palette_type;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
190 pkt->data[1] = hdr->pal_colors_count & 0xFF;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
191 pkt->data[2] = hdr->pal_colors_count >> 8;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
192 pkt->data[3] = hdr->video_frame_type;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
193
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
194 if (get_buffer(pb, &pkt->data[4], pkt_size) != pkt_size)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
195 return AVERROR_IO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
196
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
197 /* sound buffer will be processed on next read_packet() call */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
198 cin->audio_buffer_size = hdr->audio_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
199 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
200 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
201
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
202 /* audio packet */
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
203 if (av_new_packet(pkt, cin->audio_buffer_size))
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
204 return AVERROR_NOMEM;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
205
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
206 pkt->stream_index = cin->audio_stream_index;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
207 pkt->pts = cin->audio_stream_pts;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
208 cin->audio_stream_pts += cin->audio_buffer_size * 2 / cin->file_header.audio_frame_size;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
209
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
210 if (get_buffer(pb, pkt->data, cin->audio_buffer_size) != cin->audio_buffer_size)
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
211 return AVERROR_IO;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
212
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
213 cin->audio_buffer_size = 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
214 return 0;
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
215 }
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
216
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
217 AVInputFormat dsicin_demuxer = {
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
218 "dsicin",
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
219 "Delphine Software International CIN format",
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
220 sizeof(CinDemuxContext),
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
221 cin_probe,
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
222 cin_read_header,
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
223 cin_read_packet,
a32812bb5bcf support for Delphine Software .cin files demuxing / audio and video decoding, by Gregory Montoir %cyx A users P sourceforge P net%
bcoudurier
parents:
diff changeset
224 };