It can't stream Matroska (that I can see), but it will take pretty much anything if it's in an MPEG2-TS container.
That's what I'm using to copy my DVDs over directly so there's no loss.
ffmpeg -i movie.mkv -c copy movie.m2ts
Supported
Not Supported
Plex's DLNA server streams to it just fine as well, and it will do a Direct Play on H.264+AAC+MP4 videos.
Filesystems
PS4 can playback media on a FAT32 and exFAT filesystem.