How to Add Postprocessing Bloom Effect to a Specific Model in Your Scene

I was able to successfully add global bloom to my scene, but now I want to apply this effect to a specific child model, such as “cube001.” I haven’t found any one-line resources for this yet, and the only YouTube video I found was not helpful.

I want to use Postprocessing to achieve this because I need to render the scene in a specific way that other sources cannot provide.

Here’s a live example of my scene with global bloom, but I need to be able to target the child cube as I mentioned. Any help would be greatly appreciated. Thank you.all

live : selection - bloom - CodeSandbox

You can control bloom strength (and presence) by modifying .emissiveIntensity on the materials applied to the model - in your example, try adding the following in place of lines 125-135:

const child = gltf.scene.getObjectByName("Cube001");

let dt = 0.0;
setInterval(() => {
  dt += 0.01;

  child.material.emissiveIntensity = Math.sin(dt);
}, 100);

scene.add(child);

If multiple models share the same material - keep in mind changing the .emissiveIntensity will change it on all models with that specific material. To avoid this, clone the material you’re planning to modify:

const makeShiny = (model, howShiny = 1.0) => {
  model.traverse(child => {
    if (child.material) {
      child.material = child.material.clone();

      child.material.emissiveIntensity = howShiny || 0.0;
    }
  });
};

(You can later optimise it by creating shiny / nonshiny materials instead of cloning materials on every model - since that can get a bit expensive, if you’re planning to have a lot of models in the scene.)

there is a misconception about bloom and like @mjurczyk said, you control bloom on the materials. it starts with the threshold which all bloom effects have. you set the threshold to 1, which means that nothing blooms as long as colors are between 0-1 RGB. if a color goes beyond that it starts to bloom, but for that to work you need to switch off toneMapping on the material.

you can use emissiveIntensity, or even color.set(10, 0, 0) which is 10R 0G 0B, so an intensely glowing red.