JOGL has its own JPEG decoder but it doesn't have its own JPEG encoder yet. Then, JPEG encoding uses Swing under the hood if it's available and it creates at most 2 buffered images per texture data object in IIOTextureWriter: https://github.com/sgothel/jogl/blob/master/src/jogl/classes/com/jogamp/opengl/util/texture/spi/awt/IIOTextureWriter.java There is an excellent JPEG encoder written in Javascript that could be ported to Java: https://github.com/owencm/javascript-jpeg-encoder/blob/master/jpeg_encoder_basic.js