googlearchive / android-screencapture Goto Github PK
View Code? Open in Web Editor NEWMigrated:
Home Page: https://github.com/android/media-samples
License: Apache License 2.0
Migrated:
Home Page: https://github.com/android/media-samples
License: Apache License 2.0
Mediaprojection doesn't work with MediaRecorder
What am I doing wrong?
Android 6 Marshmallow (Redmi 4 Prime, MIUI 8) http://www.gsmarena.com/xiaomi_redmi_4_prime-8263.php
08-24 14:15:12.424 32114 32114 E AndroidRuntime: FATAL EXCEPTION: main
08-24 14:15:12.424 32114 32114 E AndroidRuntime: Process: com.tcl.screenrecord, PID: 32114
08-24 14:15:12.424 32114 32114 E AndroidRuntime: android.content.ActivityNotFoundException: Unable to find explicit activity class {com.android.systemui/com.android.systemui.media.MediaProjectionPermissionActivity}; have you declared this activity in your AndroidManifest.xml?
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at android.app.Instrumentation.checkStartActivityResult(Instrumentation.java:1932)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at android.app.Instrumentation.execStartActivity(Instrumentation.java:1615)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at android.app.Activity.startActivityForResult(Activity.java:4516)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at android.app.Activity.startActivityForResult(Activity.java:4474)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at com.tcl.screenrecord.MainActivity.startScreenRecording(MainActivity.java:203)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at com.tcl.screenrecord.MainActivity.access$500(MainActivity.java:25)
08-24 14:15:12.424 32114 32114 E AndroidRuntime: at com.tcl.screenrecord.MainActivity$1.onClick(MainActivity.java:128)
i tried the sample. Pressed "start" and nothing happens. Also tried "stop" after that, and still nothing. What is going on?
I have given it permission to capture the screen, btw.
I imported the project into android studio, ran the app.
When you press start it works fine, then I press stop and it stops. Now when I press play again, the device crashes fully. It no longer responds to touch, soft keys and hardware buttons (turn off screen etc. no longer works). The only option is to press and hold the power button to force the device into rebooting.
No logs could be captured because the device fully crashes, so I assume a memory leak or something
Tested on both a Nexus 7 and Samsung Galaxy S4, both updated to the latest version of android 5 as of typing
As we know, we can use Android MediaProjection API to capture screen in an Activity, but I want to capture screen in a thread of a Service. But Android Service has no onActivityResult() method that MediaProjection need to do something. It seems that we can only call MediaProjection API like belows:
startActivityForResult(mProjectionManager.createScreenCaptureIntent(), REQUEST_CODE);
Is there a way to use MediaProjection in an Android Service?
is there any way to create a custom surfaceview to hide the content of my screen while casting for some privacy concern?
testfairy develope such plugin which records user touches even if "Show touches" not enabled at developer settings.
Two of the URLs in README.md are not encoded properly and the URLs in CONTRIBUTING.md have syntax errors.
Submitting an issue because CONTRIBUTING.md says to, but I've already fixed it and will post a PR shortly.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.