Update of /cvsroot/pure-data/pd/src In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16929
Modified Files: Tag: devel_0_39 desire.tk desire.c Log Message: commented out some code so that sliders worx for now
Index: desire.tk =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.tk,v retrieving revision 1.1.2.210 retrieving revision 1.1.2.211 diff -C2 -d -r1.1.2.210 -r1.1.2.211 *** desire.tk 20 May 2006 18:09:50 -0000 1.1.2.210 --- desire.tk 21 May 2006 16:29:21 -0000 1.1.2.211 *************** *** 2779,2790 **** set span [expr $@max-$@min] set l [expr $orient?$@h:$@w] ! set value [expr $@val*$span/($l-1)/100] set @value $value if {$orient} { set size $xs set y1 [expr $y1+$ys-$value*($l-1)/$span-2] - puts "value=$value :: l=$l :: span=$span :: val=$@val" set y2 [expr $y1-2] - puts "[expr $x1+2] :: $y1 :: [expr $x1+$size-2] :: $y2" $c coords ${self}KNOB [expr $x1+2] $y1 [expr $x1+$size-2] $y2 } { --- 2779,2790 ---- set span [expr $@max-$@min] set l [expr $orient?$@h:$@w] ! #set value [expr $@val*$span/($l-1)/100] ! #set value $@value ! set value $@val set @value $value if {$orient} { set size $xs set y1 [expr $y1+$ys-$value*($l-1)/$span-2] set y2 [expr $y1-2] $c coords ${self}KNOB [expr $x1+2] $y1 [expr $x1+$size-2] $y2 } { *************** *** 2827,2832 **** $@canvas focus= $@canvas $self draw - puts "------- value is $@value -------------" pd .$self float $@value } } --- 2827,2832 ---- $@canvas focus= $@canvas $self draw pd .$self float $@value + } } *************** *** 2842,2845 **** --- 2842,2847 ---- set d [expr ($orient?-$dy:$dx)*$span/($l+0.0)] set @value [expr $@ovalue+$d*$@rate] + puts "slider value ----------------- $@value" + puts "max ::: $@max ---------- min ::: $@min" pd .$self float $@value }
Index: desire.c =================================================================== RCS file: /cvsroot/pure-data/pd/src/Attic/desire.c,v retrieving revision 1.1.2.78 retrieving revision 1.1.2.79 diff -C2 -d -r1.1.2.78 -r1.1.2.79 *** desire.c 20 May 2006 18:08:28 -0000 1.1.2.78 --- desire.c 21 May 2006 16:29:21 -0000 1.1.2.79 *************** *** 12346,12351 **** else { /* normal */ CLAMP(f,x->min,x->max); } ! g = (x->is_log ? log(f/x->min) : (f-x->min)) / x->k; ! x->val = (int)(100.0*g + 0.49999); x->pos = x->val; gobj_changed(x,"val"); --- 12346,12352 ---- else { /* normal */ CLAMP(f,x->min,x->max); } ! //g = (x->is_log ? log(f/x->min) : (f-x->min)) / x->k; ! //x->val = (int)(100.0*g + 0.49999); ! x->val = f; x->pos = x->val; gobj_changed(x,"val"); *************** *** 12358,12362 **** double out = x->is_log ? x->min*exp(t) : x->min+t; if (fabs(out) < 1.0e-10) out = 0.0; ! outlet_float(x->obj.ob_outlet, out); if(x->snd && x->snd->s_thing) pd_float(x->snd->s_thing, out); --- 12359,12364 ---- double out = x->is_log ? x->min*exp(t) : x->min+t; if (fabs(out) < 1.0e-10) out = 0.0; ! //outlet_float(x->obj.ob_outlet, out); ! outlet_float(x->obj.ob_outlet, x->val); if(x->snd && x->snd->s_thing) pd_float(x->snd->s_thing, out);