Are there any MPEG encoders written in Java?
I am aware of several Java-based decoders, but no Java-based encoders. I would recommend searching through mpeg.org and especially its "Search Software and Products" page.
In theory, if you can find an all-software MPEG encoder that exposes an API for your use, you should at least be able to wrap the encoder in your own Java bindings. It's not an all-Java solution, but it could give you a Java interface to access your MPEG encoder.