quartztext.c File Reference

Include dependency graph for quartztext.c:


Data Structures

struct  font_stack_t
struct  ft_style_t
struct  offscreen_bitmap_t
struct  filter_sys_t
 filter_sys_t: chroma method descriptor More...

Defines

#define DisposeCMProfileIterateUPP(a)   DisposeCMProfileIterateUPP(CMProfileIterateUPP userUPP __attribute__((unused)))
#define DisposeCMMIterateUPP(a)   DisposeCMMIterateUPP(CMProfileIterateUPP userUPP __attribute__((unused)))
#define __MACHINEEXCEPTIONS__
#define DEFAULT_FONT   "Arial Black"
#define DEFAULT_FONT_COLOR   0xffffff
#define DEFAULT_REL_FONT_SIZE   16
#define VERTICAL_MARGIN   3
#define HORIZONTAL_MARGIN   10
#define FONT_TEXT   N_("Font")
#define FONT_LONGTEXT   N_("Name for the font you want to use")
#define FONTSIZER_TEXT   N_("Relative font size")
#define FONTSIZER_LONGTEXT
#define COLOR_TEXT   N_("Text default color")
#define COLOR_LONGTEXT

Typedefs

typedef struct font_stack_t font_stack_t
typedef struct offscreen_bitmap_t offscreen_bitmap_t

Functions

static int Create (vlc_object_t *)
static void Destroy (vlc_object_t *)
static int LoadFontsFromAttachments (filter_t *p_filter)
static int RenderText (filter_t *, subpicture_region_t *, subpicture_region_t *)
static int RenderHtml (filter_t *, subpicture_region_t *, subpicture_region_t *)
static int GetFontSize (filter_t *p_filter)
static int RenderYUVA (filter_t *p_filter, subpicture_region_t *p_region, CFMutableAttributedStringRef p_attrString)
static void setFontAttibutes (char *psz_fontname, int i_font_size, uint32_t i_font_color, bool b_bold, bool b_italic, bool b_underline, CFRange p_range, CFMutableAttributedStringRef p_attrString)
int vlc_entry__main (module_t *p_module)
const char * vlc_entry_license__main (void)
static char * EliminateCRLF (char *psz_string)
static int PushFont (font_stack_t **p_font, const char *psz_name, int i_size, uint32_t i_color)
static int PopFont (font_stack_t **p_font)
static int PeekFont (font_stack_t **p_font, char **psz_name, int *i_size, uint32_t *i_color)
static int HandleFontAttributes (xml_reader_t *p_xml_reader, font_stack_t **p_fonts, int i_scale)
static void GetAttrStrFromFontStack (font_stack_t **p_fonts, bool b_bold, bool b_italic, bool b_uline, CFRange p_range, CFMutableAttributedStringRef p_attrString)
static int ProcessNodes (filter_t *p_filter, xml_reader_t *p_xml_reader, text_style_t *p_font_style, CFMutableAttributedStringRef p_attrString)
static CGContextRef CreateOffScreenContext (int i_width, int i_height, offscreen_bitmap_t **pp_memory, CGColorSpaceRef *pp_colorSpace)
static offscreen_bitmap_tCompose (int i_text_align, CFMutableAttributedStringRef p_attrString, unsigned i_width, unsigned i_height, unsigned *pi_textblock_height)

Variables

static const int pi_color_values []
static const char *const ppsz_color_descriptions []
static const int pi_sizes [] = { 20, 18, 16, 12, 6 }
static const char *const ppsz_sizes_text []

Define Documentation

#define __MACHINEEXCEPTIONS__

#define COLOR_LONGTEXT

Value:

N_("The color of the text that will be rendered on "\
    "the video. This must be an hexadecimal (like HTML colors). The first two "\
    "chars are for red, then green, then blue. #000000 = black, #FF0000 = red,"\
    " #00FF00 = green, #FFFF00 = yellow (red + green), #FFFFFF = white" )

#define COLOR_TEXT   N_("Text default color")

#define DEFAULT_FONT   "Arial Black"

#define DEFAULT_FONT_COLOR   0xffffff

#define DEFAULT_REL_FONT_SIZE   16

Referenced by GetFontSize().

#define DisposeCMMIterateUPP ( a   )     DisposeCMMIterateUPP(CMProfileIterateUPP userUPP __attribute__((unused)))

#define DisposeCMProfileIterateUPP ( a   )     DisposeCMProfileIterateUPP(CMProfileIterateUPP userUPP __attribute__((unused)))

