Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

当前版本,需要做如下修改,才好用 #376

Open
liuyi opened this issue Mar 16, 2019 · 0 comments
Open

当前版本,需要做如下修改,才好用 #376

liuyi opened this issue Mar 16, 2019 · 0 comments

Comments

@liuyi
Copy link

liuyi commented Mar 16, 2019

1、MediaRecorderActivity.java 修改这个方法,为结束返回结果到上一个:
@OverRide
public void onEncodeComplete() {
hideProgress();
Intent intent = new Intent();
intent.putExtra(MediaRecorderActivity.OUTPUT_DIRECTORY, mMediaObject.getOutputDirectory());
intent.putExtra(MediaRecorderActivity.VIDEO_URI, mMediaObject.getOutputTempTranscodingVideoPath());
intent.putExtra(MediaRecorderActivity.VIDEO_SCREENSHOT, mMediaObject.getOutputVideoThumbPath());
intent.putExtra("go_home", GO_HOME);

    setResult(RESULT_OK, intent);
    finish();
}

2、MediaRecorderActivity.java 添加CANCEL动作,修复奇怪的问题。

加在 case MotionEvent.ACTION_UP: 下面:

case MotionEvent.ACTION_CANCEL:
// startState = false;//added by liuyi
mMediaRecorder.setRecordState(false);
if (mMediaObject.getDuration() >= RECORD_TIME_MAX) {
mTitleNext.performClick();
} else {
mMediaRecorder.setStopDate();
setStopUI();
}

                break;

3、SmallVideoLib2的
build.gradle 去掉bintray插件依赖

4、SmallVideoLib2的
build.gradle里的complie 修改为

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant