/*
* The primary draw target
*/
- "Main",
+ "main",
.link = &gpipeline.fb_main,
.resolution_div = 1,
.attachments =
{
{
- "Colour", k_framebuffer_attachment_type_colour,
+ "colour", k_framebuffer_attachment_type_colour,
.internalformat = GL_RGB,
.format = GL_RGB,
.attachment = GL_COLOR_ATTACHMENT0
},
{
- "Motion Vectors", k_framebuffer_attachment_type_colour,
+ "motion", k_framebuffer_attachment_type_colour,
.quality = k_framebuffer_quality_high_only,
.internalformat = GL_RG16F,
.attachment = GL_COLOR_ATTACHMENT1
},
{
- "Depth/Stencil", k_framebuffer_attachment_type_renderbuffer,
+ "depth_stencil", k_framebuffer_attachment_type_renderbuffer,
.internalformat = GL_DEPTH24_STENCIL8,
.attachment = GL_DEPTH_STENCIL_ATTACHMENT
* Note: it does not have a render buffer attachement because it's
* intended to be drawn to in a MAX blending mode
*/
- "Heightmap",
+ "heightmap",
.link = &gpipeline.fb_heightmap,
.fixed_w = 1024,
.fixed_h = 1024,
.attachments =
{
{
- "Depth", k_framebuffer_attachment_type_colour,
+ "depth", k_framebuffer_attachment_type_colour,
.internalformat = GL_R32F,
.format = GL_RED,
/*
* Second rendered view from the perspective of the water reflection
*/
- "Water reflection",
+ "water_reflection",
.link = &gpipeline.fb_water_reflection,
.resolution_div = 3,
.attachments =
{
{
- "Colour", k_framebuffer_attachment_type_colour,
+ "colour", k_framebuffer_attachment_type_colour,
.internalformat = GL_RGB,
.format = GL_RGB,
.type = GL_UNSIGNED_BYTE,
.attachment = GL_COLOR_ATTACHMENT0
},
{
- "Depth/Stencil", k_framebuffer_attachment_type_renderbuffer,
+ "depth_stencil", k_framebuffer_attachment_type_renderbuffer,
.internalformat = GL_DEPTH24_STENCIL8,
.attachment = GL_DEPTH_STENCIL_ATTACHMENT
* Thid rendered view from the perspective of the camera, but just
* captures stuff thats under the water
*/
- "Water Beneath",
+ "water_beneath",
.link = &gpipeline.fb_water_beneath,
.resolution_div = 4,
.attachments =
{
{
- "Colour", k_framebuffer_attachment_type_colour,
+ "colour", k_framebuffer_attachment_type_colour,
.internalformat = GL_RGBA,
.format = GL_RGBA,
.type = GL_UNSIGNED_BYTE,
.attachment = GL_COLOR_ATTACHMENT0
},
{
- "Depth/Stencil", k_framebuffer_attachment_type_renderbuffer,
+ "depth_stencil", k_framebuffer_attachment_type_renderbuffer,
.internalformat = GL_DEPTH24_STENCIL8,
.attachment = GL_DEPTH_STENCIL_ATTACHMENT
0.0f, 0.0f, 1.0f, 0.0f, 1.0f, 1.0f,
0.2f, 0.0f, 0.8f, 1.0f, 0.2f, 1.0f,
- 0.2f, 0.0f, 0.8f, 0.0f, 0.8f, 1.0f};
+ 0.2f, 0.0f, 0.8f, 0.0f, 0.8f, 1.0f };
glGenVertexArrays( 1, &gpipeline.fsquad.vao );
glGenBuffers( 1, &gpipeline.fsquad.vbo );
glBufferData( GL_ARRAY_BUFFER, sizeof(quad), quad, GL_STATIC_DRAW );
glBindVertexArray( gpipeline.fsquad.vao );
glVertexAttribPointer( 0, 2, GL_FLOAT, GL_FALSE,
- sizeof(float)*2, (void*)0 );
+ sizeof(float)*2, (void*)0 );
glEnableVertexAttribArray( 0 );
VG_CHECK_GL_ERR();