Skip to content

Commit

Permalink
update to v2.9.1
Browse files Browse the repository at this point in the history
  • Loading branch information
illuspas committed Nov 20, 2020
1 parent c68c620 commit be3bf5a
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 17 deletions.
4 changes: 2 additions & 2 deletions nodemediaclient/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ android {
defaultConfig {
minSdkVersion 16
targetSdkVersion 28
versionCode 2806
versionName "2.8.6"
versionCode 2901
versionName "2.9.1"
}

buildTypes {
Expand Down
8 changes: 2 additions & 6 deletions nodemediaclient/src/main/java/cn/nodemedia/NodePlayer.java
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ public class NodePlayer implements NodePlayerView.RenderCallback {
private String pageUrl;
private String swfUrl;
private String connArgs;
private String cryptoKey;
private String rtspTransport;

private int bufferTime;
Expand Down Expand Up @@ -62,7 +61,6 @@ public NodePlayer(@NonNull Context context, @NonNull String license) {
this.pageUrl = "";
this.swfUrl = "";
this.connArgs = "";
this.cryptoKey = "";
this.logLevel = NM_LOGLEVEL_ERROR;
this.rtspTransport = RTSP_TRANSPORT_UDP;
this.bufferTime = 500;
Expand Down Expand Up @@ -154,10 +152,6 @@ public void setConnectWaitTimeout(int connectWaitTimeout) {
this.connectWaitTimeout = connectWaitTimeout;
}

public void setCryptoKey(String cryptoKey) {
this.cryptoKey = cryptoKey;
}

public void setLogLevel(int logLevel) {
this.logLevel = logLevel;
}
Expand Down Expand Up @@ -211,6 +205,8 @@ private void onEvent(int event, String eventMsg) {

public native int setVolume(float volume);

public native void setCryptoKey(String cryptoKey);

public native int start();

public native int stop();
Expand Down
16 changes: 7 additions & 9 deletions nodemediaclient/src/main/java/cn/nodemedia/NodePublisher.java
Original file line number Diff line number Diff line change
Expand Up @@ -33,17 +33,16 @@ public class NodePublisher implements NodeCameraView.NodeCameraViewCallback {
private String pageUrl;
private String swfUrl;
private String connArgs;
private String cryptoKey;

private boolean isFrontCamera;
private boolean isDisplayFrontMirror;
private boolean isStartPreview;

private int cameraId;
private int cameraOri;
private int windowOri;
private int cameraWidth;
private int cameraHeight;
private int surfaceOri;
private int surfaceWidth;
private int surfaceHeight;
private int logLevel;
Expand Down Expand Up @@ -75,6 +74,7 @@ public class NodePublisher implements NodeCameraView.NodeCameraViewCallback {
public static final int VIDEO_PROFILE_BASELINE = 0;
public static final int VIDEO_PROFILE_MAIN = 1;
public static final int VIDEO_PROFILE_HIGH = 2;
public static final int VIDEO_PROFILE_HEVC_MAIN = 3;

public static final int CAMERA_BACK = 0;
public static final int CAMERA_FRONT = 1;
Expand Down Expand Up @@ -159,10 +159,6 @@ public void setConnArgs(@NonNull String connArgs) {
this.connArgs = connArgs;
}

public void setCryptoKey(String cryptoKey) {
this.cryptoKey = cryptoKey;
}

public void setCameraPreview(@NonNull NodeCameraView cameraPreview, int cameraID, boolean frontMirror) {
mNodeCameraView = cameraPreview;
mNodeCameraView.setNodeCameraViewCallback(this);
Expand Down Expand Up @@ -198,7 +194,7 @@ public int startPreview() {
int ret = mNodeCameraView.startPreview(cameraId);
isFrontCamera = mNodeCameraView.isFrontCamera();
cameraOri = mNodeCameraView.getCameraOrientation();
windowOri = getWindowRotation();
surfaceOri = getWindowRotation();
if (ret == 0) {
isStartPreview = true;
}
Expand Down Expand Up @@ -306,6 +302,8 @@ public interface CapturePictureListener {

public native void setHwEnable(boolean hwEnable);

public native void setCryptoKey(String cryptoKey);

public native void setAudioEnable(boolean audioEnable);

public native void setVideoEnable(boolean videoEnable);
Expand Down Expand Up @@ -336,12 +334,12 @@ public void OnCreate() {
@Override
public void OnChange(int cameraWidth, int cameraHeight, int surfaceWidth, int surfaceHeight) {
this.cameraOri = mNodeCameraView.getCameraOrientation();
this.windowOri = getWindowRotation();
this.surfaceOri = getWindowRotation();
this.cameraWidth = cameraWidth;
this.cameraHeight = cameraHeight;
this.isFrontCamera = mNodeCameraView.isFrontCamera();
if (this.mNodePublisherVideoTextureDelegate != null) {
this.mNodePublisherVideoTextureDelegate.onChangeTextureCallback(this, this.isFrontCamera, this.cameraOri, this.windowOri);
this.mNodePublisherVideoTextureDelegate.onChangeTextureCallback(this, this.isFrontCamera, this.cameraOri, this.surfaceOri);
}
jniChangeGPUImage(cameraWidth, cameraHeight, surfaceWidth, surfaceHeight);
}
Expand Down
Binary file not shown.
Binary file not shown.
Binary file modified nodemediaclient/src/main/jniLibs/x86/libNodeMediaClient.so
Binary file not shown.
Binary file modified nodemediaclient/src/main/jniLibs/x86_64/libNodeMediaClient.so
Binary file not shown.

0 comments on commit be3bf5a

Please sign in to comment.