i am a new learner. Recently, i want to use API to change the resolution of the preview live stream. I find that i can use API from camera API, but where is it? what is the difference between camera API and web API?
https://api.ricoh/docs/theta-plugin-reference/camera-api/ From here, it said that i can configure the resolution as 640,1024, 1920. So what is the specific function that i can use in the demo project included in the SDK?
thank you very much!
Welcome to THETA Plug-in Development. You’re at the right place.
There’s a new Getting Started guide here.
Open this project, NOT the SDK.
Go to line 362 of this file:
private void setSurface(@NonNull SurfaceHolder surfaceHolder) {
if (mCamera != null) {
mCamera.stopPreview();
try {
mCamera.setPreviewDisplay(surfaceHolder);
mParameters.setPreviewSize(1920, 960);
mCamera.setParameters(mParameters);
} catch (IOException e) {
e.printStackTrace();
close();
}
mCamera.startPreview();
}
}
Use the Facial Blur sample to display the stream in a web browser.
You really help me a lot! THANK YOU!
1 Like