ReactVision / viro

ViroReact: The AR and VR library for React Native 📳💙💛🤍💚
MIT License
1.3k stars 150 forks source link

Filter video background color not working at 100% #154

Open gokugen opened 1 year ago

gokugen commented 1 year ago

Hello,

I use chromaKeyFilteringColor in order to remove my green background from my video but this creates a green border color around the character.

How can I remove this border?

my code:

ViroMaterials.createMaterials({
    chromaKeyFilteredVideo: {
        chromaKeyFilteringColor: "#00FF00",
    }
})

return (
      <ViroARSceneNavigator
        style={styles.videoItem}
        autofocus={true}
        initialScene={{
            scene: () => (
                <ViroARScene>
                    <ViroVideo
                        source={require('../assets/example.mp4')}
                        materials={['chromaKeyFilteredVideo']}
                        position={[0, -0.4, -1]}
                        scale={[scale, scale, scale]}
                        width={1}
                        height={0.5}
                    />
                </ViroARScene>
            ),
        }}
    />
)

On Android:

On IOS:

Thank you very much for your help !

Versions

johncantrell97 commented 1 year ago

fwiw I'm seeing exactly the same thing and would love to know if there's a way to improve this.

andresteves commented 9 months ago

Suffering from the same. Any solution available? Or workaround?