메소드 | 설명 | |
---|---|---|
Dispose ( ) : void |
Disposes of the GameWindow, releasing all resources consumed by it.
|
|
Exit ( ) : void |
Closes the GameWindow. Equivalent to NativeWindow.Close method. Override if you are not using GameWindow.Run(). If you override this method, place a call to base.Exit(), to ensure proper OpenTK shutdown. |
|
GameWindow ( ) : System |
Constructs a new GameWindow with sensible default attributes.
|
|
GameWindow ( int width, int height ) : System |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode ) : System |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title ) : System |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options ) : System |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
Constructs a new GameWindow with the specified attributes.
|
|
GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
Constructs a new GameWindow with the specified attributes.
|
|
MakeCurrent ( ) : void |
Makes the GraphicsContext current on the calling thread.
|
|
Run ( ) : void |
Enters the game loop of the GameWindow using the maximum update rate.
|
|
Run ( double updateRate ) : void |
Enters the game loop of the GameWindow using the specified update rate. maximum possible render frequency.
|
|
Run ( double updates_per_second, double frames_per_second ) : void |
Enters the game loop of the GameWindow updating and rendering at the specified frequency. When overriding the default game loop you should call ProcessEvents() to ensure that your GameWindow responds to operating system events. Once ProcessEvents() returns, it is time to call update and render the next frame. |
|
SwapBuffers ( ) : void |
Swaps the front and back buffer, presenting the rendered scene to the user.
|
메소드 | 설명 | |
---|---|---|
Dispose ( bool manual ) : void |
Override to add custom cleanup logic.
|
|
OnClosing ( System e ) : void |
Called when the NativeWindow is about to close.
|
|
OnLoad ( |
Called after an OpenGL context has been established, but before entering the main loop.
|
|
OnRenderFrame ( FrameEventArgs e ) : void |
Called when the frame is rendered. Subscribe to the RenderFrame event instead of overriding this method. |
|
OnResize ( |
Called when this window is resized. You will typically wish to update your viewport whenever the window is resized. See the OpenTK.Graphics.OpenGL.GL.Viewport(int, int, int, int) method. |
|
OnUnload ( |
Called after GameWindow.Exit was called, but before destroying the OpenGL context.
|
|
OnUpdateFrame ( FrameEventArgs e ) : void |
Called when the frame is updated. Subscribe to the UpdateFrame event instead of overriding this method. |
|
OnWindowInfoChanged ( |
Called when the WindowInfo for this GameWindow has changed.
|
메소드 | 설명 | |
---|---|---|
DispatchUpdateAndRenderFrame ( object sender, |
||
OnLoadInternal ( |
||
OnRenderFrameInternal ( FrameEventArgs e ) : void | ||
OnUnloadInternal ( |
||
OnUpdateFrameInternal ( FrameEventArgs e ) : void | ||
OnWindowInfoChangedInternal ( |
||
RaiseRenderFrame ( Stopwatch render_watch, double &next_render, FrameEventArgs render_args ) : void | ||
RaiseUpdateFrame ( Stopwatch update_watch, double &next_update, FrameEventArgs update_args ) : void |
protected Dispose ( bool manual ) : void | ||
manual | bool | True, if this method was called by the application; false if this was called by the finalizer thread. |
리턴 | void |
public GameWindow ( int width, int height ) : System | ||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode ) : System | ||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title ) : System | ||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
title | string | The title of the GameWindow. |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options ) : System | ||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
title | string | The title of the GameWindow. |
options | GameWindowFlags | GameWindow options regarding window appearance and behavior. |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
title | string | The title of the GameWindow. |
options | GameWindowFlags | GameWindow options regarding window appearance and behavior. |
device | The OpenTK.Graphics.DisplayDevice to construct the GameWindow in. | |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
title | string | The title of the GameWindow. |
options | GameWindowFlags | GameWindow options regarding window appearance and behavior. |
device | The OpenTK.Graphics.DisplayDevice to construct the GameWindow in. | |
major | int | The major version for the OpenGL GraphicsContext. |
minor | int | The minor version for the OpenGL GraphicsContext. |
flags | GraphicsContextFlags | The GraphicsContextFlags version for the OpenGL GraphicsContext. |
리턴 | System |
public GameWindow ( int width, int height, OpenTK.Graphics.GraphicsMode mode, string title, GameWindowFlags options, |
||
width | int | The width of the GameWindow in pixels. |
height | int | The height of the GameWindow in pixels. |
mode | OpenTK.Graphics.GraphicsMode | The OpenTK.Graphics.GraphicsMode of the GameWindow. |
title | string | The title of the GameWindow. |
options | GameWindowFlags | GameWindow options regarding window appearance and behavior. |
device | The OpenTK.Graphics.DisplayDevice to construct the GameWindow in. | |
major | int | The major version for the OpenGL GraphicsContext. |
minor | int | The minor version for the OpenGL GraphicsContext. |
flags | GraphicsContextFlags | The GraphicsContextFlags version for the OpenGL GraphicsContext. |
sharedContext | IGraphicsContext | An IGraphicsContext to share resources with. |
리턴 | System |
protected OnClosing ( System e ) : void | ||
e | System |
/// The |
리턴 | void |
protected OnRenderFrame ( FrameEventArgs e ) : void | ||
e | FrameEventArgs | Contains information necessary for frame rendering. |
리턴 | void |
protected OnUpdateFrame ( FrameEventArgs e ) : void | ||
e | FrameEventArgs | Contains information necessary for frame updating. |
리턴 | void |
protected OnWindowInfoChanged ( |
||
e | Not used. | |
리턴 | void |
public Run ( double updates_per_second, double frames_per_second ) : void | ||
updates_per_second | double | The frequency of UpdateFrame events. |
frames_per_second | double | The frequency of RenderFrame events. |
리턴 | void |