无法导入导入android.hardware.camera2类 [英] Can't import import android.hardware.camera2 classes

查看:365
本文介绍了无法导入导入android.hardware.camera2类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我将opencv android库导入了我的android studio,由于无法导入android.hardware.camera2类,所以Camera2Renderer类存在很多编译器错误.

I imported the opencv android library to my android studio and the Camera2Renderer class has a lot of compiler errors because the android.hardware.camera2 classes can't be imported.

推荐答案

我解决了这个问题.吉姆说得对,我没有正确的目标API.对于下一个遇到此问题并找到该线程的人,解决方案是您必须确保项目的build.gradle文件与openCV相匹配.感谢所有帮助我的人和圣诞快乐!

I solved the problem. Jim was right, i did not have the correct target API. For the next person who has this problem and finds this thread, the solution is that you have to make sure that the build.gradle files for your project and your openCV match. Thanks to everyone who helped me, and Merry Christmas!

这篇关于无法导入导入android.hardware.camera2类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