Welcome to Dream.In.Code
Become a Java Expert!

Join 149,615 Java Programmers for FREE! Get instant access to thousands of Java experts, tutorials, code snippets, and more! There are 1,853 people online right now. Registration is fast and FREE... Join Now!




Creating a pic of SpongeBob

 
Reply to this topicStart new topic

Creating a pic of SpongeBob, Java

CSJavaGuy
22 Sep, 2007 - 11:50 AM
Post #1

New D.I.C Head
*

Joined: 22 Sep, 2007
Posts: 3


My Contributions
Hi I have a problem that I need some help with please. Given here is a link to a picture of Spongebob Squarepants.

http://artfiles.art.com/images/-/SpongeBob...-C10284409.jpeg

I have a project that I am working on in Blue J to write a program named SpongeBob that creates a window on the computer screen that displays a picture of SpongeBob. The picture should look as similar as possible to the link provided.

My Platform in Windows XP on a PC computer, but I also use MACS

The language is Java.

I need help to get started on this. I cant seem to get program to work. I am not sure even on how to begin the source code. I am requesting if someone can please just help me get started. Thank you.

Here is my code what I have started. I have made 3 classes SpongeBob, Oval, and JFrame. So 3 boxes that I have linked as related. Here is my code so far. Please I need help to get started. I am not asking for anyone to do this for me, just to get started.

CODE

import javax.swing;
import java.awt.Color;



public class SpongeBob {

    private JFrame window;
    private Oval whiteCicle, blackCircle;
    private Rectangle blackRectangle, whiteRectangle;


    
    public SpongeBob()
    
    
    {
    }
}


This post has been edited by William_Wilson: 22 Sep, 2007 - 12:31 PM
User is offlineProfile CardPM
+Quote Post

CSJavaGuy
RE: Creating A Pic Of SpongeBob
22 Sep, 2007 - 12:27 PM
Post #2

New D.I.C Head
*

Joined: 22 Sep, 2007
Posts: 3


My Contributions
QUOTE(CSJavaGuy @ 22 Sep, 2007 - 12:50 PM) *

Hi I have a problem that I need some help with please. Given here is a link to a picture of Spongebob Squarepants.

http://artfiles.art.com/images/-/SpongeBob...-C10284409.jpeg

I have a project that I am working on in Blue J to write a program named SpongeBob that creates a window on the computer screen that displays a picture of SpongeBob. The picture should look as similar as possible to the link provided.

My Platform in Windows XP on a PC computer, but I also use MACS

The language is Java.

I need help to get started on this. I cant seem to get program to work. I am not sure even on how to begin the source code. I am requesting if someone can please just help me get started. Thank you.

Here is my code what I have started. I have made 3 classes SpongeBob, Oval, and JFrame. So 3 boxes that I have linked as related. Here is my code so far. Please I need help to get started. I am not asking for anyone to do this for me, just to get started.

import javax.swing;
import java.awt.Color;



public class SpongeBob {

private JFrame window;
private Oval whiteCicle, blackCircle;
private Rectangle blackRectangle, whiteRectangle;



public SpongeBob()


{
}


Note: I want to draw the picture as shown in the JPEG link provided using the Java drawing classes, rather than taking that picture file and displaying it directly within a frame.


User is offlineProfile CardPM
+Quote Post

William_Wilson
RE: Creating A Pic Of SpongeBob
22 Sep, 2007 - 12:34 PM
Post #3

lost in compilation
Group Icon

Joined: 23 Dec, 2005
Posts: 4,101



Thanked: 25 times
Dream Kudos: 3275
Expert In: Java, C, Javascript

My Contributions
please do not forget to use the code tags.

we will need more of an attempt than this, try this snippet:
http://www.dreamincode.net/code/snippet34.htm
it uses an applet, but the code for displaying the shape is the same in both cases.
User is offlineProfile CardPM
+Quote Post

CSJavaGuy
RE: Creating A Pic Of SpongeBob
22 Sep, 2007 - 12:56 PM
Post #4

New D.I.C Head
*

Joined: 22 Sep, 2007
Posts: 3


My Contributions
QUOTE(William_Wilson @ 22 Sep, 2007 - 01:34 PM) *

please do not forget to use the code tags.

we will need more of an attempt than this, try this snippet:
http://www.dreamincode.net/code/snippet34.htm
it uses an applet, but the code for displaying the shape is the same in both cases.



Ok, but still when i make the java drawing classes, how would I do that...make three. If you look at the SpongeBob Pic we need to make on that looks closet that. I know it will need an oval for eyes, rectangles probably for some other parts, but not sure on how to even start properly.
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/8/09 12:32AM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live Java Help!

Java Tutorials

Reference Sheets

Java Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month