Jump to content
  • Advertisement

Zanman777

Member
  • Content count

    22
  • Joined

  • Last visited

Community Reputation

219 Neutral

About Zanman777

  • Rank
    Member
  1. I'm going slightly mad on this.   I've been trying to learn OpenGL. I've never learnt 3D programming / math (in a very solid way, anyway). I do know some basics about vectors, matrices, matrix multiplication, the identity matrix, how matrices store rotations, scaling and other transformations. I've read a couple hundred pages from 3D Math Primer for Graphics and Game Development, but that was at least a year ago. Furthermore, I guess there probably are some gaps in my 3D knowledge.   Lately, I tried to learn OpenGL through the Red Book. However, the book isn't very beginner-friendly. So after googling for a while I tried to learn from the arcsynthesis.com tutorials. I was doing very good until the perspective projection tutorial (http://www.arcsynthesis.org/gltut/Positioning/Tut04%20Perspective%20Projection.html). I don't get all that math on the "Camera perspective" section, tbh I think it's poorly explained (the rest of the tutorial is top-quality, though, gotta be fair).   From arcsynthesis I jumped to scratchapixel.com. The perspective projection matrix lesson (http://scratchapixel.com/lessons/3d-advanced-lessons/perspective-and-orthographic-projection-matrix/perspective-projection-matrix/) got me understanding things a bit better, but I'm starting to get really confused as scratchapixel.com and arcsynthesis.com seem to take slightly different approaches.   From what I understand, the homogeneous coordinates (as scratchapixel.com calls them) are acquired by dividing x,y and z by w. Those will then be the NDC (normalized device coordinates, as arcsynthesis calls them), right? Arcsynthesis seems to say that we "prepare" the perspective projection by setting the correct w coordinates for each vertex and letting the hardware do the rest:     However, the same Arcsynthesis states: ...then it proceeds to explain how to feed the clip space with already-processed vertex coordinates (in a way that gives the sense of perspective). I'm confused... Isn't that effect achieved by setting the correct w values for the perspective divide, which happens during the conversion from clip space to NDC???   Scratchapixel.com, on the other hand, defines the perspective divide as some sort of process of making w equal to z, so that dividing the coordinates by w will simultaneously make them homogeneous and fit into the z = 1 plane (which is considered the image plane in their example, or projection plane as arcsynthesis calls it).     So technically, the perspective projection occurs from the conversion from clip space into NDC, NOT before feeding the clip space coordinates (as arcsynthesis stated)! Am I right?   Things are starting to get really messy in my mind, and I'm wondering if I should just pick a textbook on this subject and learn it all the hard way. Subsequent concepts mentioned by scratchapixel.com like far view and near view are also unclear to me, though there are previous tutorials on scratchapixel.com that should enlighten me about those. The question is... should I keep on hopping from place to place to figure out stuff one thing at a time, or would I better grab a textbook? If so, which one?   Any help would be very appreciated. This is starting to harm my motivation to learn OpenGL. It really gives the sense of overwhelmingness (just made up a new word).
  2. Zanman777

    Re-learning C++ and some help with learning it.

    Hi, Zero_Breaker. I feel exactly like you. And I understand why you feel so demotivated. The thing is, you're probably (subconsciously, anyway) thinking you'll be learning all this C++ again and forget it again soon. Other reason for your low morale is you don't get to see results of what you've learned. Finally, the third factor is probably you don't feel trully commited to the whole process of digging in, learning and doing.   Programming is a very, very demanding task. You have to learn C++ (considering your approach now). Then, you need to learn 2D/3D math. Then you need to learn how to use a graphics library (OpenGL, or SDL, or a 3D engine...). In the meantime you need to learn how a game is actually coded - the logic of the game loop, how to integrate several source and header files, how to organize the whole code... The list goes on and on.   Don't feel guilty because you're not getting to the finish line. It does take a long, long time. The important thing here is you like the journey, not just the final destination. I'm saying this but I'm on the same boat... I also keep getting lost on what to do next, what to learn next. Maybe we could learn together? I'm sure it would boost the heck of our morales, to share thoughts, maybe even programming stuff together?   If anyone else reading this is on the same boat, drop me a msg or reply to this topic, maybe we could gather a "beginners" group to keep everyone motivated and to help each other learning stuff.   That being said, and replying to your post, I'd say the book you chose (C++ Primer 5th Edition) is a very, very good choice. It's the book I chose too. It gets very deep into C++, and it may be tiring to finish it, but believe me, it will be worth it. It helps to really understand how C++ works. It will help you to avoid magical bugs and compiler warnings/errors popping out of nowhere because you will trully master the dirty details of it all. So be easy on yourself. You're going the right path, but it's also the hardest one. My approach to your problem (feeling demotivated, bored...) was this: taking notes on the details that will most probably be forgotten in a couple of days (because they're not used enough) but represent potential pitfalls when it comes to code. I made a kind of personal "cheat sheet" with some 15 pages of notes about everything I'll need to remind myself of when I want to code. The book itself has over 1000 pages iirc, so bringing it down to 15 pages is a major sense of accomplishment by itself. Heck, I'll share my cheat sheet with you if it helps you, no problem :)   Concerning the bookstore stuff, I can help you with that if you want. Send me PM if you're interested   Cheers ;) 
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!