Skip to main content

Posts

Showing posts with the label awt

How can I import java.awt.BufferedImage in an Android project?

I see answers to questions suggesting the use of BufferedImages for performing increases that I am very interested in. How can I avoid garbage collection delays in Java games? (Best Practices) But I cannot find out a way to import it because it is not part of the SDK of course. How has everyone else who have used it achieved this? I am basically looking for a way to store graphics I am writing on canvas without having to build them totally from stratch each time. For example storing a drawText() as a BufferedImage and drawing that each frame.