MCPcopy Create free account
hub / github.com/cocos/cocos-engine / initWindow

Method initWindow

native/cocos/core/assets/RenderTexture.cpp:91–106  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

89}
90
91void RenderTexture::initWindow() {
92 auto *device{Root::getInstance()->getDevice()};
93
94 cc::scene::IRenderWindowInfo windowInfo;
95 windowInfo.title = _name;
96 windowInfo.width = _width;
97 windowInfo.height = _height;
98 windowInfo.renderPassInfo = getDefaultRenderPassInfo(device);
99
100 if (_window != nullptr) {
101 _window->destroy();
102 _window->initialize(device, windowInfo);
103 } else {
104 _window = Root::getInstance()->createWindow(windowInfo);
105 }
106}
107
108void RenderTexture::initWindow(const IRenderTextureCreateInfo &info) {
109 auto *device{Root::getInstance()->getDevice()};

Callers

nothing calls this directly

Calls 7

getDefaultRenderPassInfoFunction · 0.85
has_valueMethod · 0.80
destroyMethod · 0.65
initializeMethod · 0.65
valueMethod · 0.65
getDeviceMethod · 0.45
createWindowMethod · 0.45

Tested by

no test coverage detected