Replies: 1 comment 2 replies
-
First of all: Thanks for the new release! While manually updating Is the old version distributed on purpose? Am I missing something or can I use the official |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Add "bold"=true (linux/NO_WIN_GDI: false), "italic"=false, "noaa"=false parameters to
"ShowFrameNumber", "ShowCRC32", "ShowSMPTE", "ShowTime" filters.
As noted below, "italic" and "noaa" parameters are ineffective in NO_WIN_GDI builds (e.g. Linux)
Add "noaa" parameter to SubTitle and Info. Setting it true will disable antialiasing.
Useful when someone would use "VCR OSD Mono" as-is, without beautifying the outlines,
as it as mentioned in https://forum.doom9.org/showthread.php?t=184627
Address Subtitle font="Arial Regular" function loading incorrect font #358, plus "noaa"
"italic" and "noaa" is provided only to match the parameter list with SubTitle.
SubTitle: to mimic former working method, defaults are "bold"=true, "italic"=false, "noaa"=false
Text: "bold"=false (as before); "italic" is not handled at all, either true or false, it does not affect output.
"italic" and "noaa" parameters exist only because on non-Windows systems "Subtitle" is aliased to "Text"
(Each Subtitle parameter must exist in "Text" as well)
Fix HistogramRGBParade script crash #360: plane fill wrongly assumed that pitch is rowsize, which is not the case after a Crop
It would result in crash e.g. in HistogramRGBParade
Enhancement: much quicker YV24 to RGB32/RGB24 conversion when AVX2 instruction set is supported. (+50% fps at i7-11700)
UserDefined2Resize got an 's' parameter (to the existing b and c): support, default value = 2.3
(following DTL2020's addition in jpsdr's MT resizer repo, UserDefined2ResizeMT filter)
Now, as we have already three variable parameters to the optional chroma resamplers in ConvertToXX
converters, ConvertToXX family got a new float 'param3' parameter which is passed to UV resizer as
's', if "userdefined2" is specified as chroma resampler.
If param3 is not used in a resizer but is defined, then it is simply ignored.
Such as "ConvertToYV24" parameter signature: c[interlaced]b[matrix]s[ChromaInPlacement]s[chromaresample]s[param1]f[param2]f[param3]f
e.g.: ConvertToYV24(chromaresample="userdefined2", param1=126, param2=22, param3=2.25)
see also description at test6, which was updated with this parameter as well.
s (support) param - controls the 'support' of filter to use by resampler engine. Float value in valid range from
1.5 to 15. Default 2.3. It allows to fine tune resampling result between partially non-linear but more sharper and less
residual ringing (at low b and c values) and more linear processing with wider 'peaking' used. Setting too high
in common use cases (about > 5) may visibly degrade resampler performance (fps) without any visible output changes.
Recommended adjustment range - between 2 and 3.
Examples:
b=126 c=22 - medium soft, almost no ringing.
b=102 c=2 - sharper, small local peaking.
b=70 c=-30 s=2 - sharper, thinner 'peaking'.
b=70 c=-30 s=2.5 - a bit softer, more thick 'peaking'.
b=82 c=20 - sharp but lots of far ringing. Not for using.
Fix ConvertToXX to accept specific _ChromaLocation values for 4:1:1 sources #350 ConvertXXX to accept YV411 clip's frame property _ChromaLocation set to 'left'
(and 'topleft' and 'bottomleft' which give the same result) instead of giving an error message.
Fix Internal
BitRotateL/R
functions (and their aliases) return incorrect results when first argument is negative. #348 bitrol/bitror functions return incorrect results when first argument is negative.Regression since the asm code of Avisynth 2.6 classic was ported to C in Avisynth+ project.
"Info": if channel mask exists, then
is displayed under "AudioLength: x".
e.g.
SetChannelMask("stereo") --> "Channel mask: stereo"
SetChannelMask("stereo+LFE") --> "Channel mask: 2.1" because the combination resulted in another known channel combo name
SetChannelMask("mono+LFE") --> "Channel mask: 2 channels (FC+LFE)" because the combination is unknown
Add SetChannel parameter: channel string syntax: (similar to ffmpeg)
a channel number followed by "c" for getting the default layout for a given number of channels.
E.g. SetChannelMask("3c") will set "2.1" because this is the default choice for 3 channels
Add SetChannel parameter: channel string syntax:
a simple number is treated as the actual numeric mask.
E.g. SetChannelMask("3") will set "stereo" because 3=1+2 that is "FL+FR" that is "stereo"
SetChannelMask string version: If string is other than "" then its set to known. It has a single string parameter.
SetChannelMask("mono") -> mask is known: "mono"
SetChannelMask("") -> mask is unknown
Add "speaker_all" to accepted layout mask strings
Fix possible crash of LLVM builds (clang-cl, Intel nextgen) on pre-AVX (SSE4-only) CPUs.
(Prevent static initialization from avx2 source modules, which cause running AVX instructions on DLL load)
ConvertToMono, GetLeftChannel, GetRightChannel: sets channel layout AVS_SPEAKER_FRONT_CENTER (mono)
GetChannel, GetChannels, MergeChannels will set default channel layout if channel count is 1 to 8
For defaults see VfW section below
New Script function: SetChannelMask: string version.
SetChannelMask(clip, string ChannelDescriptor) (parameters compulsory, no names must be set) (test10)
Accepts predefined channel string or channel layout names or their combination, in ffmpeg style.
Numerical indexes or channel counts are not allowed.
String is case sensitive!
E.g. "stereo+LFE+TC" or "FL+LR" or "5.1(side)"
"mono",
"stereo",
"2.1",
"3.0",
"3.0(back)",
"4.0",
"quad",
"quad(side)",
"3.1",
"5.0",
"5.0(side)",
"4.1",
"5.1",
"5.1(side)",
"6.0",
"6.0(front)",
"hexagonal",
"6.1",
"6.1(back)",
"6.1(front)",
"7.0",
"7.0(front)",
"7.1",
"7.1(wide)",
"7.1(wide-side)",
"7.1(top)",
"octagonal",
"cube"
"speaker_all"
Individual Speaker Channels:
"FL", front left
"FR", front right
"FC", front center
"LFE", low frequency
"BL", back left
"BR", back right
"FLC", front left-of-center
"FRC", front right-of-center
"BC", back center
"SL", side left
"SR", side right
"TC", top center
"TFL", top front left
"TFC", top front center
"TFR", top front right
"TBL", top back left
"TBC", top back center
"TBR", top back right
AudioDub will inherit channel layout setting from the audio clip.
VfW output channel guess (when ChannelMask is not specified) changed at some points.
Default number of channels to channel layout guess was modified to match of ffmpeg
3 channels: Surround to 2.1
4 channels: Quad to 4.0
6 channels: 6.1(back) to 6.1
This follows ffmpeg defaults
Present rules:
const chnls name layout
0x00004 1 mono -- -- FC
0x00003 2 stereo FL FR
0x0000B 3 2.1 FL FR LFE
0x00107 4 4.0 FL FR FC -- -- -- -- -- BC
0x00037 5 5.0 FL FR FC -- BL BR
0x0003F 6 5.1 FL FR FC LFE BL BR
0x0070F 7 6.1 FL FR FC LFE -- -- -- -- BC SL SR
0x0063F 8 7.1 FL FR FC LFE BL BR -- -- -- SL SR
Add initial audio channel mask (channel layout) support (CPP and C interface, script function)
It still belongs to V10 changes (there were only tests since then), but it can be discussed if not.
Technically it is done by using another 18+2 bits in the Clip's VideoInfo.image_type field.
Due to lack of enough bits in this VideoInfo field, the mapping between the original dwChannelMask
and Avisynth's internal values are not 1:1, but all information is kept however.
This is because not 32 but only 18 (strictly: 18+1) bits are defining speaker locations, so
the remaining bits of our existing 'image_type' field can be used for this purpose.
Thus 20 new bits are occupied.
(https://learn.microsoft.com/en-us/windows/win32/api/mmreg/ns-mmreg-waveformatextensible)
Programmers can check AvsChannelMask and AvsImageTypeFlags in avisynth.h and avisynth_c.h
new C++ interface functions
bool VideoInfo::IsChannelMaskKnown()
void VideoInfo::SetChannelMask(bool isChannelMaskKnown, unsigned int dwChannelMask)
Re-maps and stores channel mask into image_type, sets the 'has channel mask' flag as well
Note: this data can be set independently from the actual NumChannels number!
unsigned int VideoInfo::GetChannelMask()
new C interface functions
bool avs_is_channel_mask_known(const AVS_VideoInfo * p);
void avs_set_channel_mask(const AVS_VideoInfo * p, bool isChannelMaskKnown, unsigned int dwChannelMask);
unsigned int avs_get_channel_mask(const AVS_VideoInfo * p);
Like when establishing BFF, TFF and fieldbased flags from 'image_type', technically 'image_type' can
be manipulated directly. See SetChannelMask and GetChannelMask in Avisynth source for
image_type <-> dwChannelMask conversion.
I guess once ffmpeg will support it, it will read (or not read) channel masks such a way.
new Script functions
bool IsChannelMaskKnown(clip)
int GetChannelMask(clip)
SetChannelMask(clip, bool known, int dwChannelMask) (parameters compulsory, no names must be set)
SetChannelMask(clip, string ChannelDescriptor) (parameters compulsory, no names must be set) (test10)
dwChannelMask must contain the combination of up to 18 positions or 0x80000000 for SPEAKER_ALL.
VfW export rules (included the existing sequence)
1.) OPT_UseWaveExtensible global variable must be 'true'
or
newnewnew
if VideoInfo::IsChannelMaskKnown is true, then fill WAVEFORMATEXTENSIBLE struct
2.) newnewnew
Is channel mask defined in Avisynth's VideoInfo? (VideoInfo::IsChannelMaskKnown() is true)
Yes -> return VideoInfo::GetChannelMask()
3.) No-> (Channel mask not defined in VideoInfo, guess it or set from variable)
3.1)Guess channel layout:
For 0 to 8 channels there is a predefined 'guess map':
#of channels dwChannelMask
0 0,
1 0x00004, // 1 -- -- Cf
2 0x00003, // 2 Lf Rf
3 0x00007, // 3 Lf Rf Cf
4 0x00033, // 4 Lf Rf -- -- Lr Rr
5 0x00037, // 5 Lf Rf Cf -- Lr Rr
6 0x0003F, // 5.1 Lf Rf Cf Sw Lr Rr
7 0x0013F, // 6.1 Lf Rf Cf Sw Lr Rr -- -- Cr
8 0x0063F, // 7.1 Lf Rf Cf Sw Lr Rr -- -- -- Ls Rs
KillAudio will call SetChannelMask(false, 0), nevertheless.
Set automatic MT mode MT_SERIALIZED to
ConvertToMono, EnsureVBRMP3Sync, MergeChannels, GetChannel, Normalize, MixAudio, ResampleAudio
Add back audio cache from classic Avisynth 2.6.
Believe it or not, audio cache was never ported to Avisynth+
Filters are queryed about their desired audio cache mode through their SetCacheHints (similarly to CACHE_GET_MTMODE).
CACHE_AUDIO: Explicitly cache audio, X byte cache.
CACHE_AUDIO_NOTHING: Explicitly do not cache audio.
CACHE_AUDIO_AUTO_START_OFF: Audio cache off (auto mode), X byte initial cache.
CACHE_AUDIO_AUTO_START_ON: Audio cache on (auto mode), X byte initial cache.
Default cache size is 256kB.
How it works:
The decision whether the stream benefits caching or not - and how big the cache
size should be - is made upon continously gathering some statistics on the audio
stream requests (an internal score is maintained).
mode would finally changed to CACHE_AUDIO_AUTO_START_OFF.
go with CACHE_AUDIO_AUTO_START_OFF as well.
if audio cache was swithed off Avisynth would turn it into active caching by changing
the working mode to CACHE_AUDIO_AUTO_START_ON.
Fix Clang build AviSource crash on yuv422p10le UTVideo at specific widths (SSE2 or SSE4.1)
Memory leak with ScriptClip? #340: stop memory leak on propSet / MakePropertyWritable;
A bit less memory/processing overhead in internal FrameRegistry as a side effect.
ConvertToRGB bug #282: make 32-bit MSVC build to generate both decorated and undecorated export function names for C plugins
C plugins built with mingw possibly expect decorated names.
Expr: Add remaining stack element count to "Unbalanced stack..." error message.
Alpha preservation when converting RGB32->YUV #306: Add ConvertToYUVA420, ConvertToYUVA422 and ConvertToYUVA444.
Resulting clip is always YUVA:
Alpha plane is kept if exists (even from packed RGB formats like RGB32/64),
otherwise filled with maximum transparency mask value.
Parameters are the same like in ConvertToYUVYUVxxx versions.
Update build documentation with 2023 Intel C++ tools. See Compiling Avisynth+
https://avisynthplus.readthedocs.io/en/latest/avisynthdoc/contributing/compiling_avsplus.html
CMakeLists.txt: add support for Intel C++ Compiler 2023.
Enhanced performance in ConvertBits Floyd dither (dither=1) for 10->8, 16->8 and 16->10 bit cases
by providing special function templates to allow compilers to optimize them much better.
(Both Microsoft and Intel Classic 19.2 benefits, LLVM based clangCL and IntelLLVM compilers not)
Fix crash when outputting VfW (e.g. VirtualDub) for YUV422P16, or P10 in Intel SSE2 optimization
due to aligned SIMD write to an unaligned pointer - did not affect Microsoft builds.
As seen in https://forum.doom9.org/showthread.php?p=1983343#post1983343
(Adding resamplers kernels and named resizers and kernel control to Convert() #337) Add more resizers types by jpsdr's and DTL's idea: backport from https://github.com/jpsdr/ResampleMT
SinPowerResize "cii[src_left]f[src_top]f[src_width]f[src_height]f[p]f"
parameters like GaussResize: optional "p"
Default: p=2.5
SincLin2Resize "cii[src_left]f[src_top]f[src_width]f[src_height]f[taps]i"
parameters like SincFilter or LanczosFilter: optional "taps"
Default taps=15
UserDefined2Resize "cii[b]f[c]f[s]f[src_left]f[src_top]f[src_width]f[src_height]f"
parameters like BicubicResize, plus an 's' - support: Optional "b", "c" and "s"
Default b=121.0, c=19.0, s=2.3
("s" parameter is available from 3.7.3 test10)
and their equivalent for the ConvertToXXXX family:
"sinpow", "sinclin2" and "userdefined2"
Now it is possible to use chromaresample with nondefault settings.
param1 will set 'taps', 'b', or 'p', while param2 sets 'c' parameter for resizers where applicable.
param3 (since test10) sets 's' parameter for userdefined2 (UserDefined2Resize)
b,c: bicubic (1/3.0, 1/3.0)
b,c,s: userdefined2 (121.0, 19.0, 2.3)
taps: lanczos (3), blackman (4), sinc (4), sinclin2 (15)
p: gauss (30.0), sinpow (2.5)
'param1', 'param2' and "param3" are always float. For 'taps' 'param1' is truncated to integer internally.
When a resizer does not use one or more parameters they are simply ignored.
Add avs_video_frame_get_pixel_type and avs_video_frame_amend_pixel_type to C interface as well
Fix (Histogram("color2") shift in markers with parameter bits > 8. #327) Histogram "color2" markers. Fix right shifted 15 degree dots, fix square for bits>8
Feature (
VideoFrame
should provide its color format #317): (V10 interface) The color format of a VideoFrame can now be retrieved with its GetPixelType()function. Before, there was no reliable way of knowing it on a frame from propGetFrame().
The internally stored pixel_type in VideoFrame is properly converted upon a Subframe (Y8-32), SubframePlanar (strip alpha).
Feature (
VideoFrame
should provide its color format #317): (V10 interface) addedVideoFrame::AmendPixelType
andavs_video_frame_amend_pixel_type
.Introduced in order to keep VideoInfo and VideoFrame pixel_type synchronized for special cases:
when filter constructor would just change
VideoInfo::pixel_type
, but the frame would be passed w/o any change, like inConvertFromDoubleWidth
orCombinePlanes
.Feature (A couple of little requests for new Rust crate that's a basis for plugins #314): Added AVSValue::GetType()
Returns an AvsValueType enum directly, one can use it instead of calling all IsXXX functions to establish the type. (Rust use case)
Enhancement (A couple of little requests for new Rust crate that's a basis for plugins #314): (avisynth.h) Gave all enums of public C++ API a name, and added DEFAULT_PLANE to AvsPlane (also in C API).
Fix (A couple of little requests for new Rust crate that's a basis for plugins #314): (avisynth.h) Changed NewVideoFrameP() property source argument to const in accordance with copyFrameProps(), since it's not meant to be written
Fixed in C interface as well: avs_new_video_frame_p and avs_new_video_frame_p_a: prop_src argument now const (no change in use)
Enhancement (A couple of little requests for new Rust crate that's a basis for plugins #314): Made VideoFrameBuffer destructor public like in other classes of the public API to prevent compiler errors downstream when calling non-const member functions
"Text" new parameter: "placement" for chroma location hint
ChromaOutPlacement in the Convert functions.
If "center" is given directly or read from frame property, it will be used.
Otherwise "Text" renders chroma as "left" (mpeg2)
"Text": Almost fully rewritten.
(Text: support font widths >16 #310) Support any width of bdf fonts (but still of fixed width)
Render in YUY2 is as nice as in YV16
Halo is not limited to original character matrix boundaries
Halo is not character based, but rendered on the displayed string as a whole.
Some speed enhancements, mainly for subsampled formats and outlined (with halo) styles
Enhancement (Exceptions from
AvisynthPluginInit3()
not displayed! #315): Show exception message as well if a v2.6-style plugin throws AvisynthError in itsAvisynthPluginInit3() instead of only "'xy.dll' cannot be used as a plugin for AviSynth."
"Text": draw rightmost on-screen character even if only partially visible (was: not drawn at all)
"Text": support more from the BDF standard (issue Text: support font widths >16 #310): per-character boundary boxes and shifts
"Text" (Text: support font widths >16 #310): support 17-32 pixel wide external BDF fonts (issue Text: support font widths >16 #310)
Fix: "Text" rounding negative x or y coordinates (e.g. x=-1 resulted in 0 instead of -1)
Fix: "Text" would omit last character when x<0
Fix: "Text" halo_color needs only MSB=$FF and not the exact $FF000000 constant for fade
"Text"
halo_color
allows to have both halo and shaded background when halo_color MSB=$FE"Text" much nicer rendering of subsampled formats (Text color bug on subsampled formats #308)
CMakeLists.txt: add support for Intel C++ Compiler 2022
Address Issue Add support for non-decorated export names in C-plugins #305: Support for non-decorated avisynth_c_plugin_init in 32 bit C-plugins
Huge documentation update by Reel-Deal
Fix (Bug: ColorYUV(analyze=true) and YUY2 #304): ColorYUV analyze=true was displaying wrong min-max values for YUY2
Fix: C API undefined behavior when upstream throw runtime error
(released in test2, fixed in test6 - ffdshow crash)
Mute compilation warnings in avisynth.h
CMakeLists.txt: fix clang-cl/intel with ninja generator
Fix (Animate bug. Zero crossing. #293): "Text" to throw proper error message if the specified font name (e.g. Arial) is not found among internal bitmap fonts.
Fix (Animate bug. Zero crossing. #293): "Subtitle" and "Text" filter to respect the explicitely given coorditanes for y=-1 or x=-1,
instead of applying vertical/horizontal center alignment.
Fix: C interface crash when using avs_new_video_frame_p(_a)
Fix (Threshold not working for stats runtime filters #283): broken runtime functions min/max/minmaxdifference when threshold is not 0 (returned -1). Regression in 3.7.2
New: add a sixth array element to PlaneMinMaxStats: average. Defines variable "PlaneStats_average" as well if setting variables is required.
Fix (ConvertToRGB bug #282): ConvertToRGB
Legend:
_vcredist
= Includes the MSVC 2019 Redistributable_xp
= Can be used on Windows XP-filesonly
= Only the library and plugins themselves, no installer..pkg
= Installer for macOSIf you're unsure of which to download, pick AviSynthPlus_3.7.3_20230715_vcredist.exe
This discussion was created from the release AviSynth+ 3.7.3.
Beta Was this translation helpful? Give feedback.
All reactions