OGRE 2.3.3
Object-Oriented Graphics Rendering Engine
Loading...
Searching...
No Matches
Ogre::CocoaWindow Class Reference

#include <OgreOSXCocoaWindow.h>

+ Inheritance diagram for Ogre::CocoaWindow:

Public Member Functions

 CocoaWindow (const String &title, uint32 widthPt, uint32 heightPt, bool fullscreenMode)
 
virtual ~CocoaWindow ()
 
void _initialize (TextureGpuManager *textureManager) override
 Window::_initialize
 
void _setPrimary (void)
 Indicates that this is the primary window.
 
void _setVisible (bool visible) override
 Window::_setVisible
 
void create (const String &name, unsigned int widthPt, unsigned int heightPt, bool fullScreen, const NameValuePairList *miscParams)
 
void destroy (void) override
 Window::destroy
 
bool getBorderless (void) const
 
void getCustomAttribute (IdString name, void *pData)
 Window::getCustomAttribute
 
TextureGpugetDepthBuffer (void) const
 
uint32 getFrequencyDenominator (void) const
 
uint32 getFrequencyNumerator (void) const
 
uint32 getHeight (void) 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.
 
PixelFormatGpu getPixelFormat (void) const
 
uint32 getRequestedHeightPt (void) const
 
uint32 getRequestedWidthPt (void) const
 
SampleDescription getSampleDescription (void) const
 
TextureGpugetStencilBuffer (void) const
 
TextureGpugetTexture (void) const
 WARNING: Attempting to change the TextureGpu (e.g.
 
const StringgetTitle (void) const
 
float getViewPointToPixelScale () const override
 Window::setVSync
 
bool getVSync (void) const
 
uint32 getVSyncInterval (void) const
 
uint32 getWidth (void) const
 
bool isActive () const
 
bool isClosed (void) const override
 Window::isClosed
 
bool isDeactivatedOnFocusChange () const
 
bool isFocused (void) const
 
bool isFullscreen (void) const
 Returns true if we are currently in fullscreen mode.
 
bool isHidden (void) const override
 Window::isHidden
 
bool isMultisample (void) const
 
bool isPrimary (void) const
 
bool isVisible (void) const override
 Window::isVisible
 
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 *)
 
voidoperator new (size_t sz)
 
voidoperator new (size_t sz, const char *file, int line, const char *func)
 operator new, with debug line info
 
voidoperator new (size_t sz, void *ptr)
 placement operator new
 
voidoperator new[] (size_t sz)
 
voidoperator new[] (size_t sz, const char *file, int line, const char *func)
 array operator new, with debug line info
 
void reposition (int leftPt, int topPt) override
 Window::reposition
 
virtual void requestFullscreenSwitch (bool goFullscreen, bool borderless, uint32 monitorIdx, uint32 widthPt, uint32 heightPt, uint32 frequencyNumerator, uint32 frequencyDenominator)
 Requests to toggle between fullscreen and windowed mode.
 
virtual void requestResolution (uint32 widthPt, uint32 heightPt)
 Requests a change in resolution.
 
void setActive (bool value)
 
virtual void setBorderless (bool borderless)
 
void setDeactivateOnFocusChange (bool deactivate)
 
virtual void setFocused (bool focused)
 
virtual void setFsaa (const String &fsaa)
 Set the FSAA mode to be used if hardware support it.
 
void setHidden (bool hidden) override
 RenderWindow::setHidden
 
virtual void setTitle (const String &title)
 
void setVisible (bool visible)
 
virtual void setVSync (bool vSync, uint32 vSyncInterval)
 Turns VSync on/off.
 
void swapBuffers () override
 Window::swapBuffers
 
bool wantsToGoFullscreen (void) const
 Returns true if we are in windowed mode right now, but want to go fullscreen.
 
bool wantsToGoWindowed (void) const
 Returns true if we are in fullscreen mode right now, but want to go windowed mode.
 
void windowMovedOrResized (void) override
 Window::windowMovedOrResized
 

Constructor & Destructor Documentation

◆ CocoaWindow()

Ogre::CocoaWindow::CocoaWindow ( const String title,
uint32  widthPt,
uint32  heightPt,
bool  fullscreenMode 
)

◆ ~CocoaWindow()

virtual Ogre::CocoaWindow::~CocoaWindow ( )
virtual

Member Function Documentation

◆ _initialize()

void Ogre::CocoaWindow::_initialize ( TextureGpuManager textureManager)
overridevirtual

◆ _setPrimary()

void Ogre::Window::_setPrimary ( void  )
inherited

Indicates that this is the primary window.

Only to be called by Ogre::Root

