Adding a Ground - OpenGL with PyOpenGL Python and PyGame - 7

preview_player
Показать описание
In this OpenGL programming tutorial with Python and PyOpenGL we cover how to add a ground to our game if we want one. While we don't plan to continue along this thread, I wanted to show how it could be done before moving on.

Рекомендации по теме
Комментарии
Автор

Looks like one of those old-school 3d screensavers

Jamie-txpn
Автор

done part 7, now onto part 8, thank u Master, 6 years after you uploaded

py_tok
Автор

How do you put collision for the ground?

Ali
Автор

I have modified cube function for drawing graph but it is showing main() error.Could you help me with it

tanmaypandey
Автор

Hi, I have a project to do, I very liked your videos about opengl, due to I decided to use opengl in my code. my project is maze 3d, and I would like to add pictures to the cube's surfaces, can you help me with that? I searched videos about that but I didn't find :/

danasaba
Автор

sei que você é muito ocupado, mas poderia fazer um tutorial ensinando a carregar um modelo .obj com texturas? estou com muita dificuldade, poderia me ajudar?
minha intenção e pegar dados recebidos via pyserial e usar para a rotação deste modelo.obj e na tela exibir os angulos X Y Z, estou usando tkinter e pelo que vi não é possivel integrar o opengl, entao acho que vou criar um botão que ao receber um click aparece uma janela com modelo.obj
como disse, sei que é ocupado mas desde já agradeço.

maicomcoelholopes
Автор

I now it is an very old video but quiet a good tutorial to understand the fundamentals of OpenGL (better then NeHe???) in Python. I figured out to bugs in your code :


1: In main you had still the random tranformation: glTranslatef(rd.randrange(-5, 5), rd.randrange(-5, 5), -40.0)
This leads to irritations while plotting the ground. without the ground it is not really noticeable


2: Your ground vertices 2 and 3 are flipped, that leads to "corner" in your ground.

MaKaNufilms
Автор

How would you texture the GL objects using .png files. And i need it to stretch the texture because it is a 16x16 px texture

spectralknight
Автор

i have all made (i dont know the mistake.. i searched for an half hour...) correctly and it says this error to me:

Traceback (most recent call last):
  File "C:\Users\***path***", line 216, in <module>
    main()
  File "C:\Users\***path***", line 148, in main
    cube_dict[x] = set_vertices(max_distance)
  File "C:\Users\**path***", line 85, in set_vertices
    for vert in vertices:
NameError: name 'vertices' is not defined
>>>

nudelnmitreis