HTC Desire 的 MediaStore.ACTION_VIDEO_CAPTURE 问题
我正在尝试在我的应用程序中使用 MediaStore.ACTION_VIDEO_CAPTURE,请参阅下面的代码。 不过,HTC 的愿望似乎存在问题。 当视频捕获 Intent 启动时,一切都很好,但是一旦按下用于录制的圆形按钮,或者实际上与之交互的任何 UI,Intent 就会挂起。 Logcat 不会抛出任何错误,但每当我尝试与手机交互时,它都会发布“UI Block”。 我可以使用主页按钮退出应用程序,但此后相机无法访问,应用程序无法再次在手机上运行 - 直到设备重置。我已经在 HTC 手机上尝试过该应用程序,运行没有任何问题。我认为这可能是 HTC Sense UI 的问题,但我不确定。代码如下:
case R.id.VCF_Btn_record: Intent captureVideoIntent = new Intent(android.provider.MediaStore.ACTION_VIDEO_CAPTURE); startActivityForResult(captureVideoIntent, VIDEO_CAPTURED);
MediaStore 的 API 级别为 1,ACTION_VIDEO_CAPTURE API 级别为 3,因此它应该可以在此设备上运行,还有其他人经历过类似的情况吗?
I am attempting to use the MediaStore.ACTION_VIDEO_CAPTURE in my app, see code below.
However, there seems to be an issue with it on the HTC desire.
When the video capture intent launches, everything is fine, but as soon as the round button for record is pressed, or any of the UI interacted with in fact, the intent hangs. Logcat doesn't throw any errors, but whenever I attempt to interact with the phone it posts " UI Block".
I am able to quit the application with the home button, but after this the camera is unaccessable, the app cannot rund on the phone again -untill the device has been reset. Ive tried the app on a HTC sensation where it worked without problems. I think it might be an issue with the HTC Sense UI, but I am not sure. Code as follows:
case R.id.VCF_Btn_record:
Intent captureVideoIntent = new Intent(android.provider.MediaStore.ACTION_VIDEO_CAPTURE);
startActivityForResult(captureVideoIntent, VIDEO_CAPTURED);
MediaStore is API level 1, and ACTION_VIDEO_CAPTURE API lvl 3, so it should work on this device, has anyone else experienced anything similar?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这是我在我的应用程序中使用的代码,它完全符合我的愿望:
我知道 android.provider.MediaStore.ACTION_VIDEO_CAPTURE 解析为“android.media.action.VIDEO_CAPTURE”,但如果我记得在开发我的应用程序时应用程序,使用它对我不起作用。
看看这是否适合你
Here is the code that I'm using in my app, which works perfectly fine on my Desire:
I know that android.provider.MediaStore.ACTION_VIDEO_CAPTURE resolves to "android.media.action.VIDEO_CAPTURE", but if I recall when developing my app, using it didn't work for me.
See if that works for you