Graphics

 View Only
  • 1.  Visual Logic to change layer face based on text

    Posted 09-15-2020 18:13

    Hello, I'm looking to use visual logic to drive an object face to different materials based on the raw data text received from an outside source. 

     

    IE :

    I have a template that enters raw data into text fields when activated.

    Included in the template is one of those text fields under a corresponding picture object. 

    I want the material applied to the object above the text to change based on the raw data that the text field receives. 

    So, If the data received is "Cat", the material applied to the object will be the material "Cat" in my material manager. If the data is is "Dog" then the material applied will be "Dog". The specific text fields being input by the raw data must stay the same and cannot be altered because I'm using it as a label. 

    I have all possible receivable data in my material manager.

    Any ideas on how to go about doing this? Also, I am a visual logic beginner to describe my skill level. 



  • 2.  RE: Visual Logic to change layer face based on text

    Posted 09-15-2020 18:19

    I do this with the example below. The String value is the word(s) driving the change; the string compare looks at whether they are equal or not, and the multiply/max value blocks are utility blocks so that I can have more than two options. I connect the max value to the input selector and the materials for each word correspond with their number and they are fed to the quad that needs the material. Hope that helps.


    #XPression


  • 3.  RE: Visual Logic to change layer face based on text

    Posted 09-15-2020 18:23

    This worked perfectly and makes sense to me. Thank you very much for the example and explanation.


    #XPression


  • 4.  RE: Visual Logic to change layer face based on text

    Posted 10-06-2020 19:05

    Piggybacking off of this earlier post -

    Although this works perfectly, How would I best assemble this for say, 400 possible conditions without the tedious task of adding in each string value and setting the material. If need be I can accomplish it that way but was curious as to if there was a better, more time efficient solution. 


    #XPression