Dogway / Avisynth-Scripts

AviSynth+ 3.7.3+ Filters
GNU General Public License v3.0
92 stars 13 forks source link

prefilter == 1 and 2 both yield error: "I don't know what 'Lum' means" #90

Open JohnstonJ opened 3 months ago

JohnstonJ commented 3 months ago

Describe the bug The SMDegrain filter crashes with error:

image

To Reproduce

This simple filter statement seems adequate to trigger it:

SMDegrain(prefilter=1)

Prefilter 2 is also broken in the same way.

Expected behavior

The prefilter should be run and applied as part of image processing.

System:

Additional context

At https://github.com/Dogway/Avisynth-Scripts/blob/31459ff64fa39a3ea00b5cabb288e980b57a5b00/SMDegrain/SMDegrain.avsi#L320-L321 I notice that a special string is passed to ex_MinBlur containing the named parameter Y=Lum that is to be passed to ex_Median.

Later on, it is passed to Eval, for evaluation inside the ex_MinBlur function. However, that function does not have any variable named Lum in it, and thus I think that is probably the source of the error. https://github.com/Dogway/Avisynth-Scripts/blob/31459ff64fa39a3ea00b5cabb288e980b57a5b00/SMDegrain/SMDegrain.avsi#L779

If I change the ex_Median call to read """ex_Median(mode="horizontal" ,Y=Y,UV=uv)""", then the SMDegrain filter will run successfully, but I am not familiar enough with this filter to know whether the results are as expected or not.