Browse Source

modules: use actual alignment values in parameter lists

pull/162/head
Steve Lhomme 2 years ago
parent
commit
339b320df0
  1. 12
      modules/codec/dvbsub.c
  2. 2
      modules/codec/subsdec.c
  3. 14
      modules/codec/zvbi.c
  4. 15
      modules/spu/common.h
  5. 1
      modules/spu/logo.c
  6. 12
      modules/spu/mosaic.c

12
modules/codec/dvbsub.c

@ -99,7 +99,17 @@
#define ENC_POSY_TEXT N_("Encoding Y coordinate")
#define ENC_POSY_LONGTEXT N_("Y coordinate of the encoded subtitle" )
static const int pi_pos_values[] = { 0, 1, 2, 4, 8, 5, 6, 9, 10 };
static const int pi_pos_values[] = {
0,
SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_TOP,
SUBPICTURE_ALIGN_BOTTOM,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_RIGHT,
};
static const char *const ppsz_pos_descriptions[] =
{ N_("Center"), N_("Left"), N_("Right"), N_("Top"), N_("Bottom"),
N_("Top-Left"), N_("Top-Right"), N_("Bottom-Left"), N_("Bottom-Right") };

2
modules/codec/subsdec.c

@ -161,7 +161,7 @@ static const char *const ppsz_encoding_names[] = {
N_("Vietnamese (Windows-1258)"),
};
static const int pi_justification[] = { -1, 0, 1, 2 };
static const int pi_justification[] = { -1, 0, SUBPICTURE_ALIGN_LEFT, SUBPICTURE_ALIGN_RIGHT };
static const char *const ppsz_justification_text[] = {
N_("Auto"),N_("Center"),N_("Left"),N_("Right")
};

14
modules/codec/zvbi.c

@ -77,7 +77,17 @@ static void Close( vlc_object_t * );
#define LEVEL_TEXT N_("Presentation Level")
static const int pi_pos_values[] = { 0, 1, 2, 4, 8, 5, 6, 9, 10 };
static const int pi_pos_values[] = {
0,
SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_TOP,
SUBPICTURE_ALIGN_BOTTOM,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_RIGHT,
};
static const char *const ppsz_pos_descriptions[] =
{ N_("Center"), N_("Left"), N_("Right"), N_("Top"), N_("Bottom"),
N_("Top-Left"), N_("Top-Right"), N_("Bottom-Left"), N_("Bottom-Right") };
@ -101,7 +111,7 @@ vlc_module_begin ()
PAGE_TEXT, PAGE_LONGTEXT )
add_bool( "vbi-opaque", true,
OPAQUE_TEXT, OPAQUE_LONGTEXT )
add_integer( "vbi-position", 8, POS_TEXT, POS_LONGTEXT )
add_integer( "vbi-position", SUBPICTURE_ALIGN_BOTTOM, POS_TEXT, POS_LONGTEXT )
change_integer_list( pi_pos_values, ppsz_pos_descriptions )
add_bool( "vbi-text", false,
TELX_TEXT, TELX_LONGTEXT )

15
modules/spu/common.h

@ -18,6 +18,8 @@
* Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
#include <vlc_subpicture.h>
#define OPACITY_TEXT N_("Opacity")
#define OPACITY_LONGTEXT N_("Opacity (inverse of transparency), " \
"from 0 for fully transparent to 255 for fully opaque." )
@ -34,7 +36,18 @@
"also use combinations of these values, e.g. 6 = top-right).")
/* Excluding absolute, these values correspond to SUBPICTURE_ALIGN_* flags */
static const int pi_pos_values[] = { -1, 0, 1, 2, 4, 8, 5, 6, 9, 10 };
static const int pi_pos_values[] = {
-1,
0,
SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_TOP,
SUBPICTURE_ALIGN_BOTTOM,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_RIGHT,
};
static const char *const ppsz_pos_descriptions[] =
{ N_("Absolute"),
N_("Center"), N_("Left"), N_("Right"), N_("Top"), N_("Bottom"),

1
modules/spu/logo.c

@ -703,4 +703,3 @@ static logo_t *LogoListCurrent( logo_list_t *p_list )
{
return &p_list->p_logo[p_list->i_counter];
}

12
modules/spu/mosaic.c

@ -166,7 +166,17 @@ static const int pi_pos_values[] = { 0, 1, 2 };
static const char *const ppsz_pos_descriptions[] =
{ N_("auto"), N_("fixed"), N_("offsets") };
static const int pi_align_values[] = { 0, 1, 2, 4, 8, 5, 6, 9, 10 };
static const int pi_align_values[] = {
0,
SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_TOP,
SUBPICTURE_ALIGN_BOTTOM,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_TOP | SUBPICTURE_ALIGN_RIGHT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_LEFT,
SUBPICTURE_ALIGN_BOTTOM | SUBPICTURE_ALIGN_RIGHT,
};
static const char *const ppsz_align_descriptions[] =
{ N_("Center"), N_("Left"), N_("Right"), N_("Top"), N_("Bottom"),
N_("Top-Left"), N_("Top-Right"), N_("Bottom-Left"), N_("Bottom-Right") };

Loading…
Cancel
Save