#define FONT_LONGTEXT   N_("Name for the font you want to use")

#define FONT_TEXT   N_("Font")

#define FONTSIZER_LONGTEXT

Value:

N_("This is the relative default size of the " \
    "fonts that will be rendered on the video. If absolute font size is set, "\
    "relative size will be overriden." )

#define FONTSIZER_TEXT   N_("Relative font size")

#define HORIZONTAL_MARGIN   10

Referenced by Compose().

#define VERTICAL_MARGIN   3

Referenced by Compose(), and RenderYUVA().


Typedef Documentation

typedef struct font_stack_t font_stack_t


Function Documentation

static offscreen_bitmap_t* Compose ( int  i_text_align,
CFMutableAttributedStringRef  p_attrString,
unsigned  i_width,
unsigned  i_height,
unsigned *  pi_textblock_height 
) [static]

static int Create ( vlc_object_t p_this  )  [static]

static CGContextRef CreateOffScreenContext ( int  i_width,
int  i_height,
offscreen_bitmap_t **  pp_memory,
CGColorSpaceRef *  pp_colorSpace 
) [static]

static void Destroy ( vlc_object_t p_this  )  [static]

static char* EliminateCRLF ( char *  psz_string  )  [static]

Referenced by RenderText().

static void GetAttrStrFromFontStack ( font_stack_t **  p_fonts,
bool  b_bold,
bool  b_italic,
bool  b_uline,
CFRange  p_range,
CFMutableAttributedStringRef  p_attrString 
) [static]

References PeekFont(), setFontAttibutes(), and VLC_SUCCESS.

Referenced by ProcessNodes().

static int GetFontSize ( filter_t p_filter  )  [static]

static int HandleFontAttributes ( xml_reader_t p_xml_reader,
font_stack_t **  p_fonts,
int  i_scale 
) [static]

static int LoadFontsFromAttachments ( filter_t p_filter  )  [static]

static int PeekFont ( font_stack_t **  p_font,
char **  psz_name,
int *  i_size,
uint32_t *  i_color 
) [static]

static int PopFont ( font_stack_t **  p_font  )  [static]

static int ProcessNodes ( filter_t p_filter,
xml_reader_t p_xml_reader,
text_style_t p_font_style,
CFMutableAttributedStringRef  p_attrString 
) [static]

static int PushFont ( font_stack_t **  p_font,
const char *  psz_name,
int  i_size,
uint32_t  i_color 
) [static]

static int RenderHtml ( filter_t p_filter,
subpicture_region_t p_region_out,
subpicture_region_t p_region_in 
) [static]

static int RenderText ( filter_t p_filter,
subpicture_region_t p_region_out,
subpicture_region_t p_region_in 
) [static]

static int RenderYUVA ( filter_t p_filter,
subpicture_region_t p_region,
CFMutableAttributedStringRef  p_attrString 
) [static]

static void setFontAttibutes ( char *  psz_fontname,
int  i_font_size,
uint32_t  i_font_color,
bool  b_bold,
bool  b_italic,
bool  b_underline,
CFRange  p_range,
CFMutableAttributedStringRef  p_attrString 
) [static]

int vlc_entry__main ( module_t p_module  ) 

const char* vlc_entry_license__main ( void   ) 


Variable Documentation

const int pi_color_values[] [static]

Initial value:

 {
  0x00000000, 0x00808080, 0x00C0C0C0, 0x00FFFFFF, 0x00800000,
  0x00FF0000, 0x00FF00FF, 0x00FFFF00, 0x00808000, 0x00008000, 0x00008080,
  0x0000FF00, 0x00800080, 0x00000080, 0x000000FF, 0x0000FFFF }

const int pi_sizes[] = { 20, 18, 16, 12, 6 } [static]

const char* const ppsz_color_descriptions[] [static]

Initial value:

 {
  N_("Black"), N_("Gray"), N_("Silver"), N_("White"), N_("Maroon"),
  N_("Red"), N_("Fuchsia"), N_("Yellow"), N_("Olive"), N_("Green"), N_("Teal"),
  N_("Lime"), N_("Purple"), N_("Navy"), N_("Blue"), N_("Aqua") }

const char* const ppsz_sizes_text[] [static]

Initial value:

 {
    N_("Smaller"), N_("Small"), N_("Normal"), N_("Large"), N_("Larger") }


Generated on Tue May 25 08:05:26 2010 for VLC by  doxygen 1.5.6