Mankeysocks / bikinect

Automatically exported from code.google.com/p/bikinect
0 stars 0 forks source link

Boolean toggles are reset whenever a mappingset is changed. #4

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. A mappingset containing boolean with effect="toggle" is set to 
permenent="true".
2. When cycling through mappingsets, boolean is reset.

What is the expected output? What do you see instead?
Boolean should not reset (turn black), it should remain yellow if set to yellow 
during previous mappingset.

What version of the product are you using? On what operating system?
Win 7 x32, MappInectBeta

Please provide any additional information below.
Example code reproduces issue:
<?xml version="1.0" encoding="utf-8" ?>
<mappings>

    <mappingset id="set0" permanent="true" inScope="false">

        <mapping>
            <processor type="action" action="nextSet">          
                <processor type="boolean" filter="less_than">               
                    <processor type="distance" filter="less_than" >
                        <element type="joint" target="left_hand" property="position" />
                        <element type="point" x="-500" y="500" z="1100" />
                    </processor>    
                    <processor type="direct">
                        <element type="value" value="200" />
                    </processor>            
                </processor>
            </processor>
            <output>

            </output>
        </mapping>

        <mapping>
            <processor type="action" action="prevSet">      
                <processor type="boolean" filter="less_than">   
                    <processor type="distance" filter="less_than" >
                        <element type="joint" target="left_hand" property="position" />
                        <element type="point" x="-500" y="-400" z="1100" />
                    </processor>    
                    <processor type="direct">
                        <element type="value" value="200" />
                    </processor>    
                </processor>
            </processor>
            <output>

            </output>
        </mapping>

    </mappingset>

    <mappingset id="Process Toggle" permanent="true">

        <mapping id="Initiate Fabrication">
            <processor type="boolean" label="ON:OFF" effect="toggle" filter="less_than">
                <element type="joint" target="left_hand" property="position" axis="z" />
                <element type="value" value="1000" />
            </processor>
            <output>

            </output>
        </mapping>      

    </mappingset>   

    <mappingset id="disancevh">

        <mapping id="distance">
            <processor type="distance" label="Stretch Bots" min_value="200" max_value="800">
                <element type="joint" target="left_hand" />
                <element type="joint" target="right_hand" />
            </processor>
            <output>

            </output>
        </mapping>

    </mappingset>

    <mappingset id="customPoint">

        <mapping id="Custom 3D Points">
            <processor type="distance" min_value="200" max_value="800">
                <element type="joint" target="left_hand" />
                <element type="point" porperty="position" x="-530" y="-200" z="1320" />
            </processor>
            <output>

            </output>
        </mapping>

    </mappingset>

Original issue reported on code.google.com by KylevonH...@gmail.com on 10 Oct 2011 at 1:48

GoogleCodeExporter commented 8 years ago
I see what you mean.
I did that first to avoid permanent mapping set that contains action processors 
to be always true, so these processors would not stop changing the active sets.
I have to verify if the processor is an action processor or not before 
resetting the value.
I'll keep you informed of changes !

Original comment by bkuperb...@gmail.com on 25 Oct 2011 at 6:37