use texture array instead of atlas for tiles
This commit is contained in:
@@ -52,7 +52,7 @@ gfx_defines! {
|
||||
trans: gfx::ConstantBuffer<::view::Trans> = "b_trans",
|
||||
constants: gfx::ConstantBuffer<Constants> = "b_constants",
|
||||
locals: gfx::ConstantBuffer<Locals> = "b_locals",
|
||||
atlas: gfx::TextureSampler<[f32; 4]> = "t_atlas",
|
||||
atlas: gfx::TextureSampler<[f32; 4]> = "t_tiles",
|
||||
pixcolor: gfx::RenderTarget<::view::ColorFormat> = "pixcolor",
|
||||
depth: gfx::DepthTarget<::view::DepthFormat> = gfx::preset::depth::LESS_EQUAL_WRITE,
|
||||
}
|
||||
@@ -157,7 +157,7 @@ impl<D: gfx::Device, F: gfx::Factory<D::Resources>> WorldScene<D, F> {
|
||||
locals: factory.create_constant_buffer(1),
|
||||
atlas: tile::get_tiles::<_, _, view::ColorFormat>(factory),
|
||||
sampler: factory.create_sampler(tex::SamplerInfo::new(tex::FilterMethod::Scale,
|
||||
tex::WrapMode::Clamp)),
|
||||
tex::WrapMode::Tile)),
|
||||
f: PhantomData,
|
||||
|
||||
vbuf: vertex_buffer,
|
||||
|
||||
Reference in New Issue
Block a user