Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
28th October 2013, 22:17 | #21 | Link | |
Avisynth Developer
Join Date: Jan 2003
Location: Melbourne, Australia
Posts: 3,167
|
@Ultim,
Spoke to Avery :- Quote:
@TurboPascal7, Thanks for the 2 bug reports. |
|
30th October 2013, 10:36 | #23 | Link |
Guest
Posts: n/a
|
I can't find a generic thread for requests for updates to Avisynth, so I'll post this here if I may. Avisynth crossfades are simple linear dissolves. Is it possible to change this so that more complicated crossfades, such as those found in NLEs, are possible? I have a thread here that goes into more detail.
I note that there have been recent, audio-related changes to the Trim() function, so I hope that the developers will consider implementing other audio-related changes, such as a non-linear crossfade. Thanks. |
7th November 2013, 06:29 | #24 | Link |
...?
Join Date: Nov 2005
Location: Florida
Posts: 1,420
|
A couple of related requests:
First, Can avisynth_c.h be synchronized with the semi-updated version that x264 ships with in extras/? The modifications were authored by kemuri-_9 but the colorspace-specific ones haven't been integrated with the rest of the updates to avisynth_c.h mentioned in the Changelog. For convenience, I converted the changes into a patch: Code:
diff --git a/src/core/avisynth_c.h b/src/core/avisynth_c.h index e419d03..9b6325b 100644 --- a/src/core/avisynth_c.h +++ b/src/core/avisynth_c.h @@ -75,7 +75,7 @@ typedef __int64 INT64; // #ifndef __AVISYNTH_H__ -enum { AVISYNTH_INTERFACE_VERSION = 3 }; +enum { AVISYNTH_INTERFACE_VERSION = 5 }; #endif enum {AVS_SAMPLE_INT8 = 1<<0, @@ -90,13 +90,46 @@ enum {AVS_PLANAR_Y=1<<0, AVS_PLANAR_ALIGNED=1<<3, AVS_PLANAR_Y_ALIGNED=AVS_PLANAR_Y|AVS_PLANAR_ALIGNED, AVS_PLANAR_U_ALIGNED=AVS_PLANAR_U|AVS_PLANAR_ALIGNED, - AVS_PLANAR_V_ALIGNED=AVS_PLANAR_V|AVS_PLANAR_ALIGNED}; + AVS_PLANAR_V_ALIGNED=AVS_PLANAR_V|AVS_PLANAR_ALIGNED, + AVS_PLANAR_A=1<<4, + AVS_PLANAR_R=1<<5, + AVS_PLANAR_G=1<<6, + AVS_PLANAR_B=1<<7, + AVS_PLANAR_A_ALIGNED=AVS_PLANAR_A|AVS_PLANAR_ALIGNED, + AVS_PLANAR_R_ALIGNED=AVS_PLANAR_R|AVS_PLANAR_ALIGNED, + AVS_PLANAR_G_ALIGNED=AVS_PLANAR_G|AVS_PLANAR_ALIGNED, + AVS_PLANAR_B_ALIGNED=AVS_PLANAR_B|AVS_PLANAR_ALIGNED}; // Colorspace properties. -enum {AVS_CS_BGR = 1<<28, +enum {AVS_CS_BGR = 1<<28, AVS_CS_YUV = 1<<29, AVS_CS_INTERLEAVED = 1<<30, - AVS_CS_PLANAR = 1<<31}; + AVS_CS_PLANAR = 1<<31, + + AVS_CS_SHIFT_SUB_WIDTH = 0, + AVS_CS_SHIFT_SUB_HEIGHT = 1 << 3, + AVS_CS_SHIFT_SAMPLE_BITS = 1 << 4, + + AVS_CS_SUB_WIDTH_MASK = 7 << AVS_CS_SHIFT_SUB_WIDTH, + AVS_CS_SUB_WIDTH_1 = 3 << AVS_CS_SHIFT_SUB_WIDTH, // YV24 + AVS_CS_SUB_WIDTH_2 = 0 << AVS_CS_SHIFT_SUB_WIDTH, // YV12, I420, YV16 + AVS_CS_SUB_WIDTH_4 = 1 << AVS_CS_SHIFT_SUB_WIDTH, // YUV9, YV411 + + AVS_CS_VPLANEFIRST = 1 << 3, // YV12, YV16, YV24, YV411, YUV9 + AVS_CS_UPLANEFIRST = 1 << 4, // I420 + + AVS_CS_SUB_HEIGHT_MASK = 7 << AVS_CS_SHIFT_SUB_HEIGHT, + AVS_CS_SUB_HEIGHT_1 = 3 << AVS_CS_SHIFT_SUB_HEIGHT, // YV16, YV24, YV411 + AVS_CS_SUB_HEIGHT_2 = 0 << AVS_CS_SHIFT_SUB_HEIGHT, // YV12, I420 + AVS_CS_SUB_HEIGHT_4 = 1 << AVS_CS_SHIFT_SUB_HEIGHT, // YUV9 + + AVS_CS_SAMPLE_BITS_MASK = 7 << AVS_CS_SHIFT_SAMPLE_BITS, + AVS_CS_SAMPLE_BITS_8 = 0 << AVS_CS_SHIFT_SAMPLE_BITS, + AVS_CS_SAMPLE_BITS_16 = 1 << AVS_CS_SHIFT_SAMPLE_BITS, + AVS_CS_SAMPLE_BITS_32 = 2 << AVS_CS_SHIFT_SAMPLE_BITS, + + AVS_CS_PLANAR_MASK = AVS_CS_PLANAR | AVS_CS_INTERLEAVED | AVS_CS_YUV | AVS_CS_BGR | AVS_CS_SAMPLE_BITS_MASK | AVS_CS_SUB_HEIGHT_MASK | AVS_CS_SUB_WIDTH_MASK, + AVS_CS_PLANAR_FILTER = ~( AVS_CS_VPLANEFIRST | AVS_CS_UPLANEFIRST )}; // Specific colorformats enum { @@ -104,9 +137,18 @@ enum { AVS_CS_BGR24 = 1<<0 | AVS_CS_BGR | AVS_CS_INTERLEAVED, AVS_CS_BGR32 = 1<<1 | AVS_CS_BGR | AVS_CS_INTERLEAVED, AVS_CS_YUY2 = 1<<2 | AVS_CS_YUV | AVS_CS_INTERLEAVED, - AVS_CS_YV12 = 1<<3 | AVS_CS_YUV | AVS_CS_PLANAR, // y-v-u, planar - AVS_CS_I420 = 1<<4 | AVS_CS_YUV | AVS_CS_PLANAR, // y-u-v, planar - AVS_CS_IYUV = 1<<4 | AVS_CS_YUV | AVS_CS_PLANAR // same as above + // AVS_CS_YV12 = 1<<3 Reserved + // AVS_CS_I420 = 1<<4 Reserved + AVS_CS_RAW32 = 1<<5 | AVS_CS_INTERLEAVED, + + AVS_CS_YV24 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_VPLANEFIRST | AVS_CS_SUB_HEIGHT_1 | AVS_CS_SUB_WIDTH_1, // YVU 4:4:4 planar + AVS_CS_YV16 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_VPLANEFIRST | AVS_CS_SUB_HEIGHT_1 | AVS_CS_SUB_WIDTH_2, // YVU 4:2:2 planar + AVS_CS_YV12 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_VPLANEFIRST | AVS_CS_SUB_HEIGHT_2 | AVS_CS_SUB_WIDTH_2, // YVU 4:2:0 planar + AVS_CS_I420 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_UPLANEFIRST | AVS_CS_SUB_HEIGHT_2 | AVS_CS_SUB_WIDTH_2, // YUV 4:2:0 planar + AVS_CS_IYUV = AVS_CS_I420, + AVS_CS_YV411 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_VPLANEFIRST | AVS_CS_SUB_HEIGHT_1 | AVS_CS_SUB_WIDTH_4, // YVU 4:1:1 planar + AVS_CS_YUV9 = AVS_CS_PLANAR | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 | AVS_CS_VPLANEFIRST | AVS_CS_SUB_HEIGHT_4 | AVS_CS_SUB_WIDTH_4, // YVU 4:1:0 planar + AVS_CS_Y8 = AVS_CS_PLANAR | AVS_CS_INTERLEAVED | AVS_CS_YUV | AVS_CS_SAMPLE_BITS_8 // Y 4:0:0 planar }; enum { @@ -191,17 +233,29 @@ AVSC_INLINE int avs_is_yuv(const AVS_VideoInfo * p) AVSC_INLINE int avs_is_yuy2(const AVS_VideoInfo * p) { return (p->pixel_type & AVS_CS_YUY2) == AVS_CS_YUY2; } +AVSC_INLINE int avs_is_yv24(const AVS_VideoInfo * p) + { return (p->pixel_type & AVS_CS_PLANAR_MASK) == (AVS_CS_YV24 & AVS_CS_PLANAR_FILTER); } + +AVSC_INLINE int avs_is_yv16(const AVS_VideoInfo * p) + { return (p->pixel_type & AVS_CS_PLANAR_MASK) == (AVS_CS_YV16 & AVS_CS_PLANAR_FILTER); } + AVSC_INLINE int avs_is_yv12(const AVS_VideoInfo * p) - { return ((p->pixel_type & AVS_CS_YV12) == AVS_CS_YV12)||((p->pixel_type & AVS_CS_I420) == AVS_CS_I420); } + { return (p->pixel_type & AVS_CS_PLANAR_MASK) == (AVS_CS_YV12 & AVS_CS_PLANAR_FILTER); } -AVSC_INLINE int avs_is_color_space(const AVS_VideoInfo * p, int c_space) - { return ((p->pixel_type & c_space) == c_space); } +AVSC_INLINE int avs_is_yv411(const AVS_VideoInfo * p) + { return (p->pixel_type & AVS_CS_PLANAR_MASK) == (AVS_CS_YV411 & AVS_CS_PLANAR_FILTER); } + +AVSC_INLINE int avs_is_y8(const AVS_VideoInfo * p) + { return (p->pixel_type & AVS_CS_PLANAR_MASK) == (AVS_CS_Y8 & AVS_CS_PLANAR_FILTER); } AVSC_INLINE int avs_is_property(const AVS_VideoInfo * p, int property) { return ((p->pixel_type & property)==property ); } AVSC_INLINE int avs_is_planar(const AVS_VideoInfo * p) { return !!(p->pixel_type & AVS_CS_PLANAR); } + +AVSC_INLINE int avs_is_color_space(const AVS_VideoInfo * p, int c_space) + { return avs_is_planar(p) ? ((p->pixel_type & AVS_CS_PLANAR_MASK) == (c_space & AVS_CS_PLANAR_FILTER)) : ((p->pixel_type & c_space) == c_space); } AVSC_INLINE int avs_is_field_based(const AVS_VideoInfo * p) { return !!(p->image_type & AVS_IT_FIELDBASED); } @@ -351,7 +405,7 @@ AVSC_INLINE int avs_get_row_size_p(const AVS_VideoFrame * p, int plane) { else return 0; case AVS_PLANAR_U_ALIGNED: case AVS_PLANAR_V_ALIGNED: if (p->pitchUV) { - int r = (p->row_sizeUV+AVS_FRAME_ALIGN-1)&(~(AVS_FRAME_ALIGN-1)); // Aligned rowsize + r = (p->row_sizeUV+AVS_FRAME_ALIGN-1)&(~(AVS_FRAME_ALIGN-1)); // Aligned rowsize if (r < p->pitchUV) return r; return p->row_sizeUV; @@ -602,7 +656,6 @@ enum { AVS_CPUF_SSE4_2 = 0x800, // Nehalem }; - AVSC_API(const char *, avs_get_error)(AVS_ScriptEnvironment *); // return 0 if no error AVSC_API(long, avs_get_cpu_flags)(AVS_ScriptEnvironment *); @@ -715,6 +768,7 @@ struct AVS_Library { AVSC_DECLARE_FUNC(avs_function_exists); AVSC_DECLARE_FUNC(avs_get_audio); AVSC_DECLARE_FUNC(avs_get_cpu_flags); + AVSC_DECLARE_FUNC(avs_get_error); AVSC_DECLARE_FUNC(avs_get_frame); AVSC_DECLARE_FUNC(avs_get_parity); AVSC_DECLARE_FUNC(avs_get_var); @@ -739,7 +793,6 @@ struct AVS_Library { AVSC_DECLARE_FUNC(avs_subframe_planar); AVSC_DECLARE_FUNC(avs_take_clip); AVSC_DECLARE_FUNC(avs_vsprintf); - AVSC_DECLARE_FUNC(avs_get_error); }; #undef AVSC_DECLARE_FUNC @@ -774,6 +827,7 @@ AVSC_INLINE AVS_Library * avs_load_library() { AVSC_LOAD_FUNC(avs_function_exists); AVSC_LOAD_FUNC(avs_get_audio); AVSC_LOAD_FUNC(avs_get_cpu_flags); + AVSC_LOAD_FUNC(avs_get_error); AVSC_LOAD_FUNC(avs_get_frame); AVSC_LOAD_FUNC(avs_get_parity); AVSC_LOAD_FUNC(avs_get_var); @@ -798,7 +852,6 @@ AVSC_INLINE AVS_Library * avs_load_library() { AVSC_LOAD_FUNC(avs_subframe_planar); AVSC_LOAD_FUNC(avs_take_clip); AVSC_LOAD_FUNC(avs_vsprintf); - AVSC_LOAD_FUNC(avs_get_error); #undef __AVSC_STRINGIFY #undef AVSC_STRINGIFY -- 1.7.11.msysgit.1 This is a patch that adds a GNU-style Makefile to ease users needing to install AviSynth's headers. It installs both avisynth.h and avisynth_c.h: Code:
diff --git a/GNUmakefile b/GNUmakefile new file mode 100644 index 0000000..083ab09 --- /dev/null +++ b/GNUmakefile @@ -0,0 +1,13 @@ +# Makefile + +all: default + +PREFIX=/usr/local + +install: + install -d $(PREFIX)/include + install -d $(PREFIX)/include/avisynth + install -m 644 $(addprefix src/core/, avisynth.h avisynth_c.h) $(PREFIX)/include/avisynth + +uninstall: + rm -f -R $(PREFIX)/include/avisynth diff --git a/README-GNUmakefile b/README-GNUmakefile new file mode 100644 index 0000000..728584b --- /dev/null +++ b/README-GNUmakefile @@ -0,0 +1,18 @@ +AviSynth, as an MSVC-based project, does not have a 'make install' +routine that users familiar with GNU-style build systems recognize. +Thus, users must search out the right header(s) from AviSynth's +source code and manually copy them to wherever their source code +expects them to be. + +As a remedy for this issue when wanting to build libav with +--enable-avisynth, this Makefile supplies this method of +installation. + +To install: +make install + +To install to a non-standard location: +make install PREFIX=/path/to/location + +To uninstall: +make uninstall -- 1.7.11.msysgit.1 |
17th January 2014, 04:55 | #30 | Link |
HeartlessS Usurer
Join Date: Dec 2009
Location: Over the rainbow
Posts: 10,980
|
@VcMohan,
you could just copy/paste the text from here:- https://github.com/AviSynth/AviSynth...ude/avisynth.h
__________________
I sometimes post sober. StainlessS@MediaFire ::: AND/OR ::: StainlessS@SendSpace "Some infinities are bigger than other infinities", but how many of them are infinitely bigger ??? |
17th January 2014, 04:59 | #31 | Link | |
Registered User
Join Date: Oct 2011
Posts: 52
|
Quote:
or get the files separately from here. (click RAW) |
|
17th January 2014, 12:09 | #34 | Link | |
AVS+ Dev
Join Date: Aug 2013
Posts: 359
|
Quote:
__________________
AviSynth+ Last edited by ultim; 17th January 2014 at 15:28. |
|
19th January 2014, 20:21 | #37 | Link | ||
Moderator
Join Date: Nov 2001
Location: Netherlands
Posts: 6,364
|
Quote:
Quote:
The reason the exemption was temporary removed is described here http://forum.doom9.org/showthread.php?t=125582 (plugins can be fixed when the api is finished). Yes if devs stay around the reason is a bit moot. |
||
19th January 2014, 20:40 | #38 | Link | |
Registered User
Join Date: Jan 2010
Posts: 270
|
Quote:
As for the reasoning - the point is very moot if the avs dev himself doesn't really stay around. Not to mention that 6 years is quite a long time to finalize the interface, don't you think? |
|
19th January 2014, 22:23 | #39 | Link | |
Guest
Join Date: Jan 2002
Posts: 21,901
|
Quote:
|
|
19th January 2014, 22:46 | #40 | Link | |
AVS+ Dev
Join Date: Aug 2013
Posts: 359
|
Quote:
To summarize, you are free to proceed as if the exemption is still in effect if you don't use his 2.6-style header. Otherwise you're violating the licence. EDIT: Actually, assuming he has contributed his non-header code under the GPL too, without his explicit agreement you cannot use the exemption at all with any of his copyrightable code, not even with other headers. Otherwise it would be possible to add non-GPL headers to GPL code and circumvent the licence in any project this way.
__________________
AviSynth+ Last edited by ultim; 20th January 2014 at 00:07. |
|
|
|