Files
gdvapi/project/example.gd

11 lines
329 B
GDScript

extends Node
func _ready() -> void:
$GDVAPIVideoStream.queue_depth = 4 # default; proves the property binding
$GDVAPIVideoStream.begin("/tmp/gdvapi_test.sdp")
func _process(_delta: float) -> void:
var tex: Texture2D = $GDVAPIVideoStream.get_texture()
if tex:
if $TextureRect.texture != tex:
$TextureRect.texture = tex