I’m in the middle of a project with a very important customer and this couldn’t have come at a worse time but here we go:
I’m using the new media framework (4.18.3) for capturing webcam footage and displaying it on screen.
I’ve implemented everything as show by the documentation at Playing Live Video Captures | Unreal Engine Documentation.
I’m experiencing issues playing most video formats.shown under Playback Options > Video > … .
Once I change format to pretty much anything other than the default 640x480 (which shows up fine) the image turns black and instead of “Playing” the overlay text says “Error”.
I did of course make sure the format I’m trying to change to is supported by the webcam capture device.
Example trying to switch to 1920x1080 (same codec and frame rate as the functioning counterpart of 640x480)
Note: Some formats do show signs of life but result in a completely distorted and unusable image.
This same effect also happens when I try to load video from a DSLR camera with 3RD party software like SparkoCam (regardless of what format I use, non of them show a clear image, they’re all distorted).
Example trying to switch to 320*180 (same codec and frame rate as the functioning counterpart of 640x480)
This issue occurs whether I change the format though the media player or even at runtime using blueprints.
It also occurs in both editor and packaged project.
I’ve turned on verbose logging for media framework as described in the media framework technical reference Media Framework Technical Reference | Unreal Engine Documentation
but there seem to be no interesting logs or warnings/errors that indicate something is off.
I’ve attached a file with the content of the output log when running the project and then switching to another video format at run time.
[link text][3]
Here’s what’s odd:
The issues described above I’m experiencing when running the project game on my laptop.
But if I run the same project files (copy/pasted) with the exact same webcam on my PC everything works well!
Also on both the Laptop and PC I am able access the webcam feed at any resolution I desire using 3rd party software such as OBS Studio without any issues - it’s only when accessing the feed through the engine that these issues arise.
My laptop also has a built in webcam which works when used with 3rd party software such as OBS Studio but not through the engine (black screen) regardless of the format I choose.
This to me pretty much rules out the possibility that the issue is caused by either the device not functioning as intended or the project’s logic doing something wrong.
Main differences between PC and Laptop that come to mind:
OS: Laptop is Win7, PC is Win8.1
Graphics Cars: Laptop has Intel HD4000, PC has GTX1070.
The camera I’m using is the Logitech C922 Pro Stream.
I’ve attached my laptop’s DxDiag output as a text file.
[link text][4]
If there’s any other details I could that would help troubleshooting this issue please do let me know.