Does anyone know how to draw an image or play a sound from file? I imagine there is (are) a library (libraries), but I can't find them...
venomlash
55
Junior Poster
Recommended Answers
Jump to PostIs this what you mean?
Image a; public void init() { a = getImage(getDocumentBase(), "a.jpg"); } public void paint(Graphics g){ g.drawImage(a, x, y, width, height, this); }
AudioClip a; public void init() { a = getImage(getDocumentBase(), "a.wma"); a.play(); }
You need to make sure …
All 4 Replies
jasimp
427
Senior Poster
Featured Poster
venomlash
commented:
He just seems to know this stuff...
+2
venomlash
55
Junior Poster
venomlash
55
Junior Poster
jasimp
427
Senior Poster
Featured Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.