I'd like to use imageReader to get frames from stdin.
Perhaps, a generic way of reading from any System.IO.Handle would be even better.
Maybe, something like this:
import System.IO (Handle)
data InputSource = File FilePath
| Camera String CameraConfig
| InputHandle Handle
deriving (Eq, Show) -- System.IO.Handle doesn't have instances for Read and Ord
I'd like to use
imageReader
to get frames fromstdin
.Perhaps, a generic way of reading from any
System.IO.Handle
would be even better.Maybe, something like this:
Or is there another way to read from
stdin
?