OGRE-Next  2.3
Object-Oriented Graphics Rendering Engine
Ogre::EmscriptenEGLWindow Class Reference

#include <OgreEmscriptenEGLWindow.h>

+ Inheritance diagram for Ogre::EmscriptenEGLWindow:

Public Member Functions

 EmscriptenEGLWindow (EmscriptenEGLSupport *glsupport)
 
virtual ~EmscriptenEGLWindow ()
 
void _createInternalResources (NativeWindowType window)
 
void _destroyInternalResources ()
 
virtual void _initialize (TextureGpuManager *textureManager)
 
void _setPrimary ()
 Indicates that this is the primary window. More...
 
virtual void _setVisible (bool visible)
 Internal method to notify the window it has been obscured or minimized. More...
 
void copyContentsToMemory (const Box &src, const PixelBox &dst, FrameBuffer buffer)
 
void create (const String &name, unsigned int width, unsigned int height, bool fullScreen, const NameValuePairList *miscParams)
 
virtual void destroy ()
 RenderWindow::destroy More...
 
void destroy ()
 
bool getBorderless () const
 
virtual void getCustomAttribute (const String &name, void *pData)
 
virtual void getCustomAttribute (IdString name, void *pData)
 
TextureGpugetDepthBuffer () const
 
uint32 getFrequencyDenominator () const
 
uint32 getFrequencyNumerator () const
 
uint32 getHeight () const
 
virtual void getMetrics (uint32 &width, uint32 &height, int32 &left, int32 &top) const
 Overloaded version of getMetrics from RenderTarget, including extra details specific to windowing systems. More...
 
PixelFormatGpu getPixelFormat () const
 
uint32 getRequestedHeightPt () const
 
uint32 getRequestedWidthPt () const
 
SampleDescription getSampleDescription () const
 
TextureGpugetStencilBuffer () const
 
