Example #1
0
mesh1.create()
mesh1_mat = pyrr.matrix44.create_from_translation(pyrr.Vector3([0, 0, 2]))

mesh2 = Mesh("resources/meshes/plane2_p_n_uv1.ply")
mesh2.load()
mesh2.create()
mesh2_mat = pyrr.matrix44.create_from_translation(pyrr.Vector3([0, 0, 0]))

# mesh3 = Mesh("resources/meshes/Dragon.ply")
# mesh3.load()
# mesh3.create()
# mesh3_mat = pyrr.matrix44.create_from_translation(pyrr.Vector3([2, 1, .5]))

shader1 = Shader("resources/shaders/shader1.vs", "resources/shaders/shader1.fs")
shader1.load()
shader1.create()
# shader1.use() # needed

tex1 = Texture("resources/images/marble.jpg")
tex1.load()
tex1.create()

tex2 = Texture("resources/images/brickwall.jpg")
tex2.load()
tex2.create()

tex3 = Texture("resources/images/StoneMarbleCalacatta004_COL_2K.jpg")
tex3.load()
tex3.create()

light_pos = [0.0, 1.0, 3.0]