HOW TO Color Mask in Blender Shader⬅️ No Photoshop Needed!

  Рет қаралды 11,802

Chris P

Chris P

Күн бұрын

How to create a color mask (chroma key) from an image/texture so we can easily change colors or materials inside a shader node tree WITHOUT going to an external photo editor app to create a mask!
2 quick EXTRAS for this tutorial in that video: • ➕ In-Shader Chroma Key...
"Donut Sunday" Artwork: www.kittl.com/stefano
💗 LIKE, COMMENT, SUBSCRIBE - THANK YOU! 💗
💥 ChrisP's Feature-Packed Startup File for Blender: • ChrisP's Feature-Packe...
Realistic Material Packs for EEVEE+Cycles: chrisp.zone/blendermarket
🔥 Note: "Gold Monkey" Patrons get free access to all existing and future material packs!
Patreon / chrisp
Blendermarket blendermarket.com/creators/ch...
Brave brave.com/chr471
Twitter / chrisprenn
Insta / chrisprenn
Home chrisp.zone

Пікірлер: 45
@chrisprenn
@chrisprenn 2 жыл бұрын
Here's the back story: I was working on a product visualization for a client and they sent me a PDF of the product label with the note "everything displayed in yellow will be printed with a gold foil application". I would have made a quick mask with a photo editor app but I knew the design will change frequently until it is finalized so I wanted to create a chroma key / color mask inside the shader node tree. You would think this is as easy as using one of the many nodes Blender has to offer? Turns out, you have to do a little bit of work . And this video shows what I came up with.
@seanaholic
@seanaholic 4 күн бұрын
For anyone coming here after they've updated to 4.1, the "HSV" node thing at around 1:26 has been modified. It will no longer be titled "Separate HSV". Instead, use the "Separate Color" node, and there will be a stand-in drop down where you can pick HSV as an option. Great Tutorial btw, lucky to have found it here. Good luck to you guys.
@_evildoer
@_evildoer 2 жыл бұрын
This can be greatly simplified with the compare function in the math node. The epsilon replaces the add and subtract nodes, and you don't need the less than and greater than nodes either. Its all done in one node. 5 nodes vs 20 altogether
@chrisprenn
@chrisprenn 2 жыл бұрын
I was so focused on explaining WHY that I forgot to think about optimizing the node tree... Using the compare node + blurring the mask here: kzfaq.info/get/bejne/o9eRlJuWuteupKc.html
@mobinvaryan7196
@mobinvaryan7196 Жыл бұрын
thank you i looked for this tutorial for weeks and what good comment sections you also have great viewers I'm glad to find this video
@WiremuTeKani
@WiremuTeKani Жыл бұрын
This is exactly what I was looking for - thank you for this great tutorial!
@user-zb9cj6mt5n
@user-zb9cj6mt5n 7 ай бұрын
HEY SIR ! IT WAS EXTREMELY NICE , LEARNT A LOT THANK YOU , .
@TiagoTiagoT
@TiagoTiagoT Жыл бұрын
It's a bit hard to spell out the whole noodle setup in a KZfaq comment, but for a feathered mask (softer transition between selected and unselected), you use the vector math Distance node to get the distances between colors (if you wanna measure in HSV space, plug a Separate HSV into a Combine XYZ node to "convert"), and you can control the influence of each component by multiplying the vectors of both the image and the selected color by a same vector before they go into the Distance node, and the overall intensity of the curve can be controlled with math or float curve (or gradient, or map range etc) after the Distance node. Oh, and don't forget to cap the value to the 0-1 range before using it as a Mix factor or whatever.
@bDwS27
@bDwS27 2 жыл бұрын
fantastic! I've been doing this in a much less practical way , great stuff!
@chrisprenn
@chrisprenn 2 жыл бұрын
Simplify the node tree: kzfaq.info/get/bejne/o9eRlJuWuteupKc.html
@YvesBonheur
@YvesBonheur 6 ай бұрын
I find your tuts are extremely helpful and useful,whether it's about shader nodes or geo nodes,thank you so much🥰
@chrisprenn
@chrisprenn 6 ай бұрын
Thank you!
@user-bx6tu8pu1w
@user-bx6tu8pu1w 2 ай бұрын
nice tutorial, very useful.
@alekseyabramov9259
@alekseyabramov9259 2 жыл бұрын
Good job, Chris!
@Kavukamari
@Kavukamari Жыл бұрын
I have a node setup which converts the rgb signal to LAB format and it gives really interesting results when I do something similar, but I need to do a different kind of distance function
@BlenderBob
@BlenderBob Жыл бұрын
Thank you so much Chris! Love your tutorials!
@drippdrapp
@drippdrapp Жыл бұрын
hab mich sofort schockverliebt in deinen kanal super erklaert
@chrisprenn
@chrisprenn Жыл бұрын
😁 danke!
@TripTilt
@TripTilt 2 жыл бұрын
very interesting and useful! Thanks!
@liamsmyth3849
@liamsmyth3849 Жыл бұрын
if you want something even easier just dot product an RGB with the color attribute and use "greater than" or contrast adjust to get the color mask; similar colors will return white from the dot
@MrRainbowCalendar
@MrRainbowCalendar Жыл бұрын
Thanks, Chris!!!
@bohdandonchyk
@bohdandonchyk Жыл бұрын
you are the man Chris! Tnx
@pianoatthirty
@pianoatthirty 8 ай бұрын
Woah… this is so cool!!!
@danialsoozani
@danialsoozani Жыл бұрын
thank you this was very useful and innovative
@benskope
@benskope Жыл бұрын
Thank you for this, really helpful!!!
@simoneiorio9703
@simoneiorio9703 2 жыл бұрын
And the final group node seems not computational heavy too!
@chrisprenn
@chrisprenn 2 жыл бұрын
And can be further simplified: kzfaq.info/get/bejne/o9eRlJuWuteupKc.html
@PlanetXtreme
@PlanetXtreme Жыл бұрын
Hello good sir. Thank you for your intelligent words, now my project is on a roll again. Wishing you the best.
@PlanetXtreme
@PlanetXtreme Жыл бұрын
I'll elaborate because I'm bored, I was creating a stoplight texture and realized I wanted to animate an emission property, only emitting the red, green, and yellow hues. Turns out this was the solution to that equation, and by using a mix node on the original image(ColorA), with a multiply setting(node), comboed with your nodes(ColorB), inputted into emission on BSDF, gave me the solution I was looking for. Your solution even gave me a quick mask for the glassy part of the stoplight.
@johntnguyen1976
@johntnguyen1976 2 жыл бұрын
Next level...so useful!
@chrisprenn
@chrisprenn 2 жыл бұрын
Thank you!
@GaryParris
@GaryParris 2 жыл бұрын
Excellent Chris
@chrisprenn
@chrisprenn 2 жыл бұрын
Thanks!
@nurb2kea
@nurb2kea 2 жыл бұрын
In PS add an image and a hue layer in difference mode. all black now. Change the hue in one color with the slider and at the bottom set the range. Now what do you see? Use this in blender an you're done.
@stefanguiton
@stefanguiton 2 жыл бұрын
Excellent video!
@chrisprenn
@chrisprenn 2 жыл бұрын
Thank you!
@genkidama7385
@genkidama7385 Жыл бұрын
couldnt you use a color ramp to set the range
@s7tuts448
@s7tuts448 2 жыл бұрын
great video sir
@chrisprenn
@chrisprenn 2 жыл бұрын
Thank you!
@antonios5572
@antonios5572 2 жыл бұрын
what about adding a little blur to feather the mask?
@chrisprenn
@chrisprenn 2 жыл бұрын
👍🏻I do that with my little blur node (also in the startup file)
@chrisprenn
@chrisprenn 2 жыл бұрын
Watch this: kzfaq.info/get/bejne/o9eRlJuWuteupKc.html
@chrisprenn
@chrisprenn 2 жыл бұрын
Check out 2 quick extras in this video: kzfaq.info/get/bejne/o9eRlJuWuteupKc.html
MORE Nondestructive Modeling in Blender
35:04
Chris P
Рет қаралды 128 М.
Slow motion boy #shorts by Tsuriki Show
00:14
Tsuriki Show
Рет қаралды 9 МЛН
Blender 2.9 Tutorial - How to UV Unwrap &  Texture Paint Hands
14:43
Russell Midfield
Рет қаралды 17 М.
Blender Tutorial: Use Image Texture on Simulations
8:20
Tomi Viitanen
Рет қаралды 23 М.
Blender: RGB Texture Painting [TUTORIAL]
7:04
TheCGMaker
Рет қаралды 7 М.
Procedural Planets in Blender - TUTORIAL
21:08
Critical Giants
Рет қаралды 122 М.
How to make realistic translucent curtains in Blender (shading nodes)
8:53
GarageFarm Academy
Рет қаралды 68 М.
Blender Geometry Nodes Proximity Disintegration For Beginners  | Part 2/3
24:17
How to Texture Paint Emission Maps (Blender Tutorial)
7:02
Ryan King Art
Рет қаралды 27 М.
Control a ColorRamp Outside of a Node Group (Blender Tutorial)
23:11
Create Projectors Fast (Blender Tutorial)
5:30
CGMatter
Рет қаралды 214 М.
Slow motion boy #shorts by Tsuriki Show
00:14
Tsuriki Show
Рет қаралды 9 МЛН