aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar reynaldo <reynaldo@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-07-13 20:59:18 +0000
committerGravatar reynaldo <reynaldo@b3059339-0415-0410-9bf9-f77b7e298cf2>2006-07-13 20:59:18 +0000
commitc0c641f0e3e9a6d5a071c65e53fdd93ba3274029 (patch)
tree013d636a653c725c7ed7a8440702f6e43c3b3e3c
parentd8c03e95a56e63f5a7bba4d9c27739cd3c03d01e (diff)
marks several function without a prototype which arent used outside its sourcefile as static, Patch by Stefan Huehner - stefan AT huehner-org
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@19071 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r--libass/ass_render.c4
-rw-r--r--libmpcodecs/vf_remove_logo.c21
-rw-r--r--subreader.c36
-rw-r--r--vidix/drivers/nvidia_vid.c4
-rw-r--r--vidix/drivers/radeon_vid.c2
-rw-r--r--vidix/drivers/savage_vid.c8
-rw-r--r--vidix/drivers/unichrome_vid.c14
7 files changed, 44 insertions, 45 deletions
diff --git a/libass/ass_render.c b/libass/ass_render.c
index 341698056a..3dbc38359d 100644
--- a/libass/ass_render.c
+++ b/libass/ass_render.c
@@ -1361,7 +1361,7 @@ static void process_karaoke_effects(void)
}
}
-int get_face_ascender(FT_Face face)
+static int get_face_ascender(FT_Face face)
{
int v = face->size->metrics.ascender;
if (!v)
@@ -1369,7 +1369,7 @@ int get_face_ascender(FT_Face face)
return v;
}
-int get_face_descender(FT_Face face)
+static int get_face_descender(FT_Face face)
{
int v = face->size->metrics.descender;
if (!v)
diff --git a/libmpcodecs/vf_remove_logo.c b/libmpcodecs/vf_remove_logo.c
index 775c81d280..6b4e370c00 100644
--- a/libmpcodecs/vf_remove_logo.c
+++ b/libmpcodecs/vf_remove_logo.c
@@ -174,7 +174,7 @@ typedef struct
* of how MPlayer works, it cannot safely halt execution, but at least the user
* will get an error message before the segfault happens.
*/
-void * safe_malloc(int size)
+static void * safe_malloc(int size)
{
void * answer = malloc(size);
if (answer == NULL)
@@ -194,8 +194,7 @@ void * safe_malloc(int size)
* pixels. The results are returned by reference to posx1, posy1, posx2, and
* posy2.
*/
-
-void calculate_bounding_rectangle(int * posx1, int * posy1, int * posx2, int * posy2, pgm_structure * filter)
+static void calculate_bounding_rectangle(int * posx1, int * posy1, int * posx2, int * posy2, pgm_structure * filter)
{
int x; /* Temporary variables to run */
int y; /* through each row or column. */
@@ -264,7 +263,7 @@ void calculate_bounding_rectangle(int * posx1, int * posy1, int * posx2, int * p
* We call this function when our filter is done. It will free the memory
* allocated to the masks and leave the variables in a safe state.
*/
-void destroy_masks(vf_instance_t * vf)
+static void destroy_masks(vf_instance_t * vf)
{
int a, b;
@@ -301,7 +300,7 @@ void destroy_masks(vf_instance_t * vf)
* values. The values will not change during program execution once this function
* is done.
*/
-void initialize_masks(vf_instance_t * vf)
+static void initialize_masks(vf_instance_t * vf)
{
int a, b, c;
@@ -349,7 +348,7 @@ void initialize_masks(vf_instance_t * vf)
* to implement than a proper pythagorean distance since I'm using a modified
* erosion algorithm to compute the distances.
*/
-void convert_mask_to_strength_mask(vf_instance_t * vf, pgm_structure * mask)
+static void convert_mask_to_strength_mask(vf_instance_t * vf, pgm_structure * mask)
{
int x, y; /* Used by our for loops to go through every single pixel in the picture one at a time. */
int has_anything_changed = 1; /* Used by the main while() loop to know if anything changed on the last erosion. */
@@ -430,7 +429,7 @@ void convert_mask_to_strength_mask(vf_instance_t * vf, pgm_structure * mask)
* logo and blurs it. It does so by finding the average of all the pixels within
* the mask and outside of the logo.
*/
-void get_blur(const vf_instance_t * const vf, unsigned int * const value_out, const pgm_structure * const logo_mask,
+static void get_blur(const vf_instance_t * const vf, unsigned int * const value_out, const pgm_structure * const logo_mask,
const mp_image_t * const image, const int x, const int y, const int plane)
{
int mask_size; /* Mask size tells how large a circle to use. The radius is about (slightly larger than) mask size. */
@@ -486,7 +485,7 @@ void get_blur(const vf_instance_t * const vf, unsigned int * const value_out, co
/**
* \brief Free a pgm_structure. Undoes load_pgm(...).
*/
-void destroy_pgm(pgm_structure * to_be_destroyed)
+static void destroy_pgm(pgm_structure * to_be_destroyed)
{
if (to_be_destroyed == NULL)
return; /* Don't do anything if a NULL pointer was passed it. */
@@ -503,7 +502,7 @@ void destroy_pgm(pgm_structure * to_be_destroyed)
}
/** \brief Helper function for load_pgm(...) to skip whitespace. */
-void load_pgm_skip(FILE *f) {
+static void load_pgm_skip(FILE *f) {
int c, comment = 0;
do {
c = fgetc(f);
@@ -533,7 +532,7 @@ void load_pgm_skip(FILE *f) {
* guaranteed with ppm is that all zero (R = 0, G = 0, B = 0) pixels will remain
* zero, and non-zero pixels will remain non-zero.
*/
-pgm_structure * load_pgm(const char * file_name)
+static pgm_structure * load_pgm(const char * file_name)
{
int maximum_greyscale_value;
FILE * input;
@@ -594,7 +593,7 @@ pgm_structure * load_pgm(const char * file_name)
* rounding error will only cause a minor amount of excess blur in the chroma
* planes.
*/
-pgm_structure * generate_half_size_image(vf_instance_t * vf, pgm_structure * input_image)
+static pgm_structure * generate_half_size_image(vf_instance_t * vf, pgm_structure * input_image)
{
int x, y;
pgm_structure * new_pgm = (pgm_structure *) safe_malloc (sizeof(pgm_structure));
diff --git a/subreader.c b/subreader.c
index 0c0002d231..d7dc377f34 100644
--- a/subreader.c
+++ b/subreader.c
@@ -95,7 +95,7 @@ static char *stristr(const char *haystack, const char *needle) {
return NULL;
}
-subtitle *sub_read_line_sami(stream_t* st, subtitle *current) {
+static subtitle *sub_read_line_sami(stream_t* st, subtitle *current) {
static char line[LINE_LEN+1];
static char *s = NULL, *slacktime_s;
char text[LINE_LEN+1], *p=NULL, *q;
@@ -236,7 +236,7 @@ subtitle *sub_read_line_sami(stream_t* st, subtitle *current) {
}
-char *sub_readtext(char *source, char **dest) {
+static char *sub_readtext(char *source, char **dest) {
int len=0;
char *p=source;
@@ -258,7 +258,7 @@ char *sub_readtext(char *source, char **dest) {
else return NULL; // last text field
}
-subtitle *sub_read_line_microdvd(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_microdvd(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
char line2[LINE_LEN+1];
char *p, *next;
@@ -286,7 +286,7 @@ subtitle *sub_read_line_microdvd(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_mpl2(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_mpl2(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
char line2[LINE_LEN+1];
char *p, *next;
@@ -312,7 +312,7 @@ subtitle *sub_read_line_mpl2(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_subrip(stream_t* st, subtitle *current) {
+static subtitle *sub_read_line_subrip(stream_t* st, subtitle *current) {
char line[LINE_LEN+1];
int a1,a2,a3,a4,b1,b2,b3,b4;
char *p=NULL, *q=NULL;
@@ -342,7 +342,7 @@ subtitle *sub_read_line_subrip(stream_t* st, subtitle *current) {
return current;
}
-subtitle *sub_read_line_subviewer(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_subviewer(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
int a1,a2,a3,a4,b1,b2,b3,b4;
char *p=NULL;
@@ -391,7 +391,7 @@ subtitle *sub_read_line_subviewer(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_subviewer2(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_subviewer2(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
int a1,a2,a3,a4;
char *p=NULL;
@@ -424,7 +424,7 @@ subtitle *sub_read_line_subviewer2(stream_t *st,subtitle *current) {
}
-subtitle *sub_read_line_vplayer(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_vplayer(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
int a1,a2,a3;
char *p=NULL, *next,separator;
@@ -470,7 +470,7 @@ subtitle *sub_read_line_vplayer(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_rt(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_rt(stream_t *st,subtitle *current) {
//TODO: This format uses quite rich (sub/super)set of xhtml
// I couldn't check it since DTD is not included.
// WARNING: full XML parses can be required for proper parsing
@@ -520,7 +520,7 @@ subtitle *sub_read_line_rt(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_ssa(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_ssa(stream_t *st,subtitle *current) {
/*
* Sub Station Alpha v4 (and v2?) scripts have 9 commas before subtitle
* other Sub Station Alpha scripts have only 8 commas before subtitle
@@ -592,7 +592,7 @@ subtitle *sub_read_line_ssa(stream_t *st,subtitle *current) {
return current;
}
-void sub_pp_ssa(subtitle *sub) {
+static void sub_pp_ssa(subtitle *sub) {
int l=sub->lines;
char *so,*de,*start;
@@ -621,7 +621,7 @@ void sub_pp_ssa(subtitle *sub) {
*
* by set, based on code by szabi (dunnowhat sub format ;-)
*/
-subtitle *sub_read_line_pjs(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_pjs(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
char text[LINE_LEN+1], *s, *d;
@@ -659,7 +659,7 @@ subtitle *sub_read_line_pjs(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_mpsub(stream_t *st, subtitle *current) {
+static subtitle *sub_read_line_mpsub(stream_t *st, subtitle *current) {
char line[LINE_LEN+1];
float a,b;
int num=0;
@@ -704,7 +704,7 @@ subtitle *sub_read_line_mpsub(stream_t *st, subtitle *current) {
subtitle *previous_aqt_sub = NULL;
#endif
-subtitle *sub_read_line_aqt(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_aqt(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
char *next;
int i;
@@ -761,7 +761,7 @@ subtitle *sub_read_line_aqt(stream_t *st,subtitle *current) {
subtitle *previous_subrip09_sub = NULL;
#endif
-subtitle *sub_read_line_subrip09(stream_t *st,subtitle *current) {
+static subtitle *sub_read_line_subrip09(stream_t *st,subtitle *current) {
char line[LINE_LEN+1];
int a1,a2,a3;
char * next=NULL;
@@ -813,7 +813,7 @@ subtitle *sub_read_line_subrip09(stream_t *st,subtitle *current) {
return current;
}
-subtitle *sub_read_line_jacosub(stream_t* st, subtitle * current)
+static subtitle *sub_read_line_jacosub(stream_t* st, subtitle * current)
{
char line1[LINE_LEN], line2[LINE_LEN], directive[LINE_LEN], *p, *q;
unsigned a1, a2, a3, a4, b1, b2, b3, b4, comment = 0;
@@ -1004,7 +1004,7 @@ subtitle *sub_read_line_jacosub(stream_t* st, subtitle * current)
return current;
}
-int sub_autodetect (stream_t* st, int *uses_time) {
+static int sub_autodetect (stream_t* st, int *uses_time) {
char line[LINE_LEN+1];
int i,j=0;
char p;
@@ -1118,7 +1118,7 @@ void subcp_close (void)
#define ICBUFFSIZE 512
static char icbuffer[ICBUFFSIZE];
-subtitle* subcp_recode (subtitle *sub)
+static subtitle* subcp_recode (subtitle *sub)
{
int l=sub->lines;
size_t ileft, oleft;
diff --git a/vidix/drivers/nvidia_vid.c b/vidix/drivers/nvidia_vid.c
index e549eb98e3..710336098e 100644
--- a/vidix/drivers/nvidia_vid.c
+++ b/vidix/drivers/nvidia_vid.c
@@ -387,7 +387,7 @@ static void rivatv_enable_PMEDIA (struct rivatv_info *info){
}
/* Stop overlay video. */
-void rivatv_overlay_stop (struct rivatv_info *info) {
+static void rivatv_overlay_stop (struct rivatv_info *info) {
switch (info->chip.arch ) {
case NV_ARCH_10:
case NV_ARCH_20:
@@ -517,7 +517,7 @@ static void nv_getscreenproperties(struct rivatv_info *info){
/* Start overlay video. */
-void rivatv_overlay_start (struct rivatv_info *info,int bufno){
+static void rivatv_overlay_start (struct rivatv_info *info,int bufno){
uint32_t base, size, offset, xscale, yscale, pan;
uint32_t value;
int x=info->wx, y=info->wy;
diff --git a/vidix/drivers/radeon_vid.c b/vidix/drivers/radeon_vid.c
index 4a8c095d48..33a05e3acd 100644
--- a/vidix/drivers/radeon_vid.c
+++ b/vidix/drivers/radeon_vid.c
@@ -950,7 +950,7 @@ vidix_capability_t def_cap =
};
#ifdef HAVE_X11
-void probe_fireGL_driver(void) {
+static void probe_fireGL_driver(void) {
Display *dp = XOpenDisplay ((void*)0);
int n = 0;
char **extlist;
diff --git a/vidix/drivers/savage_vid.c b/vidix/drivers/savage_vid.c
index ac19266591..2165230cb1 100644
--- a/vidix/drivers/savage_vid.c
+++ b/vidix/drivers/savage_vid.c
@@ -323,7 +323,7 @@ static struct savage_cards savage_card_ids[] = {
{ PCI_CHIP_PROSAVAGE_DDRK , S3_PROSAVAGE },
};
-void SavageSetColorOld(void)
+static void SavageSetColorOld(void)
{
@@ -360,7 +360,7 @@ void SavageSetColorOld(void)
}
}
-void SavageSetColorKeyOld(void)
+static void SavageSetColorKeyOld(void)
{
int red, green, blue;
@@ -528,7 +528,7 @@ SavageDisplayVideoOld(void)
}
-void SavageInitStreamsOld(void)
+static void SavageInitStreamsOld(void)
{
/*unsigned long jDelta;*/
unsigned long format = 0;
@@ -726,7 +726,7 @@ static void savage_getscreenproperties(struct savage_info *info){
}
-void SavageStreamsOff(void)
+static void SavageStreamsOff(void)
{
unsigned char jStreamsControl;
unsigned short vgaCRIndex = 0x3d0 + 4;
diff --git a/vidix/drivers/unichrome_vid.c b/vidix/drivers/unichrome_vid.c
index 3eef1bb3b9..549db826a8 100644
--- a/vidix/drivers/unichrome_vid.c
+++ b/vidix/drivers/unichrome_vid.c
@@ -159,7 +159,7 @@ find_chip (unsigned chip_id)
* @note Derived from VIA's V4L driver.
* See ddover.c, DDOVER_HQVCalcZoomHeight()
*/
-int
+static int
uc_ovl_map_vzoom (int sh, int dh, uint32_t * zoom, uint32_t * mini)
{
uint32_t sh1, tmp, d;
@@ -223,7 +223,7 @@ uc_ovl_map_vzoom (int sh, int dh, uint32_t * zoom, uint32_t * mini)
* @note Derived from VIA's V4L driver.
* See ddover.c, DDOVER_HQVCalcZoomWidth() and DDOver_GetDisplayCount()
*/
-int
+static int
uc_ovl_map_hzoom (int sw, int dw, uint32_t * zoom, uint32_t * mini,
int *falign, int *dcount)
{
@@ -292,7 +292,7 @@ uc_ovl_map_hzoom (int sw, int dw, uint32_t * zoom, uint32_t * mini,
* @note Derived from VIA's V4L driver. See ddover.c, DDOver_GetFetch()
* @note Only call after uc_ovl_map_hzoom()
*/
-uint32_t
+static uint32_t
uc_ovl_map_qwfetch (uint32_t format, int sw)
{
uint32_t fetch = 0;
@@ -335,7 +335,7 @@ uc_ovl_map_qwfetch (uint32_t format, int sw)
*
* @note Derived from VIA's V4L driver. See ddover.c, DDOver_GetV1Format()
*/
-uint32_t
+static uint32_t
uc_ovl_map_format (uint32_t format)
{
switch (format)
@@ -371,7 +371,7 @@ uc_ovl_map_format (uint32_t format)
* @param control will hold value for V1_CONTROL.
* @param fifo will hold value for V1_FIFO_CONTROL.
*/
-void
+static void
uc_ovl_map_v1_control (uint32_t format, int sw,
int hwrev, int extfifo_on,
uint32_t * control, uint32_t * fifo)
@@ -431,7 +431,7 @@ uc_ovl_map_v1_control (uint32_t format, int sw,
* @param extfifo_on pointer determining if extended fifo is enable or not.
* @param dst_w destination width.
*/
-void
+static void
uc_ovl_setup_fifo (int *extfifo_on, int dst_w)
{
if (dst_w <= 1024) /* Disable extended FIFO */
@@ -456,7 +456,7 @@ uc_ovl_setup_fifo (int *extfifo_on, int dst_w)
}
}
-void
+static void
uc_ovl_vcmd_wait (volatile uint8_t * vio)
{
while ((VIDEO_IN (vio, V_COMPOSE_MODE)