Ask your own question, for FREE!
Computer Science 15 Online
OpenStudy (rsmith6559):

I have been trying for week to find an appropriate algorithm to plot a color curve. I'm trying to write a program that lets the user input an arbitrary number of color values, which I regard as immutable, and I need to connect them into one "curve". The input values can be fairly screwy. After the curve is drawn, it will be output to a file that Photoshop can import as a curve. A math teacher gave me y = ax^2 + bx + c, which works for one segment, except that it remains symmetrical, and asymmetrical curves can be expected.

OpenStudy (shadowfiend):

Have you looked at all at bézier curves? These are more likely to help you model what you need. See http://en.wikipedia.org/wiki/Bezier_curve .

OpenStudy (anonymous):

sorry out of my reach......

OpenStudy (rsmith6559):

I've looked at most every type of curve on Wikipedia. It seems that all the articles are written for the higher math, and I don't understand most of what I'm seeing. Kind of wish I'd taken more math in high school, but I wasn't going through geometry proofs again! I finally found some Java code for Beziers that may change my mind about them. The articles have shown them dropping "freak" points, and I want to include them. I had been thinking of best fit, but what little I could find, made it look like they weren't much more than a wild guess and then trying to reduce the error to a tolerable level using math that, TBH, I don't really understand.

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!