Entra:     


Forum: VirtualDJ Skins

Topic: Color visual with movement in it?

Questo argomento è obsoleto e potrebbe contenere informazioni obsolete o errate.

Hi!

As I know I can create visual like this ones:

<visual type="circle" source="get_position" direction="right">
<size width="134" height="134"/>
<pos x="+0" y="+0"/>
<mask x="10" y="10"/>
</visual>


OR like this:

<visual type="color" source="get_deck_color">
<size width="134" height="134"/>
<pos x="+0" y="+0"/>
<mask x="10" y="10"/>
</visual>



Is it possible to make one visual that can do both?
Like a color visual that can give the position of the song or the rotation of a deck, but in a specific color like "get_deck_color" or "cue_color"?
 

Inviato Sat 17 Nov 18 @ 8:46 pm
You could probably overlap them then use a mask so you can only see what you want.

You wouldn’t be able to to combine the codes (I don’t think) as you cant have multiple “source” in each “visual”.
 

I tried the masking-thing but this helps only for a few of my ideas...

Since you are from the staff...
Is it possible for the developers to expand the abilities of the visual-element by giving it "source2" and such things?
I could also imagine this as a great improvement for other elements like buttons for over or down attributes.

Example for sources:
<visual type="circle" source="get_position" type2="color" source2="get_deck_color"> ....... </visual>

Example for button or other attributes:
<button action="play">
<pos x="100" y="200"/>
<size width="50" height="50"/>
<up type="color" source="color 'darkblue'"/>
<over type="color" source="color 'white'"/>
<down type="color" source="color 'blue'"/>
</button>

Could you suggest this to the developers?
 

The problem here is not to give 2 sources, but how to manipulate them.
You assume that the software would know what to do with 2 sources because in your case (and mind) it's clear...
One source controls the movement of the visual, the other controls it's color.
But what gets colorized ? How would the software know ?
The entire surface ?
A masked one ?
And what should rotate ? The entire surface ? A different one ? A masked surface same as above ? A different mask surface ?
Remember that the color visual is not meant to be used as a color attribute since most elements in VirtualDJ don't have one!
And those that do have (like text) can already accept VDJScript instead of a fixed color:
<text>
<pos x="+60" y="+9"/>
<size width="128" height="19"/>
<text size="18" color="`effect_active 1 ? color '#00c8fa' : color '#404040'`" weight="bold" scroll="no" align="center" action="get_effect_name 1"/>
</text>


Your button example is better:
What is colorized ? the entire button, or a part of it ?
And if it's a part of it, how would the software know ?

That's why we have defined classes:

<define class="MySpecialButton">
<button action"play"
<pos x="100" y="200"/>
<size width="100" height="50"/>
</button
<visual type="color" source="play ? color 'green' : cue ? color 'darkgreen' : blink ? color 'green' : color 'darkgreen'">
<pos x="+10" y="+30"/>
<size width="80" height="10"/>
</visual>
</define>


Later down the road on your skin you can use:

<panel deck="1" class="MySpecialButton" />
To call the above "special button"




 



(Vecchi argomenti e forum sono automaticamente chiusi)