Processing is related to Android mode ‘RTSP (RTP, SDP)’.
The ‘processing.video’ library of the JAVA program makes it easy to resolve ‘RTSP’.
By the way, as far as I know
The ‘processing.video’ library does not support Android mode.
Question 1) Does the ‘processing.video’ library work in Android mode?
question 2= yes, you can using android videoView or android native mediaPlayer - Be sure that the file referred by your rtsp is ok with android supported media codecs.
more details here: https://developer.android.com/guide/topics/media/media-formats
I would like to check the video and sound of CCTV video on mobile.
You cannot hear the sound with ‘MJPEG’.
So, I think it is necessary to implement ‘RTSP’ on mobile.
[JAVA MODE]
import VLCJVideo.*;
VLCJVideo video;
void setup() {
size(640, 360);
video = new VLCJVideo(this);
video.openAndPlay(“rtsp://admin:aa852456!@myksj1105.iptime.org:8081/11/”);
}
@GWAK ===
ok, i understand what you are wanting;
one more question: are you sure that you have to use RTP ? Why? - Using http should be more simple with a webView.
Anyway it is not easy to code that using a videoView without any library; there are a lot of problems with codecs and as for now i think that the most sure way is to add the genuine VLC library to your app. It exists for android but is it possible to add it to Processing, i dont know. I have to see.
@GWAK === yes, i know that there is no error in this code and that ACTION_VIEW must be set; but when you set it to your URL what happens? What is the error code or what is the message inside the app?
ERROR in C:\Users\user\AppData\Local\Temp\android6658805089143585074sketch\src\processing\test\webview_test\webVIEW_TEST.java (at line 90)
URI uri = URI.parse(url);
^^^^^
The method parse(String) is undefined for the type URI
ERROR in C:\Users\user\AppData\Local\Temp\android6658805089143585074sketch\src\processing\test\webview_test\webVIEW_TEST.java (at line 91)
Intent intent = new Intent(Intent.ACTION_VIEW, uri);
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
The constructor Intent(String, URI) is undefined
@GWAK ===
the code you have put cannot run; there are at least 3 errors:
fl (the frame layout) cannot be acceeded as you do (it was possible before, but now it does not work) ; you have to code: fl = (FrameLayout) act.getWindow().getDecorView().getRootView();
Last problem is that for parsing your import is not the good one; you have to import import android.net.Uri;
Now i think that the code will run… Of course i cannot test as i dont know if your cam is running… but with another url it works.
dont forget to ask for internet permission!