Latest In


Sphere Mask - Creating A Belching Chimney

A mask value is produced by the sphere mask expression, and it is determined by a calculation of distance.

Author:Morgan Maverick
Reviewer:Raven Noir
Jun 13, 202223 Shares685 Views
A mask value is produced by the sphere maskexpression, and it is determined by a calculation of distance.
The mask value is 0 outside and 1 inside with some transition area in between if one of the inputs is the position of a point and the other input is the center of a sphere with some radius.
This is valid for component vectors with one, two, three, and four elements.

Belching Chimney

According to jesshiderue4, he was seeking a way to make a chimney that 'belched' out puffs of smoke, and dragging a sphere mask up the model seemed like one approach to accomplish this goal.
Black and grey belching chimney material diagram
Black and grey belching chimney material diagram
The Material is composed of two primary components:
  • The first causes the chimney to grow along the X and Y axes
  • While the second of which brings this motion upward along the Z-axis.
Black and grey background sphere mask in out pulse diagram
Black and grey background sphere mask in out pulse diagram
Utilizing a sine wave allows him to control how far in and out the Chimney moves.
After multiplying Time by 0.2, which slowed down the movement, he then multiplied the sine wave by 20, which made the expansion far larger. He gets rid of any negative values by taking this thing's absolute value (Abs) (which will stop my mesh from shrinking to smaller than its original size).
Red and blue waves in white background sphere mask graph
Red and blue waves in white background sphere mask graph
After that, he multiplies the VertexNormalWS by the modified Sine wave, and then he masks out the B channel, which corresponds to the Z-direction so that the chimney only expands in the horizontal direction.
After that, he appends the vector, setting the Z direction to zero, so that he ends up with a three-dimensional vector.
Note - As stated in the Material, do not remove the Z-movement until after the Sine wave and Vertex Normals have been multiplied together.
This is the only time that this may be done. If it is done before, the material will twist into an egg form rather than grow horizontally in an even manner.
Black and grey background move sphere mask up in z-axis diagram
Black and grey background move sphere mask up in z-axis diagram
In the second phase, he masked out the horizontal growth by using a sphere mask that he moved about.
He found Eric's explanation of a sphere mask to be quite helpful in comprehending how a sphere mask functions, and consequently how one may operate one.
The sphere mask creates a sphere that is centered on the actor's position by basically taking into account both the position of the Absolute World Position and the actor's position.
In order to raise the level of the sphere, then he first adjusts the Actor Position along the Z-axis by one.
He divides Time by 0.8 to have it move at a more leisurely pace, and then he takes the Frac.
The way that Frac works is by deleting the integer component of the number, leaving me with a value that loops and increments between 0.01 and 0.99 (with two decimal places).
After performing this operation (which makes the value visible in my world space), he appends it to the Z-part of a vector and then multiplies it by 400.
After making this adjustment to the Actor Position, he feeds the new value into the SphereMask.
Black and grey background sphere mask Z-axis diagram.
Black and grey background sphere mask Z-axis diagram.
The result of the SphereMask is plugged into Lerp's Alpha input, while the VertexNormalWS input is used for Lerp's A input, and the Appended vector input is used for Lerp's B input.
The final step involves connecting the output of the Lerp to the World Position Offset.

Unity Shader Graph Mask

How Do I Change The Color Of My Shader Graph In Unity?

  • Right-click on your project and select Create > Shader > PBR Graph.
  • Name the new Shader “SampleGraph.”
  • Double-click the Shader you created to open it.
  • In the new window that opens, right-click and select Create Node.
  • Type in “Color” and click the result that matches.

Mask Textures Blender

How Do I Add A Layer Mask To A Layer?

Choose the two pictures you want to mask, and then organize them into two distinct layers. Click the "Add layer mask" button at the bottom of the Layers panel once you have chosen a layer to mask in the Layers panel. On the layer that was selected, a white layer mask thumbnail will emerge, displaying everything that was on the layer that was selected.

People Also Ask

What Are The Properties Of Sphere Mask?

  • Provides the radius that will be utilized for calculating the distance.
  • Identifies the dimensions of the transition area. This operates similarly to the brush hardness value in Photoshop. 0 indicates that the transition is challenging, while 100 indicates that the transition area is at its greatest (soft).

What Are The Inputs Of A Sphere Mask?

  • A - The value that represents the position of the point to check is taken as an input here.
  • B - This function takes the value that represents the center of the sphere as its input.

What Are The Applications Of A Sphere Mask?

Sphere mask has a wide variety of applications. For example, in this scenario, it is used to scale a mesh along the Z-axis, to scale the mesh along all axes, and as an opacity mask.


Have you ever used a sphere mask? Do let us know in the comment section below.
Have you heard about real life Shrek?
Jump to
Morgan Maverick

Morgan Maverick

Morgan Maverick is an unorthodox news reporter driven by an insatiable hunger for the truth. Fearless and unconventional, he uncovers hidden narratives that lie beneath the surface, transforming each news piece into a masterpiece of gritty authenticity. With a dedication that goes beyond the boundaries of conventional journalism, Morgan fearlessly explores the fringes of society, giving voice to the marginalized and shedding light on the darkest corners. His raw and unfiltered reporting style challenges established norms, capturing the essence of humanity in its rawest form. Morgan Maverick stands as a beacon of truth, fearlessly pushing boundaries and inspiring others to question, dig deeper, and recognize the transformative power of journalism.
Raven Noir

Raven Noir

Raven Noir is a captivating and enigmatic news reporter who unravels mysteries with a relentless pursuit of truth. Possessing an insatiable curiosity and an astute mind, Raven delves into the depths of complex stories, unearthing secrets that lie beneath the surface. With a masterful grasp of deduction and observation, Raven stands as a beacon of fearless investigation. In the realm of journalism, Raven is known for his enigmatic presence, drawing people in with an aura of intrigue. Driven by an unwavering passion for unveiling the truth, Raven Noir continues to shed light on the darkest corners of society. Through captivating storytelling and unwavering determination, he challenges conventions and uncovers enigmatic secrets that lie just beyond the surface.
Latest Articles
Popular Articles