+1(316)4441378

+44-141-628-6690

Java JWJGL

Write a Java program using only NetBeans 8.2 IDE which uses the LWJGL library to draw a window of 640×480 in the center of the screen.

Your program should then read in coordinates from a file titled coordinates.txt and draw the primitives in the same window using the algorithms for each primitive.

The program should draw the primitives in different colors (red for lines, blue for circles and green for ellipses) on a black background.

Use the glVertex2f() command to plot the primitives pixel by pixel. Finally, your program should also use the input.Keyboard class to have the escape key quit your application.

If you are motivated enough, you may also add extra functional keys that would allow the user to change the colors of the primitives. These added functions should be clearly stated in your comments.

The given coordinates.txt file will be in the following format:

l -15,-15 150,180
c 100,150 80
e 225,370 35,75
l -100,100 50,75
e 200,-100 50,50

“l” stands for a line and is followed by a space, this is then followed by the two endpoints of the line separated by a space.

“c” stands for a circle followed by a space, the center of the circle, space and then the radius of the circle.

“e” stands for ellipse followed by a space, center of the ellipse, space again followed by value of rx and ry(separated by a comma).

When your program is evaluated, a different coordinates.txt file will be used by me so be sure your algorithm tests all cases for each of the three primitives.

Note: Please do not turn in anything that does not use Java with our LWJGL library. Your programs should be hand-coded. Hence, dont use pre-existing code from other texts or from the internet.

What to turn in:
– Soft copy of the program

The output should look like the picture posted when the program is finished.
The program should change the sizes/positions of the shapes if the text file is changed.

 

You can place an order similar to this with us. You are assured of an authentic custom paper delivered within the given deadline besides our 24/7 customer support all through.

 

Latest completed orders:

# topic title discipline academic level pages delivered
6
Writer's choice
Business
University
2
1 hour 32 min
7
Wise Approach to
Philosophy
College
2
2 hours 19 min
8
1980's and 1990
History
College
3
2 hours 20 min
9
pick the best topic
Finance
School
2
2 hours 27 min
10
finance for leisure
Finance
University
12
2 hours 36 min
[order_calculator]