Class StimulusObject

Class StimulusObject

Warning, links to the API class, i.e., java.awt.*, java.lang.*, etc., do not exist. Only links to Poggendoff class exists: the "see also" links.
java.lang.Object
   |
   +----StimulusObject

class StimulusObject
extends Object
This class builds and displays the poggendoff stimuli.

Constructor Index

 o StimulusObject(int, int, double, double, int, double, double)
This constructor initializes the poggendoff stimuli via the display parameters collected from the html file.

Method Index

 o GetCmpConnectionPoint()
This method returns the y-intersection point on the right vertical line that is used to connect the standard and comparison transverse lines.
 o GetRightVerticalLineTop()
This method returns the top point of the right vertical line.
 o drawMe(Graphics, int)
Draws the poggendoff stimuli.

Constructors

 o StimulusObject
  public StimulusObject(int w,
                        int h,
                        double vertParam,
                        double dParam,
                        int theta,
                        double transParam,
                        double sAreaParam)
This constructor initializes the poggendoff stimuli via the display parameters collected from the html file. The stimuli consists of 4 parts: a left and right vertical line segement, the standard transverse segement, and the comparison transverse segment. The only segment that will change from trial to trial will be the position of the comparison segement. This routine, therefore, will position each segment except the comparison segment in their constant positions. Note that upper left hand canvas corner is (0,0). Error checking: 1) if the seperation between the 2 vert. line segments is greater than 80% of the canvas width, the seperation will be reset to 80% of the length of a vert. line segment. 2) makes sure the transverse line segments fit on the canvas--if not, their length will be reduced. 3) make sure that the standard transversal intersects the left vertical line, e.g., make sure that the intersect point is not below the left vertical line. This could happen if the acute angle is too small and/or the seperation is too large. The algorithm will correct by reducing the sample area thus raising transverse line. .
Parameters:
w - is the canvas width
h - is the canvas height
vertParam - is a value between 0 & 1 such that when multipled by h gives the lenght of a vert. line segment.
dParam - is a value between 0 & 1 such that when mulitipled by a vert. line seg. length gives the seperation between the 2 vert. line seg.s
theta - is the acute angle between a transverse line seg. and a vert. line seg.
transParam - is a value bet. 0 & 1 such that when mulitipled by a vert. line seg. length give the length of a transverse line segment.
sAreaParam - is a value bet. 0 & 1 such that when mulitipled by a vert. line seg. len. gives the cmp. line sample area
Returns:
void

Methods

 o drawMe
  public void drawMe(Graphics g,
                     int yComp)
Draws the poggendoff stimuli.
Parameters:
g - is the Graphics object attacted to StimulusCanvas class
yComp - is the y-component of where the sample comparison line will connect to the right vertical line
Returns:
void
 o GetCmpConnectionPoint
  public Point GetCmpConnectionPoint()
This method returns the y-intersection point on the right vertical line that is used to connect the standard and comparison transverse lines.
Returns:
Point
 o GetRightVerticalLineTop
  public Point GetRightVerticalLineTop()
This method returns the top point of the right vertical line.
Returns:
Point
Back to StimuliCanvas class document page