13 Feb 2020 |
adamnemecek | https://github.com/gfx-rs/metal-rs/blob/master/examples/window/main.rs#L25 | 17:24:20 |
adamnemecek | https://github.com/gfx-rs/metal-rs/blob/master/examples/window/shaders.metal#L16 | 17:24:33 |
adamnemecek | i guess the functions got renamed, in metallib they are called triangle_* but metallib never got recompiled | 17:24:48 |
kvark | Make a pr plz? | 17:24:44 |
adamnemecek | will do, i also want to adda build script to compile the metallibs as opposd to include them in the repo | 17:25:47 |
adamnemecek | but i'm not sure how to get the name of the example in the build script | 17:26:06 |
adamnemecek | i checked the environment variables but it doesn't seem to dump the example name, only the library name | 17:26:33 |
adamnemecek | i guess i could recompile all the shaders? | 17:27:04 |
kvark | The build script is ran for the library, not each example | 17:27:29 |
adamnemecek | i guess i can use println!("cargo:rerun-if-changed=..."); | 17:28:26 |
adamnemecek | on the shaders? | 17:28:29 |
adamnemecek | or how would you do this? | 17:29:06 |
kvark | I'm not fluent in build scripts:) groves can advise better
but the rerun-if-changed sounds right here | 17:30:06 |
adamnemecek | ok i'll try to create a pr later today | 17:30:27 |
kvark | thank you! | 17:30:35 |
kvark | * thank you! xxx | 18:45:44 |
kvark | * thank you! | 18:45:51 |
mindtree | What is the most efficient approach to writing one texture to another where each have different TextureFormat s? Would the recommended approach be to sample the first texture within a fragment shader and draw it to the second as an output attachment? Or will the copy_texture_to_texture command implicitly take care of the conversion? E.g. in Vulkan, I believe when you blit a linear sRGBA image to a non-linear sRGBA image the implementation will implicitly perform the conversion. I'm wondering if copy_texture_to_texture behaves similarly? | 21:03:06 |
adamnemecek | https://github.com/gfx-rs/metal-rs/pull/111 | 21:15:09 |
adamnemecek | i'll add the build script | 21:15:25 |
adamnemecek | * i'll add the build script in a separate pr | 21:15:36 |
kvark | mindtree: only by a shader sampling from one and rendering to another (or a compute shader). Copies don't do conversions in wgpu by the spec today | 21:32:05 |
mindtree | @kvark thanks! | 21:33:18 |
adamnemecek | https://github.com/gfx-rs/metal-rs/pull/112/files | 21:46:25 |
adamnemecek | turns out my shader wasn't quite right but it should be now | 21:46:48 |
adamnemecek | i added the build script | 21:47:38 |
adamnemecek | right now it recompiles both compute and window if either of them changes | 21:47:45 |
adamnemecek | i'm not sure how to do it more selectively | 21:48:02 |
adamnemecek | also am i the only one for whom messages get delayed? | 21:48:14 |
adamnemecek | this issue can be closed now https://github.com/gfx-rs/metal-rs/issues/75 | 21:48:25 |