问题
I'm trying to blur a node or create a blur effect in SceneKit.
let ship = scene.rootNode.childNodeWithName("ship", recursively: true)!
var ciFilters = [CIFilter]()
ciFilters.append(CIFilter(name: "CIGaussianBlur", withInputParameters: [kCIInputRadiusKey: 30])!)
ship.filters = ciFilters
Results in:
Which, I thought ok maybe I'm using the CIFilter incorrectly. However CIHalftone works fine:
ciFilters.append(CIFilter(name: "CICMYKHalftone", withInputParameters: ["inputWidth": 20])!)
I've also tried with CIZoomBlur also doesn't work, however CIPixellate does.
Am I missing something fundamental here?
Update: I have tried everything in CICategoryBlur and can't get any of them to work, however every other CICategory item i've tried I could get to work.
Thanks.
来源:https://stackoverflow.com/questions/34210293/scenekit-cifilter-cicategoryblur-filters-nothing-visible