diff --git a/encoder/libaom/libaom.go b/encoder/libaom/libaom.go index 2f9cbcd..b6253d6 100644 --- a/encoder/libaom/libaom.go +++ b/encoder/libaom/libaom.go @@ -72,7 +72,9 @@ func NewEncoder(w io.Writer, properties frame.StreamProperties, settings map[str if photonNoiseIso > 0 && photonNoiseTransferFunction != nil { //create table - table, err := filmgrain.CreatePhotonNoiseTable(properties.Width, properties.Height, float64(photonNoiseIso), photonNoiseTransferFunction) + noiseWidth := getSettingUnsigned[uint](clonedSettings, "photon-noise-width", uint(properties.Width)) + noiseHeight := getSettingUnsigned[uint](clonedSettings, "photon-noise-height", uint(properties.Height)) + table, err := filmgrain.CreatePhotonNoiseTable(int(noiseWidth), int(noiseHeight), float64(photonNoiseIso), photonNoiseTransferFunction) if err != nil { return nil, err }