Example #1
0
 public static void SetCursorPosCallback(Window window, CursorPosFunc callback)
 {
     cursorPosFunc = callback;
     var ptr = Marshal.GetFunctionPointerForDelegate(callback);
     glfwSetCursorPosCallback(window.Ptr, ptr);
     GC.KeepAlive(callback);
 }
Example #2
0
    public static void SetScrollCallback(Window window, CursorPosFunc callback)
    {
        var ptr = Marshal.GetFunctionPointerForDelegate(callback);

        glfwSetScrollCallback(window.Ptr, ptr);
    }