ogg: Prevent some symbol conflicts between the ogg plugin and schroedinger

This commit is contained in:
Sebastian Dröge 2013-04-15 08:38:34 +02:00
parent 05c7cd1113
commit 6e01d1869b
5 changed files with 30 additions and 26 deletions

View file

@ -21,22 +21,22 @@ static unsigned int schro_unpack_decode_bit (Unpack * unpack);
static unsigned int schro_unpack_decode_uint (Unpack * unpack);
void schro_video_format_set_std_video_format (DiracSequenceHeader * format,
int index);
void schro_video_format_set_std_frame_rate (DiracSequenceHeader * format,
int index);
void schro_video_format_set_std_aspect_ratio (DiracSequenceHeader * format,
int index);
void schro_video_format_set_std_signal_range (DiracSequenceHeader * format,
int index);
void schro_video_format_set_std_colour_spec (DiracSequenceHeader * format,
static void schro_video_format_set_std_video_format (DiracSequenceHeader *
format, int index);
static void schro_video_format_set_std_frame_rate (DiracSequenceHeader * format,
int index);
static void schro_video_format_set_std_aspect_ratio (DiracSequenceHeader *
format, int index);
static void schro_video_format_set_std_signal_range (DiracSequenceHeader *
format, int index);
static void schro_video_format_set_std_colour_spec (DiracSequenceHeader *
format, int index);
int
dirac_sequence_header_parse (DiracSequenceHeader * header,
gst_dirac_sequence_header_parse (DiracSequenceHeader * header,
unsigned char *data, int n_bytes)
{
int bit;
@ -165,7 +165,7 @@ dirac_sequence_header_parse (DiracSequenceHeader * header,
/* standard stuff */
static DiracSequenceHeader schro_video_formats[] = {
static const DiracSequenceHeader schro_video_formats[] = {
{0, 0, 0, 0,
0, /* custom */
640, 480, SCHRO_CHROMA_420,
@ -304,7 +304,7 @@ static DiracSequenceHeader schro_video_formats[] = {
3, 0, 0},
};
void
static void
schro_video_format_set_std_video_format (DiracSequenceHeader * format,
int index)
{
@ -323,7 +323,7 @@ struct _SchroFrameRate
int denominator;
};
static SchroFrameRate schro_frame_rates[] = {
static const SchroFrameRate schro_frame_rates[] = {
{0, 0},
{24000, 1001},
{24, 1},
@ -337,7 +337,7 @@ static SchroFrameRate schro_frame_rates[] = {
{25, 2}
};
void
static void
schro_video_format_set_std_frame_rate (DiracSequenceHeader * format, int index)
{
if (index < 1 || index >= ARRAY_SIZE (schro_frame_rates)) {
@ -365,7 +365,7 @@ static const SchroPixelAspectRatio schro_aspect_ratios[] = {
{4, 3}
};
void
static void
schro_video_format_set_std_aspect_ratio (DiracSequenceHeader * format,
int index)
{
@ -395,7 +395,7 @@ static const SchroSignalRangeStruct schro_signal_ranges[] = {
{256, 3504, 2048, 3584}
};
void
static void
schro_video_format_set_std_signal_range (DiracSequenceHeader * format, int i)
{
if (i < 1 || i >= ARRAY_SIZE (schro_signal_ranges)) {
@ -439,7 +439,7 @@ static const SchroColourSpecStruct schro_colour_specs[] = {
SCHRO_TRANSFER_CHAR_TV_GAMMA}
};
void
static void
schro_video_format_set_std_colour_spec (DiracSequenceHeader * format, int i)
{
if (i < 0 || i >= ARRAY_SIZE (schro_colour_specs)) {

View file

@ -2,6 +2,8 @@
#ifndef __DIRAC_PARSE_H__
#define __DIRAC_PARSE_H__
#include <glib.h>
#ifdef __cplusplus
extern "C" {
#endif
@ -166,8 +168,8 @@ struct _DiracSequenceHeader {
int unused2;
};
int dirac_sequence_header_parse (DiracSequenceHeader *header,
G_GNUC_INTERNAL
int gst_dirac_sequence_header_parse (DiracSequenceHeader *header,
unsigned char *data, int length);
#ifdef __cplusplus

View file

@ -517,7 +517,7 @@ setup_dirac_mapper (GstOggStream * pad, ogg_packet * packet)
int ret;
DiracSequenceHeader header;
ret = dirac_sequence_header_parse (&header, packet->packet + 13,
ret = gst_dirac_sequence_header_parse (&header, packet->packet + 13,
packet->bytes - 13);
if (ret == 0) {
GST_DEBUG ("Failed to parse Dirac sequence header");
@ -785,7 +785,7 @@ setup_vorbis_mapper (GstOggStream * pad, ogg_packet * packet)
if (pad->granulerate_n == 0)
return FALSE;
parse_vorbis_header_packet (pad, packet);
gst_parse_vorbis_header_packet (pad, packet);
pad->caps = gst_caps_new_simple ("audio/x-vorbis",
"rate", G_TYPE_INT, pad->granulerate_n, "channels", G_TYPE_INT, chans,
@ -801,7 +801,7 @@ is_header_vorbis (GstOggStream * pad, ogg_packet * packet)
return FALSE;
if (packet->packet[0] == 5) {
parse_vorbis_setup_packet (pad, packet);
gst_parse_vorbis_setup_packet (pad, packet);
}
return TRUE;

View file

@ -76,7 +76,7 @@
void
parse_vorbis_header_packet (GstOggStream * pad, ogg_packet * packet)
gst_parse_vorbis_header_packet (GstOggStream * pad, ogg_packet * packet)
{
/*
* on the first (b_o_s) packet, determine the long and short sizes,
@ -98,7 +98,7 @@ parse_vorbis_header_packet (GstOggStream * pad, ogg_packet * packet)
}
void
parse_vorbis_setup_packet (GstOggStream * pad, ogg_packet * op)
gst_parse_vorbis_setup_packet (GstOggStream * pad, ogg_packet * op)
{
/*
* the code pages, a whole bunch of other fairly useless stuff, AND,

View file

@ -24,7 +24,9 @@
#include <gst/gst.h>
void parse_vorbis_header_packet (GstOggStream * pad, ogg_packet * packet);
void parse_vorbis_setup_packet (GstOggStream * pad, ogg_packet * op);
G_GNUC_INTERNAL
void gst_parse_vorbis_header_packet (GstOggStream * pad, ogg_packet * packet);
G_GNUC_INTERNAL
void gst_parse_vorbis_setup_packet (GstOggStream * pad, ogg_packet * op);
#endif /* __GST_VORBIS_PARSE_H__ */