Mercurial > mplayer.hg
diff libmpcodecs/vf_ass.c @ 20446:e8adc3778348
Split ass_configure() into several smaller functions.
FontConfig initialization moved from ass_init() to ass_set_fonts().
author | eugeni |
---|---|
date | Thu, 26 Oct 2006 20:08:46 +0000 |
parents | 9a2462925e07 |
children | de4a66d99f41 |
line wrap: on
line diff
--- a/libmpcodecs/vf_ass.c Thu Oct 26 15:27:00 2006 +0000 +++ b/libmpcodecs/vf_ass.c Thu Oct 26 20:08:46 2006 +0000 @@ -77,8 +77,6 @@ int width, int height, int d_width, int d_height, unsigned int flags, unsigned int outfmt) { - ass_settings_t settings; - if (outfmt == IMGFMT_IF09) return 0; vf->priv->outh = height + ass_top_margin + ass_bottom_margin; @@ -94,17 +92,8 @@ vf->priv->dirty_rows = malloc(vf->priv->outh); if (vf->priv->ass_priv) { - memset(&settings, 0, sizeof(ass_settings_t)); - settings.frame_width = vf->priv->outw; - settings.frame_height = vf->priv->outh; - settings.font_size_coeff = ass_font_scale; - settings.line_spacing = ass_line_spacing; - settings.top_margin = ass_top_margin; - settings.bottom_margin = ass_bottom_margin; - settings.use_margins = ass_use_margins; - settings.aspect = ((double)d_width) / d_height; - - ass_configure(vf->priv->ass_priv, &settings); + ass_configure(vf->priv->ass_priv, vf->priv->outw, vf->priv->outh); + ass_set_aspect_ratio(vf->priv->ass_priv, ((double)d_width) / d_height); } return vf_next_config(vf, vf->priv->outw, vf->priv->outh, d_width, d_height, flags, outfmt);