Beginner C++ DirectX Game Programming Tutorial: Lesson 10

preview_player
Показать описание
Oh god the math it burns!!
Рекомендации по теме
Комментарии
Автор

Thank you so much for the tutorials. You have no idea how awesome this is that you're doing. These tutorials are definitely changing my life. Sorry for the english.

LuizHeringerCantor
Автор

Chili, thx for this tutorial series! First of all you make it really very easy to understand and follow you even if one is not an English native. Second:You take your time explaining this stuff thoroughly to your audience so there's no room for misunderstandings.I used to learn C in school to a very basic level almost a decade ago and watching these vids of you made me remember the fun i had coding my own programs...Today I've shown your series to a former class mate and voila: new subscriber :)

breakingVIE
Автор

Chilli, Since like age of 10 I wanted to program but every tutorial I saw was assuming I know all the terms and that got me down. Now Im 16 and and I decided to be staright into learning C++ and not be lazy. I want to thank you even I have a long travel to go I never know programming was kinda easy! And you make it seem fun and challenging! Thank you a lot!

nindocomic
Автор

I swear i've learned more here than i have in all my years so far in college. Professors can't hold a candle to you... this is the future of learning

aceofmwc
Автор

last video's homework was SO hard for me. I had never had trouble with any of the challenges before but that one really had me stumped :\ I could make the square (although not as cleanly as you did) but I couldn't get it to move properly. Felt dirty having to cheat and look at the answer in this video.

DubstepFromGod
Автор

in 1:05:00, instead of calculating other m and b values, you could simply isolate x in that old equation, like y = mx + b to 
x = (y - b)/m

RotcivOcnarb
Автор

holy shit this this was confusing as hell. Took me 4 times of watching the video to finally grasp it. Awesome explanations. it was nice seeing you use the debugging feature to fix the errors. You deserve more subs and views.

anaximander
Автор

If you don't add the 'f' what you get is a double-precision float, and that slows down your calculations a lot because the compiler has to start converting between single and double precision.

ChiliTomatoNoodle
Автор

Finally back home. Sorry it took me a while to add my thumbs-up to your vids. I hope you'll keep making more of these.

EndlessMystify
Автор

Chili, you're awesome dude! You make programming fun and entertaining while giving us noobs essential knowledge of how to make that code Chili hot :D Loads of respect.

LiezhuvisSF
Автор

Trust me when I say I know enough about forgetting to put absolute values to have spotted that part pretty quickly!

Very good lessons, will definitely apply that to my planned projects.

GlobalWarmingSkeptic
Автор

Instead of using float variables for y and x, you could do your calculations in a single step.
Also, I used vector calculations instead of the straight line equation, which can draw the line for any gradient without needing two separate functions.
And to solve the problem of signs in the 'for' statement (i.e. x <= x2) you could do
abs(x-x1) <= abs(x2-x1).

septne
Автор

Yeah Im lost, going to look for some other videos or start all over with these again. I feel like breaking stuff.

ChuckWilsonWilsonsStudio
Автор

Vectors per se are not complex in and of themselves. 2D cartesian coordinate ordered pairs (x, y) are vectors. In 3D you just add a third ordinate (z).
For your basic 3D graphics, you need a good understanding of matrix operations, vector operations like dot product and cross product, and you need a solid grasp of trig.
Integral calculus, differential equations, complex numbers, etc. don't really see much use (except perhaps in some advanced special effects).

ChiliTomatoNoodle
Автор

I love you man, so far so good, i just have a question about the last thing you did when you added +0.5 to round up, you writed +0.5f i guess the f stand for float why do we have to specify this in this specific case ?

GodOfMacro
Автор

y = mx + b
b is the y-intercept so apply the first you see
m is the slope: rise over run, so go up or down and to the right and then you're done.

UltimateWaifuXD
Автор

why when I debug, the break point notices that "the breakpoint will not currently be hit. no executable code of the debugger's target code type is associated with this line" ?

TheHieu
Автор

Instead of using the abs() function, which requres the addition of the math header file, couldn't you just multiply the variable onto itself? If its negative that would make it positive, and if its positive it would stay positive. It would even retain the relationship of magnitide allowing a boolean compare if ((dx*dx) > (dy*dy)). I suppose it could present a problem for really large variables, but that wouldnt be the case here anyways. Just a thought, and thanks for the great videos!

ixamraxi
Автор

I feel like I'm in 6th grade algebra again ^__^

For 3D graphics, what kind of math do we need to know? I'm starting Calc B/C now, and I hear vectors are a big topic. Does it take as complex of a topic as that, or dare I say, differential equations and whatnot? Just wondering what I'm getting into 0.o

fredbutnormal
Автор

As soon as you started typing temp's my mind blew up.

Pwegoable
visit shbcf.ru