Back to class index
Graphics[Class Summary]
Resized
OrientationAboutToChange
size
type
normalized
stride
pointer[const]
timeStalledForGPU
ctor
~dtor
Deinit()
Clear(...)
ScreenWidth()[const]
ScreenHeight()[const]
GetDisplayState()[const]
Resize(...)
Present()
ApplyVertexBuffer(vb)
ApplyIndexBuffer(ib)
ApplyMaterialShaders(material)
ApplyMaterial(material)
ApplyConstantBuffer(...)
ApplyTexture(...)
ApplyTextureSampler(...)
ApplyRasterizerState(rasterizerState)
ApplyBlendState(blendState)
ApplyDepthState(depthState)
Render(...) (+1 overload)
ApplyAndRender(...) (+1 overload)
ProfileDisableRendering(disableRendering_)
IsTextureFormatSupported(format)[const]
ProfileReplaceTexturesWith4x4Block(...)
ProfileDisableAlphaBlending(...)
Instance()[static]
SupportsGLExtension(extensionString)[static]
CheckErrors(hintOperation)[static]
DumpGLES2State()[static]
GlActiveTexture(textureIndex)[static]

Graphics::Resize

Syntax

void Graphics::Resize(int newScreenWidth, int newScreenHeight, DisplayState newDisplayMode=DisplayRetainCurrentMode, ScreenOrientation newOrientation=ScreenOrientationPreserveCurrent);

Call this function to resize the current rendering canvas size.

Note
This function is available on Desktop OSes (Win, OSX, Linux) and when compiling for Emscripten, but do not call this function on iOS or Android. (on those platforms, it is called internally to trigger screen orientation change events) This function is a no-op if called with the same screen size as currently set, otherwise the rendering surface is recreated to the given size.

Parameters

ScreenOrientationnewOrientationThis parameter specifies what the new orientation of the device is. For desktop platforms, always pass in ScreenOrientationPreserveCurrent.

Return Value

The currently displayed render window orientation. On desktop platforms, this function always returns ScreenOrientationLandscape. ScreenOrientation GetScreenOrientation() const;

Work in progress:

Todo: in void Graphics::Resize(int newScreenWidth, int newScreenHeight, DisplayState newDisplayMode=DisplayRetainCurrentMode, ScreenOrientation newOrientation=ScreenOrientationPreserveCurrent):
Add
Todo: in void Graphics::Resize(int newScreenWidth, int newScreenHeight, DisplayState newDisplayMode=DisplayRetainCurrentMode, ScreenOrientation newOrientation=ScreenOrientationPreserveCurrent):
Store newOrientation as a member and add Graphics::ScreenOrientation.
Todo: in void Graphics::Resize(int newScreenWidth, int newScreenHeight, DisplayState newDisplayMode=DisplayRetainCurrentMode, ScreenOrientation newOrientation=ScreenOrientationPreserveCurrent):
Bug: in void Graphics::Resize(int newScreenWidth, int newScreenHeight, DisplayState newDisplayMode=DisplayRetainCurrentMode, ScreenOrientation newOrientation=ScreenOrientationPreserveCurrent):
This removes creation flags!

Leave a Comment

Name:
Comments:
Captcha:captcha image Type in the black symbols:
Back to class index