[Bf-blender-cvs] [3936b96ad7c] temp-eevee-next-cryptomatte: Remove unneeded access to instance attribute.
Jeroen Bakker
noreply at git.blender.org
Fri Sep 2 08:33:13 CEST 2022
Commit: 3936b96ad7c0882dd8d3f33ff51bf49f33215fe2
Author: Jeroen Bakker
Date: Fri Sep 2 08:25:02 2022 +0200
Branches: temp-eevee-next-cryptomatte
https://developer.blender.org/rB3936b96ad7c0882dd8d3f33ff51bf49f33215fe2
Remove unneeded access to instance attribute.
===================================================================
M source/blender/draw/engines/eevee_next/eevee_film.cc
M source/blender/draw/engines/eevee_next/eevee_film.hh
===================================================================
diff --git a/source/blender/draw/engines/eevee_next/eevee_film.cc b/source/blender/draw/engines/eevee_next/eevee_film.cc
index 393f9856579..dec40a9cdc0 100644
--- a/source/blender/draw/engines/eevee_next/eevee_film.cc
+++ b/source/blender/draw/engines/eevee_next/eevee_film.cc
@@ -474,12 +474,11 @@ void Film::sync()
cryptomatte_post_ps_ = DRW_pass_create("Film.Cryptomatte.Post", DRW_STATE_NO_DRAW);
GPUShader *sh = inst_.shaders.static_shader_get(FILM_CRYPTOMATTE_POST);
DRWShadingGroup *grp = DRW_shgroup_create(sh, cryptomatte_post_ps_);
- Texture &cryptomatte_tx = inst_.film.cryptomatte_tx_get();
- DRW_shgroup_uniform_image_ref(grp, "cryptomatte_img", &cryptomatte_tx);
+ DRW_shgroup_uniform_image_ref(grp, "cryptomatte_img", &cryptomatte_tx_);
DRW_shgroup_uniform_int_copy(grp, "cryptomatte_layer_len", cryptomatte_layer_count);
DRW_shgroup_uniform_int_copy(
grp, "cryptomatte_samples_per_layer", inst_.view_layer->cryptomatte_levels);
- int3 dispatch_size = math::divide_ceil(cryptomatte_tx.size(), int3(FILM_GROUP_SIZE));
+ int2 dispatch_size = math::divide_ceil(int2(cryptomatte_tx_.size()), int2(FILM_GROUP_SIZE));
DRW_shgroup_call_compute(grp, UNPACK2(dispatch_size), 1);
}
else {
diff --git a/source/blender/draw/engines/eevee_next/eevee_film.hh b/source/blender/draw/engines/eevee_next/eevee_film.hh
index b2543ebede9..7ec405d8a58 100644
--- a/source/blender/draw/engines/eevee_next/eevee_film.hh
+++ b/source/blender/draw/engines/eevee_next/eevee_film.hh
@@ -101,11 +101,6 @@ class Film {
return data_.background_opacity;
}
- Texture &cryptomatte_tx_get()
- {
- return cryptomatte_tx_;
- }
-
eViewLayerEEVEEPassType enabled_passes_get() const;
int cryptomatte_layer_max_get() const;
int cryptomatte_layer_len_get() const;
More information about the Bf-blender-cvs
mailing list