MCPcopy Create free account
hub / github.com/defold/defold / SetUp

Method SetUp

engine/dlib/src/test/test_buffer.cpp:71–82  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69
70protected:
71 void SetUp() override {
72 dmBuffer::NewContext();
73
74 dmBuffer::StreamDeclaration streams_decl[] = {
75 {dmHashString64("position"), dmBuffer::VALUE_TYPE_FLOAT32, 3},
76 {dmHashString64("texcoord"), dmBuffer::VALUE_TYPE_UINT16, 2}
77 };
78
79 count = 4;
80 stride = sizeof(float)*3 + sizeof(uint16_t)*2;
81 dmBuffer::Create(count, streams_decl, 2, &buffer);
82 }
83
84 void TearDown() override {
85 dmBuffer::Destroy(buffer);

Callers

nothing calls this directly

Calls 2

NewContextFunction · 0.50
CreateFunction · 0.50

Tested by

no test coverage detected