Skip to Main Content

Java SE (Java Platform, Standard Edition)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

webcam applet

843807Apr 7 2005 — edited Nov 25 2005
i am new to java and am not sure what i'm doing. i'm writing an applet to display a webcam i can get the webcam to display the first frame but am not sure how to use th repaint method to show the frames as they are uploaded. below is my code so far and any help would be appreciated.

import java.awt.*;
import java.applet.*;

public class SimpleImageLoad extends Applet
{
Image img;

public void init()
{
img = getImage(getDocumentBase(),getParameter("img"));
}

public void paint(Graphics g)
{
g.drawImage(img,50,50,this);
}

}
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 23 2005
Added on Apr 7 2005
1 comment
115 views