// SquareGenerator is a FrameGenerator that draws a given amount of randomly // sized and colored squares. Between each new generated frame, the squares // are moved slightly towards the lower right corner. class SquareGenerator : public FrameGeneratorInterface {
public:
SquareGenerator(int width, int height, OutputType type, int num_squares);
private:
Random random_generator_; int x_; int y_; constint length_; const uint8_t yuv_y_; const uint8_t yuv_u_; const uint8_t yuv_v_; const uint8_t yuv_a_;
};
mutable Mutex mutex_; const OutputType type_; int width_ RTC_GUARDED_BY(&mutex_); int height_ RTC_GUARDED_BY(&mutex_);
std::vector<std::unique_ptr<Square>> squares_ RTC_GUARDED_BY(&mutex_);
};
class YuvFileGenerator : public FrameGeneratorInterface {
public:
YuvFileGenerator(std::vector<FILE*> files,
size_t width,
size_t height, int frame_repeat_count);
class NV12FileGenerator : public FrameGeneratorInterface {
public:
NV12FileGenerator(std::vector<FILE*> files,
size_t width,
size_t height, int frame_repeat_count);
// SlideGenerator works similarly to YuvFileGenerator but it fills the frames // with randomly sized and colored squares instead of reading their content // from files. class SlideGenerator : public FrameGeneratorInterface {
public:
SlideGenerator(int width, int height, int frame_repeat_count);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.