• Post Reply Bookmark Topic Watch Topic
  • New Topic

Drawing a growing "view finder" shape? In processing  RSS feed

Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
1. Since the task requires precision, floating-point variables should be used
unless it is absolutely necessary to use integers.

2. The background should be black and the color of the VF should be
hexadecimal #14A028.

3. The VF has a diameter of DIA (200 in the sample output)

4. The VF should have two axes – horizontal and vertical (white)

5. There should be marking on the two axes. The number of such markings
on each axis is N (16 in the sample output) and the length of each marking
is LENGTH (10 pixels in the sample output). These markings MUST be
drawn using a loop.

The VF should be drawn at the location of the mouse pressed until the
mouse is pressed again when the first VF is erased and an updated VF is
drawn at the new location. The VF should grow from diameter = 1 to the
maximum diameter (DIA).
[Thumbnail for Capture.PNG]
This is how the growing viewfinder should look like.
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!