On 4/17/09 1:47 PM, "joenee...@gmail.com" <joenee...@gmail.com> wrote:

> Very pretty slurs!

Thanks!

> 
> 
> http://codereview.appspot.com/41099/diff/1021/59
> File lily/bezier.cc (right):
> 
> http://codereview.appspot.com/41099/diff/1021/59#newcode275
> Line 275: Bezier::subdivide (Real t, Bezier &left_part, Bezier
> &right_part)
> We only use references if they are const (for clarity), so please change
> the arguments to pointers. Also, this function can be marked as const.

So, if I understand right, you want
Bezier::subdivide (Real t, Bezier *left_part, Bezier *right_part) const

and then in the code, instead of

left_part.control_[i]=

I do

*left_part.control_[i]=

Is this right?


But when I try this, I get compile errors.

Can you give me a summary of how this works properly with classes?  The
syntax I used previously is what I have used in the past.

> 
> http://codereview.appspot.com/41099/diff/1021/59#newcode296
> Line 296: Bezier::extract (Real t_min, Real t_max)
> const here too

OK
> 
> http://codereview.appspot.com/41099/diff/1021/59#newcode302
> Line 302: bez2.control_[i] = control_[i];
> bez2 = *this

OK

> 
> http://codereview.appspot.com/41099/diff/1021/62
> File lily/lookup.cc (right):
> 
> http://codereview.appspot.com/41099/diff/1021/62#newcode347
> Line 347: SCM dash_details)
> Since dash_details seems to just be a list of Reals, perhaps its better
> to have a vector<Real> const& (with an empty vector to signify a solid
> slur).

No, dash_details is a list of lists of floating point numbers.  There is one
list for each segment of the slur; there can be as many segments as the user
desires.

Thanks,

Carl



_______________________________________________
lilypond-devel mailing list
lilypond-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to