bezierTangent()…A Peer-Review

As I stated in my last post, I will be performing peer-reviews for my 0.4 release. Today I looked at bezierTangent() coded by Dliu53. Here is a link to the lighthouse ticket, the processing reference, and the JAVA code I used to decide what the function is suppose to return. It took me a while to test the function because I couldn’t find any of Dliu53’s demos or test pages. When I compared the Java code with the JavaScript code I realized that it wasn’t the same. I decided to write my own demos, well just basically spitting out the values that were returned by the function. Here is a demo using Dliu53’s bezierTangent(). Here is a demo using my own (well I copy and pasted the Java code I linked to above) .Notice the output is not the same. Now you might be thinking how I figured out which one is correct? I copied the code from my demos into the Java 1.0.7 environment. I am including a screen shot of the output below.

The basis for my decision:

  • the function returns the appropriate value.
  • the function is written following the coding standards . Using 2 spaces instead of a tab, and leaving a space around brackets

After reviewing the code I gave bezierTangent() the status of review-needs-work because the output was wrong.

View all of my blogs on Processing.js
View all of my blogs

Advertisements

One thought on “bezierTangent()…A Peer-Review

  1. Pingback: BezierTangent()…A Second Look « Anna on Stuff (Processing.js/Open Source)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s