I try to read a 4k video in Matlab. I use the next code:
vision.VideoFileReader('my_file.mp4', ...
'ImageColorSpace', 'RGB', ...
'VideoOutputDataType', 'uint8');
The video file is obtained from GoPro camera and the MPEG-4 H264 codec is used to compress the video. The resolution of each frame is 3840 x 2160 pixels, so it is indeed the 4k UHD video. I got the next error:
Error using coder.internal.errorIf (line 9)
Unable to read video from the file. Use dsp.AudioFileReader to read audio content.
Error in vision.VideoFileReader/setFileInfoProps (line 352)
Error in vision.VideoFileReader/set.Filename (line 150)
Error in matlab.system.SystemProp/parseInputs (line 908)
Error in matlab.system.SystemProp/sysObjSetProperties (line 298)
Error in vision.VideoFileReader (line 133)
The video from the same camera (meaning the same codec), but using resolution 1920 x 1080 pixels,can be read without any errors.
I use Matlab R2014b (64-bit), Windows 7 Professional.
Any ideas how I can read the 4k video without converting it to different format?