◆ _setVisible()

void Ogre::CocoaWindow::_setVisible ( bool  visible)
overridevirtual

◆ create()

void Ogre::CocoaWindow::create ( const String name,
unsigned int  widthPt,
unsigned int  heightPt,
bool  fullScreen,
const NameValuePairList miscParams 
)

◆ destroy()

void Ogre::CocoaWindow::destroy ( void  )
overridevirtual

◆ getBorderless()

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

◆ getCustomAttribute()

void Ogre::CocoaWindow::getCustomAttribute ( IdString  name,
void pData 
)
virtual

Window::getCustomAttribute

Window::getCustomAttribute

Remarks
Get custom attribute; the following attributes are valid: GLCONTEXT WINDOW VIEW NSOPENGLCONTEXT NSOPENGLPIXELFORMAT

Reimplemented from Ogre::Window.

◆ getDepthBuffer()

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

◆ getFrequencyDenominator()

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

◆ getFrequencyNumerator()

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

◆ getHeight()

uint32 Ogre::Window::getHeight ( void  ) 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 ( void  ) const
inherited

◆ getRequestedHeightPt()

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

◆ getRequestedWidthPt()

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

◆ getSampleDescription()

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

◆ getStencilBuffer()

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

◆ getTexture()

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

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

setResolution, setPixelFormat) is undefined behavior

◆ getTitle()

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

◆ getViewPointToPixelScale()

float Ogre::CocoaWindow::getViewPointToPixelScale ( ) const
overridevirtual

◆ getVSync()

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

◆ getVSyncInterval()

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

◆ getWidth()

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

◆ isActive()

bool Ogre::CocoaWindow::isActive ( ) const

◆ isClosed()

bool Ogre::CocoaWindow::isClosed ( void  ) const
overridevirtual

◆ isDeactivatedOnFocusChange()

bool Ogre::CocoaWindow::isDeactivatedOnFocusChange ( ) const

◆ isFocused()

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

◆ isFullscreen()

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

Returns true if we are currently in fullscreen mode.

◆ isHidden()

bool Ogre::CocoaWindow::isHidden ( void  ) const
inlineoverridevirtual

◆ isMultisample()

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

◆ isPrimary()

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

◆ isVisible()

bool Ogre::CocoaWindow::isVisible ( void  ) const
overridevirtual

◆ 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()

void Ogre::CocoaWindow::reposition ( int  leftPt,
int  topPt 
)
overridevirtual

◆ requestFullscreenSwitch()

virtual void Ogre::Window::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 in Ogre::EGLWindow, Ogre::EglPBufferWindow, Ogre::GLXWindow, Ogre::Win32Window, Ogre::NULLWindow, Ogre::VulkanWin32Window, and Ogre::VulkanXcbWindow.

◆ requestResolution()

virtual void Ogre::Window::requestResolution ( uint32  widthPt,
uint32  heightPt 
)
virtualinherited

Requests a change in resolution.

Change is not immediate. Use getRequestedWidthPt & getRequestedHeightPt if you need to know what you've requested, but beware you may not get that resolution, and once we get word from the OS, getRequested{Width/Height}Pt will change again so that getWidth == getRequestedWidthPt * getViewPointToPixelScale.

Reimplemented in Ogre::EGLWindow, Ogre::EglPBufferWindow, Ogre::GLXWindow, Ogre::Win32Window, Ogre::MetalWindow, Ogre::NULLWindow, Ogre::VulkanAndroidWindow, Ogre::VulkanWin32Window, and Ogre::VulkanXcbWindow.

◆ setActive()

void Ogre::CocoaWindow::setActive ( bool  value)

◆ setBorderless()

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

◆ setDeactivateOnFocusChange()

void Ogre::CocoaWindow::setDeactivateOnFocusChange ( bool  deactivate)

◆ 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.

◆ setHidden()

void Ogre::CocoaWindow::setHidden ( bool  hidden)
overridevirtual

◆ setTitle()

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

◆ setVisible()

void Ogre::CocoaWindow::setVisible ( bool  visible)

◆ setVSync()

virtual void Ogre::Window::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 in Ogre::EGLWindow, Ogre::EglPBufferWindow, Ogre::GLXWindow, Ogre::Win32Window, and Ogre::VulkanWindowSwapChainBased.

◆ swapBuffers()

void Ogre::CocoaWindow::swapBuffers ( )
overridevirtual

◆ wantsToGoFullscreen()

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

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

◆ wantsToGoWindowed()

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

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

◆ windowMovedOrResized()

void Ogre::CocoaWindow::windowMovedOrResized ( void  )
overridevirtual

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