Add some comments to video.h

This commit is contained in:
Stephen Seo 2021-12-01 16:31:56 +09:00
parent f9e87adcd3
commit fa7b5a110a

View file

@ -13,6 +13,11 @@ constexpr unsigned int kReadBufPaddingSize = AV_INPUT_BUFFER_PADDING_SIZE;
constexpr unsigned int kReadBufSizeWithPadding = constexpr unsigned int kReadBufSizeWithPadding =
kReadBufSize + kReadBufPaddingSize; kReadBufSize + kReadBufPaddingSize;
/*!
* \brief Helper class that uses Image and OpenCLHandle to dither video frames.
*
* Note that libraries provided by ffmpeg are used to decode the video.
*/
class Video { class Video {
public: public:
explicit Video(const char *video_filename); explicit Video(const char *video_filename);
@ -20,8 +25,15 @@ class Video {
~Video(); ~Video();
/// Same as DitherVideo(const std::string&, Image*, bool)
bool DitherVideo(const char *output_filename, Image *blue_noise, bool DitherVideo(const char *output_filename, Image *blue_noise,
bool grayscale = false); bool grayscale = false);
/*!
* \brief Dithers the frames in the input video.
*
* \return True on success.
*/
bool DitherVideo(const std::string &output_filename, Image *blue_noise, bool DitherVideo(const std::string &output_filename, Image *blue_noise,
bool grayscale = false); bool grayscale = false);