3D Graphics Engine Progress
Moderator: PC Supremacists
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] 3D Engine Progress
MrDeathNote wrote:Lol, your right it does look awesome
:P Got a new screenshot, the artist fixed the door texture and stuffeatcomics wrote:that's awesome :D
![Happy :)](./images/smilies/icon_smile.gif)
->
![Image](http://groundupengine.webs.com/photos/Engine-tests/39.png)
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] lol
I changed class Vector3 to vec3 and CObject to Object
->
![Image](http://groundupengine.webs.com/photos/Engine-tests/40-1.png)
![Laughing :lol:](./images/smilies/icon_lol.gif)
->
![Image](http://groundupengine.webs.com/photos/Engine-tests/40-1.png)
- MrDeathNote
- ES Beta Backer
- Posts: 594
- Joined: Sun Oct 11, 2009 9:57 am
- Current Project: cocos2d-x project
- Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
- Programming Language of Choice: C/++
- Location: Belfast, Ireland
- Contact:
Re: [GroundUpEngine] lol
Lol niceGroundUpEngine wrote:I changed class Vector3 to vec3 and CObject to Object![]()
->
![Laughing :lol:](./images/smilies/icon_lol.gif)
http://www.youtube.com/user/MrDeathNote1988
![Image](http://img34.imageshack.us/img34/1706/22263.gif)
![Image](http://f.imagehost.org/0636/1399.jpg)
"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
![Image](http://img34.imageshack.us/img34/1706/22263.gif)
![Image](http://f.imagehost.org/0636/1399.jpg)
"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
-
- Chaos Rift Junior
- Posts: 345
- Joined: Tue Jan 12, 2010 7:23 pm
- Favorite Gaming Platforms: PC - Windows 7
- Programming Language of Choice: c++;haxe
- Contact:
Re: [GroundUpEngine] lol
+1. I especially love it when you have 10,000 errors and changing one/two things suddenly results in a compiled EXE. At first it's like "Man, this shits broken to hell, it'll never be fixed". Then it's like cool.MrDeathNote wrote:Lol niceGroundUpEngine wrote:I changed class Vector3 to vec3 and CObject to Object![]()
->
![Image](http://i48.tinypic.com/11296pl.png)
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] 3D Engine Progress
Tutorial Attempt:
Small vid on basic GLSL, and ease of use in Engine->
Link - http://www.youtube.com/watch?v=C-wUcP2I6Fo
![Laughing :lol:](./images/smilies/icon_lol.gif)
Small vid on basic GLSL, and ease of use in Engine->
Link - http://www.youtube.com/watch?v=C-wUcP2I6Fo
Re: [GroundUpEngine] 3D Engine Progress
Hehe, nice! Now do some lighting with it
I can help you with shader stuff if you need it ![Wink ;)](./images/smilies/icon_wink.gif)
![Wink ;)](./images/smilies/icon_wink.gif)
![Wink ;)](./images/smilies/icon_wink.gif)
- MrDeathNote
- ES Beta Backer
- Posts: 594
- Joined: Sun Oct 11, 2009 9:57 am
- Current Project: cocos2d-x project
- Favorite Gaming Platforms: SNES, Sega Megadrive, XBox 360
- Programming Language of Choice: C/++
- Location: Belfast, Ireland
- Contact:
Re: [GroundUpEngine] 3D Engine Progress
Nice!
http://www.youtube.com/user/MrDeathNote1988
![Image](http://img34.imageshack.us/img34/1706/22263.gif)
![Image](http://f.imagehost.org/0636/1399.jpg)
"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
![Image](http://img34.imageshack.us/img34/1706/22263.gif)
![Image](http://f.imagehost.org/0636/1399.jpg)
"C makes it easy to shoot yourself in the foot. C++ makes it
harder, but when you do, it blows away your whole leg." - Bjarne Stroustrup
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] 3D Engine Progress
Thanks ![Wink ;)](./images/smilies/icon_wink.gif)
*goes off to try learn some per pixel lighting*
![Wink ;)](./images/smilies/icon_wink.gif)
*goes off to try learn some per pixel lighting*
Re: [GroundUpEngine] 3D Engine Progress
You should try to make the color of your "red"-shader a uniform variable, which you can set from your program ![Wink ;)](./images/smilies/icon_wink.gif)
![Wink ;)](./images/smilies/icon_wink.gif)
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] 3D Engine Progress
Ah I see, so 'uniform' is like constants in C++ and varying is the opposite ![Happy :)](./images/smilies/icon_smile.gif)
![Happy :)](./images/smilies/icon_smile.gif)
Re: [GroundUpEngine] 3D Engine Progress
No. Uniforms are your normal parameters you can pass to your shader. It's more or less like a parameter of a function call
For example, your color could be set in your program with
![Wink ;)](./images/smilies/icon_wink.gif)
Code: Select all
float r,g,b;
glSendUniform3f(glGetUniformLocation("color"), r, g, b);
Code: Select all
#version 120
uniform vec3 color;
const float alpha = 0.3;
void main()
{
gl_FragColor = vec4(color, alpha);
}
- GroundUpEngine
- Chaos Rift Devotee
- Posts: 835
- Joined: Sun Nov 08, 2009 2:01 pm
- Current Project: mixture
- Favorite Gaming Platforms: PC
- Programming Language of Choice: C++
- Location: UK
Re: [GroundUpEngine] 3D Engine Progress
Oh damn
/fail
Sweet, thanks for the info!
![Laughing :lol:](./images/smilies/icon_lol.gif)
/fail
Sweet, thanks for the info!
-
- Respected Programmer
- Posts: 387
- Joined: Fri Dec 19, 2008 3:33 pm
- Location: Dallas
- Contact:
Re: [GroundUpEngine] 3D Engine Progress
No, you had it right.
"uniform" variables in GLSL are indeed read-only (constant). They are passed to constant registers on the logic unit (You can define them at compile time (in the shader) or link time (from the caller). "varying" parameters in GLSL are passed by "register" so its almost like the "register" keyword in C++ and only the vertex units and pixel ALU's can write to GPU registers.
They're trying to make GLSL a little more HLSL-esque so "varying" is actually deprecated in the current version of GLSL (although every driver i've seen still supports it). The preferred method is the HLSL syntax of "out"/"in".
"uniform" variables in GLSL are indeed read-only (constant). They are passed to constant registers on the logic unit (You can define them at compile time (in the shader) or link time (from the caller). "varying" parameters in GLSL are passed by "register" so its almost like the "register" keyword in C++ and only the vertex units and pixel ALU's can write to GPU registers.
They're trying to make GLSL a little more HLSL-esque so "varying" is actually deprecated in the current version of GLSL (although every driver i've seen still supports it). The preferred method is the HLSL syntax of "out"/"in".