cocos2d-x  2.2.3-gd2.113-rev1ec524e
Loading...
Searching...
No Matches
CCEGLView.h File Reference
#include "CCStdC.h"
#include "platform/CCCommon.h"
#include "cocoa/CCGeometry.h"
#include "platform/CCEGLViewProtocol.h"
#include "robtop/glfw/glfw3.h"
Include dependency graph for CCEGLView.h:
This graph shows which files directly or indirectly include this file:

Classes

class  CCEGLView
 

Namespaces

namespace  cocos2d
 

Typedefs

typedef LRESULT(* CUSTOM_WND_PROC) (UINT message, WPARAM wParam, LPARAM lParam, BOOL *pProcessed)
 
typedef void(* LPFN_ACCELEROMETER_KEYHOOK) (UINT message, WPARAM wParam, LPARAM lParam)
 

Functions

 CCEGLView ()
 
virtual bool isOpenGLReady ()
 
virtual void end ()
 
virtual void swapBuffers ()
 
virtual void setFrameSize (float width, float height)
 
virtual void setIMEKeyboardState (bool bOpen)
 
void setMenuResource (LPCWSTR menu)
 
void setWndProc (CUSTOM_WND_PROC proc)
 
bool initGL ()
 
void destroyGL ()
 
void setHWnd (HWND hWnd)
 
void setFrameZoomFactor (float fZoomFactor)
 
float getFrameZoomFactor ()
 
void setAccelerometerKeyHook (LPFN_ACCELEROMETER_KEYHOOK lpfnAccelerometerKeyHook)
 
virtual void setViewPortInPoints (float x, float y, float w, float h)
 
virtual void setScissorInPoints (float x, float y, float w, float h)
 
void resizeWindow (int width, int height)
 
void centerWindow ()
 
void showCursor (bool state)
 
CCPoint getMousePosition ()
 
void toggleFullScreen (bool fullscreen)
 
GLFWwindow * getWindow (void) const
 
void onGLFWCharCallback (GLFWwindow *window, unsigned int entered)
 
void onGLFWCursorEnterFunCallback (GLFWwindow *window, int entered)
 
void onGLFWDeviceChangeFunCallback (GLFWwindow *window)
 
void onGLFWError (int code, const char *description)
 
void onGLFWframebuffersize (GLFWwindow *window, int width, int height)
 
void onGLFWMouseMoveCallBack (GLFWwindow *window, double x, double y)
 
void onGLFWMouseCallBack (GLFWwindow *window, int button, int action, int mods)
 
void onGLFWKeyCallback (GLFWwindow *window, int key, int scancode, int action, int mods)
 
void onGLFWMouseScrollCallback (GLFWwindow *window, double xoffset, double yoffset)
 
void onGLFWWindowIconifyFunCallback (GLFWwindow *window, int iconified)
 
void onGLFWWindowPosCallback (GLFWwindow *window, int x, int y)
 
void onGLFWWindowSizeFunCallback (GLFWwindow *window, int width, int height)
 

Variables

bool m_bCaptured
 
bool m_bSupportTouch
 
float m_fFrameZoomFactor
 
bool m_bInRetinaMonitor
 
bool m_bRetinaEnabled
 
int m_nRetinaFactor
 
bool m_bCursorHidden
 
GLFWwindow * m_pMainWindow
 
GLFWmonitor * m_pPrimaryMonitor
 
CCSize m_obWindowedSize
 
float m_fMouseX
 
float m_fMouseY
 
bool m_bIsFullscreen
 
bool m_bShouldHideCursor
 
bool m_bShouldCallGLFinish
 

Typedef Documentation

◆ LPFN_ACCELEROMETER_KEYHOOK

typedef void(* LPFN_ACCELEROMETER_KEYHOOK) (UINT message, WPARAM wParam, LPARAM lParam)

Function Documentation

◆ CCEGLView()

CCEGLView ( )

◆ centerWindow()

void centerWindow ( )
Remarks
Added by RobTop. See RT_ADD for more info.

◆ destroyGL()

void destroyGL ( )

◆ end()

virtual void end ( )
virtual

◆ getFrameZoomFactor()

float getFrameZoomFactor ( )

◆ getMousePosition()

CCPoint getMousePosition ( )
inline
Remarks
Added by RobTop. See RT_ADD for more info.

◆ getWindow()

