#174 Overlay() mask mode transparency bug

Filters (75)

I can't make a full blend overlay in mask mode, yet I
give it a clear white mask clip.

In mask mode the base clip doesn't disappear totally
(again, with full white mask clip), instead it
slightly shows as a "ghost" image, like when i would
use a circa .95 opacity value.

This bug causes some troubles me, because i'm using
complex, automated editing functions.


  • Ian Brabham

    Ian Brabham - 2006-05-28

    Logged In: YES

    Is this a PC levels versus TV levels confusion?

    Post a minimal sample script!

  • Márton Sári

    Márton Sári - 2006-05-28

    Logged In: YES

    base = avisource("avi1.avi")
    overlayclip = avisource("avi2.avi")

    #The base clip is slightly visible, and according to it if I
    use color_black
    #then the overlayclip so is visible
    m = blankclip(overlayclip, color=color_white,

    base.overlay(overlayclip, mask=m)

  • Ian Brabham

    Ian Brabham - 2006-05-29

    Logged In: YES

    In overlay() the Mask clip is alway full scale, PC-Levels,
    range, i.e. [0-255] In your sample script the "m" clip will
    be CCIR601 range. i.e color_white=YUV[235,128,128] and

    For this sample script the easiest fix is to force "m" to
    be RGB by adding a Pixel_Type="RGB32" to the BlankClip()
    call. Thus color_white=RGB[255,255,255] and color_black=YUV

    In a more general case use ColorYUV(levels="TV->PC") or
    Levels(16, 1.0, 235, 0, 255, Coring=False) to appropriately
    rescale your YUV mask clips. Or use RGB pixel format for
    your mask clips.

    In AviSynth 2.6 a new Pixel format, Y8, will be available,
    and there is some work scheduled to Overlay to use this new
    format to improve this function.

  • Ian Brabham

    Ian Brabham - 2006-05-29
    • milestone: --> v2.5x
    • assigned_to: nobody --> ianb1957
    • status: open --> closed-works-for-me

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks