changeset 7961:78e0f2776da7

cosmetics ;) prefixing all functions with pp_ to avoid namespace issues
author michael
date Tue, 29 Oct 2002 18:51:52 +0000
parents 0a4ab841ae29
children 1d2d47aa8717
files libmpcodecs/vf_pp.c postproc/postprocess.c postproc/postprocess.h
diffstat 3 files changed, 15 insertions(+), 16 deletions(-) [+]
line wrap: on
line diff
--- a/libmpcodecs/vf_pp.c	Tue Oct 29 18:35:15 2002 +0000
+++ b/libmpcodecs/vf_pp.c	Tue Oct 29 18:51:52 2002 +0000
@@ -25,13 +25,13 @@
 static int config(struct vf_instance_s* vf,
         int width, int height, int d_width, int d_height,
 	unsigned int voflags, unsigned int outfmt){
-    vf->priv->context= getPPContext(width, height);
+    vf->priv->context= pp_get_context(width, height);
 
     return vf_next_config(vf,width,height,d_width,d_height,voflags,vf->priv->outfmt);
 }
 
 static void uninit(struct vf_instance_s* vf){
-    if(vf->priv->context) freePPContext(vf->priv->context);
+    if(vf->priv->context) pp_free_context(vf->priv->context);
 }
 
 static int query_format(struct vf_instance_s* vf, unsigned int fmt){
@@ -89,7 +89,7 @@
     
     if(vf->priv->pp || !(mpi->flags&MP_IMGFLAG_DIRECT)){
 	// do the postprocessing! (or copy if no DR)
-	postprocess(mpi->planes           ,mpi->stride,
+	pp_postprocess(mpi->planes           ,mpi->stride,
 		    vf->priv->dmpi->planes,vf->priv->dmpi->stride,
 		    (mpi->w+7)&(~7),mpi->h,
 		    mpi->qscale, mpi->qstride,
@@ -132,7 +132,7 @@
     
     if(args){
 	if(!strcmp("help", args)){
-		printf("%s", postproc_help);
+		printf("%s", pp_help);
 		exit(1);
 	}
 	
@@ -147,7 +147,7 @@
     
     if(name){
         for(i=0; i<=GET_PP_QUALITY_MAX; i++){
-            vf->priv->ppMode[i]= getPPModeByNameAndQuality(name, i);
+            vf->priv->ppMode[i]= pp_get_mode_by_name_and_quality(name, i);
             if(vf->priv->ppMode[i].error) return -1;
         }
     }else{
--- a/postproc/postprocess.c	Tue Oct 29 18:35:15 2002 +0000
+++ b/postproc/postprocess.c	Tue Oct 29 18:51:52 2002 +0000
@@ -587,7 +587,7 @@
  * name is the string after "-pp" on the command line
  * quality is a number from 0 to GET_PP_QUALITY_MAX
  */
-struct PPMode getPPModeByNameAndQuality(char *name, int quality)
+struct PPMode pp_get_mode_by_name_and_quality(char *name, int quality)
 {
 	char temp[GET_MODE_BUFFER_SIZE];
 	char *p= temp;
@@ -765,7 +765,7 @@
 	return ppMode;
 }
 
-void *getPPContext(int width, int height){
+void *pp_get_context(int width, int height){
 	PPContext *c= memalign(32, sizeof(PPContext));
 	int i;
 	int mbWidth = (width+15)>>4;
@@ -799,7 +799,7 @@
 	return c;
 }
 
-void freePPContext(void *vc){
+void pp_free_context(void *vc){
 	PPContext *c = (PPContext*)vc;
 	int i;
 	
@@ -844,7 +844,7 @@
 }
 
 
-void  postprocess(uint8_t * src[3], int srcStride[3],
+void  pp_postprocess(uint8_t * src[3], int srcStride[3],
                  uint8_t * dst[3], int dstStride[3],
                  int width, int height,
                  QP_STORE_T *QP_store,  int QPStride,
--- a/postproc/postprocess.h	Tue Oct 29 18:35:15 2002 +0000
+++ b/postproc/postprocess.h	Tue Oct 29 18:51:52 2002 +0000
@@ -64,8 +64,9 @@
 
 #define QP_STORE_T int
 
-char *postproc_help;
+char *pp_help;
 
+//FIXME decide if this should be exported at all
 typedef struct PPMode{
 	int lumMode; //acivates filters for luminance
 	int chromMode; //acivates filters for chrominance
@@ -82,18 +83,16 @@
 	int forcedQuant; // quantizer if FORCE_QUANT is used
 } PPMode;
 
-void  postprocess(uint8_t * src[3], int srcStride[3],
+void  pp_postprocess(uint8_t * src[3], int srcStride[3],
                  uint8_t * dst[3], int dstStride[3],
                  int horizontalSize, int verticalSize,
                  QP_STORE_T *QP_store,  int QP_stride,
 		 PPMode *mode, void *ppContext, int pict_type);
 
 // name is the stuff after "-pp" on the command line
-PPMode getPPModeByNameAndQuality(char *name, int quality);
+PPMode pp_get_mode_by_name_and_quality(char *name, int quality);
 
-void *getPPContext(int width, int height);
-void freePPContext(void *ppContext);
-
-int readPPOpt(void *conf, char *arg);
+void *pp_get_context(int width, int height);
+void pp_free_context(void *ppContext);
 
 #endif