Skip to main content

Video File Formats

VRChat (specifically AVPro Video Player) requires certain formats to work correctly.

From various sources, here are the worst to best codecs to use for your streaming to VRChat Worlds:

  1. h264
  2. h265 (hevc)
  3. AV1

h265, and AV1 require extra codecs. I have yet to test AV1 with Quest standalone.

AVPro also seems to studder and require a pause/unpause at the beginning if the file container is a .mkv file. You can convert the file to .mp4 without transcoding the audio or video easily with ffmpeg.

If the world is not setup for surround sound (only has stereo speakers), then you need to downmix the 5.1 audio to stereo. This bash script will take all .mkv files in a directory, keep the video codec, and rewrite the audio codec to AAC and mix the audio down to stereo in a way that dialog is not lost behind the music track.

for i in *.mkv; 
do ffmpeg -i "$i" -vcodec copy -acodec aac -vol 425 -af "pan=stereo|c0=0.5*c2+0.707*c0+0.707*c4+0.5*c3|c1=0.5*c2+0.707*c1+0.707*c5+0.5*c3" -movflags faststart "${i%.*}.mp4";
done

To Encode to AAC + H265 (HEVC) do the following

for i in *.mkv;
do ffmpeg -i "$i" -c:v libx265 -crf 25 -preset medium -tune fastdecode -c:a aac -vol 512 -af "pan=stereo|c0=0.5*c2+0.707*c0+0.707*c4+0.5*c3|c1=0.5*c2+0.707*c1+0.707*c5+0.5*c3" -movflags faststart "${i%.*}.mp4";
done