Skip to content

Commit

Permalink
Process Ears features from skin even when loading from cache
Browse files Browse the repository at this point in the history
  • Loading branch information
NickAcPT committed Nov 3, 2024
1 parent e621000 commit e621000
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion nmsr-aas/src/model/resolver/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,16 @@ impl RenderRequestResolver {
&self,
entry: &RenderRequestEntry,
) -> Result<ResolvedRenderEntryTextures> {
if let Some(result) = self.model_cache.get_cached_resolved_texture(entry).await? {
#[cfg_attr(not(feature = "ears"), allow(unused_mut))]
if let Some(mut result) = self.model_cache.get_cached_resolved_texture(entry).await? {
#[cfg(feature = "ears")]
if let Some(skin) = result.textures.remove(&ResolvedRenderEntryTextureType::Skin) {
Self::resolve_ears_textures(&skin, &mut result.textures);
result.textures.insert(ResolvedRenderEntryTextureType::Skin, skin);

return Ok(result);
}

return Ok(result);
}

Expand Down

0 comments on commit e621000

Please sign in to comment.