ffmpeg: correctly access planar data