Comments (4)
with gradle or manually?
https://github.com/pedroSG94/rtmp-rtsp-stream-client-java/wiki/Add-library-to-your-project
what builder are you using?
can you post your code used and console log?
from rtmp-rtsp-stream-client-java.
i used gradle in android studio.
allprojects {
repositories {
maven { url 'https://jitpack.io' }
}
}
dependencies {
compile 'com.github.pedroSG94.rtmp-rtsp-stream-client-java:builder:1.1.0'
}
MainActivity.java
import android.Manifest;
import android.annotation.SuppressLint;
import android.app.Activity;
import android.app.ProgressDialog;
import android.content.ContentUris;
import android.content.Context;
import android.content.DialogInterface;
import android.content.Intent;
import android.content.pm.PackageManager;
import android.content.res.Configuration;
import android.database.Cursor;
import android.graphics.Bitmap;
import android.graphics.Color;
import android.net.ConnectivityManager;
import android.net.NetworkInfo;
import android.net.Uri;
import android.os.Build;
import android.os.Bundle;
import android.os.Environment;
import android.os.Handler;
import android.os.StrictMode;
import android.provider.DocumentsContract;
import android.provider.MediaStore;
import android.support.v4.app.ActivityCompat;
import android.support.v4.content.ContextCompat;
import android.support.v7.app.AlertDialog;
import android.util.AttributeSet;
import android.util.Log;
import android.view.InflateException;
import android.view.KeyEvent;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.SurfaceHolder;
import android.view.SurfaceView;
import android.view.WindowManager;
import android.webkit.*;
import android.widget.TextView;
import android.widget.Toast;
import android.hardware.Camera;
import android.content.Context;
import java.io.IOException;
import android.content.pm.ActivityInfo;
import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.hardware.Camera;
import android.hardware.Camera.PictureCallback;
import android.media.MediaRecorder;
import android.media.CamcorderProfile;
import com.pedro.encoder.input.video.CameraOpenException;
import com.pedro.encoder.input.video.EffectManager;
import com.pedro.builder.rtmp.RtmpBuilder;
import net.ossrs.rtmp.ConnectCheckerRtmp;
import com.pedro.rtmpstreamer.R;
import java.io.File;
import java.io.IOException;
import java.net.HttpURLConnection;
import java.net.URL;
import java.text.SimpleDateFormat;
import java.util.Date;
console output:
Executing tasks: [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies]
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2520Library
:app:prepareComAndroidSupportAppcompatV72520Library
:app:prepareComAndroidSupportSupportCompat2520Library
:app:prepareComAndroidSupportSupportCoreUi2520Library
:app:prepareComAndroidSupportSupportCoreUtils2520Library
:app:prepareComAndroidSupportSupportFragment2520Library
:app:prepareComAndroidSupportSupportMediaCompat2520Library
:app:prepareComAndroidSupportSupportV42520Library
:app:prepareComAndroidSupportSupportVectorDrawable2520Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaBuilder110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaEncoder110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaRtmp110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaRtsp110Library
:app:prepareComMcxiaokeVolleyLibraryAar100Library
:app:prepareComWritingmindsFFmpegAndroid032Library
:app:prepareDebugDependencies
:app:compileDebugAidl UP-TO-DATE
:app:compileDebugRenderscript UP-TO-DATE
:app:generateDebugBuildConfig UP-TO-DATE
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources UP-TO-DATE
:app:mergeDebugResources UP-TO-DATE
:app:processDebugManifest UP-TO-DATE
:app:processDebugResources UP-TO-DATE
:app:generateDebugSources UP-TO-DATE
:app:preDebugAndroidTestBuild UP-TO-DATE
:app:prepareComAndroidSupportTestEspressoEspressoCore222Library
:app:prepareComAndroidSupportTestEspressoEspressoIdlingResource222Library
:app:prepareComAndroidSupportTestExposedInstrumentationApiPublish05Library
:app:prepareComAndroidSupportTestRules05Library
:app:prepareComAndroidSupportTestRunner05Library
:app:prepareDebugAndroidTestDependencies
:app:compileDebugAndroidTestAidl UP-TO-DATE
:app:processDebugAndroidTestManifest UP-TO-DATE
:app:compileDebugAndroidTestRenderscript UP-TO-DATE
:app:generateDebugAndroidTestBuildConfig UP-TO-DATE
:app:generateDebugAndroidTestResValues UP-TO-DATE
:app:generateDebugAndroidTestResources UP-TO-DATE
:app:mergeDebugAndroidTestResources UP-TO-DATE
:app:processDebugAndroidTestResources UP-TO-DATE
:app:generateDebugAndroidTestSources UP-TO-DATE
:app:mockableAndroidJar UP-TO-DATE
:app:preDebugUnitTestBuild UP-TO-DATE
:app:prepareDebugUnitTestDependencies
BUILD SUCCESSFUL
Total time: 7.034 secs
Executing tasks: [:app:generateDebugSources, :app:generateDebugAndroidTestSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:compileDebugSources, :app:compileDebugAndroidTestSources, :app:compileDebugUnitTestSources]
Configuration on demand is an incubating feature.
Incremental java compilation is an incubating feature.
:app:preBuild UP-TO-DATE
:app:preDebugBuild UP-TO-DATE
:app:checkDebugManifest
:app:preReleaseBuild UP-TO-DATE
:app:prepareComAndroidSupportAnimatedVectorDrawable2520Library
:app:prepareComAndroidSupportAppcompatV72520Library
:app:prepareComAndroidSupportSupportCompat2520Library
:app:prepareComAndroidSupportSupportCoreUi2520Library
:app:prepareComAndroidSupportSupportCoreUtils2520Library
:app:prepareComAndroidSupportSupportFragment2520Library
:app:prepareComAndroidSupportSupportMediaCompat2520Library
:app:prepareComAndroidSupportSupportV42520Library
:app:prepareComAndroidSupportSupportVectorDrawable2520Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaBuilder110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaEncoder110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaRtmp110Library
:app:prepareComGithubPedroSG94RtmpRtspStreamClientJavaRtsp110Library
:app:prepareComMcxiaokeVolleyLibraryAar100Library
:app:prepareDebugDependencies
:app:compileDebugAidl UP-TO-DATE
:app:compileDebugRenderscript UP-TO-DATE
:app:generateDebugBuildConfig UP-TO-DATE
:app:generateDebugResValues UP-TO-DATE
:app:generateDebugResources UP-TO-DATE
:app:mergeDebugResources UP-TO-DATE
:app:processDebugManifest UP-TO-DATE
:app:processDebugResources UP-TO-DATE
:app:generateDebugSources UP-TO-DATE
:app:preDebugAndroidTestBuild UP-TO-DATE
:app:prepareComAndroidSupportTestEspressoEspressoCore222Library
:app:prepareComAndroidSupportTestEspressoEspressoIdlingResource222Library
:app:prepareComAndroidSupportTestExposedInstrumentationApiPublish05Library
:app:prepareComAndroidSupportTestRules05Library
:app:prepareComAndroidSupportTestRunner05Library
:app:prepareDebugAndroidTestDependencies
:app:compileDebugAndroidTestAidl UP-TO-DATE
:app:processDebugAndroidTestManifest UP-TO-DATE
:app:compileDebugAndroidTestRenderscript UP-TO-DATE
:app:generateDebugAndroidTestBuildConfig UP-TO-DATE
:app:generateDebugAndroidTestResValues UP-TO-DATE
:app:generateDebugAndroidTestResources UP-TO-DATE
:app:mergeDebugAndroidTestResources UP-TO-DATE
:app:processDebugAndroidTestResources UP-TO-DATE
:app:generateDebugAndroidTestSources UP-TO-DATE
:app:mockableAndroidJar UP-TO-DATE
:app:preDebugUnitTestBuild UP-TO-DATE
:app:prepareDebugUnitTestDependencies
:app:incrementalDebugJavaCompilationSafeguard UP-TO-DATE
:app:javaPreCompileDebug
:app:compileDebugJavaWithJavac
:app:compileDebugJavaWithJavac - is not incremental (e.g. outputs have changed, no previous execution, etc.).
C:\testRtmp\app\src\main\java\com\rtmp\testrtmp\MainActivity.java:67: error: package com.pedro.rtmpstreamer does not exist
import com.pedro.rtmpstreamer.R;
^
Note: C:\testRtmp\app\src\main\java\com\rtmp\testrtmp\MainActivity.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 error
:app:compileDebugJavaWithJavac FAILED
FAILURE: Build failed with an exception.
- What went wrong:
Execution failed for task ':app:compileDebugJavaWithJavac'.
Compilation failed; see the compiler error output for details.
- Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 3.636 secs
from rtmp-rtsp-stream-client-java.
The problem is that you try use R from a not downloaded module.
when you use:
compile 'com.github.pedroSG94.rtmp-rtsp-stream-client-java:builder:1.1.0'
You said to gradle that you want download and compile builder module from com.github.pedroSG94.rtmp-rtsp-stream-client-java in version 1.1.0
So you download builder module and dependencies from it.
import com.pedro.rtmpstreamer.R is from app and app module is not a dependencie of builder module.
To solve delete import com.pedro.rtmpstreamer.R and all import started with com.pedro.rtmpstreamer (app module is only a grafic module for show you how to use the library).
from rtmp-rtsp-stream-client-java.
ok thanks. I thought this might be causing no video to show and no data to be sent to the server.
i'll remove that import.
from rtmp-rtsp-stream-client-java.
Related Issues (20)
- How to play multiple files with RtspServerFromFile HOT 9
- Echo Problem HOT 9
- Hello! I would like to ask you if this library can achieve screen recording and push stream, not through the camera through the screen recording to push the device picture and sound to the server. HOT 14
- Unstable FPS HOT 3
- Where can I download previous versions? HOT 7
- Local Screen Recording and Device Audio Recording HOT 5
- import issue HOT 2
- i can't streaming HOT 5
- Pause Record to File for GenericStream/StreamBase HOT 4
- WHIP & RIST Support HOT 4
- Need help Livestream app for football events not working when adding an overlay over the camera video HOT 3
- How to record screen on android HOT 4
- Corrupt duration in file metadata when recording and livestreaming HOT 11
- What is a legal srt push stream url? HOT 4
- AutoFitTextureView not works
- Android run error when add library HOT 6
- Sharpening filter no visible effect HOT 2
- Set SRT latency HOT 2
- Bitrate on screen not matching streamed bitrate HOT 6
- Occur error at onCreate() HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rtmp-rtsp-stream-client-java.