VideoHelp Forum




+ Reply to Thread
Results 1 to 6 of 6
  1. Hi

    The only tool I was introduced to get the job done was Avisynth so I tried MeGUI and AvsPmod but both give me errors.

    the script:
    Code:
    LoadPlugin("C:\Users\me\Desktop\MeGUI-2944-64\tools\lsmash\LSMASHSource.dll")
    LSMASHVideoSource("C:\Users\me\Desktop\video.mp4")
    #deinterlace
    #crop
    #resize
    #denoise
    Image=ImageSource("C:\Users\me\Desktop\logo.png",pixel_type="RGB32")
    Overlay(last,Image,mask=Image.ShowAlpha(),x=10,y=10)
    I get no error with the script above but the logo is too big so if I chain <.Spline16Resize(159,67)> to ImageSoure then it throws an error like "Could not read AVS frame" and the log says "Could not read frame: Filter Error: Attempted to request a planar frame that wasn't mod2 in width!"

    I've never used Avisynth successfully so please any help would be really appreciated. I've spent hours without any success.
    Quote Quote  
  2. Member
    Join Date
    Mar 2008
    Location
    United States
    Search Comp PM
    It probably means you cannot use odd numbers on the resize, must be mod2 (even numbers)
    Quote Quote  
  3. I do all my production in FCP and Premier Pro for commercial purposes. Either can easily add a transparent logo or watermark but not free and high learning curve. Probably not for you.

    I think ffmpeg can do it. Have a look at this thread https://stackoverflow.com/questions/39591675/ffmpeg-add-semi-transparent-watermarkpng-...different-size
    Quote Quote  
  4. FFMPEG code.

    Code:
    ffmpeg -i input.mkv -i logo.png -filter_complex ^
    
    [1]scale=VALUE[S];^
    
    [S]format=argb,colorchannelmixer=aa=0.5[alpha];^
    
    [0:v][alpha]overlay=x=10:y=10 output.mkv
    0.5 alpha can be set between 0 and 1. Replace VALUE with logo desired size.
    Last edited by Secoast; 16th Jul 2023 at 03:47.
    Quote Quote  
  5. Originally Posted by davexnet View Post
    It probably means you cannot use odd numbers on the resize, must be mod2 (even numbers)
    Originally Posted by TubeBar View Post
    I do all my production in FCP and Premier Pro for commercial purposes. Either can easily add a transparent logo or watermark but not free and high learning curve. Probably not for you.

    I think ffmpeg can do it. Have a look at this thread https://stackoverflow.com/questions/39591675/ffmpeg-add-semi-transparent-watermarkpng-...different-size
    Originally Posted by Secoast View Post
    FFMPEG code.
    ...
    0.5 alpha can be set between 0 and 1. Replace VALUE with logo desired size.
    Thanks everyone. I got the desired result with no errors by changing the logo size but the whole time I thought it would be added as a new layer or a "logo filter" so there'd be no need to re-encode the whole file but I was simply wrong, it took so long

    Anyway could you please let me know if there is any way to add a logo to mp4/mkv files without rencoding? No issue on my side if it would be "soft" i.e. could be easily turned off.
    Quote Quote  
  6. I don't know if you can add an overlay track to an MKV file. But even if you can, I suspect most players will not support the feature. You could try using a graphic subtitle format (VOBSUB maybe, but limit color optoins) and forced subs.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!