Skip to content

Commit

Permalink
Mention raster-fade-duration layer property in VideoSource documentat…
Browse files Browse the repository at this point in the history
…ion (maplibre#2972)

Co-authored-by: neodescis <[email protected]>
  • Loading branch information
neodescis and neodescis authored Aug 12, 2023
1 parent 4879e34 commit 82b60a0
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/source/video_source.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 82b60a0

Please sign in to comment.