• Daz 3D
  • Shop
  • 3D Software
    • Daz Studio Premier
    • Daz Studio
    • Install Manager
    • Exporters
    • Daz to Roblox
    • Daz to Maya
    • Daz to Blender
    • Daz to Unreal
    • Daz to Unity
    • Daz to 3ds Max
    • Daz to Cinema 4D
  • 3D Models
    • Genesis 9
    • Genesis 8.1
    • Free 3D Models
  • Community
    • Gallery
    • Forums
    • Blog
    • Press
    • Help
  • Memberships
    • Daz Premier
    • Daz Plus
    • Daz Base
    • Compare
  • Download Studio
  • Menu
  • Daz 3D
  • Shop
  • 3d Software
    • Daz Studio Premier
    • Daz Studio
    • Install Manager
    • Exporters
    • Daz to Roblox
    • Daz to Maya
    • Daz to Blender
    • Daz to Unreal
    • Daz to Unity
    • Daz to 3ds Max
    • Daz to Cinema 4D
  • 3D Models
    • Genesis 9
    • Genesis 8.1
    • Free 3D Models
  • Community
    • Our Community
    • Gallery
    • Forums
    • Blog
    • Press
    • Help
  • Memberships
    • Daz Premier
    • Daz Plus
    • Daz Base
    • Compare

Notifications

You currently have no notifications.

Loading...
    • Categories
    • Recent Discussions
Daz 3D Forums > 3rd Party Software > Unity Discussion

How to change color diffuse Iray shader?

x-ecutionnerx-ecutionner Posts: 13
October 2020 in Unity Discussion
hello, my question is: how to change the color in the runtime please? because the method which consists in changing the color of an hdrp / LIT shader ("_BaseColor") does not work on Daz / IrayUber shaders. Please, your help would be welcome. Thank you. (I also try ("_Diffuse" And "_DiffuseColor)

Comments

  • ArtiniArtini Posts: 9,918
    October 2020 edited October 2020

    Could you just change the color in Daz Studio and then export the item with Daz to Unity bridge.

     

    Post edited by Artini on October 2020
  • x-ecutionnerx-ecutionner Posts: 13
    October 2020
    Thank you but that was not my question.
  • x-ecutionnerx-ecutionner Posts: 13
    October 2020
    I can change the color with the editor, but I can't do it in runtime with a script. Yet I get there with the hdrp shaders without any problem.
  • ArtiniArtini Posts: 9,918
    October 2020

    Sorry, I am not that advanced, yet.

     

  • x-ecutionnerx-ecutionner Posts: 13
    October 2020
    No problem
  • x-ecutionnerx-ecutionner Posts: 13
    October 2020
    Exemple : _BaseColor("BaseColor", Color) = (1,1,1,1) This work for change color shader hdrp/Lit, but not work for shaders Daz/IrayUber
  • DAZ_jesseDAZ_jesse Posts: 30
    October 2020

    On both the metal and specular workflow the property "_Diffuse" is the one being multiplied with the "_DiffuseMap" texture to produce the final base color that's plugged into the master node. That's not always the best way to tint something, but it is similar to how it works in Daz Studio. Can you send upload a screenshot showing an asset you're having trouble with (both w/o any modifications and with the tint you're trying to get)? I'd be happy to modify the base shaders with a supplemental flow for a color transition using other techniques provided the current one doesn't work.

  • x-ecutionnerx-ecutionner Posts: 13
    October 2020
    Thanks for the response, Excuse me but I do not see what I will be able to send as a screenshot ... I can very easily change the color of a clothes in the inspector via the diffuse color picker. but can't change colors from runtime, something I do very easily with hdrp / lit shaders. In fact, I would like to have the example of C # code which allows to have control over the color of the Daz / IrayUber shaders. Thank you
  • DAZ_jesseDAZ_jesse Posts: 30
    October 2020
    x-ecutionner said:
    Thanks for the response, Excuse me but I do not see what I will be able to send as a screenshot ... I can very easily change the color of a clothes in the inspector via the diffuse color picker. but can't change colors from runtime, something I do very easily with hdrp / lit shaders. In fact, I would like to have the example of C # code which allows to have control over the color of the Daz / IrayUber shaders. Thank you

    It would be something like material.SetColor("_Diffuse",new Color(1,0,0,1);); //makes the material red

  • x-ecutionnerx-ecutionner Posts: 13
    October 2020

    I have already tried this, but it does not work.

  • x-ecutionnerx-ecutionner Posts: 13
    October 2020

    I'm confused, it actually works ... I don't understand why it didn't work before. No doubt a fault on my part, thank you for taking the time to answer me. My problem is solved. thank you

Sign In or Register to comment.
Adding to Cart…

Daz 3D is part of Tafi

Connect

DAZ Productions, Inc.
7533 S Center View Ct #4664
West Jordan, UT 84084

HELP

Contact Us

Tutorials

Help Center

Sell Your 3D Content

Affiliate Program

Documentation Center

Open Source

Consent Preferences

JOIN DAZ

Memberships

Blog

About Us

Press

Careers

Bridges

Community

In the Studio

Gallery

Forum

DAZ STORE

Shop

Freebies

Published Artists

Licensing Agreement | Terms of Service | Privacy Policy | EULA

© 2025 Daz Productions Inc. All Rights Reserved.