OpenGL Tutorial 16 - GLFW Key Input

preview_player
Показать описание
🚀 Get 100% Off Your First Month with CustomGPT! 🚀

Sign up for a Standard CustomGPT.ai subscription using my referral link and enjoy 100% off your first month. Plus, you'll help support my channel with a 15% commission at no extra cost to you!

If you like this stuff, as always, show the love through comments, likes, favorites, subscriptions, etc.

Thousands of free videos at

If you have any questions feel free to post them at

Our Website

Our games made using Cocos2d-x
------------------------------------------------------

Рекомендации по теме
Комментарии
Автор

Welcome to this OpenGL tutorial.

If you have any questions feel free to post them on our free education platform sonarlearning.co.uk

SonarSystemsCoUk
Автор

that rare thing - a youtube coding tutorial that's still delivering nearly 9 years later
super useful - thanks again for sharing your knowledge, and extra thanks for sharing your source code x

samdavepollard
Автор

Thanks man, this is exactly what I was looking for, just a very simple basic guide on how to actually do it, without the fancy jargon.

HavengulRunebinder
Автор

your videos are saving me in my graphics course, thank you very much!

chrischen
Автор

thank you so much for this tutorial, it works very well!!

buanenochorvo
Автор

If your keyCallback function is contained in a class, declare it as static; to make sure that the function is not bound with the class.

valizeth
Автор

i get an error (variable or field keyCallback declared void)

ProgrammingExplosion
Автор

All, Thank you. Is there a source that I can learn to how to use this to modify variables with my key input. This does not seem to allow me to pass in extra variables in the gflwSetKeyCallback. So when it calls the keyCallback() method it cant work with extra variables. I am a new programmer so thank you.

marcstephens
Автор

i made tthe function exacly how it is in the video vodi keycallback .. etc

but when i use
glfwSetKeyCallback(window, key_callback); simple does not work .

raf.nogueira
Автор

when i press " F12" the program throw exception "has triggered has a break point" why plz?
sr my English not good

khanhduyn
Автор

Hi! Thanks for the tutorial! I want to do something when the key is released, so I put it
if (glfwGetKey(window, GLFW_KEY_UP))
{
if (glfwGetKey(window, GLFW_KEY_UP) == GLFW_PRESS)
{
cout << "press" << glGetString(GL_VERSION) << endl;

}
else if (glfwGetKey(window, GLFW_KEY_UP) == GLFW_RELEASE)
{
cout << "release" << glGetString(GL_VERSION) << endl;

}
}
But it never print "release" after I released the key. May I know what's the error done here?

nicolelyy