Imports OpenGLLib Imports System.Runtime.InteropServices Public Class TessCall Public Sub glEndCB() glEnd() End Sub End Class Module DeclareB Public Delegate Sub CallCC() 'glEndCB() 'デリゲート End Module Public Function TessMake(ByVal ListNo As Integer) As Integer Dim tobj As Integer Dim MyCall As New TessCall Dim CallC As New CallCC(AddressOf MyCall.glEndCB) Dim returnValue3 As IntPtr returnValue3 = Marshal.GetFunctionPointerForDelegate(CallC) '① MainForm.Invoke(New CallCC(AddressOf MyCall.glEndCB)) '② CallC() tobj = gluNewTess() gluTessCallback(tobj, GLU_TESS_VERTEX, returnValue3) '③ '~~~~~~~~~~~~ '尚、Imports OpenGLLib 内では Public Declare Sub gluTessCallback Lib "GLU32.DLL" (ByVal tess As IntPtr, _ ByVal which As UInt32, ByVal fn As IntPtr) 'です。