Aw, sloppy.  Try the attached one instead.

-Jonathan




----- Original Message -----
> From: Jonathan Wilkes <[email protected]>
> To: Esteban Viveros <[email protected]>; Simon Wise <[email protected]>
> Cc: "[email protected]" <[email protected]>
> Sent: Tuesday, February 5, 2013 2:28 AM
> Subject: Re: [PD] Range Slider Object
> 
> Here's a prototype using data structures.  It has "springs"
> instead of hard proportions, but it obeys the limits of the slider,
> which gets closer to an rslider.  I think there's a hack to get it
> to obey hard proportions.  Also, I'm just working with one
> scalar so I'm not sure if I've got class-wide state in the patch
> (as opposed to "per-scalar" state by storing it as fields in the
> struct).
> 
> Of course this is one of those Pd-style prototypes where it
> becomes increasingly difficult to do anything beyond the
> prototype.  Try to encapsulate it in an abstraction and you
> deal with gop resizing issues and state-saving issues.
> For that matter, try making it resizable and you give up
> the hard boundaries since quanta values don't accept
> variables.
> 
> -Jonathan
> 
> _______________________________________________
> [email protected] mailing list
> UNSUBSCRIBE and account-management -> 
> http://lists.puredata.info/listinfo/pd-list
> 
#N struct rslider float x float y float min float max float slider
;
#N canvas 55 40 450 300 10;
#N canvas 388 69 606 534 rslider 0;
#X obj 126 53 struct rslider float x float y float min float max float
slider;
#X obj 126 423 filledpolygon 900 0 1 min(0:1)(0:100) 0 min(0:1)(5:105)
5 min(0:1)(5:105) 0 slider(0:1)(10:110) 0 slider(0:1)(10:110) 5 slider(0:1)(20:120)
5 slider(0:1)(20:120) 0 max(0:1)(25:125) 0 max(0:1)(25:125) 5 max(0:1)(30:130)
0 max(0:1)(25:125) -5 max(0:1)(25:125) 0 slider(0:1)(20:120) 0 slider(0:1)(20:120)
-5 slider(0:1)(10:110) -5 slider(0:1)(10:110) 0 min(0:1)(5:105) 0 min(0:1)(5:105)
-5;
#X obj 126 95 route change;
#X obj 126 165 change;
#X obj 126 188 t a a;
#X obj 126 328 set rslider min max;
#X obj 126 117 trigger anything anything;
#X obj 126 241 t a a;
#X obj 126 143 get rslider slider min max;
#X obj 127 389 drawpolygon 0 1 -1 -7 132 -7 132 7 -1 7 -1 -7;
#X obj 126 288 + 0.35;
#X obj 181 288 + 0.61;
#X obj 126 219 - 0.48;
#X connect 0 0 2 0;
#X connect 2 0 6 0;
#X connect 3 0 4 0;
#X connect 4 0 12 1;
#X connect 4 1 12 0;
#X connect 6 0 8 0;
#X connect 6 1 5 2;
#X connect 7 0 10 0;
#X connect 7 1 11 0;
#X connect 8 0 3 0;
#X connect 8 1 10 1;
#X connect 8 2 11 1;
#X connect 10 0 5 0;
#X connect 11 0 5 1;
#X connect 12 0 7 0;
#X restore 245 105 pd rslider;
#X obj 257 199 s foo;
#X obj 257 221 namecanvas foo;
#X scalar rslider 62 105 0.35 0.61 0.48 \;;
#X msg 257 177 scalar rslider2 20 20;
#X connect 4 0 1 0;
_______________________________________________
[email protected] mailing list
UNSUBSCRIBE and account-management -> 
http://lists.puredata.info/listinfo/pd-list

Reply via email to