MCPcopy Create free account
hub / github.com/Snapchat/Valdi / TestBitmap

Method TestBitmap

snap_drawing/test/utils/TestBitmap.cpp:6–15  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4namespace snap::drawing {
5
6TestBitmap::TestBitmap(int width, int height) : _width(width), _height(height) {
7 auto offset = getPixelOffset(0, height);
8 _pixels.resize(offset);
9
10 for (int y = 0; y < height; y++) {
11 for (int x = 0; x < width; x++) {
12 setPixel(x, y, Color::white());
13 }
14 }
15}
16
17TestBitmap::~TestBitmap() = default;
18

Callers

nothing calls this directly

Calls 1

resizeMethod · 0.45

Tested by

no test coverage detected