Win a copy of Kotlin in Action this week in the Kotlin forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

creating & loading the image  RSS feed

Sonara Rahul
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created a JPanel over which image is painted using paint method.
I have component which creates image by making repeated calls to createImage method of that component.I haven't still painted in the JPanel but just making a call to createImage method itself results in OutOfMemoryError within the java.awt.image class. How can I prevent the memory from begin eaten up by
successive calls to createImage? I have tried image.flush() and Runtime.getRuntime().gc() but it didn't work.I have also increased the heap size.but it didn't work.
Excepting u'r suggestions,
with regards,
sonara rahul.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!