android - 打开安卓相机

标签 android camera

在搜索如何打开相机并获取返回的图像时,我看到了大量结果。只是打开相机应用程序而根本没有任何返回呢?我只想让相机正常工作。

最佳答案

您可以只发送一个 ACTION_CAMERA_BUTTON Intent 吗?这应该可以解决问题。

Intent intent = new Intent(ACTION_CAMERA_BUTTON, null);
startActivity(intent);

显然,“this”必须是您当前的 Activity 。

关于android - 打开安卓相机,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3877664/

相关文章:

android - 没有 Braintree 的原生移动设备中的 Paypal 结帐集成

android - UriMatcher 返回错误的值

ios - 如何设置iOS相机的帧速率

Android webview 允许使用当前的 Android Studio 访问相机

image-processing - 射影空间中来自内参的无穷远平面

ios - 我可以更改相机闪光灯亮度级别吗?

android - 如何实现 Android 相机在任何屏幕方向拍照?

android - theme.appcompat.light 的默认文本颜色是什么?

java - 如何在 android oreo 中运行持续的后台服务?

c# - 团结 : How to make camera look at a point