CNMAT / Music-and-Computing

Materials built for MUS158A, MUS158B (B is only io area of patchers)
Other
6 stars 3 forks source link

confusing text in m158.o.duration2x #50

Closed equilet closed 8 years ago

equilet commented 8 years ago

"m158.o.duration2x converts duration values to /x start times, starting at 0 and ending at 1. Since an end point is required to represent the duration, an extra /x point is added."

This is unclear. The resultant vector yields: [0., 3., 6., 7., 8., 11.]

ramagottfried commented 8 years ago

yes, that's correct -- the input durations are transformed into x steps, similar to OM's dx->x function

equilet commented 8 years ago

starting with 0 and ending at 1?

ramagottfried commented 8 years ago

no it's accumulating steps, so 0 is the beginning adding up to the end of the last duration.

equilet commented 8 years ago

Right, so how about this:

[m158.o.duration2x] expects a list of durations (specified by its argument) to generate a list of "/x start times"; a list representing the successive accumulation between duration elements. Since an end point is always required to represent durations, an extra /x point (0.) is prepended to the beginning of the list as an initial start time.

?

ramagottfried commented 8 years ago

thanks, yes -- that's better. I see what you were saying now about the misleading 0-1 comment.

equilet commented 8 years ago

done. pushed the change.