MCPcopy Create free account
hub / github.com/Tencent/libpag / SetupPAG

Function SetupPAG

test/src/MultiThreadCase.cpp:59–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

57static std::shared_ptr<PAGFile> TestPAGFile = nullptr;
58
59void SetupPAG() {
60 TestPAGFile = LoadPAGFile("resources/apitest/test.pag");
61 ASSERT_TRUE(TestPAGFile != nullptr);
62 TestPAGSurface = OffscreenSurface::Make(TestPAGFile->width(), TestPAGFile->height());
63 ASSERT_TRUE(TestPAGSurface != nullptr);
64 TestPAGPlayer = std::make_shared<PAGPlayer>();
65 TestPAGPlayer->setSurface(TestPAGSurface);
66 TestPAGPlayer->setComposition(TestPAGFile);
67}
68
69void TearDownPAG() {
70 TestPAGFile = nullptr;

Callers 1

PAG_TESTFunction · 0.85

Calls 6

LoadPAGFileFunction · 0.85
MakeFunction · 0.50
widthMethod · 0.45
heightMethod · 0.45
setSurfaceMethod · 0.45
setCompositionMethod · 0.45

Tested by

no test coverage detected