Hallo, and sorry for my terrible english
Is there a way to get the shadow from an plane with chroma-keyed video-texture not to throw the shadow form the plane itself but from the not transparent parts of the texture.
Iām paying an greenscreen-video with an person; i make the green pixels transparent by using following function:
thanks for reply.
BUT, ialready pushed it to the shadowgenerator, but i only get an rectangular shadow of the whole plane.
Anything else i could do to get the shadow from the non transparent parts of the video-texture only?
i managed to get the correct shadow by using an transparent png as texture, but NOT using the video.
var videoTexture = new BABYLON.VideoTexture("s",["./cam4.mp4"], vrscene);
You have a valid point. Perhaps a bug? If youāre using a hemispheric light then the shadow generator wonk work as hemispheric light donāt cast shadows. But hereās a PG scene I modified which uses a point ligh and I would expect it to cast a shadow from the plane.
Unfortunately video do not contains alpha value so you also have to update the shadow generator code to update it to take your chroma key change into account
Problem:
.) the shadow of the video-texture is the whole plane-rectangle. (seems, i need to set the pixel alpha anyhow, instead of using discard)
.) is there a way to use the video without a light, so i donāt get the lightās reflection when doing chroma-key?
@Deltakosh, can you elaborate on your last response? I am trying to get shadows to work with transparent videos, and havenāt quite got things working with all the good stuff in this thread.