Menu

#165 Material animations with condition element aren't evaluated each frame

Fixed
nobody
OSG (57)
2011-06-05
2010-10-18
Anonymous
No

Originally created by: zakalawe@mac.com
Originally owned by: timoor... (code.google.com)@gmail.com

The 'standard' technique to achieve night-time appearance for models, is broken in Git due to an optimisation that regards them as invariants. Unfortunately this is prompting ugly work-arounds!

Related

Tickets: #896

Discussion

  • Anonymous

    Anonymous - 2010-10-18

    Originally posted by: zakalawe@mac.com

    Sample previously working, currently broken animation XML:

    <animation>
    <type>material</type>
    <object-name>Light</object-name>
    <condition>       
      <greater-than>       
       <property>/sim/time/sun-angle-rad</property>
       <value>1.57</value>
      </greater-than>
    </condition>
    <emission>   
      <red>1</red>   
      <green>0</green>   
      <blue>0</blue>
    </emission>
    </animation>

     
  • Anonymous

    Anonymous - 2010-10-18

    Originally posted by: zakalawe@mac.com

    (Note the lack of property elements outside the condition, in the example above)

     
  • Anonymous

    Anonymous - 2010-11-02

    Originally posted by: vivian.m...@lineone.net

    Another example of this bug

        <animation>
            <type>material</type>
            <object-name>Hangar-Deckhead</object-name>
            <condition>
                <less-than-equals>
                    <property>sim/time/sun-angle-rad</property>
                    <value>1.57</value>
                </less-than-equals>
            </condition>
            <texture>hangar_lm.png</texture>
            <emission>
                <!--<factor-prop>controls/lighting/flood-lights-red-norm</factor-prop>-->
                <factor>1.0</factor>
                <red>0.75</red>
                <green>0.25</green>
                <blue>0.25</blue>
            </emission>
        </animation>
       
        <animation>
            <type>material</type>
            <object-name>Hangar-Deckhead</object-name>
            <condition>
                <greater-than>
                    <property>sim/time/sun-angle-rad</property>
                    <value>1.57</value>
                </greater-than>
            </condition>
            <texture>hangar.png</texture>
            <emission>
                <!--<factor-prop>controls/lighting/flood-lights-red-norm</factor-prop>-->
                <factor>1.0</factor>
                <red>0.5</red>
                <green>0.5</green>
                <blue>0.5</blue>
            </emission>
        </animation>

     
  • Anonymous

    Anonymous - 2010-11-02

    Originally posted by: vivian.m...@lineone.net

    I don't think the condion is ever evaluated the fist animation works for any value of the condition

     
  • Anonymous

    Anonymous - 2010-11-04

    Originally posted by: timoor... (code.google.com)@gmail.com

    I've committed a fix to next and will close the bug after feedback.

    Cc: zakalawe
    Status: Testing

     
  • Anonymous

    Anonymous - 2010-12-12

    Originally posted by: zakalawe@mac.com

    Marking fixed since Tim keeps forgetting :)

    Status: Fixed

     
  • Anonymous

    Anonymous - 2011-06-05

    Originally posted by: bre... (code.google.com)@gmail.com

    (No comment was entered for this change.)

    Status: Temp

     
  • Anonymous

    Anonymous - 2011-06-05

    Originally posted by: bre... (code.google.com)@gmail.com

    (No comment was entered for this change.)

    Status: Fixed

     

Log in to post a comment.

MongoDB Logo MongoDB