w3c / mediacapture-worker

MediaStream with worker
Other
9 stars 12 forks source link

Simplify the ChannelPixelLayout and ImageFormatPixelLayout #41

Closed kakukogou closed 8 years ago

kakukogou commented 8 years ago

@rocallahan suggested that rename the ImageFormatPixelLayout to ImagePixelLayout because the original one is too redundant.

@smaug---- suggested using WebIDL dictionary for ChannelPixelLayout and then the Image(Format)PixelLayout becomes just sequence<ChannelPixelLayout>. (maybe using a typedef)

anssiko commented 8 years ago

LGTM.

One case where using a constructor for ChannelPixelLayout might come handy would be to provide some sort of error handling for invalid input per channel. However, I think we're better off doing that on the ImageFormatPixelLayout level instead.