Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (582)
Games in Android Showcase (163)
games submitted by our members
Games in WIP (633)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  Really confused with all the OpenGL version  (Read 2515 times)
0 Members and 1 Guest are viewing this topic.
Offline OrelBitton

Junior Newbie

« Posted 2013-11-22 11:11:17 »

Hey guys!
I am looking forward to develop a 2d game, but I really want to use the OpenGL library, I will probably use the LWJGL as a wrapper.
My main problem is that I don't know what version I should learn.. I have learned the basics of 1.1 and did a simple game and painted few cubes on the screen.
I want my game to be able to run almost on every computer(something in the zone of minecraft) and when I mention every computer, I also mean OS because I've understood that only few versions of OpenGL can run on mac.
So my question is simply, what version should I learn for my needs?
If you can, please provide me a few good resources, books are acceptable too.

Thank you very much in advance Smiley
Offline trollwarrior1
« Reply #1 - Posted 2013-11-22 11:20:59 »

There is no such thing as which version should I learn. It really depends.

First off all lets take versions 1.1 for example. It contains more than just rendering method. It also contains some other methods which are like a must for your application. So even if you're making a game with higher versions, you will need to use lower versions.

You should be asking what rendering method you want to use. There are few rendering methods available, however only 1 is supported by modern OpenGL. All the rest are deprecated. Here are the modes: (I might not even know all of them)
-Immediate mode - very slow, but very easy to use.
-Display Lists - very fast, easy to use, but cannot modify the data after you send it to GPU.
-Vertex Arrays - I think it is like display lists, but you can modify the data after sending it to GPU. It is easy to use.
-Vertex Buffer Objects (VBOs) - not the fastest, hard to use(for beginners), can modify the data. I don't really know the difference between VBO and Vertex Array, but I think VBO is better. This is the only rendering mode that is supported by modern OpenGL.

If you're just starting out in OpenGL, you should just go with Immediate rendering mode, which is all contained in OpenGL version 1.1

Hope this helps ! Tongue


Check out some of these youtubers, they make pretty awesome LWJGL tutorials for beginners!
-thecodinguniverse -
-thebennybox -
Offline theagentd

« JGO Bitwise Duke »

Medals: 454
Projects: 2
Exp: 8 years

« Reply #2 - Posted 2013-11-22 11:22:11 »

As long as you stick to 2.x and lower you should be fine. Unless you're doing anything fancy with shaders or framebuffers, you can probably get by with OGL 1.x. Mac supports up to 2.x (or 3.2, but in that case you'll lose backwards compatibility with deprecated functions).

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline opiop65
« Reply #3 - Posted 2013-11-22 11:31:19 »

As advised above, do start out with old OpenGL (immediate mode, display lists etc...) But don't get hung up on it like I did. I spend nearly a year messing around with immediate mode when I could have been learning more about shaders. Shaders are possibly the single most useful thing ever, and I still barely understand them because I spent so much time learning deprecated code and not new OpenGL. I would recommend that as soon as you're comfortable with immediate mode and all the other 1.1 functions, to move up to VBOs and shaders. Watch theCodingUniverse and try to modify his code so that it uses modern OpenGL instead of old, it's a really great way to learn!

Edit: People will tell you everyday that you shouldn't be using immediate mode/display lists. While they're right, ignore them for now. Everyone tries to pressure you into the hard stuff first, which I've never understood. Just stay persistent and don't give in to their pressure unless you're ready to learn the new stuff!

Good luck! Smiley
Offline OrelBitton

Junior Newbie

« Reply #4 - Posted 2013-11-22 11:43:51 »

Thank you very much guys! Very helpful information, so your saying I should be based on version 2.1?
Offline opiop65
« Reply #5 - Posted 2013-11-22 11:48:20 »

When you feel like you're ready, yes, you should learn 2.1+ versions. Don't just sit at 2.xx versions though, keep learning more modern OpenGL. The other thing is, you'll need to learn matrices if you ever want to completely get rid of the old fixed function pipeline. Just something to consider!
Offline SHC
« Reply #6 - Posted 2013-11-22 15:10:38 »

The problem with opengl on macs is that apple ships with it's own drivers, it won't let developers to work with low level hardware directly. This is the main cause for the lower versions of opengl on macs. A good news is that Osx Maverics supports opengl version 4.1

Offline OrelBitton

Junior Newbie

« Reply #7 - Posted 2013-11-22 16:36:21 »

Can you recommend me any good book? or a tutorials?
Offline trollwarrior1
« Reply #8 - Posted 2013-11-22 16:37:45 »

Can you recommend me any good book? or a tutorials?

I already did in my first post Tongue
Offline OrelBitton

Junior Newbie

« Reply #9 - Posted 2013-11-22 16:42:49 »

Yes saw that, but are they teaching 2.1?
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline opiop65
« Reply #10 - Posted 2013-11-22 19:31:44 »

@SHC I don't believe OP stated he has a Mac?
theBennyBox uses strictly above 2.0 code I believe, maybe even 3.x, however theCodingUniverse doesn't.
Offline SHC
« Reply #11 - Posted 2013-11-23 13:05:12 »


I didn't say that OP mentioned he has a mac. I posted that news since he mentioned the maximum OpenGL version that macs have.

Offline opiop65
« Reply #12 - Posted 2013-11-23 13:08:27 »


I didn't say that OP mentioned he has a mac. I posted that news since he mentioned the maximum OpenGL version that macs have.
Yes, I know, it just seemed odd that you would mention a Mac, sorry Tongue Didn't mean to be rude!
Offline SHC
« Reply #13 - Posted 2013-11-23 13:14:28 »

sorry Tongue Didn't mean to be rude!

You are welcome. I didn't take your comment seriously by the way, I didn't see anything that seemed rude in it.

Online philfrei
« Reply #14 - Posted 2013-11-24 02:20:51 »

You might check out the stats for Minecraft itself, on its users:

The post is from May, 2012. I don't know if the stats have been updated or not.

"We all secretly believe we are right about everything and, by extension, we are all wrong." W. Storr, The Unpersuadables
Pages: [1]
  ignore  |  Print  
You cannot reply to this message, because it is very, very old.

Ralphanese (18 views)
2015-05-29 13:07:55

Gibbo3771 (15 views)
2015-05-29 06:54:17

Ralphanese (23 views)
2015-05-28 16:52:52

theagentd (31 views)
2015-05-27 22:21:17

theagentd (36 views)
2015-05-27 22:21:08

CopyableCougar4 (25 views)
2015-05-27 19:24:50

MrMapcom (24 views)
2015-05-23 20:26:16

MrMapcom (33 views)
2015-05-23 20:23:34

Waterwolf (37 views)
2015-05-20 15:01:45

chrislo27 (44 views)
2015-05-20 03:42:21
Intersection Methods
by Roquen
2015-05-29 08:19:33

List of Learning Resources
by SilverTiger
2015-05-05 10:20:32

How to: JGO Wiki
by Mac70
2015-02-17 20:56:16

2D Dynamic Lighting
by ThePixelPony
2015-01-01 20:25:42

How do I start Java Game Development?
by gouessej
2014-12-27 19:41:21

Resources for WIP games
by kpars
2014-12-18 10:26:14

Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02 is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!