The EASIEST way to setup OpenGL with Visual Studio. (CMake Setup for Gamedev)

Поделиться
HTML-код
  • Опубликовано: 29 окт 2024
  • I have for you all the things you need to start writing OpenGL. It is difficult to configure libraries like GLFW GLAD GLM or IMGUI and that is why I already configured them for you. I used CMake to configure OpenGL but you don't have to learn it, just use my template. Thank me later.
    #cpp #opengl #gameprogramming #graphicsprogramming #visualstudio #cmake
    Followup video on using my setup to make your first game:
    • Make your first C++ ga...
    The first setup:
    github.com/mee...
    The second(bigger) setup:
    github.com/mee...
    Join my Discord server:
    / discord
    Wishlist my game on Steam 💪:
    store.steampow...
    Check out my Cmake Video:
    • The only CMake tutoria...
    Check out my OpenGL guiding video:
    • How you can start lear...
    Check out my Game Dev in C++ video:
    • If you want to learn h...

Комментарии • 58

  • @developerdeveloper67
    @developerdeveloper67 Год назад +31

    Do it a billion times then eventually you will just know how to do it...

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      Yeah kinda 😂😂 that is what I did and that is why I wanted to share my work with others

  • @pvini07BR
    @pvini07BR 2 месяца назад +2

    man, this is a godsend. You have no idea how many times I quitted C++ because of how much work i have to do just for setting up a stupid project, I hate how i have to spend so much time configuring instead of programming itself, and switched to Rust. However after coming to your channel you definitely helped me to stop hating it less, because you're helping to make the process much more painless.

  • @Luna.Firethorn
    @Luna.Firethorn 10 месяцев назад +4

    I was having trouble with setting up GLFW, but then I found this. I absolutely love your channel, yet haven't thought to sub yet, so I just have. You are super underrated and I just wanted to show you some appreciation for your content! Tysm!!!

  • @КимЧенОрк
    @КимЧенОрк Год назад +3

    What?! I've been looking for just such a video all day

  • @anuhasjayawardana9905
    @anuhasjayawardana9905 Год назад +9

    wow you made my work like 75% easier

  • @h3l_l
    @h3l_l 2 дня назад

    A kind of stupid question but wouldn't setting up this on my own make me improve? I mean I haven't even went through the process yet.

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  2 дня назад +1

      so the answer is complicated. So setting this things up is a part of learning cpp, not of learning opengl, so I recomand beginners to do this later, but yes yo do at some point, whenever you want to, need to learn how to setup cmake. And if you do so I recomand you to copy how I did it (type it yourself) and learn what I did because this is the best way to setup cmake that I have seen and other people don't do it like this for some reason 💪

    • @h3l_l
      @h3l_l День назад

      @@lowlevelgamedev9330 your channel is the best for learning opengl dude, thanks for the help we all appreciate it

  • @Nebula_Protogen752
    @Nebula_Protogen752 9 месяцев назад

    When I try to compile the Simple Example, it just crashes and gives me a long error code ...

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  9 месяцев назад +1

      hm I'll recheck it, can you send me the error on the discord server and tag me?

    • @Nebula_Protogen752
      @Nebula_Protogen752 9 месяцев назад

      @@lowlevelgamedev9330
      Sure! I'll do that in a few minutes

  • @AlexAlex10703
    @AlexAlex10703 7 месяцев назад

    idk this might be correct but it isnt three different colour triangle its just one color. Is there something wrong with like the shader or something

  • @mathvisuallyexplained6839
    @mathvisuallyexplained6839 2 месяца назад +1

    Remember to have cmake installed in vsstudio components!

  • @jacksonbaldwin3463
    @jacksonbaldwin3463 11 месяцев назад

    im not quite sure if i understand how you open a project using this. I have cloned the repo, but how do i create a new OpenGL file after running the program? Is OpenGL now implemented in VS, or do i need to open this repo every time I want to start a new project?

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  11 месяцев назад +1

      you clone this repo everytime you want a new opengl project and you add cpp and header files to it. This means that you will clone all of the dependences every time but disk space is not a problem nowadays and there are some advantages to having all your depndences locally in your project like the fact that you can change them update them modify them and also the fact that it is easy to send to others

    • @jacksonbaldwin3463
      @jacksonbaldwin3463 11 месяцев назад

      @@lowlevelgamedev9330 i tried making a .cpp file in the repo (with some sample OpenGL code), saving the .txt file, and compiling the program, but i am met with dozens of errors. Does it matter where I place the .cpp file in the repo?

  • @Jo-ik6un
    @Jo-ik6un Месяц назад

    how to configure for glut?

  • @rafagamedev3606
    @rafagamedev3606 Год назад

    Spent hours stuck on "the code execution cannot proceed because glfw3d.dll was not found," anyone have any leads? Thank you!

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      you have to add that dll in the same folder as your exe but I recomand you to link it statically, just use my setop for example

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      to clarify I'm talking about tje glfw32.dll file that should have come with the library download, just put that in the same folder as your exe file (or sollution dir if it still doesn't work)

  • @ChaseCarlson
    @ChaseCarlson Год назад

    Which project of yours is shown at 0:06? I like the feel of this one.

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад +1

      I don't have a video about that project, I talk about it very briefly at the end of my learn opengl video. It is my first 3D opengl project.

  • @ahmedwafi2171
    @ahmedwafi2171 8 месяцев назад +1

    Unfortunately the video was really fast and it has alot of new informations on me that I didn't understand it :'(

  • @Skelyvelocirap
    @Skelyvelocirap 4 месяца назад

    How would i go about making this work for opengl 4.3?

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  4 месяца назад

      it already works for opengl 4.3, maybe I didn't understand the question, if so leave a new comment so I can see it or tag me on discord 💪

    • @Skelyvelocirap
      @Skelyvelocirap 4 месяца назад

      @@lowlevelgamedev9330 oh ok. I thought it was version 3.3 for some reason. Good to know though, thank you

  • @Volian0
    @Volian0 Год назад

    Nice! Are you planning to make a video on raytracing?

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      I don't have it planned but it would ne a nice topic, si it is possible.

  • @Vo0idsEmbrace
    @Vo0idsEmbrace 8 месяцев назад

    doesnt work just like every other setup on youtube for open gl .. im beginning to think cmake openg gl and everything to do with it is just cursed so i just wont bother

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  8 месяцев назад +2

      what happened? can you provide some details on my discord so I can help you and improve the setup? tag me please on the youtube help channel on my discord so I can help you

  • @5starcode
    @5starcode 8 месяцев назад

    The triangle is only red for me

  • @silloo2072
    @silloo2072 Год назад +2

    i want to lean how to make games in c++ i know the basic(i watched a 6 hour long video, the bro code) and now i want to make game and game engine, please, can you send me some good video in the reply ?i am really motivated so can you please help me 😁

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад +2

      I would strongly recommand any video from Javidx9's youtube channel. Also check out the handmade hero series(it is quite long but you could watch the first videos). The video from my channel about called how to start gamedev in c++ (it is like my fourth video or something) is basically a compilation of the best resources that I know of. Also I have a special channel on my discord server called resources where I post links. Good luck I love seing motivated people 💪

    • @silloo2072
      @silloo2072 Год назад +1

      Ok thank you a lot 🙏 I am so happy now your the best, I will join your discord

    • @silloo2072
      @silloo2072 Год назад +1

      @@lowlevelgamedev9330 and wich video should i watch fron javidx?

    • @Maverick56912
      @Maverick56912 Год назад

      @@silloo2072 ayo mr, whats up with your engine so far?

    • @silloo2072
      @silloo2072 Год назад +1

      @@Maverick56912 i gave up, i can't install openGL all the tutorials doesn't work on my mac i am sorry and thanks for asking, if you have any tips i will be happy to continue.

  • @gamingpcgamer459
    @gamingpcgamer459 Год назад

    Can I do this in visual studio code too?

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      yes, the process is less smooth tho. You need to install the c++ extensions so you can open cmake projects with vscode. For C++ dev I recomand visual studio if it is an option for you however.

  • @ocramkd
    @ocramkd Год назад

    i didn't understand anything... am i dumb or something

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад +1

      Nah it is not your fault don't worry. The point of the video is not to understand how the configuration works but rather to steal it and use it to quickly be able to start learning opengl and don't deal with configuring libraries and such

  • @Maverick56912
    @Maverick56912 Год назад

    easy, dump vs and use premake

  • @E_mosfet
    @E_mosfet Год назад

    can you make this for c

    • @lowlevelgamedev9330
      @lowlevelgamedev9330  Год назад

      For the simple opengl setup it should probably work for c with little trouble. Some libraries are c++ only and you can just remove those (like glm is probably the only one that has to be replaced with cglm). Remove the cmake command that sets the project to c++17 if there is any and replace the cpp file to a c one. Let me know if you run into trouble.