I encoded a raw video in Y4M format with the following command on Matlab
system(['ffmpeg -i ' videoNameIn, videoTypeIn, ' -s ' num2str(width),'x',num2str(height), ' -r ', num2str(frameRate), ' -c:v libx265 -preset ultrafast', videoNameOut, videoTypeOut]);
The output is in .h265
. Now I want to decode it to the original format which means Y4M, how can I do that?