TextureGpugetTexture () const
 WARNING: Attempting to change the TextureGpu (e.g. More...
 
const StringgetTitle () const
 
virtual float getViewPointToPixelScale () const
 Many windowing systems that support HiDPI displays use special points to specify size of the windows and controls, so that windows and controls with hardcoded sizes does not become too small on HiDPI displays. More...
 
bool getVSync () const
 
uint32 getVSyncInterval () const
 
uint32 getWidth () const
 
virtual bool isClosed () const
 RenderWindow::isClosed More...
 
bool isClosed () const
 Indicates whether the window has been closed by the user. More...
 
bool isFocused () const
 
bool isFullscreen () const
 Returns true if we are currently in fullscreen mode. More...
 
bool isHidden () const
 RenderWindow::isHidden More...
 
bool isMultisample () const
 
bool isPrimary () const
 
bool isVisible () const
 RenderWindow::isVisible More...
 
bool isVisible () const
 
void operator delete (void *ptr)
 
void operator delete (void *ptr, const char *, int, const char *)
 
void operator delete (void *ptr, void *)
 
void operator delete[] (void *ptr)
 
void operator delete[] (void *ptr, const char *, int, const char *)
 
void * operator new (size_t sz)
 
void * operator new (size_t sz, const char *file, int line, const char *func)
 operator new, with debug line info More...
 
void * operator new (size_t sz, void *ptr)
 placement operator new More...
 
void * operator new[] (size_t sz)
 
void * operator new[] (size_t sz, const char *file, int line, const char *func)
 array operator new, with debug line info More...
 
virtual void reposition (int32 left, int32 top)
 
void requestFullscreenSwitch (bool goFullscreen, bool borderless, uint32 monitorIdx, uint32 width, uint32 height, uint32 frequencyNumerator, uint32 frequencyDenominator)
 Requests to toggle between fullscreen and windowed mode. More...
 
void requestResolution (uint32 width, uint32 height)
 RenderWindow::resize More...
 
bool requiresTextureFlipping () const
 
bool requiresTextureFlipping () const
 
virtual void setBorderless (bool borderless)
 
virtual void setFocused (bool focused)
 
virtual void setFsaa (const String &fsaa)
 Set the FSAA mode to be used if hardware support it. More...
 
virtual void setFullscreen (bool fullscreen, uint width, uint height)
 
void setHidden (bool hidden)
 RenderWindow::setHidden More...
 
virtual void setTitle (const String &title)
 
void setVisible (bool visible)
 
virtual void setVSync (bool vSync, uint32 vSyncInterval)
 Turns VSync on/off. More...
 
virtual void swapBuffers ()
 RenderWindow::swapBuffers More...
 
bool wantsToGoFullscreen () const
 Returns true if we are in windowed mode right now, but want to go fullscreen. More...
 
bool wantsToGoWindowed () const
 Returns true if we are in fullscreen mode right now, but want to go windowed mode. More...
 

Constructor & Destructor Documentation

◆ EmscriptenEGLWindow()

Ogre::EmscriptenEGLWindow::EmscriptenEGLWindow ( EmscriptenEGLSupport glsupport)

◆ ~EmscriptenEGLWindow()

virtual Ogre::EmscriptenEGLWindow::~EmscriptenEGLWindow ( )
virtual

Member Function Documentation

◆ _createInternalResources()

void Ogre::EmscriptenEGLWindow::_createInternalResources ( NativeWindowType  window)

◆ _destroyInternalResources()

void Ogre::EmscriptenEGLWindow::_destroyInternalResources ( )

◆ _initialize()

virtual void Ogre::EGLWindow::_initialize ( TextureGpuManager textureManager)
virtualinherited

Implements Ogre::Window.

◆ _setPrimary()

void Ogre::Window::_setPrimary ( )
inherited

Indicates that this is the primary window.

Only to be called by Ogre::Root

◆ _setVisible()

virtual void Ogre::EGLWindow::_setVisible ( bool  visible)
virtualinherited

Internal method to notify the window it has been obscured or minimized.

Implements Ogre::Window.

◆ copyContentsToMemory()

void Ogre::EGLWindow::copyContentsToMemory ( const Box src,
const PixelBox &  dst,
FrameBuffer  buffer 
)
inherited

◆ create()

void Ogre::EmscriptenEGLWindow::create ( const String name,
unsigned int  width,
unsigned int  height,
bool  fullScreen,
const NameValuePairList miscParams 
)

◆ destroy() [1/2]

virtual void Ogre::EGLWindow::destroy ( )
virtualinherited

RenderWindow::destroy

RenderWindow::destroy

Implements Ogre::Window.

◆ destroy() [2/2]

void Ogre::EGLWindow::destroy ( )
virtualinherited

Implements Ogre::Window.

◆ getBorderless()

bool Ogre::Window::getBorderless ( ) const
inherited

◆ getCustomAttribute() [1/2]

virtual void Ogre::EGLWindow::getCustomAttribute ( const String name,
void *  pData 
)
virtualinherited
Remarks
Get custom attribute; the following attributes are valid: WINDOW The X NativeWindowType target for rendering. GLCONTEXT The Ogre GLContext used for rendering. DISPLAY EGLDisplay connection behind that context. DISPLAYNAME The name for the connected display.

Reimplemented in Ogre::X11EGLWindow.

◆ getCustomAttribute() [2/2]

virtual void Ogre::EGLWindow::getCustomAttribute ( IdString  name,
void *  pData 
)
virtualinherited
Remarks
Get custom attribute; the following attributes are valid: WINDOW The X Window target for rendering. GLCONTEXT The Ogre GL3PlusContext used for rendering. DISPLAY The X Display connection behind that context. DISPLAYNAME The X Server name for the connected display. ATOM The X Atom used in client delete events.

Reimplemented from Ogre::Window.

◆ getDepthBuffer()

TextureGpu* Ogre::Window::getDepthBuffer ( ) const
inherited

◆ getFrequencyDenominator()

uint32 Ogre::Window::getFrequencyDenominator ( ) const
inherited

◆ getFrequencyNumerator()

uint32 Ogre::Window::getFrequencyNumerator ( ) const
inherited

◆ getHeight()

uint32 Ogre::Window::getHeight ( ) const
inherited

◆ getMetrics()

virtual void Ogre::Window::getMetrics ( uint32 width,
uint32 height,
int32 left,
int32 top 
) const
virtualinherited

Overloaded version of getMetrics from RenderTarget, including extra details specific to windowing systems.

Result is in pixels.

◆ getPixelFormat()

PixelFormatGpu Ogre::Window::getPixelFormat ( ) const
inherited

◆ getRequestedHeightPt()

uint32 Ogre::Window::getRequestedHeightPt ( ) const
inherited

◆ getRequestedWidthPt()

uint32 Ogre::Window::getRequestedWidthPt ( ) const
inherited

◆ getSampleDescription()

SampleDescription Ogre::Window::getSampleDescription ( ) const
inherited

◆ getStencilBuffer()

TextureGpu* Ogre::Window::getStencilBuffer ( ) const
inherited

◆ getTexture()

TextureGpu* Ogre::Window::getTexture ( ) const
inherited

WARNING: Attempting to change the TextureGpu (e.g.

setResolution, setPixelFormat) is undefined behavior

◆ getTitle()

const String& Ogre::Window::getTitle ( ) const
inherited

◆ getViewPointToPixelScale()

virtual float Ogre::Window::getViewPointToPixelScale ( ) const
inlinevirtualinherited

Many windowing systems that support HiDPI displays use special points to specify size of the windows and controls, so that windows and controls with hardcoded sizes does not become too small on HiDPI displays.

Such points have constant density ~ 100 points per inch (probably 96 on Windows and 72 on Mac), that is independent of pixel density of real display, and are used through the all windowing system.

Sometimes, such view points are choosen bigger for output devices that are viewed from larger distances, like 30" TV comparing to 30" monitor, therefore maintaining constant points angular density rather than constant linear density.

In any case, all such windowing system provides the way to convert such view points to pixels, be it DisplayProperties::LogicalDpi on WinRT or backingScaleFactor on MacOSX. We use pixels consistently through the Ogre, but window/view management functions takes view points for convenience, as does the rest of windowing system. Such parameters are named using xxxxPt pattern, and should not be mixed with pixels without being converted using getViewPointToPixelScale() function.

Sometimes such scale factor can change on-the-fly, for example if window is dragged to monitor with different DPI. In such situation, window size in view points is usually preserved by windowing system, and Ogre should adjust pixel size of RenderWindow.

Reimplemented in Ogre::CocoaWindow, and Ogre::MetalWindow.

◆ getVSync()

bool Ogre::Window::getVSync ( ) const
inherited

◆ getVSyncInterval()

uint32 Ogre::Window::getVSyncInterval ( ) const
inherited

◆ getWidth()

uint32 Ogre::Window::getWidth ( ) const
inherited

◆ isClosed() [1/2]

virtual bool Ogre::EGLWindow::isClosed ( ) const
virtualinherited

RenderWindow::isClosed

RenderWindow::isClosed

Implements Ogre::Window.

◆ isClosed() [2/2]

bool Ogre::EGLWindow::isClosed ( ) const
virtualinherited

Indicates whether the window has been closed by the user.

Implements Ogre::Window.

◆ isFocused()

bool Ogre::Window::isFocused ( ) const
inherited

◆ isFullscreen()

bool Ogre::Window::isFullscreen ( ) const
inherited

Returns true if we are currently in fullscreen mode.

◆ isHidden()

bool Ogre::EGLWindow::isHidden ( ) const
inlinevirtualinherited

RenderWindow::isHidden

RenderWindow::isHidden

Implements Ogre::Window.

◆ isMultisample()

bool Ogre::Window::isMultisample ( ) const
inherited

◆ isPrimary()

bool Ogre::Window::isPrimary ( ) const
inherited

◆ isVisible() [1/2]

bool Ogre::EGLWindow::isVisible ( ) const
virtualinherited

RenderWindow::isVisible

RenderWindow::isVisible

Implements Ogre::Window.

◆ isVisible() [2/2]

bool Ogre::EGLWindow::isVisible ( ) const
virtualinherited

Implements Ogre::Window.

◆ operator delete() [1/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr)
inlineinherited

◆ operator delete() [2/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr,
const char *  ,
int  ,
const char *   
)
inlineinherited

◆ operator delete() [3/3]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete ( void *  ptr,
void *   
)
inlineinherited

◆ operator delete[]() [1/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void *  ptr)
inlineinherited

◆ operator delete[]() [2/2]

template<class Alloc >
void Ogre::AllocatedObject< Alloc >::operator delete[] ( void *  ptr,
const char *  ,
int  ,
const char *   
)
inlineinherited

◆ operator new() [1/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz)
inlineinherited

◆ operator new() [2/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
const char *  file,
int  line,
const char *  func 
)
inlineinherited

operator new, with debug line info

◆ operator new() [3/3]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new ( size_t  sz,
void *  ptr 
)
inlineinherited

placement operator new

◆ operator new[]() [1/2]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz)
inlineinherited

