Sorry to be so offtopic but does any of you know of a trick to log back into an instagram account? I somehow forgot the account password. I love any assistance you can offer me
@Maximus Deshawn I really appreciate your reply. I got to the site on google and I'm waiting for the hacking stuff atm. Takes a while so I will get back to you later with my results.
Hey Gabe, thanks for the great content. Just wanted to say that the problem with the Time class was because the timeStarted variable was declared as a float and System.nanoTime() returns a long so there was probably some loss of precision. If you change timeStarted to be a long everything should work fine.
Hi Gabe, loving this series of tutorials, thank you for making such helpful videos! I've always managed to fix any bugs or errors so far, but now I really feel like I'm stumped: right around the 27:05 timestamp, when you fix the black screen and get to see the colored rectangle again, something goes horribly wrong on my pc and I can't seem to understand why. Basically I can see the background just fine, and the rectangle is there as well, but most of it is black with the exception of smaller rectangles on the "top row", which seem to be colored just the way they should be (as if the rectangle was actually colored but most of it was then covered with black). I checked the code on your github and it seems to be the same I have, I even rewatched this video up to this point to make sure I didn't miss anything... do you have any idea as to why this could be happening? Edit: I've noticed that it has something to do with the Max_Batch_Size, the bigger it is the larger the portion of the rectangle that gets covered in black (for example, if I use values 1 to 5 there's no black and it renders just the way it should). Also, if I modify the color vector of each sprite to have the blue value (the third parameter) to be 0 this issue disappears
I had this problem too, I figured out that the issue for me was when defining COLOR_OFFSET and such I had it formatted as "COLOR_OFFSET = (POS_OFFSET + POS_SIZE) * Float.BYTES" which is wrong, it had to be "COLOR_OFFSET = POS_OFFSET + POS_SIZE * Float.BYTES" to get the order of operations you want and thus getting the correct numbers
@@RUclipsDoesntSupportMyUsername Hi, thank you for your answer! Unfortunately, I had it already formatted the way it works for you. I also tried different orders of operations just to be sure, but it does not seem like that is the source of my problem. Thank you again though, I'll keep looking for the error!
To avoid using the stbi_set_flip_vertically_on_load() function. its work for me. I use these UV coordinates: Vector2f[] textureCord = { new Vector2f(1,0), new Vector2f(1,1), new Vector2f(0,1), new Vector2f(0,0) };
Hi gabe, -i was following your beautiful tutorial on macos for a school project. Unfortunately it doesn't render anything... It's just a lonely black screen. Do you have any idea of what I can do to solve this problem?
I have a strange bug where I get solid color bars instead of my image. It looks like I only have like 4 points of color. I'm not sure what I'm doing wrong
It sounds like you may have a mismatch of color components in your texture vs the actual image. I would make sure you're actually using rgba if the color has 4 components, or rgb if it only has 3 when you do glTexImage :)
@@GamesWithGabe I couldn't figure it out for the longest time but I finally came back to it after setting it aside. Turns out I number of dimensions wrong for my Texture coordinates. I was using 1 instead of 2 and that obviously causes everything to be misaligned. Whew that took me longer than it should have, but thanks for the help though :)
Hello! I am from the future hopefully you will still see this. We pretty much have the same code but I keep getting a NullPointException error pointing to the loadVertexProperties method more specifically vertices[offset + 6] = texCords[i].x; vertices[offset + 7] = texCords[i].y; It's saying that is cannot load from object array because "texCords" is null. I assume that is because texCords is never intialized or it is thinking texCords is something else rather than the things defined in SpriteRenderer class. Regardless I have been trying to fix this to no avail any help will be appreciated!
Hi Gabe I'm doing your whole tutorial right now but i'm kind of stuck atm. i get this following message when I try to compile at the end:"0:15(27): error: sampler arrays indexed with non-constant expressions are forbidden in GLSL 1.30 and later" If i change the integer id in the default.glsl file to a number for example 3 then the program runs but when i put in id, like you did i get the error. Do you have an idea what i should do? I saw online that people were able to get rid of the bug by updating to a newer OpenGL version, but that surely can't be the reason why it workes for you but not for me. Best regards Henri
Hey Henri! So I later found out that the technique I showed in this video is technically undefined behavior. I saw another video of somebody doing it this way, and it was a lot easier than what I was doing previously, unfortunately like you found out its not supported everywhere. The easiest way to get around this is to have a large switch statement in your shader and then based on the index you can just access the texture array using a constant number. I can dig up an old example if you want, and if you join the Discord I know there are some other developers who can show you some examples of this :)
@@GamesWithGabe Thanks you for answering, first of all i want to say thank you for the tutorial i really appreciate it. Tbh i think I'm just fine if you send me the link on where they show how you would normally do it. I don't have too much time because my new Semester starts next week and I thought why not get in touch with java again with a project. Yea so the link would be amazing and if I decide I want to fully complete the tutorial and understand OpenGL even more I'll text you again :). Cheers
Hey Henri it's no problem at all! Here's a link to a community project with the static indexing github.com/azurite-engine/Azurite/blob/65f99bd783bf87fd475005adc0c166c065c63f51/src/assets/shaders/default.glsl#L43 . You can just replace the code where you sample a texture with this and it should work alright. Best of luck with university!
Man you're wonderful!!!
Haha thanks Pipe Martínez FRV :D
It makes me sad to see how much the viewer count decreases with each episode :| Great work.. every single video
Loving these tutorials, thankyou for uploading them
Thanks for watching :)
Sorry to be so offtopic but does any of you know of a trick to log back into an instagram account?
I somehow forgot the account password. I love any assistance you can offer me
@Yael Jared Instablaster =)
@Maximus Deshawn I really appreciate your reply. I got to the site on google and I'm waiting for the hacking stuff atm.
Takes a while so I will get back to you later with my results.
@Maximus Deshawn It did the trick and I finally got access to my account again. Im so happy:D
Thanks so much, you saved my ass!
Hey Gabe, thanks for the great content. Just wanted to say that the problem with the Time class was because the timeStarted variable was declared as a float and System.nanoTime() returns a long so there was probably some loss of precision. If you change timeStarted to be a long everything should work fine.
awesome! Great video as always =)
Thanks again! :)
Great effort.thanks
I get the exact same thing as you! Except... mine has black upside-down right-pointing triangles all over it
31:38 might as well make our whole texture images upside-down xD
Hi Gabe, loving this series of tutorials, thank you for making such helpful videos!
I've always managed to fix any bugs or errors so far, but now I really feel like I'm stumped: right around the 27:05 timestamp, when you fix the black screen and get to see the colored rectangle again, something goes horribly wrong on my pc and I can't seem to understand why.
Basically I can see the background just fine, and the rectangle is there as well, but most of it is black with the exception of smaller rectangles on the "top row", which seem to be colored just the way they should be (as if the rectangle was actually colored but most of it was then covered with black).
I checked the code on your github and it seems to be the same I have, I even rewatched this video up to this point to make sure I didn't miss anything... do you have any idea as to why this could be happening?
Edit: I've noticed that it has something to do with the Max_Batch_Size, the bigger it is the larger the portion of the rectangle that gets covered in black (for example, if I use values 1 to 5 there's no black and it renders just the way it should).
Also, if I modify the color vector of each sprite to have the blue value (the third parameter) to be 0 this issue disappears
I had this problem too, I figured out that the issue for me was when defining COLOR_OFFSET and such I had it formatted as "COLOR_OFFSET = (POS_OFFSET + POS_SIZE) * Float.BYTES" which is wrong, it had to be "COLOR_OFFSET = POS_OFFSET + POS_SIZE * Float.BYTES" to get the order of operations you want and thus getting the correct numbers
@@RUclipsDoesntSupportMyUsername Hi, thank you for your answer! Unfortunately, I had it already formatted the way it works for you. I also tried different orders of operations just to be sure, but it does not seem like that is the source of my problem. Thank you again though, I'll keep looking for the error!
You can do GL45.glBindTextureSlot(texSlot, textureID); instead of activating the slot and then binding the texture. It's just nicer in my opinion
Thanks for the suggestion Nikhil! I'll try it out in the future :)
I've actually tried this and now I feel smart making my first modification outside of the video series!
Im not sure of I am doing something horrible wrong but I dont have that method in GL45
@@monkey5266 Me neither, the method just doesn't exist for me when I try to import it
To avoid using the stbi_set_flip_vertically_on_load() function. its work for me. I use these UV coordinates:
Vector2f[] textureCord = {
new Vector2f(1,0),
new Vector2f(1,1),
new Vector2f(0,1),
new Vector2f(0,0)
};
Hi gabe, -i was following your beautiful tutorial on macos for a school project. Unfortunately it doesn't render anything... It's just a lonely black screen. Do you have any idea of what I can do to solve this problem?
Try to add -XstartOnFirstThread as a VM option
I have a strange bug where I get solid color bars instead of my image. It looks like I only have like 4 points of color. I'm not sure what I'm doing wrong
It sounds like you may have a mismatch of color components in your texture vs the actual image. I would make sure you're actually using rgba if the color has 4 components, or rgb if it only has 3 when you do glTexImage :)
@@GamesWithGabe I couldn't figure it out for the longest time but I finally came back to it after setting it aside. Turns out I number of dimensions wrong for my Texture coordinates. I was using 1 instead of 2 and that obviously causes everything to be misaligned. Whew that took me longer than it should have, but thanks for the help though :)
Hello! I am from the future hopefully you will still see this. We pretty much have the same code but I keep getting a NullPointException error pointing to the loadVertexProperties method more specifically vertices[offset + 6] = texCords[i].x;
vertices[offset + 7] = texCords[i].y;
It's saying that is cannot load from object array because "texCords" is null. I assume that is because texCords is never intialized or it is thinking texCords is something else rather than the things defined in SpriteRenderer class. Regardless I have been trying to fix this to no avail any help will be appreciated!
Hi Gabe I'm doing your whole tutorial right now but i'm kind of stuck atm.
i get this following message when I try to compile at the end:"0:15(27): error: sampler arrays indexed with non-constant expressions are forbidden in GLSL 1.30 and later"
If i change the integer id in the default.glsl file to a number for example 3 then the program runs but when i put in id, like you did i get the error. Do you have an idea what i should do? I saw online that people were able to get rid of the bug by updating to a newer OpenGL version, but that surely can't be the reason why it workes for you but not for me.
Best regards Henri
Hey Henri! So I later found out that the technique I showed in this video is technically undefined behavior. I saw another video of somebody doing it this way, and it was a lot easier than what I was doing previously, unfortunately like you found out its not supported everywhere. The easiest way to get around this is to have a large switch statement in your shader and then based on the index you can just access the texture array using a constant number. I can dig up an old example if you want, and if you join the Discord I know there are some other developers who can show you some examples of this :)
@@GamesWithGabe Thanks you for answering, first of all i want to say thank you for the tutorial i really appreciate it. Tbh i think I'm just fine if you send me the link on where they show how you would normally do it. I don't have too much time because my new Semester starts next week and I thought why not get in touch with java again with a project. Yea so the link would be amazing and if I decide I want to fully complete the tutorial and understand OpenGL even more I'll text you again :).
Cheers
Hey Henri it's no problem at all! Here's a link to a community project with the static indexing github.com/azurite-engine/Azurite/blob/65f99bd783bf87fd475005adc0c166c065c63f51/src/assets/shaders/default.glsl#L43 . You can just replace the code where you sample a texture with this and it should work alright. Best of luck with university!
@@GamesWithGabe Thank you very much!!
do you program a 2d game later?
Yea, we will be building Mario later with the engine
@@GamesWithGabe cool, i am currently trying to program a 2d game with java and eclipse
Nice! I hope development goes well!
Any reason you didn't just use int texId = textures.indexOf(sprite.getTexture)