Skip to content

Commit c6d5ee3

Browse files
Merge pull request #127 from nipunG314/master
Move clustered_rendering ex to examples submodule
2 parents 9c83d32 + 3e53ad1 commit c6d5ee3

19 files changed

+6927
-0
lines changed

old_to_refactor/07.SubpassBaking/main.cpp

Lines changed: 482 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
include(common RESULT_VARIABLE RES)
2+
if(NOT RES)
3+
message(FATAL_ERROR "common.cmake not found. Should be in {repo_root}/cmake directory")
4+
endif()
5+
6+
set(EXAMPLE_SOURCES
7+
../../src/nbl/ext/LumaMeter/CLumaMeter.cpp
8+
../../src/nbl/ext/ToneMapper/CToneMapper.cpp
9+
)
10+
11+
set(ASSET_DIR ${PROJECT_SOURCE_DIR}/examples_tests/media)
12+
13+
nbl_create_executable_project("${EXAMPLE_SOURCES}" "" "" ${ASSET_DIR})
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
#version 430 core
2+
3+
// Copyright (C) 2018-2020 - DevSH Graphics Programming Sp. z O.O.
4+
// This file is part of the "Nabla Engine".
5+
// For conditions of distribution and use, see copyright notice in nabla.h
6+
7+
// vertex shader is provided by the fullScreenTriangle extension
8+
9+
layout (set = 3, binding = 0) uniform usampler2DArray tex0;
10+
11+
layout(location = 0) in vec2 TexCoord;
12+
13+
layout(location = 0) out vec4 pixelColor;
14+
15+
void main()
16+
{
17+
const uint packed = texture(tex0, vec3(TexCoord.x, TexCoord.y, 1.0)).r;
18+
pixelColor = unpackUnorm4x8(packed);
19+
}

0 commit comments

Comments
 (0)