wgpu: Use the preferred texture format of the surface

Signed-off-by: Tilmann Meyer <me@atiltedtree.dev>
This commit is contained in:
Tilmann Meyer 2021-08-01 20:38:34 +02:00
parent a08e4ebccb
commit d7975a9de5
No known key found for this signature in database
GPG key ID: A95E199988004B62
4 changed files with 37 additions and 33 deletions

View file

@ -6,11 +6,6 @@ pub use crate::Antialiasing;
/// [`Backend`]: crate::Backend
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub struct Settings {
/// The output format of the [`Backend`].
///
/// [`Backend`]: crate::Backend
pub format: wgpu::TextureFormat,
/// The present mode of the [`Backend`].
///
/// [`Backend`]: crate::Backend
@ -68,7 +63,6 @@ impl Settings {
impl Default for Settings {
fn default() -> Settings {
Settings {
format: wgpu::TextureFormat::Bgra8UnormSrgb,
present_mode: wgpu::PresentMode::Mailbox,
internal_backend: wgpu::BackendBit::PRIMARY,
default_font: None,