diff options
Diffstat (limited to 'libmpcodecs')
-rw-r--r-- | libmpcodecs/vf_1bpp.c | 8 | ||||
-rw-r--r-- | libmpcodecs/vf_ass.c | 12 | ||||
-rw-r--r-- | libmpcodecs/vf_blackframe.c | 4 | ||||
-rw-r--r-- | libmpcodecs/vf_bmovl.c | 2 | ||||
-rw-r--r-- | libmpcodecs/vf_boxblur.c | 2 | ||||
-rw-r--r-- | libmpcodecs/vf_crop.c | 10 |
6 files changed, 19 insertions, 19 deletions
diff --git a/libmpcodecs/vf_1bpp.c b/libmpcodecs/vf_1bpp.c index d0e4ffd007..873e431855 100644 --- a/libmpcodecs/vf_1bpp.c +++ b/libmpcodecs/vf_1bpp.c @@ -12,7 +12,7 @@ //===========================================================================// -static unsigned int bgr_list[]={ +static const unsigned int bgr_list[]={ IMGFMT_Y800, IMGFMT_Y8, IMGFMT_BGR8, @@ -43,7 +43,7 @@ static unsigned int bgr_list[]={ static unsigned int find_best(struct vf_instance_s* vf){ unsigned int best=0; int ret; - unsigned int* p=bgr_list; + const unsigned int* p=bgr_list; while(*p){ ret=vf->next->query_format(vf->next,*p); mp_msg(MSGT_VFILTER,MSGL_V,"[%s] query(%s) -> %d\n",vf->info->name,vo_format_name(*p),ret&3); @@ -74,7 +74,7 @@ static int config(struct vf_instance_s* vf, return vf_next_config(vf,width,height,d_width,d_height,flags,vf->priv->fmt); } -static int bittab[8]={128,64,32,16,8,4,2,1}; +static const int bittab[8]={128,64,32,16,8,4,2,1}; static void convert(mp_image_t *mpi, mp_image_t *dmpi, int value0, int value1,int bpp){ int y; @@ -171,7 +171,7 @@ static int open(vf_instance_t *vf, char* args){ return 1; } -vf_info_t vf_info_1bpp = { +const vf_info_t vf_info_1bpp = { "1bpp bitmap -> YUV/BGR 8/15/16/32 conversion", "1bpp", "A'rpi", diff --git a/libmpcodecs/vf_ass.c b/libmpcodecs/vf_ass.c index 9ce50cf006..9f4c91961a 100644 --- a/libmpcodecs/vf_ass.c +++ b/libmpcodecs/vf_ass.c @@ -51,7 +51,7 @@ #define rgba2v(c) ( (( 450*_r(c) - 376*_g(c) - 73*_b(c)) >> 10) + 128 ) -static struct vf_priv_s { +static const struct vf_priv_s { int outh, outw; unsigned int outfmt; @@ -64,7 +64,7 @@ static struct vf_priv_s { unsigned char* planes[3]; unsigned char* dirty_rows; -} const vf_priv_dflt; +} vf_priv_dflt; extern int opt_screen_size_x; extern int opt_screen_size_y; @@ -372,7 +372,7 @@ static void uninit(struct vf_instance_s* vf) free(vf->priv->dirty_rows); } -static unsigned int fmt_list[]={ +static const unsigned int fmt_list[]={ IMGFMT_YV12, IMGFMT_I420, IMGFMT_IYUV, @@ -405,19 +405,19 @@ static int open(vf_instance_t *vf, char* args) } #define ST_OFF(f) M_ST_OFF(struct vf_priv_s,f) -static m_option_t vf_opts_fields[] = { +static const m_option_t vf_opts_fields[] = { {"auto", ST_OFF(auto_insert), CONF_TYPE_FLAG, 0 , 0, 1, NULL}, { NULL, NULL, 0, 0, 0, 0, NULL } }; -static m_struct_t vf_opts = { +static const m_struct_t vf_opts = { "ass", sizeof(struct vf_priv_s), &vf_priv_dflt, vf_opts_fields }; -vf_info_t vf_info_ass = { +const vf_info_t vf_info_ass = { "Render ASS/SSA subtitles", "ass", "Evgeniy Stepanov", diff --git a/libmpcodecs/vf_blackframe.c b/libmpcodecs/vf_blackframe.c index 054b37c09b..a405803429 100644 --- a/libmpcodecs/vf_blackframe.c +++ b/libmpcodecs/vf_blackframe.c @@ -76,7 +76,7 @@ static int put_image(struct vf_instance_s* vf, mp_image_t *mpi, double pts){ int w = mpi->w, h = mpi->h; int bthresh = vf->priv->bthresh; int bamount = vf->priv->bamount; - static const char *picttypes[4] = { "unknown", "I", "P", "B" }; + static const char *const picttypes[4] = { "unknown", "I", "P", "B" }; for (y=1; y<=h; y++) { for (x=0; x<w; x++) @@ -138,7 +138,7 @@ static int open(vf_instance_t *vf, char* args){ return 1; } -vf_info_t vf_info_blackframe = { +const vf_info_t vf_info_blackframe = { "detects black frames", "blackframe", "Brian J. Murrell, Julian Hall, Ivo van Poorten", diff --git a/libmpcodecs/vf_bmovl.c b/libmpcodecs/vf_bmovl.c index ef7ce19ce9..ab2c23944c 100644 --- a/libmpcodecs/vf_bmovl.c +++ b/libmpcodecs/vf_bmovl.c @@ -469,7 +469,7 @@ vf_open(vf_instance_t* vf, char* args) return TRUE; } -vf_info_t vf_info_bmovl = { +const vf_info_t vf_info_bmovl = { "Read bitmaps from a FIFO and display them in window", "bmovl", "Per Wigren", diff --git a/libmpcodecs/vf_boxblur.c b/libmpcodecs/vf_boxblur.c index c6da40509b..a45e72889d 100644 --- a/libmpcodecs/vf_boxblur.c +++ b/libmpcodecs/vf_boxblur.c @@ -206,7 +206,7 @@ static int open(vf_instance_t *vf, char* args){ return 1; } -vf_info_t vf_info_boxblur = { +const vf_info_t vf_info_boxblur = { "box blur", "boxblur", "Michael Niedermayer", diff --git a/libmpcodecs/vf_crop.c b/libmpcodecs/vf_crop.c index 2bb2ea8bd2..c9bd11c6c7 100644 --- a/libmpcodecs/vf_crop.c +++ b/libmpcodecs/vf_crop.c @@ -13,10 +13,10 @@ #include "m_option.h" #include "m_struct.h" -static struct vf_priv_s { +static const struct vf_priv_s { int crop_w,crop_h; int crop_x,crop_y; -} const vf_priv_dflt = { +} vf_priv_dflt = { -1,-1, -1,-1 }; @@ -166,7 +166,7 @@ static int open(vf_instance_t *vf, char* args){ } #define ST_OFF(f) M_ST_OFF(struct vf_priv_s,f) -static m_option_t vf_opts_fields[] = { +static const m_option_t vf_opts_fields[] = { {"w", ST_OFF(crop_w), CONF_TYPE_INT, M_OPT_MIN,0 ,0, NULL}, {"h", ST_OFF(crop_h), CONF_TYPE_INT, M_OPT_MIN,0 ,0, NULL}, {"x", ST_OFF(crop_x), CONF_TYPE_INT, M_OPT_MIN,-1 ,0, NULL}, @@ -174,14 +174,14 @@ static m_option_t vf_opts_fields[] = { { NULL, NULL, 0, 0, 0, 0, NULL } }; -static m_struct_t vf_opts = { +static const m_struct_t vf_opts = { "crop", sizeof(struct vf_priv_s), &vf_priv_dflt, vf_opts_fields }; -vf_info_t vf_info_crop = { +const vf_info_t vf_info_crop = { "cropping", "crop", "A'rpi", |