How do I enable multisampling using glfw in Python?
Question:
I am trying to enable 4x multisampling for OpenGL in Python. But I keep getting an error saying "GFLW_SAMPLES" is not defined. The way I understand it this should be included in glfw.
from OpenGL.GL import *
import glfw
import sys
glfw.window_hint(GLFW_SAMPLES, 4)
Is there another library I have to import for this?
Answers:
You have 2 possibilities:
import glfw
glfw.window_hint(glfw.SAMPLES, 4)
or
from glfw.GLFW import *
glfwWindowHint(GLFW_SAMPLES, 4)
I am trying to enable 4x multisampling for OpenGL in Python. But I keep getting an error saying "GFLW_SAMPLES" is not defined. The way I understand it this should be included in glfw.
from OpenGL.GL import *
import glfw
import sys
glfw.window_hint(GLFW_SAMPLES, 4)
Is there another library I have to import for this?
You have 2 possibilities:
import glfw
glfw.window_hint(glfw.SAMPLES, 4)
or
from glfw.GLFW import *
glfwWindowHint(GLFW_SAMPLES, 4)