package readers; class Box{ int x,y,w,h; boolean ja_required; final static int BOX_THRESHOLD=8; //How many pixels outside the specified region the score can be. Box(int x,int y,int w, int h) { this.x=x; this.y=y; this.w=w; this.h=h; } boolean insideBox(int x,int y) { return this.x-BOX_THRESHOLD<=x&&this.x+this.w+BOX_THRESHOLD>=x&&this.y-BOX_THRESHOLD<=y&&this.y+this.h+BOX_THRESHOLD>=y; } }