Showing only posts by Jonathan Hale. Show all posts.

back-face culling

I recently found a tutorial on back-face culling. It means telling OpenGL not to draw invisible faces (faces on the back side ;) ) of a mesh, which does speed up the rendering a lot.

I was looking for something like this after I increased the height of the world in Mineshooter …

Mouselook and SDL - Code

Okay, here is some code for mouselook with SDL

struct {
              int x, y;
              //In this case: the position where the mouse is held at
              bool trap; //flag for holding mouse at one place
          } mouse;

          void MouseMotion(){
              /* Set x and y to the current mouse position */
              int x, y;
              SDL_GetMouseState(&x …

Fixed the SDL and Mouselook Problem

After spending hours trying to figure out why my mouselook function didn’t work with SDL, I finally got a solution.

The problem was that I didn’t use SDL_PumpEvents() before calling SDL_GetMouseState(). But if I do that I get the next problem: my Keyboard Events get delayed because the …

Mineshooter with SDL...

Almost done with rewriting Mineshooter to work with the Simple DirectMedia Layer Library. Still have a few problems with the mouselook, but I should be able to work out a solution very soon.

SDL is quite simple. I now have about 150 lines less than when I used the Windows …

Mineshooter with SDL?

I’m currently working on learning SDL and am also thinking about making my Mineshooter Projekt use SDL. Does anybody have experience with programming SDL-Applications and would advice against using it?

This post was imported from tumblr.

Gravity and World-Collision

Finally worked out the World-Collision problem. The player now collides perfectly with the blocks, but there is one problem left:

If you collide with a block in front on you, “you look inside the block”. That’s because you are 0.0f long 0.0f wide and the near clipping …

Photo post 7

image0

Continued work on Mineshooter!

I just read a blog-article from manwithsteelnerves about z-fighting which really motivated me to continue 3D-programming with OpenGL. That’s why I decided to continue my Mineshooter project and here is a new screenshot.

What I did: I had stopped developing this game, because of difficulties …

Photo post 8

image0

image1

This is the last of the projects I’m currently working on. It’s called “Notenspiel” (German), probably could translate it to “Note Game” (Meaning musical notes).

You can see your points in the top-left (yes, “Punkte” is German for points :) ), you get them by pressing the right key on …

Posted on in tumblr. updated archived

« newer articles | page 26 | older articles »