Skip to content

Conversation

@sim-the-bean
Copy link
Contributor

This is a simple pr that implements 3d textures as a mostly-copy of 2d textures.

One big, potentially breaking change is that now RenderResource requires an implementation of fn texture3d, which works just like fn texture. The derive macro has been updated to support this.

I haven't tested this yet properly, so I'm making it a draft until I've verified that this works.

@karroffel karroffel added C-Feature A new feature, making something new possible A-Rendering Drawing game state to the screen labels Sep 7, 2020
@tsal
Copy link

tsal commented Sep 19, 2020

Would this be better served as a new Trait that extends the RenderResource trait - something like:

pub trait RenderResource3d: RenderResource  {
    fn texture3d(&self) -> Option<Handle<Texture3D>>;
}

I'm still a bit new to Rust, but if I'm understanding traits, this kind of makes sense if we want to write systems specific to 3d textures vs 2d.

@cart
Copy link
Member

cart commented Dec 30, 2020

Closed in favor of #903

@cart cart closed this Dec 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Rendering Drawing game state to the screen C-Feature A new feature, making something new possible

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants