CameraStreaming
CameraStreaming copied to clipboard
请教下编译上的几个问题
1、请问编译最低使用SDK是4.1吗?运行平台是4.1吗?
2、/MyActivity/src/tv/inhand/rtmp/BasePacketizer.java中 public BasePacketizer() throws IOException { localSocket = new LocalSocket(); dataQueue = new LinkedBlockingDeque<Packet>(MAX_QUEUE_SIZE); // LinkedBlockingDeque<>编译失败 this.is = new ParcelFileDescriptor.AutoCloseInputStream(localSocket.getReceiver()); } 源代码是LinkedBlockingDeque<> 编译失败,提示 Type '<>' operator is not allowed for source level below 1.7
3、如果编译使用4.1,会提示 MEDIA_ERROR_SERVER_DIED cannot be resolved or is not a field 需要用4.4才能编译通过。
是的
需要JDK1.7的语法支持 -- new的时候省略模板参数