Hi,
I have this slider that works pretty fine, but from left to right is the shallower field of view to the wider field of view.
I'd like to have the opposite.
The wider field of view on the left and the zoomed in fov on the right.
Could anyone help me please?
<!-- HORIZONTAL SLIDER -->
<plugin name="slider_bg" url="slider-background.png" align="bottom" x="0" y="30" handcursor="false" zorder="1" parent="stage"/>
<plugin name="slider_grip" url="slider-grip.png" align="left" edge="center" parent="slider_bg" x="0" zorder="2"
dragging="if(pressed,
sub(dx, mouse.stagex, drag_stagex);
add(newx, drag_currentx, dx);
if(newx LT 0, set(newx,0));
if(newx GT plugin[slider_bg].pixelwidth, copy(newx,plugin[slider_bg].pixelwidth));
copy(x,newx);
div(val, newx, plugin[slider_bg].pixelwidth);
sub(fovrange, view.fovmax, view.fovmin);
mul(newfov, val, fovrange);
add(newfov, view.fovmin);
set(view.fov, get(newfov));
delayedcall(0,dragging());
);"
ondown="copy(drag_currentx,x); copy(drag_stagex,mouse.stagex); dragging();"
/>
<events name="sliderevents" keep="true" onviewchanged="updateslider();" />
<action name="updateslider">
sub(val, view.fov, view.fovmin);
sub(fovrange, view.fovmax, view.fovmin);
div(val, fovrange);
mul(plugin[slider_grip].x, val, plugin[slider_bg].pixelwidth);
</action>
THANKS!