[Solved] How Can I Set Target for OutlineEffect?

Hello, I’m looking for an way to set outlines for objects.

I’m using ‘OutlineEffect’ instead of ‘EffectComposer’( OutlinePass and etc. ), because when I use effect composer, resolution quality is low even use FXAAShader, SSAA Shader and OutlinePass cannot use ‘dark’ color.

On OutlineEffect, it said:

 * 1. Traditional
 * var effect = new THREE.OutlineEffect( renderer );
 * function render() {
 * 	effect.render( scene, camera );
 * }

and when I use it, every objects get outline even skybox.

The problem is I don’t want to let it draw a outline on skybox.

So I used effect.setRenderTarget(objects);, and an error occured:

three.js:18819 Uncaught TypeError: Invalid value used as weak map key
    at WeakMap.set (<anonymous>)
    at Object.get (three.js:18819)
    at WebGLTextures.setupRenderTarget (three.js:22177)
    at WebGLRenderer.setRenderTarget (three.js:25956)
    at THREE.OutlineEffect.setRenderTarget (OutlineEffect.js:563)

Thank you for your help :slight_smile: