1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:07:35 +00:00

LibSoftGPU: Make samplers part of device

This adds a sampler array to the device implementation and adds a method
`set_sampler_config` to configure samplers.
This commit is contained in:
Stephan Unverwerth 2021-12-20 16:14:40 +01:00 committed by Brian Gianforcaro
parent b8bb72abbe
commit 2a72d14336
2 changed files with 13 additions and 0 deletions

View file

@ -812,4 +812,11 @@ NonnullRefPtr<Image> Device::create_image(ImageFormat format, unsigned width, un
return adopt_ref(*new Image(format, width, height, depth, levels, layers));
}
void Device::set_sampler_config(unsigned sampler, SamplerConfig const& config)
{
VERIFY(sampler < num_samplers);
m_samplers[sampler].set_config(config);
}
}