Play vedio in jmonkey from byte array

i want to play an encrypted vedio in jmonkey, decrypt a vedio without writing file to disk.

play vedio from byte array,( mp4 vedios)

You may take a look at

do this play vedio from byte array.
play vedio from stream of bytes .

i dont want to give file name as hello.mp4
like this
play = new play(new File(“hello.mp4”);

play = new play(byte[]);

Yes I think it plays from file. For more info you can look at source code anyway.

so i hve to built my own vedio player , this is ur suggesting.

because no vlcj and javafx can play vedio from byte array .

if i hve to built my own vedio player for just one format mp4
how do i start.

do i start animating images and play audio concourently

or extract images from hex code of mp4 and audio
and play

No, I mean you can take a look at vlcj source code to see if it supports what you want. Here is vlcj source

A quick search shows it supports playing from InputStraem which then you can first convert your byte array to input stream

then play it with vlcj

You havent explained WHY you need to use a byte array to read from. Are you streaming from the internet?

copyright protection and in future streaming also.

You are about 4 years of intensive mathematics ahead of yourself. You can’t do what you’re trying to do because your trying to use standard tools using non standard methods. You will need to develop your own player. If you decrypt it to mp4 like you say, you just circumvented your own protection. The whole point of copyright protection is that it cannot be played by regular players.

And just a heads up. Every protection you make can be bypassed by a simple frame by frame print screen and audio feed recording. It’s a well travelled road.

1 Like