Skip to main content
slaviatura
Participant
August 5, 2022
Answered

Expose color parameter without alpha?

  • August 5, 2022
  • 1 reply
  • 849 views

How can i expose color parameter without alpha?

This topic has been closed for replies.
Correct answer davescm

Hi

What you have to do is change the four inputs to three and replace the fourth (alpha) with a constant value set to 1

Follow these steps:

1. Expose the uniform color node parameters as normal

2. Go to the graph input parameters and change Type/Editor from Float 4 to Float 3. Also change the input box next to it from slider to Color(RGB)

3. Go back to the uniform Color node and edit the function graph

4. Replace the single Get Float4 node with the function nodes below. This sets alpha to 1. Don't forget to right click and set the Vector Float 4 as the output node.

 

 

 

That's it.

 

Dave

1 reply

davescm
Community Expert
davescmCommunity ExpertCorrect answer
Community Expert
August 5, 2022

Hi

What you have to do is change the four inputs to three and replace the fourth (alpha) with a constant value set to 1

Follow these steps:

1. Expose the uniform color node parameters as normal

2. Go to the graph input parameters and change Type/Editor from Float 4 to Float 3. Also change the input box next to it from slider to Color(RGB)

3. Go back to the uniform Color node and edit the function graph

4. Replace the single Get Float4 node with the function nodes below. This sets alpha to 1. Don't forget to right click and set the Vector Float 4 as the output node.

 

 

 

That's it.

 

Dave

slaviatura
Participant
August 5, 2022

Thank you so much!

davescm
Community Expert
Community Expert
August 5, 2022

You're welcome .

Note I just edited my post and added a step under '2' to change from 'Slider' to 'Color(RGB)' input. I omitted that in my first reply.

 

Dave