From 8461147ca081c0626cbce5f42a4cf1899fb076f8 Mon Sep 17 00:00:00 2001 From: Ben Hansen Date: Mon, 1 Jun 2020 13:01:12 -0600 Subject: [PATCH] fixed #44 fixed $48 --- docs/.vuepress/dist | 2 +- docs/beginner/tutorial5-textures/README.md | 4 ++-- docs/beginner/tutorial9-models/README.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/docs/.vuepress/dist b/docs/.vuepress/dist index bbc5f48e..16140025 160000 --- a/docs/.vuepress/dist +++ b/docs/.vuepress/dist @@ -1 +1 @@ -Subproject commit bbc5f48e574cb17ceae63ace67e71e5e19bfe452 +Subproject commit 16140025e6cff3045a74b0a3f30e45f793e89183 diff --git a/docs/beginner/tutorial5-textures/README.md b/docs/beginner/tutorial5-textures/README.md index 4a471aed..ccfaaafd 100644 --- a/docs/beginner/tutorial5-textures/README.md +++ b/docs/beginner/tutorial5-textures/README.md @@ -396,9 +396,9 @@ pub struct Texture { impl Texture { // 1. - pub fn from_bytes(device: &wgpu::Device, bytes: &[u8]) -> Result<(Self, wgpu::CommandBuffer), failure::Error> { + pub fn from_bytes(device: &wgpu::Device, bytes: &[u8], label: &str) -> Result<(Self, wgpu::CommandBuffer), failure::Error> { let img = image::load_from_memory(bytes)?; - Self::from_image(device, &img) + Self::from_image(device, &img, Some(label)) } pub fn from_image(device: &wgpu::Device, img: &image::DynamicImage) -> Result<(Self, wgpu::CommandBuffer), failure::Error> { diff --git a/docs/beginner/tutorial9-models/README.md b/docs/beginner/tutorial9-models/README.md index 558cb426..166c8e78 100644 --- a/docs/beginner/tutorial9-models/README.md +++ b/docs/beginner/tutorial9-models/README.md @@ -73,7 +73,7 @@ let render_pipeline = device.create_render_pipeline(&wgpu::RenderPipelineDescrip }); ``` -With all that in place we need a model to render. If you have one already that's great, but I've supplied a [zip file](https://github.com/sotrh/learn-wgpu/tree/master/code/beginner/tutorial9-model/src/res) with the model and all of it's textures. We're going to put this model in a new `res` folder. +With all that in place we need a model to render. If you have one already that's great, but I've supplied a [zip file](https://github.com/sotrh/learn-wgpu/blob/master/code/beginner/tutorial9-models/src/res/cube.zip) with the model and all of it's textures. We're going to put this model in a new `res` folder. Speaking of textures, let's add a `load()` method to `Texture` in `texture.rs`.