I am trieing to create a camera preview and adjustment screen applieng multible filters to
the preview object which is filled with the camera feed. Everything is fine as long as I only use one filter in my custom effect list.
As soon as I add a second effect the result is just black. Any ideas?
Thanks in advance.
Here is a code snippet:
local imgCamPreview = display.newRect( _W/2, _H/2 - 20, 480, 640 )
imgCamPreview.fill = { type=“camera” }
graphics.defineEffect({
language = “glsl”,
category = “filter”,
name = “camSetting”,
graph = {
nodes = {
brightnessFilter = { effect = “filter.brightness”, input1 = “paint1” }
– contrastFilter = { effect = “filter.contrast”, input1 = “brightnessFilter” }
},
output = “brightnessFilter”
--output = “contrastFilter”
}
})
imgCamPreview.fill.effect = “filter.custom.camSetting”
imgCamPreview.fill.effect.brightnessFilter.intensity = mnBrightness
– imgCamPreview.fill.effect.contrast = mnContrast