viva,
Eu tenho que fazer um trabalho visual basic .net com opengl, mas só que não sei por onde começar. Alquém pode ajudar-me?
Algum tutorial em português?
Opengl Vb .net
Started By Forgon, 22/06/2009, 20:55
1 reply to this topic
#1
Posted 22/06/2009, 20:55
#2
Posted 12/08/2009, 09:58
http://ondotnet.com/.../28/opengl.html
http://64.233.163.13...Hy3mIGDd2hm7Q7w
No VS.Net cliqe em File->New->Projec
Escolha Visual Basic Application and Windows Application
no form1
Add Reference
csgl.dll
OPENGL32.DLL
http://64.233.163.13...Hy3mIGDd2hm7Q7w
No VS.Net cliqe em File->New->Projec
Escolha Visual Basic Application and Windows Application
no form1
Public Class Form1 Inherits System.Windows.Forms.Form Windows Form Designer generated code End Class
Add Reference
csgl.dll
OPENGL32.DLL
Public Class Form1 Inherits System.Windows.Forms.Form #Region " Windows Form Designer generated code " Public Sub New() MyBase.New() 'This call is required by the Windows Form Designer. InitializeComponent() 'Add any initialization after the 'InitializeComponent() call End Sub 'Form overrides dispose to clean up the component list. Protected Overloads Overrides Sub Dispose _ (ByVal disposing As Boolean) If disposing Then If Not (components Is Nothing) Then components.Dispose() End If End If MyBase.Dispose(disposing) End Sub 'Required by the Windows Form Designer Private components As System.ComponentModel.IContainer 'NOTE: The following procedure is required by the 'Windows Form Designer It can be modified using the 'Windows Form Designer. Do not modify it using the 'code editor. <System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent() components = New System.ComponentModel.Container() Me.Text = "Form1" End Sub #End Region End Class
Imports CsGL.OpenGL Public Class Form1 Inherits System.Windows.Forms.Form Private view As myOpenGL.myView Private thrOpenGL
#Region " Windows Form Designer generated code " Public Sub New() MyBase.New() 'This call is required by the Windows Form Designer. InitializeComponent() 'Add any initialization after the InitializeComponent() call Me.view = New myOpenGL.myView() Me.view.Parent = Me Me.view.Dock = DockStyle.Fill Me.thrOpenGL = New Threading.Thread(AddressOf OpenGL_Start) Me.thrOpenGL.Start() End Sub #End Region
Private Sub OpenGL_Start() While 1 = 1 Me.view.Refresh() End While End Sub
'Form overrides dispose to clean up the component list. Protected Overloads Overrides Sub Dispose(ByVal disposing As Boolean) If disposing Then If Not (components Is Nothing) Then components.Dispose() End If End If MyBase.Dispose(disposing) Me.thrOpenGL.Abort() End Sub
Namespace myOpenGL Public Class myView Inherits OpenGLControl
$ awk '/#define/ { print $2 " = &H" substr($3, 3) }' gl.h > glconst $ awk '/#define/ { print $2 " = &H" substr($3, 3) }' glu.h > gluconst
rivate Enum GLConstants GL_COLOR_BUFFER_BIT = &H4000 GL_DEPTH_BUFFER_BIT = &H100 GL_SMOOTH = &H1D01 GL_DEPTH_TEST = &HB71 GL_LEQUAL = &H203 GL_PERSPECTIVE_CORRECTION_HINT = &HC50 GL_NICEST = &H1102 GL_PROJECTION = &H1701 GL_MODELVIEW = &H1701 GL_POLYGON = &H9 End Enum
*************** M ** A ** C ** U ** L ***************
*************************************************
*************************************************
1 user(s) are reading this topic
0 membro(s), 1 visitante(s) e 0 membros anônimo(s)