anyone have a Simple Camera Movement Example?

Hello All!
First time poster here.
Let me say how excited I am to have found JOGL and this community. I dinked around in Java3D before, but am much more impressed here with what I see from the demos/tutorials and this thriving community!

I’ve read all the posts, and looked at a lot of the NeHe ports (Thanks to those that did them by the way), and am starting to mess around with this new syntax I’m learning, etc.

In the tutorials, I was a little disappointed in how complex Lesson10 was (Loading and Moving through a 3D world). I’m sure those more familiar with Java and openGL had no problem with it, but I was hoping for something much simpler when I got to that point.
edit: let me reword that, not disappointed at all in the lesson, only in that I am not at the level to comprehend it completely.

So I was wondering if anyone had a simple framework they use, that they’d shared, from where I could start.

What I was hoping for was a pretty stripped down sample with the basics in place to which I could add other building blocks as I learned them. For example, when I think of a simple tutorial for “Navigating a 3d world”, I think of a simple quad for the ground; a movable camera that can go forward/backward, and turn; and maybe a cube there to walk around and look at.

I am trying to follow the tutorials, but some are way too complex for me right now, and then it seems there are several different setups of the code (some are all in one, some break out things like CCamera, some don’t, some use packages and some don’t. ) This is making it hard to kind of cut and paste out the pieces I would like for my simple example.

Anyway, if noone has such a thing, I’ll definately share it once I get there, but if someone does I’d love to get it :slight_smile:

edit: I’ve seen it looks like a couple different implementations of movement, one being the CCamera class, one being an InputHandler Class, one being a KeyboardInput class or something like that, and then some just have them in one of the other classes. Since Camera movement is obviously the part I’m trying to tackle here, what would be the best approach to use? Which is the best?

Thanks in advance!!

As you may have read somewhere, there is no built-in OpenGL camera, so it’s only a matter of which abstraction to use.

For my current CS project I have been implementing a Quaternion Camera. The main difference between other kinds of cameras is that this one uses Quaternions (a complex mathematical structure) instead of angles and trigonometry to calculate rotations.

In theory it should be faster, more efficient, easier to use and obviously way more cool than an euler camera :slight_smile:

I followed countless tutorials, but eventually got it to work. My Camera class supports almost every kind of movement except one (which in my opinion isn’t working as it should): orbiting around a point… Well maybe if someone wants to take a look at it we can try to fix it…

I’ll post it in a new thread called Quaternion Camera Source Code, so it will be easier to find that thread in the future.

Thank you AvengerDr! I’ll head up there now and check it out.

I actually am pretty new to openGL and was not aware of how the “camera” (or lack of) works, so this is very helpful info. I was beginning to think something was up when I saw in demos “zoom in” and “zoom out” instead of forward/backward :slight_smile:

The learning continues!

Thanks again!