0

I am doing a VCL streaming and I need to get the frames or the video from a java multicast.

I join the multicast group and I receive these datagram packets, but I do not know how to handle them.

Any code advices? Or any library to convert these packets into frames in kind of real time?

public static void main(String[] args) throws UnknownHostException {

            InetAddress address = InetAddress.getByName(INET_ADDR);
            byte[] buffer = new byte[256];

            try (MulticastSocket clientSocket = new MulticastSocket(PORT)){

                clientSocket.joinGroup(address);

                while (true) {

                    DatagramPacket msgPacket = new DatagramPacket(buffer, buffer.length);
                    clientSocket.receive(msgPacket);


                }
            } catch (IOException exception) {
                exception.printStackTrace();
            }                System.out.println(i);

        }

p.s I can not modify the way of sending the streaming packets

Thanks

diego
  • 147
  • 1
  • 1
  • 8
  • There are thousands of possible format combinations the video can be encoded as. You first need to figure out what the encoding and packaging method is before somebody can help you. – szatmary Apr 08 '19 at 18:53
  • Hi, I am just trying to make it work somehow, lets say in VLC I choose MPEG-TS. My problem is that I can not find the way to transform this kind of text: " G d�w{�{��" in something usable. Thanks – diego Apr 09 '19 at 10:13

0 Answers0