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.

 

Go Back   Doom9's Forum > Capturing and Editing Video > VapourSynth

Reply
 
Thread Tools Search this Thread Display Modes
Old 24th October 2021, 19:55   #1  |  Link
Reclusive Eagle
Registered User
 
Join Date: Oct 2021
Posts: 51
How do you view edge masks?

I'm trying to create a Sobel Edge mask and I get no errors but literally nothing happens when I should be seeing detected edges.

I am using this article as a guide however literally nothing happens.

The clip is YUV420P8 so 470BG

This code does nothing:
core.std.Binarize(clip,24, v0=0, v1=255)
clipmax = core.std.Maximum(clip)
clipmin = core.std.Minimum(clip)
minmax = core.std.Expr([clipmax, clipmin], 'x y -')
mask = core.std.Sobel(clip, 0)
luma = core.std.ShufflePlanes(mask, 0, colorfamily=vs.GRAY)


Neither does this:
This code does nothing:
core.std.Sobel(clip)
sx = core.std.Convolution(clip,[-1, -2, -1, 0, 0, 0, 1, 2, 1], saturate=False)
sy = core.std.Convolution(clip,[-1, 0, 1, -2, 0, 2, -1, 0, 1], saturate=False)
core.std.Expr([sx, sy], 'x y max')

Am I supposed to display the mask layer somehow?
Reclusive Eagle is offline   Reply With Quote
Old 24th October 2021, 20:03   #2  |  Link
ChaosKing
Registered User
 
Join Date: Dec 2005
Location: Germany
Posts: 1,514
You need an add output at the end: your_clip_name.set_output()
In your case it would be
Code:
luma.set_output()
If you want the mask
Code:
mask.set_output()
__________________
AVSRepoGUI // VSRepoGUI - Package Manager for AviSynth // VapourSynth
VapourSynth Portable FATPACK || VapourSynth Database || https://github.com/avisynth-repository
ChaosKing is offline   Reply With Quote
Old 24th October 2021, 20:09   #3  |  Link
Reclusive Eagle
Registered User
 
Join Date: Oct 2021
Posts: 51
Quote:
Originally Posted by ChaosKing View Post
You need an add output at the end: your_clip_name.set_output()
In your case it would be
Code:
luma.set_output()
If you want the mask
Code:
mask.set_output()
Yup that was it, thank you!
Was clip.set_output(). I guess there is more to the output than I realized
Reclusive Eagle is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 20:32.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.