C# 클래스 OpenTK.GLControl

OpenGL-aware WinForms control. The WinForms designer will always call the default constructor. Inherit from this class and call one of its specialized constructors to enable antialiasing or custom GraphicsModes.
상속: System.Windows.Forms.UserControl
파일 보기 프로젝트 열기: prepare/HTML-Renderer 1 사용 예제들

Private Properties

프로퍼티 타입 설명
GLControl System
GrabScreenshot System.Drawing.Bitmap
InitializeComponent void
ValidateState void

공개 메소드들

메소드 설명
GLControl ( OpenTK.Graphics.GraphicsMode mode ) : System

Constructs a new GLControl with the specified GraphicsMode.

GLControl ( OpenTK.Graphics.GraphicsMode mode, int major, int minor, GraphicsContextFlags flags ) : System

Constructs a new GLControl with the specified GraphicsMode.

GetEglDisplay ( ) : IntPtr
GetEglSurface ( ) : IntPtr
MakeCurrent ( ) : void

Makes the underlying this GLControl current in the calling thread. All OpenGL commands issued are hereafter interpreted by this GLControl.

SwapBuffers ( ) : void

Swaps the front and back buffers, presenting the rendered scene to the screen.

보호된 메소드들

메소드 설명
ChildCtorOnlyResetGraphicMode ( OpenTK.Graphics.GraphicsMode mode ) : void
Dispose ( bool disposing ) : void

Clean up any resources being used.

OnHandleCreated ( EventArgs e ) : void

Raises the HandleCreated event.

OnHandleDestroyed ( EventArgs e ) : void

Raises the HandleDestroyed event.

OnPaint ( PaintEventArgs e ) : void

Raises the System.Windows.Forms.Control.Paint event.

OnParentChanged ( EventArgs e ) : void

Raises the ParentChanged event.

OnResize ( EventArgs e ) : void

Raises the Resize event. Note: this method may be called before the OpenGL context is ready. Check that IsHandleCreated is true before using any OpenGL methods.

비공개 메소드들

메소드 설명
GLControl ( ) : System
GrabScreenshot ( ) : Bitmap
InitializeComponent ( ) : void

Required method for Designer support - do not modify the contents of this method with the code editor.

ValidateState ( ) : void

메소드 상세

ChildCtorOnlyResetGraphicMode() 보호된 메소드

protected ChildCtorOnlyResetGraphicMode ( OpenTK.Graphics.GraphicsMode mode ) : void
mode OpenTK.Graphics.GraphicsMode
리턴 void

Dispose() 보호된 메소드

Clean up any resources being used.
protected Dispose ( bool disposing ) : void
disposing bool true if managed resources should be disposed; otherwise, false.
리턴 void

GLControl() 공개 메소드

Constructs a new GLControl with the specified GraphicsMode.
public GLControl ( OpenTK.Graphics.GraphicsMode mode ) : System
mode OpenTK.Graphics.GraphicsMode The OpenTK.Graphics.GraphicsMode of the control.
리턴 System

GLControl() 공개 메소드

Constructs a new GLControl with the specified GraphicsMode.
public GLControl ( OpenTK.Graphics.GraphicsMode mode, int major, int minor, GraphicsContextFlags flags ) : System
mode OpenTK.Graphics.GraphicsMode The OpenTK.Graphics.GraphicsMode of the control.
major int The major version for the OpenGL GraphicsContext.
minor int The minor version for the OpenGL GraphicsContext.
flags GraphicsContextFlags The GraphicsContextFlags for the OpenGL GraphicsContext.
리턴 System

GetEglDisplay() 공개 메소드

public GetEglDisplay ( ) : IntPtr
리턴 System.IntPtr

GetEglSurface() 공개 메소드

public GetEglSurface ( ) : IntPtr
리턴 System.IntPtr

MakeCurrent() 공개 메소드

Makes the underlying this GLControl current in the calling thread. All OpenGL commands issued are hereafter interpreted by this GLControl.
public MakeCurrent ( ) : void
리턴 void

OnHandleCreated() 보호된 메소드

Raises the HandleCreated event.
protected OnHandleCreated ( EventArgs e ) : void
e System.EventArgs Not used.
리턴 void

OnHandleDestroyed() 보호된 메소드

Raises the HandleDestroyed event.
protected OnHandleDestroyed ( EventArgs e ) : void
e System.EventArgs Not used.
리턴 void

OnPaint() 보호된 메소드

Raises the System.Windows.Forms.Control.Paint event.
protected OnPaint ( PaintEventArgs e ) : void
e PaintEventArgs A System.Windows.Forms.PaintEventArgs that contains the event data.
리턴 void

OnParentChanged() 보호된 메소드

Raises the ParentChanged event.
protected OnParentChanged ( EventArgs e ) : void
e System.EventArgs A System.EventArgs that contains the event data.
리턴 void

OnResize() 보호된 메소드

Raises the Resize event. Note: this method may be called before the OpenGL context is ready. Check that IsHandleCreated is true before using any OpenGL methods.
protected OnResize ( EventArgs e ) : void
e System.EventArgs A System.EventArgs that contains the event data.
리턴 void

SwapBuffers() 공개 메소드

Swaps the front and back buffers, presenting the rendered scene to the screen.
public SwapBuffers ( ) : void
리턴 void