AssRender

From Avisynth wiki
(Difference between revisions)
Jump to: navigation, search
 
Line 2: Line 2:
 
{{Filter3
 
{{Filter3
 
|1=pinterf, vadosnaprimer, Blitzker, pingplug, lachs0r, TheFluff
 
|1=pinterf, vadosnaprimer, Blitzker, pingplug, lachs0r, TheFluff
|2=v0.30
+
|2=v0.35
 
|3=[https://github.com/pinterf/assrender/releases/ assrender-0.35.7z]
 
|3=[https://github.com/pinterf/assrender/releases/ assrender-0.35.7z]
 
|4=Subtitling
 
|4=Subtitling
Line 97: Line 97:
 
2021-03-04 - pinterf
 
2021-03-04 - pinterf
 
     * Version 0.35:
 
     * Version 0.35:
         - Windows MSVC: Update to libass v0.15 (git submodule update --init --recursive --remote) For changes since v0.14 see https://github.com/libass/libass/blob/master/Changelog
+
         - Windows MSVC: Update to libass v0.15 (git submodule update --init --recursive --remote)
         - don't guess base on video resolution (realfinder) if .ass file has no Matrix info then it should be treated as it "Rec601" to maintain compatibility
+
          For changes since v0.14 see https://github.com/libass/libass/blob/master/Changelog
 +
         - don't guess base on video resolution (realfinder)
 +
          if .ass file has no Matrix info then it should be treated as it "Rec601" to maintain compatibility
 
         - Parameter 'colorspace' default value is no longer "guess"
 
         - Parameter 'colorspace' default value is no longer "guess"
         - Add more color options: PC.709, PC.601, TV.fcc, PC.fcc, TV.240m, PC.240m, none. "none" and "guess" implies "guess-by-resolution".
+
         - Add more color options: PC.709, PC.601, TV.fcc, PC.fcc, TV.240m, PC.240m, none.
 +
          "none" and "guess" implies "guess-by-resolution".
 
         - Fix: possible crash on initializing phase (buffer overread, linux crashed, Windows was just lucky)
 
         - Fix: possible crash on initializing phase (buffer overread, linux crashed, Windows was just lucky)
  
Line 106: Line 109:
 
     * Version 0.34:
 
     * Version 0.34:
 
         - Fix the fix: revert matrix change made in 0.33
 
         - Fix the fix: revert matrix change made in 0.33
         - Fix: Check matrix from .ASS file "YCbCr Matrix:" section besides "Video Colorspace:" Recognized values are "tv.601" and "tv.709"
+
         - Fix: Check matrix from .ASS file "YCbCr Matrix:" section besides "Video Colorspace:"
 +
          Recognized values are "tv.601" and "tv.709"
  
 
2021-02-28 - pinterf
 
2021-02-28 - pinterf

Latest revision as of 15:21, 4 March 2021

Abstract
Author pinterf, vadosnaprimer, Blitzker, pingplug, lachs0r, TheFluff
Version v0.35
Download assrender-0.35.7z
Category Subtitling
License Source code is MIT license, binaries are GPL
Discussion Doom9 Thread


Contents

[edit] Description

AssRender is an AviSynth plugin that renders ASS/SSA and SRT (without the HTML-like markup) subtitles. It uses libass to render the subtitles.

This also means that it is much more picky about script syntax than VSFilter and friends, so keep that in mind before blaming the filter. Yes, people have reported a lot of errors that were actually the script author’s fault and libass vs VSFilter compatibility.

Note: AssRender is a C-plugin so it must be loaded using LoadCPlugin, except if you're using AviSynth+, it allows autoloading of C-plugins.

[edit] Requirements


[edit] Syntax and Parameters

assrender (clip, string file, string "vfr", int "hinting", float "scale", float "line_spacing", float "dar", float "sar", int "top", int "bottom", int "left", int "right", string "charset", int "debuglevel", string "fontdir", string "srt_font", string "colorspace")


clip   =
Input clip.


string   =
Your subtitle file. May be ASS, SSA or SRT.


string  vfr =
Specify timecodes v1 or v2 file when working with VFRaC.


int  hinting = 0
Font hinting mode. Choose between:
  • none (0, default), light (1), normal (2) and Freetype native (3) autohinting.


float  scale = 1.0
Font scale. Defaults to 1.0.


float  line_spacing = 1.0
Line spacing in pixels. Defaults to 1.0 and won’t be scaled with frame size.


float  dar =
float  sar =
Aspect ratio. Of course you need to set both parameters.


int  top = 0
int  bottom = 0
int  left = 0
int  right = 0
Margins. They will be added to the frame size and may be negative.


string  charset = "UTF-8"
Character set to use, in GNU iconv or enca format. Defaults to UTF-8.
Example enca format: enca:pl:cp1250 (guess the encoding for Polish, fall back on cp1250)


int  debuglevel = 0
How much crap assrender is supposed to spam to stderr.


string  fontdir = ""
Additional font directory.
Useful if you are lazy but want to keep your system fonts clean.


string  srt_font = "Sans"
Font to use for SRT subtitles. Defaults to whatever Fontconfig chooses for “Sans”.


string  colorspace = ""
The color space of your (YUV) video. Possible values:
  • "Rec2020", "BT.2020"
  • "Rec709", "BT.709"
  • "Rec601", "BT.601"
  • "PC.709"
  • "PC.601"
  • "TV.fcc", "PC.fcc"
  • "TV.240m", "PC.240m"
  • "none", "guess"
Default is to use the ASS script's "YCbCr Matrix" or "Video Colorspace" property.
Recognized .ASS properties: "TV.601" "TV.709", "PC.601" "PC.709" "TV.240m" "PC.240m" "TV.fcc" "PC.fcc" and "none".
"none" and "guess" decides upon on video resolution: width > 1280 or height > 576 → BT.709, else → BT.601. When no hint found in ASS script and 'colorspace' parameter is empty then the default is BT.601.


[edit] Examples

AviSource("Blah.avi")
AssRender("subtitles.ass")


[edit] Changelog

2021-03-04 - pinterf
     * Version 0.35:
        - Windows MSVC: Update to libass v0.15 (git submodule update --init --recursive --remote)
          For changes since v0.14 see https://github.com/libass/libass/blob/master/Changelog
        - don't guess base on video resolution (realfinder)
          if .ass file has no Matrix info then it should be treated as it "Rec601" to maintain compatibility
        - Parameter 'colorspace' default value is no longer "guess"
        - Add more color options: PC.709, PC.601, TV.fcc, PC.fcc, TV.240m, PC.240m, none.
          "none" and "guess" implies "guess-by-resolution".
        - Fix: possible crash on initializing phase (buffer overread, linux crashed, Windows was just lucky)

2021-03-01 - pinterf
     * Version 0.34:
        - Fix the fix: revert matrix change made in 0.33
        - Fix: Check matrix from .ASS file "YCbCr Matrix:" section besides "Video Colorspace:"
          Recognized values are "tv.601" and "tv.709"

2021-02-28 - pinterf
     * Version 0.33:
        - Fix: wrong Bt.709 matrix (it wasn't :) )

2021-02-27 - pinterf
     * Version 0.32:
        - Fix: treat I420 variant as YV12 instead of unsupported color space

2021-02-18 - pinterf
     * Version 0.31:
        - Fix colors for planar RGB
        - code: hidden ifdef FOR_AVISYNTH_26_ONLY for Avisynth 2.6-only build

2021-02-17 - pinterf
     * Version 0.30:
        - 10-16 bit support (including RGB48 and RGB64)
        - YV411, Planar RGB support

2021-02-16 - pinterf
     * Version 0.29:
        - project moved to https://github.com/pinterf/assrender from https://github.com/vadosnaprimer/assrender
        - Move to Visual Studio 2019 - v142 platform toolset
        - Add .def module definition file for Avisynth 2.6 std compatibility (function name mangling)
        - Update Avisynth C headers
        - Check Linux and gcc-MinGW CMake build
        - Add build instructions and change log to README

2019-01-14 - vadosnaprimer
        - https://github.com/vadosnaprimer/assrender/
        - add batch that lets not to change deps sdk and vs version copied from SMP libass
        - update SMP submodules

2016-10-18 - Blitzker
        - https://github.com/Blitzker/assrender
        - Visual Studio 2015 support

2012-04-20 - lachs0r 
    * Version 0.25:
        - code restructured
        - added support for the BT.709 color space and the “Video Colorspace”
          property that has been introduced with recent versions of Aegisub.
        binary:
            - updated everything, switched to MinGW-w64
              (same toolchain as mplayer2 now)

2011-09-22 - lachs0r 
    * Version 0.24.1:
        binary:
            - updated libass to current git HEAD
            - switched Harfbuzz to libass’ compatibility branch
            - compiled Harfbuzz without Uniscribe backend
              fixes lots of crashes and misbehavior

2011-07-29 - lachs0r
    * Version 0.24:
        binary:
            - updated libass to current git HEAD:
                - fixed performance regression

2011-07-29 - lachs0r
    * Version 0.23:
        - disabled font hinting by default
        binary:
            - updated libass to current git HEAD and included Harfbuzz:
                - added support for bidirectional text, Arabic shaping etc.
                - added proper support for @fonts (vertical writing)
                - slight performance regression
                  (glyph cache not hooked up with Harfbuzz yet)
            - updated FreeType to current git HEAD:
                - fixed outline stroker for some broken fonts

2011-06-16 - lachs0r
    * Version 0.22:
        - fixed hang when a glyph with zero dimensions was encountered
          (mostly vector clips)

2011-06-08 - lachs0r <lachs0r@srsfckn.biz>
    * Version 0.21:
        - finally implemented proper subsampling for YV12
        - temporarily removed YV16 support
        - renamed parameter verbosity → debuglevel
        - code cleanups
        binary:
            - reverted to GCC 4.5.2 (4.6 miscompiles MinGW)

2011-06-01 - lachs0r
    * Version 0.20:
        - fixed the masksub stuff
        - properly output debug messages to stderr instead of stdout
        - reformatted source and corrected/removed some comments
        - modified CMakeLists.txt to strip the binary by default
        binary:
            - now built with GCC 4.6 instead of 4.5.2
            - included enca again
            - patched fontconfig:
                - prettier debug output
                - use the correct location for its cache

2011-02-01 - lachs0r
    * Version 0.19:
        This is a bugfix/cleanup release.
        - fixed possible buffer overflows in timecodesv1 and SRT parsing
        - fixed random crashes on unloading
        - probably fixed compilation with MSVC (patch by TheFluff)
        - very slightly improved performance with GCC
        - various code cleanups

2011-01-25 - lachs0r
    * Version 0.18:
        - improved YV12 support (should be somewhat usable now)
        - added support for RGB24, YV24, YV16 and Y8 (YUY2 coming soon)
        - added SRT subtitle format support
            additional parameter: srt_font (font to use for srt subs)
        - exposed some libass parameters:
            line_spacing (line spacing)
            dar, sar (aspect ratio)
            top, bottom, left, right (margins)
            fontdir (additional font directory)
        - masksub equivalent if used on a blankclip
            (still buggy - read source for details)
        - no more global variables

2011-01-17 - lachs0r 
    * Version 0.17:
        - added rudimentary YV12 support (chroma subsampling still needs work)
        - binary: Previously, I linked against a very old avisynth_c.lib - now
                  you shouldn’t get any error messages about “avisynth_c.dll”
        - tidied up the RGB32 blitter a bit

2011-01-16 - lachs0r
    * Version 0.15:
        - reimplemented as AviSynth C plugin - this fixed several crashes and
          got rid of the major pain in the ass that is MSVC
        - binary: built with patched Fontconfig (no longer needs fonts.conf)
    * Version 0.16:
        - implemented VFRaC support via timecodes files (v1 and v2 supported)


[edit] Archived Downloads

Version Download Mirror
v0.25 assrender-0.25.7z assrender-0.25.7z


[edit] External Links

  • GitHub - Updated version (v0.30+)
  • GitHub - Updated version (v0.28), only source code available.




Back to External Filters

Personal tools