This site requires JavaScript, please enable it in your browser!
Greenfoot back
Greenfoot.Master
Greenfoot.Master wrote ...

2014/2/24

New Project - ChipRider

Greenfoot.Master Greenfoot.Master

2014/2/24

#
Can someone possibly please give me code that will allow a phone for example to accept a code? Thanks
TheBakerBastard TheBakerBastard

2014/2/24

#
public class FilterExample { /* *pre: image != null, image.length > 1, image.length > 1 * image is a rectangular matrix, neighberhoodSize > 0 *post: return a smoothed version of image */ public Color smooth(Color image, int neighberhoodSize) { //check precondition assert image != null && image.length > 1 && image.length > 1 && ( neighberhoodSize > 0 ) && rectangularMatrix( image ) : "Violation of precondition: smooth"; Color result = new Color.length]; for(int row = 0; row < image.length; row++) { for(int col = 0; col < image.length; col++) { result = aveOfNeighbors(image, row, col, neighberhoodSize); } } return result; }
xxX_Muffin.man_Xxx xxX_Muffin.man_Xxx

2014/2/24

#
I Love starch
You need to login to post a reply.