◆ operator new[]() [2/2]

template<class Alloc >
void* Ogre::AllocatedObject< Alloc >::operator new[] ( size_t  sz,
const char *  file,
int  line,
const char *  func 
)
inlineinherited

array operator new, with debug line info

◆ reposition()

virtual void Ogre::EGLWindow::reposition ( int32  left,
int32  top 
)
virtualinherited

Implements Ogre::Window.

◆ requestFullscreenSwitch()

void Ogre::EGLWindow::requestFullscreenSwitch ( bool  goFullscreen,
bool  borderless,
uint32  monitorIdx,
uint32  widthPt,
uint32  heightPt,
uint32  frequencyNumerator,
uint32  frequencyDenominator 
)
virtualinherited

Requests to toggle between fullscreen and windowed mode.

Remarks
Use wantsToGoFullscreen & wantsToGoWindowed to know what you've requested. Same remarks as requestResolution apply: If we request to go fullscreen, wantsToGoFullscreen will return true. But if get word from OS saying we stay in windowed mode, wantsToGoFullscreen will start returning false.
Parameters
goFullscreenTrue to go fullscreen, false to go windowed mode.
borderlessWhether to be borderless. Only useful if goFullscreen == false;
monitorIdx
widthNew width. Leave 0 if you don't care.
heightNew height. Leave 0 if you don't care.
frequencyNumeratorNew frequency (fullscreen only). Leave 0 if you don't care.
frequencyDenominatorNew frequency (fullscreen only). Leave 0 if you don't care.

