Jump to content

  • Log In with Google      Sign In   
  • Create Account


Member Since 25 Nov 2008
Offline Last Active Oct 02 2015 10:23 AM

Posts I've Made

In Topic: OpenGL SuperBible, 5th vs 6th edition

02 November 2013 - 09:25 PM

I say continue with the fifth edition. I have both, and am constantly going back to the early edition because some things are just better explained, like UBOs and PBOs (the latter is hardly mentioned at the end of the book in the 6th ed). Explanations in the newest edition are pretty terse. Also, the reference is cut out in the 6th ed; I guess it was to save some trees. I hardly ever used the reference, but it was a nice addition. Stick with the 5th version, and when you're ready to move onto atomic counters and compute shaders, the 6th version will be ready for you. Also have a look at g-trunc OpenGL reviews, if you haven't already. It'll put things into perspective of where OpenGL was back in the day, and where it is heading - especially when it come to the bind to edit model. ARB_bindless_texture anyone?

In Topic: Trouble transforming vertices in simple shader.

08 September 2013 - 05:03 AM

OpenGL by default looks down the -z axis. Setting your triangle z coords to -1 should help

GLfloat pos[] = { -0.5, -0.5, -1.0,
                           0.5, -0.5, -1.0,
                           0.0,  0.5, -1.0 };

In Topic: is there any 3rd openGL debug tool on macosx?

02 August 2013 - 08:40 AM

You can use Apple's first party tools. If you're using Xcode, then in the menu bar go to Xcode-> Open Developer Tools -> More Developer Tools -> then download the xcode graphics tools for your OS. Open the .dmg and click OpenGL Profiler. Copy the executable to the list box, then in the menu select Views->Breakpoints then check "Break on GL Error". Back in the main view, highlight the app so that "launch" is no longer grayed out, and hit that. This is how I debug my apps, and it's pretty good. 

In Topic: Understanding Composition

13 May 2009 - 06:16 AM

Sorry, I was still typing my message. So composition is just combination of objects? It doesn't matter if they can be changed at run time or not. That's what the strategy pattern is for.

In Topic: Understanding Composition

13 May 2009 - 06:06 AM

Thank you, jpetrie. You first paragraph definitely puts things into perspective. I definitely looking for a way to use my shiny new toy. I wrote many GL classes before. One with regular member functions and all state encapsulated. I wasn't happy with that solution. It was too immutable. I also tried inheritance. I wasn't too happy with that. There was this nagging voice saying "Don't use inheritance. Use composition." I got that from you gamedevers. But I think I got my definition of composition wrong. But are composition and the strategy pattern really different? One allows you to interchange state. The other allows you to interchange behavior. Are there any other differences besides that? If there is, then I don't have any understanding of this.