Is there a simple way of making a sequence of 3d array of UInt8 into a video?

Is there a simple way to save a sequence of Array{UInt8, 3} as a video? Can’t find any documentation on this. Writing Videos · VideoIO.jl (

I want to do something like:

import VideoIO
imgstack = map(x->rand(UInt8, 100, 100, 3), 1:100)  #vector of 3D arrays. RGB.
encoder_options = (crf=23, preset="medium")"video.mp4", imgstack, framerate=30, encoder_options=encoder_options)

This works for grayscale images i.e., when framestack = map(x->rand(UInt8, 100, 100), 1:100) #vector of 2D arrays.

Would appreciate any help.

you need RGB{N0f8} as eltype if you want to produce colored video output

1 Like