Reimplemented from Ogre::Window.

◆ requestResolution()

void Ogre::EGLWindow::requestResolution ( uint32  width,
uint32  height 
)
virtualinherited

RenderWindow::resize

RenderWindow::resize

Reimplemented from Ogre::Window.

◆ requiresTextureFlipping() [1/2]

bool Ogre::EGLWindow::requiresTextureFlipping ( ) const
inlineinherited

◆ requiresTextureFlipping() [2/2]

bool Ogre::EGLWindow::requiresTextureFlipping ( ) const
inherited

◆ setBorderless()

virtual void Ogre::Window::setBorderless ( bool  borderless)
virtualinherited

◆ setFocused()

virtual void Ogre::Window::setFocused ( bool  focused)
virtualinherited

◆ setFsaa()

virtual void Ogre::Window::setFsaa ( const String fsaa)
inlinevirtualinherited

Set the FSAA mode to be used if hardware support it.

This option will be ignored if the hardware does not support it or setting can not be changed on the fly on per-target level.

Parameters
fsaaRequesed FSAA mode (
See also
Root::createRenderWindow)

Reimplemented in Ogre::D3D11WindowSwapChainBased.

◆ setFullscreen()

virtual void Ogre::EGLWindow::setFullscreen ( bool  fullscreen,
uint  width,
uint  height 
)
virtualinherited

Reimplemented in Ogre::X11EGLWindow.

◆ setHidden()

void Ogre::EGLWindow::setHidden ( bool  hidden)
virtualinherited

RenderWindow::setHidden

RenderWindow::setHidden

Implements Ogre::Window.

◆ setTitle()

virtual void Ogre::Window::setTitle ( const String title)
virtualinherited

◆ setVisible()

void Ogre::EGLWindow::setVisible ( bool  visible)
inherited

◆ setVSync()

virtual void Ogre::EGLWindow::setVSync ( bool  vSync,
uint32  vSyncInterval 
)
virtualinherited

Turns VSync on/off.

Parameters
vSync
vSyncIntervalWhen true, specifies how often the screen should be updated. e.g. at 60hz: vSyncInterval = 1 then update at 60hz vSyncInterval = 2 then update at 30hz vSyncInterval = 3 then update at 15hz vSyncInterval = 4 then update at 7.5hz

If the 31st bit is set, i.e. 0x80000000, then lowest latency mode, aka mailbox, will be used (which doesn't limit the framerate)

Reimplemented from Ogre::Window.

◆ swapBuffers()

virtual void Ogre::EmscriptenEGLWindow::swapBuffers ( )
virtual

RenderWindow::swapBuffers

RenderWindow::swapBuffers

Reimplemented from Ogre::EGLWindow.

◆ wantsToGoFullscreen()

bool Ogre::Window::wantsToGoFullscreen ( ) const
inherited

Returns true if we are in windowed mode right now, but want to go fullscreen.

◆ wantsToGoWindowed()

bool Ogre::Window::wantsToGoWindowed ( ) const
inherited

Returns true if we are in fullscreen mode right now, but want to go windowed mode.


The documentation for this class was generated from the following file: