From 82b60a07aafd75b8e3f42ebf0697d954ed4b404c Mon Sep 17 00:00:00 2001 From: neodescis Date: Fri, 11 Aug 2023 23:56:10 -0600 Subject: [PATCH] Mention raster-fade-duration layer property in VideoSource documentation (#2972) Co-authored-by: neodescis --- src/source/video_source.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/source/video_source.ts b/src/source/video_source.ts index 8390afdb0b..5aa966dfc5 100644 --- a/src/source/video_source.ts +++ b/src/source/video_source.ts @@ -48,6 +48,10 @@ import type {VideoSourceSpecification} from '@maplibre/maplibre-gl-style-spec'; * map.removeSource('some id'); // remove * ``` * @see [Add a video](https://maplibre.org/maplibre-gl-js/docs/examples/video-on-a-map/) + * + * Note that when rendered as a raster layer, the layer's `raster-fade-duration` property will cause the video to fade in. + * This happens when playback is started, paused and resumed, or when the video's coordinates are updated. To avoid this behavior, + * set the layer's `raster-fade-duration` property to `0`. */ export class VideoSource extends ImageSource { options: VideoSourceSpecification;