好了,谢谢 |
不能 您参考一下开发文档 |
不能为空吗 |
廖斌 发表于 2015-5-11 09:20 最后一个参数需要传一个AnyChatOutParam对象 |
pengyuxulyy 发表于 2015-5-11 08:16 您好,最好一个参数不能传空 |
先调用一个文件选择器,然后根据选择的结果得到文件名,再进行传输 下面是传输的代码 protected void onActivityResult(int requestCode, int resultCode, Intent data) { switch (requestCode) { case FILE_SELECT_CODE: // Toast.makeText(this, "选择文件:", Toast.LENGTH_LONG).show(); if (resultCode == RESULT_OK) { // Get the Uri of the selected file Uri uri = data.getData(); final String path = FileUtils.getPath(this, uri); new Thread(new Runnable() { @Override public void run(){ transFile(position, path); } } ).start(); ; } break; } public int transFile(int position,String path){ String id=idList.get(position); return anychat.TransFile(Integer.parseInt(id), path, 0, 0, 0, null); } |
[2015-05-11 08:08:27(398)] ---------------------------AnyChat Platform Core SDK Client Log--------------------------- [2015-05-11 08:08:27(399)] Load libanychatcore.so success!(V5.1 Build Time:Sep 17 2014 15:29:02) [2015-05-11 08:08:27(399)] Android OS SDK Version:19, Support ARMv7:2, Support Neon:4 [2015-05-11 08:08:27(414)] Load libmediautil_v7.so success!(V5.1 Build Time:Sep 17 2014 15:30:19) [2015-05-11 08:08:27(422)] Load libmediashow_4.0.so failed,video display functions will fail!(dlopen failed: cannot locate symbol "_ZN7android7Surface7isValidEv" referenced by "libmediashow_4.0.so"...) [2015-05-11 08:08:27(430)] dlopen failed: cannot locate symbol "_ZN7android6Camera17setPreviewDisplayERKNS_2spINS_7SurfaceEEE" referenced by "libmediacore_4.2.so"... [2015-05-11 08:08:27(431)] Load libmediacore.so success!(V5.1 Build Time:Sep 17 2014 15:29:40) [2015-05-11 08:08:27(432)] HM NOTE 1LTE(Xiaomi) msm8226 4.4.4 [2015-05-11 08:08:29(283)] Invoke BRAC_Connect(10.28.23.197,8906)=0 [2015-05-11 08:08:29(285)] Invoke LoginServer(username=lb) [2015-05-11 08:08:29(357)] CheckClientSocketLink Connect(ip=10.28.23.197,port=8906) [2015-05-11 08:08:29(439)] Server version: V5.1(Build Time:2014-09-17 22:20:35, Server OS:Windows) [2015-05-11 08:08:29(656)] Message OnConnect(bSuccess:1, errorcode=0) [2015-05-11 08:08:29(929)] Message OnLoginSystem(userid=-138,errorcode=0,username=lb), msg deliver worked(0) [2015-05-11 08:08:29(939)] Load libmediashow_4.0.so failed,video display functions will fail!(dlopen failed: cannot locate symbol "_ZN7android7Surface7isValidEv" referenced by "libmediashow_4.0.so"...) [2015-05-11 08:08:29(981)] Connection to streaming media server successfully!(udp delay:20ms) [2015-05-11 08:08:30(028)] Apply video parameter:320x240, bitrate:150000, quality:3, gop:40, fps:10, preset:3, codec:0 [2015-05-11 08:08:30(028)] Invoke BRAC_SetSDKOption(BRAC_SO_NETWORK_P2PPOLITIC=1) [2015-05-11 08:08:30(029)] Invoke SetSDKOption(BRAC_SO_AUDIO_ECHOCTRL,1) [2015-05-11 08:08:30(029)] Invoke BRAC_SetSDKOption(BRAC_SO_CORESDK_USEHWCODEC=0) [2015-05-11 08:08:31(122)] Invoke EnterRoom(roomid=1) [2015-05-11 08:08:31(360)] Message OnEnterRoom(roomid=1,errorcode=0,siteindex=1) [2015-05-11 08:08:31(363)] Audio Playback Device Init(0, 1, 16000, 16), Default Playback Driver [2015-05-11 08:08:31(367)] Message OnReceiveOnlineUser(count=2,roomid=1) [2015-05-11 08:08:31(521)] Message OnP2PConnectState(userid=-135, state=2) [2015-05-11 08:08:31(531)] On Remote UserCameraControl(dwUserId:-135, bOpen:1) [2015-05-11 08:08:31(636)] Message OnP2PConnectState(userid=-135, state=3) [2015-05-11 08:08:31(728)] On Remote UserSpeakControl(dwUserId:-135, bOpen:1) [2015-05-11 08:08:39(528)] Invoke BRAC_TransFile(dwUserid=-135, dwTaskId:971839616, PathName:/storage/emulated/0/DCIM/Camera/IMG_20150409_075546.jpg)=0 |
您好,请将完整的logcat中显示异常的信息帖上来,上面的附图所能看到的信息有限,谢谢。 另外,请将SD卡根目录下的日志文件:BRAnyChatCore.log也一并附上来帮您分析一下。 |
Archiver|手机版|AnyChat ( 粤ICP备13022410号-1 )
GMT+8, 2024-12-22 15:28 , Processed in 0.133685 second(s), 26 queries .
Powered by Discuz! X3
© 2001-2013 Comsenz Inc.