patriciogonzalezvivo / glslViewer

Console-based GLSL Sandbox for 2D/3D shaders
BSD 3-Clause "New" or "Revised" License
4.57k stars 352 forks source link

Webcam input fails with "Failed to decode packet: End of file" #358

Open jschmdt opened 2 months ago

jschmdt commented 2 months ago

My specs: Macbook Pro M3, OSX Sonoma 14.4.1, glslViewer 3.30 (built from source)

Task: Testing webcam input with shader example: glslViewer -l test_video.frag --video 0

Issue: Webcam input is shown inside of glslViewer for 1-2 frames but then immediately stops with following error: Failed to decode packet: End of file

FFMPEG:

[AVFoundation indev @ 0x138005ea0] AVFoundation video devices:
**[AVFoundation indev @ 0x138005ea0] [0] FaceTime HD-Kamera
[AVFoundation indev @ 0x138005ea0] [1] Capture screen 0
[AVFoundation indev @ 0x138005ea0] [2] Capture screen 1**
[AVFoundation indev @ 0x138005ea0] AVFoundation audio devices:
[AVFoundation indev @ 0x138005ea0] [0] MacBook Pro-Mikrofon

Testing if webcam works: