Comments (8)
Hi @AnkanDey88,
Using Tokbox archiving feature you can store your recorded videos to:
- Amazon S3 bucket or Windows Azure container or
- OpenTok cloud
You can download the archives from both the locations when archives are successfully uploaded. More info here: https://tokbox.com/developer/guides/archiving/
from opentok-android-sdk-samples.
Thank you for letting me know on this. But is there any other way to save local video instead of the Tokbox archiving feature. May be we can use MediaRecorder.
Please let me know on this.
from opentok-android-sdk-samples.
Hi @AnkanDey88,
Yes, you could try to use MediaRecorder with TextureViews.
from opentok-android-sdk-samples.
I have tried to use this. But no result. When I use MediaRecorder, then camera freezes and opponent sees my still image.
If it is possible to use MediaRecorder with TextureViews then please give me any tutorials for that.
Thanks in advance.
from opentok-android-sdk-samples.
Hi @AnkanDey88,
I think you could try 2 approaches:
- If you wan to record entire screen, you could use the MediaRecorder and MediaProjection
- If you only want to record the publisher stream, you could implement a CustomVideoCapturer, where you can manage the mediaRecorder and the Camera.
Find an example about how to manage a CustomVideoCapturer here: https://github.com/opentok/opentok-android-sdk-samples/tree/master/Custom-Video-Driver
from opentok-android-sdk-samples.
I did exactly the same thing which you mentioned in 2nd point. But I'm facing one problem is that, when I start video recording using MediaRecorder I have to unlock the camera first and so that the camera stream freezes for TokBox.
mediaRecorder = new MediaRecorder();
mediaRecorder.setCamera(myCamera); // This camera object got fromCustomVideoCapturer
myCamera.unlock();
mediaRecorder.setAudioSource(MediaRecorder.AudioSource.CAMCORDER);
mediaRecorder.setVideoSource(MediaRecorder.VideoSource.CAMERA);
mediaRecorder.setProfile(CamcorderProfile.get(CamcorderProfile.QUALITY_LOW));
mediaRecorder.setOutputFile("/sdcard/video.mp4");
mediaRecorder.setMaxDuration(60000); // Set max duration 60 sec.
mediaRecorder.setMaxFileSize(5000000); // Set max file size 5M
try {
mediaRecorder.prepare();
mediaRecorder.start();
} catch (IllegalStateException e) {
return false;
} catch (IOException e) {
return false;
}
from opentok-android-sdk-samples.
Hi @AnkanDey88 ,
To use TextureViews you need to indicate it in the SessionOptions.
https://tokbox.com/developer/sdks/android/reference/com/opentok/android/Session.SessionOptions.html
Eg:
mSession = new Session(MainActivity.this, APIKEY, SESSION_ID, new Session.SessionOptions() {
@OverRide
public boolean useTextureViews() {
return true;
}
});
from opentok-android-sdk-samples.
I’m closing this issue because it has been inactive for a few weeks. This probably means that it is not reproducible or it has been fixed.
Please reopen if you still encounter this issue You can also contribute directly by providing a patch.
Thank you!
from opentok-android-sdk-samples.
Related Issues (20)
- iOS app crashing on SDK version 2.25.3 HOT 1
- Publisher video freeze on app resume HOT 1
- TokBox crashes when we pause the publisher and open device camera to capture image HOT 1
- Android 14 crash while screen sharing opentok HOT 2
- Android app crashing when photo gallery is accessed from app to send photo during videocall HOT 7
- okio-2.8.0.jar: 1 vulnerabilities (highest severity is: 7.5)
- setTorchMode error: camera is in use after cycling camera HOT 3
- Issue with obfuscation HOT 1
- Cannot change AudioDevice for advanced CustomAudioDevice HOT 4
- For BackgroundBlur feature with custom radius, application starts lagging HOT 9
- Android and iOS opentok lib not working for screenshare on android and iOS 2.26 version of lib HOT 12
- [ERROR] PublisherKit Error: Unable to Publish. HOT 3
- App is crashing always in dubai zone specific devices only, any idea? HOT 2
- Publisher custom video renderer shows video with inverted colour only HOT 3
- Custom video renderer is giving black and white video frame HOT 1
- Black stream when switching between Publishers after cycleCamera HOT 1
- Stream freezes when `cycleCamera` is called without delay multiple times HOT 1
- BUG: Speaker is used instead of bluetooth earphones after mute/unmute HOT 2
- Android:- Audio shuts down when move the app to background state HOT 2
- metrics.yml - Ensure top-level permissions are not set to write-all
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 opentok-android-sdk-samples.