Reducing latency when capturing and displaying an RTSP stream

I am trying to display the video being streamed by an IP camera through the RTSP protocol.
After finding many outdated examples (which did rely on the old codeanticode.GSvideo library, which is not available for Processing 3), I did find a sample of code which is working with my IP camera:

Movie movie;

void setup() {
  size(2048, 1024, P2D);
  Movie.supportedProtocols[0] = "rtsp";
  try {
    movie = new Movie(this, "rtsp://");;
  catch (Exception e) {

void movieEvent(Movie m) {;

void draw() {
  image(movie, 0, 0, width, height);

Only problem is the terrible 3-second latency. Which comes definitely from Processing, not from the camera, as using other tools for capturing the RTSP stream (for example PraxisLive) I get a much smaller latency, something as 100-200 ms, not 3 seconds!.
So Processing is doing some large buffering of the incoming RTSP stream.
Does anyone know how to reduce this buffering, or avoiding it entirely?
As I did in PraxisLive with the following setting for the device:

rtspsrc latency=0 buffer-mode=0 udp-buffer-size=400000 location="rtsp://" ! rtph264depay ! decodebin

Thanks in advance for any answer…
Sincerely yours
Angelo Farina
University of Parma, ITALY