Question

In: Computer Science

Using any existing 2D or 3D graphics library ( Java 2D, Java 3D, draw a scene...

Using any existing 2D or 3D graphics library ( Java 2D, Java 3D, draw a scene within one of the following categories:

  1. Satire or humor
  2. Promote a cause

You are free to create whatever you choose but it must conform to the following guidelines.  

  • Show evidence of at least four colors.
  • Have a textual composition on the finished product.
  • Imagery or images
  • Scene composition of at least six (6) elements
  • One of the following 1) Shadows or Glows.
  • May be of cartoon type or more polished composition.
  • Duplication of at least one element coming from an existing class.

You are submitting a ZIP file only name CPTR485_PROJECT1_YourName.zip containing your original project folder, a compiled *.exe file and your documentation.

Your documentation should 1) describe the project 2) how you approached it, 3) challenges that you faced and conquered.

Solutions

Expert Solution

public class Main{

public static void main(String[] args) {

new MyFrame();

}

}

import javax.swing.*;

public class MyFrame extends JFrame{

MyPanel panel;

MyFrame(){

panel = new MyPanel();

this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);

this.add(panel);

this.pack();

this.setLocationRelativeTo(null);

this.setVisible(true);

}

}

import java.awt.*;

import javax.swing.*;

public class MyPanel extends JPanel{

//Image image;

MyPanel(){

//image = new ImageIcon("sky.png").getImage();

this.setPreferredSize(new Dimension(500,500));

}

public void paint(Graphics g) {

Graphics2D g2D = (Graphics2D) g;

//g2D.drawImage(image, 0, 0, null);

g2D.setPaint(Color.blue);

g2D.setStroke(new BasicStroke(5));

g2D.drawLine(0, 0, 500, 500);

//g2D.setPaint(Color.pink);

//g2D.drawRect(0, 0, 100, 200);

//g2D.fillRect(0, 0, 100, 200);

//g2D.setPaint(Color.orange);

//g2D.drawOval(0, 0, 100, 100);

//g2D.fillOval(0, 0, 100, 100);

//g2D.setPaint(Color.red);

//g2D.drawArc(0, 0, 100, 100, 0, 180);

//g2D.fillArc(0, 0, 100, 100, 0, 180);

//g2D.setPaint(Color.white);

//g2D.fillArc(0, 0, 100, 100, 180, 180);

//int[] xPoints = {150,250,350};

//int[] yPoints = {300,150,300};

//g2D.setPaint(Color.yellow);

//g2D.drawPolygon(xPoints, yPoints, 3);

//g2D.fillPolygon(xPoints, yPoints, 3);

//g2D.setPaint(Color.magenta);

//g2D.setFont(new Font("Ink Free",Font.BOLD,50));

//g2D.drawString("U R A WINNER! :D", 50, 50);

}

}


Related Solutions

Gauss Jordan elimination using python for a 2d list (3x3) without using any library. Thanks
Gauss Jordan elimination using python for a 2d list (3x3) without using any library. Thanks
In Java Develop, test, and execute a graphics application for simulations using Java. Create a Java...
In Java Develop, test, and execute a graphics application for simulations using Java. Create a Java application. Given a set of events, choose the resulting programming actions. Understand the principles behind Java. Understand the basic principles of object-oriented programming including classes and inheritance. Deliverables .java files as requested below. Requirements Create all the panels. Create the navigation between them. Start navigation via the intro screen. The user makes a confirmation to enter the main panel. The user goes to the...
Draw the 3d Structure and isomers (if any), find the molecular structure, polarity, and hybridization of...
Draw the 3d Structure and isomers (if any), find the molecular structure, polarity, and hybridization of the following: C3H6Br2, N3-, ClO4-, SeCl2, ClO3-, SCl2, N2O4, C2H3F.
using java Define a class Library based on the following specifications: a. A library can have...
using java Define a class Library based on the following specifications: a. A library can have multiple books. Decide on the best possible data structure to store books. b. A library has a name. c. A library has an address. Define a 2-argument constructor for the Library class. Decide on the arguments needed for this constructor. e. Define a method that can add new books to the library. f. Define a method that allows a book to be borrowed (checked...
Interactive computer graphics course. by java language, no need to explain. Q1: Draw a line between...
Interactive computer graphics course. by java language, no need to explain. Q1: Draw a line between P0 and Pe P0= (x,y)=(2,5) Pe=(xe,ye)=(7,9) Q2: P=(3,5) Scale P by (5,7) and then sheer by -3 along y-axis
Write a java program of a multiplication table of binary numbers using a 2D array of...
Write a java program of a multiplication table of binary numbers using a 2D array of integers.
Write a program in JAVA using the BigInteger library that can be used to check a...
Write a program in JAVA using the BigInteger library that can be used to check a RSA signature, based on the signer's RSA public key pair. To test your program, take the following information about a message Alice signed and use the verify signature to reproduce the message Alice signed and convert it back to String format. n = 68236588817658935156357212288430888402056854883696767622850112840388111129987 e = 65537 signature = 46612763171375975923246342580942010388414761162366281695045830390867474569531
Using the Library link or any biology websites to find an enzyme that is related to...
Using the Library link or any biology websites to find an enzyme that is related to either a disease or a condition (human, animal or plant) and place a summarizing paragraph on the thread below. Consider including: 1 point description of disease or condition 1 point for a brief description of the symptoms of the disease or expression in plants 1 point for description of the protein involved 1 point for anecdote(story) related to the disease or interesting information about...
Develop a Java application using Parboiled library to write aparser for a customer form. Your...
Develop a Java application using Parboiled library to write a parser for a customer form. Your program should include a grammar for the parser and display the parse tree with no errors.The customer form should include the following structure:First name, middle name (optional), last nameStreet address, city, state (or province), countryPhone numberRules• First name, middle name and last name should start with an uppercase letter followed by lower case letters. Middle name is an optional input meaning such an input...
Using existing Stack Java Collection Framework, write Java Code segment to do the following.   You may...
Using existing Stack Java Collection Framework, write Java Code segment to do the following.   You may write this in jGrasp Create a Stack of String called, myStacks Read input from keyboard, 10 names and then add to myStacks As you remove each name out, you will print the name in uppercase along with a number of characters the name has in parenthesis. (one name per line).   e.g.     Kennedy (7) Using existing Stack Java Collection Framework, write Java Code segment to...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT