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

Record Activity was crashed after initializing recorded video #480

Closed
kieukhuongthinh opened this issue Aug 15, 2016 · 1 comment
Closed

Comments

@kieukhuongthinh
Copy link

kieukhuongthinh commented Aug 15, 2016

Hi Saudet,

I'm trying to run the record activity in your javacv-1.2-src.zip, but when I clicked on Start button, the app has stopped.

My logcat:

08-15 20:40:50.040 9581-9581/demos.recordactivity E/Camera: Camera new cameraInitNormal:0
08-15 20:40:50.040 9581-9581/demos.recordactivity I/RecordActivity: cameara open
08-15 20:40:50.040 9581-9581/demos.recordactivity W/camera: camera view
08-15 20:40:50.041 9581-9581/demos.recordactivity I/RecordActivity: cameara preview start: OK

                                                                    [ 08-15 20:40:50.059   482:  628 I/         ]
                                                                    mempoolcfg case CLEAR_ALL, virtual void android::MTMemoryPool::MemHandler::handleMessage(const android::Message&)
08-15 20:40:50.202 9581-9612/demos.recordactivity I/OpenGLRenderer: Initialized EGL, version 1.4
08-15 20:40:55.107 9581-9581/demos.recordactivity W/RecordActivity: init recorder
08-15 20:40:55.154 9581-9581/demos.recordactivity I/RecordActivity: ffmpeg_url: /storage/emulated/0/KKTTesting/recordedVideo.mp4

My build.gradle:

configurations {
    all*.exclude group: 'org.bytedeco', module: 'javacpp-presets'
}

repositories {
    mavenCentral()
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])
    testCompile 'junit:junit:4.12'
    compile 'com.android.support:appcompat-v7:24.0.0-beta1'

    compile group: 'org.bytedeco', name: 'javacv', version: '1.2'
}

I've changed something:

private String ffmpeg_link;
private String outputDir = "/KKTTesting";
...
@Override
public void onCreate(Bundle savedInstanceState) {
...
          new File(Environment.getExternalStorageDirectory(), outputDir).mkdir();
          ffmpeg_link = Environment.getExternalStorageDirectory() + outputDir + "/recordedVideo.flv";
}

I tested it on Android 6.0 and I'm using android studio.

@kieukhuongthinh
Copy link
Author

I found the answer here: #412

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

No branches or pull requests

2 participants