[PD] Circular scrolling in pd

Patrice Colet colet.patrice at free.fr
Sun Jan 6 23:02:33 CET 2013


hello,

what about converting cartesian to polar coordinates instead?

with something like

angle = atan(y/x)

you can even get the distance from the center with

R = Sqrt(x2 + y2)

that should be a lot easier


----- Mail original -----
> De: "James Dunn" <james at 4thharmonic.com>
> À: "pd-list" <pd-list at iem.at>
> Envoyé: Dimanche 6 Janvier 2013 22:28:30
> Objet: [PD] Circular scrolling in pd
> 
> Hi,
> 
> I'm trying to implement circular scrolling with the trackpad in pd
> and
> am approaching it by dividing a circle into segments and trying to
> detect when the mouses moves from one segment to the other. At the
> moment I can only detect 4 segments (basically just the zero
> crossings)
> which is not really accurate enough.
> 
> How would I go about detecting the boundaries of the 12 segments in
> the
> attached patch (circscroll.pd)?
> 
> Eventually I want to detect speed and direction too - but perhaps
> there
> is a better approach?
> 
> any advice welcome.
> 
> thanks,
> 
> james
> 
> _______________________________________________
> Pd-list at iem.at mailing list
> UNSUBSCRIBE and account-management ->
> http://lists.puredata.info/listinfo/pd-list
> 



More information about the Pd-list mailing list