GLFWwindow * getWindow ( void  ) const
Remarks
Added by RobTop. See RT_ADD for more info.

◆ initGL()

bool initGL ( )

◆ isOpenGLReady()

virtual bool isOpenGLReady ( )
virtual

◆ onGLFWCharCallback()

void onGLFWCharCallback ( GLFWwindow *  window,
unsigned int  entered 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWCursorEnterFunCallback()

void onGLFWCursorEnterFunCallback ( GLFWwindow *  window,
int  entered 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWDeviceChangeFunCallback()

void onGLFWDeviceChangeFunCallback ( GLFWwindow *  window)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWError()

void onGLFWError ( int  code,
const char *  description 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWframebuffersize()

void onGLFWframebuffersize ( GLFWwindow *  window,
int  width,
int  height 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWKeyCallback()

void onGLFWKeyCallback ( GLFWwindow *  window,
int  key,
int  scancode,
int  action,
int  mods 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWMouseCallBack()

void onGLFWMouseCallBack ( GLFWwindow *  window,
int  button,
int  action,
int  mods 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWMouseMoveCallBack()

void onGLFWMouseMoveCallBack ( GLFWwindow *  window,
double  x,
double  y 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWMouseScrollCallback()

void onGLFWMouseScrollCallback ( GLFWwindow *  window,
double  xoffset,
double  yoffset 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWWindowIconifyFunCallback()

void onGLFWWindowIconifyFunCallback ( GLFWwindow *  window,
int  iconified 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWWindowPosCallback()

void onGLFWWindowPosCallback ( GLFWwindow *  window,
int  x,
int  y 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ onGLFWWindowSizeFunCallback()

void onGLFWWindowSizeFunCallback ( GLFWwindow *  window,
int  width,
int  height 
)
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ resizeWindow()

void resizeWindow ( int  width,
int  height 
)
Remarks
Added by RobTop. See RT_ADD for more info.

◆ setAccelerometerKeyHook()

void setAccelerometerKeyHook ( LPFN_ACCELEROMETER_KEYHOOK  lpfnAccelerometerKeyHook)

◆ setFrameSize()

virtual void setFrameSize ( float  width,
float  height 
)
virtual

◆ setFrameZoomFactor()

void setFrameZoomFactor ( float  fZoomFactor)

◆ setHWnd()

void setHWnd ( HWND  hWnd)

◆ setIMEKeyboardState()

virtual void setIMEKeyboardState ( bool  bOpen)
virtual

◆ setMenuResource()

void setMenuResource ( LPCWSTR  menu)

◆ setScissorInPoints()

virtual void setScissorInPoints ( float  x,
float  y,
float  w,
float  h 
)
virtual

◆ setViewPortInPoints()

virtual void setViewPortInPoints ( float  x,
float  y,
float  w,
float  h 
)
virtual

◆ setWndProc()

void setWndProc ( CUSTOM_WND_PROC  proc)

◆ showCursor()

void showCursor ( bool  state)
Remarks
Added by RobTop. See RT_ADD for more info.

◆ swapBuffers()

virtual void swapBuffers ( )
virtual

◆ toggleFullScreen()

void toggleFullScreen ( bool  fullscreen)
Remarks
Added by RobTop. See RT_ADD for more info.

Variable Documentation

◆ m_bCaptured

bool m_bCaptured
protected

◆ m_bCursorHidden

bool m_bCursorHidden
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bInRetinaMonitor

bool m_bInRetinaMonitor
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bIsFullscreen

bool m_bIsFullscreen
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bRetinaEnabled

bool m_bRetinaEnabled
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bShouldCallGLFinish

bool m_bShouldCallGLFinish
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bShouldHideCursor

bool m_bShouldHideCursor
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_bSupportTouch

bool m_bSupportTouch
protected

◆ m_fFrameZoomFactor

float m_fFrameZoomFactor
protected

◆ m_fMouseX

float m_fMouseX
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_fMouseY

float m_fMouseY
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_nRetinaFactor

int m_nRetinaFactor
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_obWindowedSize

CCSize m_obWindowedSize
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_pMainWindow

GLFWwindow* m_pMainWindow
protected
Remarks
Added by RobTop. See RT_ADD for more info.

◆ m_pPrimaryMonitor

GLFWmonitor* m_pPrimaryMonitor
protected
Remarks
Added by RobTop. See RT_ADD for more info.