mirror of
https://github.com/italicsjenga/vello.git
synced 2025-01-10 12:41:30 +11:00
commit
942da778a3
|
@ -15,6 +15,7 @@ pollster = "0.2.5"
|
||||||
# for picosvg
|
# for picosvg
|
||||||
roxmltree = "0.13"
|
roxmltree = "0.13"
|
||||||
clap = { version = "4.1.0", features = ["derive"] }
|
clap = { version = "4.1.0", features = ["derive"] }
|
||||||
|
env_logger = "0.10.0"
|
||||||
|
|
||||||
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
|
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
|
||||||
vello = { path = "../../", features = ["hot_reload"] }
|
vello = { path = "../../", features = ["hot_reload"] }
|
||||||
|
|
|
@ -225,6 +225,7 @@ enum UserEvent {
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
let args = Args::parse();
|
let args = Args::parse();
|
||||||
|
env_logger::init();
|
||||||
#[cfg(not(target_arch = "wasm32"))]
|
#[cfg(not(target_arch = "wasm32"))]
|
||||||
{
|
{
|
||||||
use winit::{dpi::LogicalSize, window::WindowBuilder};
|
use winit::{dpi::LogicalSize, window::WindowBuilder};
|
||||||
|
|
|
@ -96,12 +96,11 @@ impl RenderContext {
|
||||||
|
|
||||||
/// Creates a compatible device handle id.
|
/// Creates a compatible device handle id.
|
||||||
async fn new_device(&mut self, compatible_surface: Option<&Surface>) -> Option<usize> {
|
async fn new_device(&mut self, compatible_surface: Option<&Surface>) -> Option<usize> {
|
||||||
let adapter = self
|
let adapter = wgpu::util::initialize_adapter_from_env_or_default(
|
||||||
.instance
|
&self.instance,
|
||||||
.request_adapter(&RequestAdapterOptions {
|
wgpu::Backends::PRIMARY,
|
||||||
compatible_surface,
|
compatible_surface,
|
||||||
..Default::default()
|
)
|
||||||
})
|
|
||||||
.await?;
|
.await?;
|
||||||
let features = adapter.features();
|
let features = adapter.features();
|
||||||
let limits = Limits::default();
|
let limits = Limits::default();
|
||||||
|
|
Loading…
Reference in a new issue