Fixed screenshot

This commit is contained in:
maik klein 2016-12-12 04:30:01 +01:00
parent 8e60030a04
commit 9ba4ac429f
3 changed files with 2 additions and 3 deletions

View file

@ -122,7 +122,7 @@ cargo run
### [Triangle](https://github.com/MaikKlein/ash/blob/master/examples/texture/src/main.rs) ### [Triangle](https://github.com/MaikKlein/ash/blob/master/examples/texture/src/main.rs)
Display a texture on a quad. Needs a cleanup. Display a texture on a quad. Needs a cleanup.
![texture](https://i.imgur.com/HozDzta.png) ![texture](http://i.imgur.com/trow00H.png)
## Open questions ## Open questions

View file

@ -13,7 +13,6 @@ layout (location = 0) in vec2 o_uv;
layout (location = 0) out vec4 uFragColor; layout (location = 0) out vec4 uFragColor;
void main() { void main() {
//uFragColor = o_color;
vec4 color = texture(samplerColor, o_uv); vec4 color = texture(samplerColor, o_uv);
uFragColor = color; uFragColor = color;
} }

View file

@ -558,7 +558,7 @@ fn main() {
queue_family_index_count: 0, queue_family_index_count: 0,
p_queue_family_indices: ptr::null(), p_queue_family_indices: ptr::null(),
}; };
let uniform_color_buffer_data = [0.0f32, 1.0, 1.0]; let uniform_color_buffer_data = [0.0f32, 0.0, 1.0];
let uniform_color_buffer = device.create_buffer(&uniform_color_buffer_info).unwrap(); let uniform_color_buffer = device.create_buffer(&uniform_color_buffer_info).unwrap();
let uniform_color_buffer_memory_req = let uniform_color_buffer_memory_req =
device.get_buffer_memory_requirements(uniform_color_buffer); device.get_buffer_memory_requirements(uniform_color_buffer);