亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? idardevice.cc

?? 一個機器人平臺
?? CC
?? 第 1 頁 / 共 2 頁
字號:
		  // also reflectors.		  //break;		  		case IDARReflect: // it's a reflector (ie. an obstacle)		  //printf( "REFLECT from %p type %s idar_return %d\n",		  //	ent, ent->token, ent->idar_return );					  // try poking this message into my own receiver		  if( (intensity = LookupIntensity(0,range,true)) > 0 )		    ReceiveMessage( (CEntity*)this, 				    transmit->mesg,				    transmit->len,				    intensity, 				    true );		  break;					default:		  printf( "STAGE WARNING: UNKNOWN IDAR VALUE %d\n", 			  ent->idar_return );		}		  	      break; // out of the while loop because we hit something	    }	}#ifdef INCLUDE_RTK2#ifdef RENDER_SCANLINES      rtk_fig_color_rgb32(this->rays_fig, RGB(220,220,220) );	      rtk_fig_arrow(this->rays_fig, 0,0, scanline_bearing-oth, range, 0.03);#endif#endif        }}bool CIdarDevice::ReceiveMessage( CEntity* sender,				  unsigned char* mesg, int len, 				  uint8_t intensity,				  bool reflection ){  //PRINT_DEBUG( "RECEIVE MESSAGE" );  //printf( "mesg recv - sensor: %d  len: %d  intensity: %d  refl: %d\n",  //  sensor, len, intensity, reflection );  // TEST INTENSITY  // we only accept this message if it's the most intense thing we've seen  if( intensity < recv.intensity )    return false;    // TEST REFLECTION AND  ANGLE OF INCIDENCE  // we accept reflections without checking angle  if( !reflection )     { // it's not a reflection, so we check the angle of incidence       double sx, sy, sa; // the sender's pose      double lx, ly, la; // my pose            sender->GetGlobalPose( sx, sy, sa );      this->GetGlobalPose( lx, ly, la );            double incidence = atan2( sy-ly, sx-lx ) - la;      NORMALIZE(incidence);            //printf( "%p G: %.2f,%.2f,%.2f   L: %.2f,%.2f,%.2f inc: %.2f\n",       //      this, sx, sy, sa, lx, ly, la, incidence );            // if it's out of our receptive angle, we reject it and bail.      if( fabs(incidence) > IDAR_RECEIVE_ANGLE/2.0 )	return false;    }      // looks good  - accept the message  // copy the message into the data buffer  memcpy( &recv.mesg, mesg, len );    recv.len = len;  recv.intensity = intensity;  recv.reflection = (uint8_t)reflection;    // record the time we received this message  recv.timestamp_sec = m_world->m_sim_timeval.tv_sec;  recv.timestamp_usec = m_world->m_sim_timeval.tv_usec;  #ifdef INCLUDE_RTK2        // reflections are green, remote messages are red  rtk_fig_color_rgb32(this->data_fig, 		      reflection ? RGB(0,200,0) : RGB(200,0,0) );    rtk_fig_arrow(this->data_fig, 0,0,0, 1.5*size_x, size_y );  #ifdef SHOW_MSGS    // room for the message in hex text  char message[ 3 * IDARBUFLEN + 6];    // print the message in hex, with a space between each char  for( int c=0; c<recv.len; c++ )    sprintf( message + 3*c, "%2X ", recv.mesg[c] );  message[ 3 * recv.len ] = 0; // terminate    // add the intensity  sprintf( message, "%s (%d)", message, recv.intensity );      rtk_fig_text(this->data_fig, 0,0,0, message);#endif#endif  return true; // we accepted the message}// HERE ARE A BUNCH OF RANGE/INTENSITY CONVERSION TABLES DETERMINED// EMPIRICALLY BY EXPERIMENTS WITH THE PHERBOTS. WE USE ONE OF THESE// FOR ROBOT-TO-ROBOT TRANSMISSIONS AND ONE FOR REFLECTIONS// ranges are in INCHES// (BASED ON 3g32)int reflection_intensity[] = { 150,129,117,115,112,104,103,102,101,100};int reflection_range[]     = {   0,  1,  7, 10, 14, 26, 28, 31, 35, 39, 99};int reflection_len = 10;// (BASED ON HERE_I_AM)int direct_intensity[] = { 130,126,125,123,122,121,120,119,118,117,115,114,			   112,112,111,109,108,107,106,105,104,103,101, 97,			   96, 95, 94, 93, 90 };int direct_range[]     = {   6,  9, 12, 15, 18, 21, 24, 28, 32, 36, 40, 44, 			     48, 52, 56, 60, 64, 68, 72, 76, 80, 84, 88, 92, 			     96,100,104,108,120,1200};int direct_len = 30;// RTV - reverse lookup distance to intensityuint8_t CIdarDevice::LookupIntensity( uint8_t transmit_intensity,				      double trans_range, 				      bool reflection ){  // transmit_intensity isn't used for now  // subtract our radius from the range reading  trans_range -= size_x / 2.0;  // convert range from m to inches (yuk!)  int irange = (int)(trans_range * 39.37); // m to inches     uint8_t result = 255; // make sure we got a result  int* dist_table = 0;  int* sigi_table = 0;  int table_len = 0;  // choose the tables to work from  if( reflection )    {      dist_table = reflection_range;      sigi_table = reflection_intensity;      table_len = reflection_len;    }  else    {      dist_table = direct_range;      sigi_table = direct_intensity;      table_len = direct_len;    }        // now do the lookup  // if we're below the minimum distance, return the maximum intensity  if( irange < dist_table[0] )    {      //printf( "vrange %d below minimum %d\n", vrange, dist_table[0] );      result = sigi_table[0];    }  // if we're above the max distance, return zero intensity  else if( irange > dist_table[ table_len-1 ] )    {      //printf( "irange %d is above maximum %d %s\n",       //      irange, dist_table[ table_len-1],      //      reflection ? "reflect" : "direct" );            result = 0;//sigi_table[ table_len-1 ];    }  // otherwise, interpolate a result from the table  else    for (int j = 1; j < table_len; j++)	      {	if( irange == dist_table[j] )	  {	    result = sigi_table[j];	    break;	  }	else if (irange < dist_table[j])		  {	    //printf( "irange %d is between %d and %d %s\n",	    //    irange, dist_table[j-1], dist_table[j],	    //    reflection ? "reflect" : "direct" );	    	    //# we're in the right range; calc ans;	    result =  (uint8_t)((irange - dist_table[j-1])				* (sigi_table[j] - sigi_table[j-1])				/ (dist_table[j] - dist_table[j-1])				+ sigi_table[j-1] );	    break;	  }      }      assert( result != 255 );    if( result > 200 )    printf( "WARNING: intensity suspicious!" );    //printf( "RANGE: %umm %u' %uv  INT: %u\n",   //  trans_range, irange, vrange, result );    return result;} #ifdef INCLUDE_RTK2///////////////////////////////////////////////////////////////////////////// Initialise the rtk guivoid CIdarDevice::RtkStartup(){  CPlayerEntity::RtkStartup();    // Create a figure representing this object  this->data_fig = rtk_fig_create(m_world->canvas, this->fig, 49);  this->rays_fig = rtk_fig_create(m_world->canvas, this->fig, 48);    rtk_fig_origin(this->data_fig, 0,0,0 );  rtk_fig_origin(this->rays_fig, 0,0,0 );   // show our orientation in the body figure  rtk_fig_line( this->fig, 0,0, size_x/2.0, 0);  // Set the color  rtk_fig_color_rgb32(this->data_fig, this->color);  rtk_fig_color_rgb32(this->rays_fig, RGB(200,200,200) );  #ifdef RENDER_INDEX  // render our index number  char buf[16];  sprintf( buf,"%d", m_player.index );  rtk_fig_text(this->fig, 2.0 * size_x, 0, 0, buf );#endif}///////////////////////////////////////////////////////////////////////////// Finalise the rtk guivoid CIdarDevice::RtkShutdown(){  // Clean up the figure we created  if(this->data_fig) rtk_fig_destroy(this->data_fig);  if(this->rays_fig) rtk_fig_destroy(this->rays_fig);    CPlayerEntity::RtkShutdown();} ///////////////////////////////////////////////////////////////////////////// Update the rtk guivoid CIdarDevice::RtkUpdate(){  CPlayerEntity::RtkUpdate();     // Get global pose  //double gx, gy, gth;  //GetGlobalPose(gx, gy, gth);  //rtk_fig_origin(this->data_fig, gx, gy, gth );  //  if( m_world->ShowDeviceData( this->type_num) )  //{  //  rtk_fig_show( this->data_fig, true );  //  rtk_fig_show( this->rays_fig, true );  // }  //else  //{  //  rtk_fig_show( this->data_fig, false );  //  rtk_fig_show( this->rays_fig, false );  // }    //if( Subscribed() < 1 )  //{  //rtk_fig_clear( this->rays_fig );  //rtk_fig_clear( this->data_fig );  // }}#endif

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
日韩美女在线视频| 欧美一区国产二区| 精品一区二区三区不卡 | 成人精品免费看| 日本免费在线视频不卡一不卡二| 国产精品成人免费精品自在线观看| 国产亚洲欧美在线| 国产精品日日摸夜夜摸av| 国产欧美日韩在线| 国产精品欧美久久久久无广告 | 国产清纯美女被跳蛋高潮一区二区久久w| 日韩精品一区二区三区四区视频| 91精品国模一区二区三区| 这里只有精品视频在线观看| 欧美性生活大片视频| 8v天堂国产在线一区二区| 欧美一区二区日韩一区二区| 日韩一区二区在线看片| 日韩女同互慰一区二区| 久久综合五月天婷婷伊人| 2019国产精品| 亚洲图片你懂的| 无码av免费一区二区三区试看 | 国产偷v国产偷v亚洲高清| wwwwxxxxx欧美| 国产精品国产三级国产普通话99| 最新中文字幕一区二区三区| 天天影视网天天综合色在线播放| 蜜桃精品在线观看| 粉嫩高潮美女一区二区三区 | 欧美日韩精品一区视频| 日韩一区二区三区在线视频| 久久久不卡网国产精品二区| 亚洲天堂av一区| 麻豆成人免费电影| 97国产一区二区| 日韩欧美一区二区免费| 国产精品久久777777| 天天综合色天天| bt欧美亚洲午夜电影天堂| 欧美日本一区二区三区四区| 久久免费视频色| 亚洲成a人片综合在线| 国产一区三区三区| 欧美在线色视频| 国产精品三级久久久久三级| 亚洲h在线观看| 成人av动漫在线| 日韩精品中文字幕在线不卡尤物| 中文字幕亚洲区| 国产一区久久久| 欧美精品123区| 亚洲精品日韩一| 国产a区久久久| 欧美电视剧在线看免费| 一区二区三区四区激情| 粉嫩蜜臀av国产精品网站| 日韩一区二区三区电影在线观看| 亚洲欧美日韩系列| 国v精品久久久网| 精品免费视频.| 视频一区二区三区中文字幕| youjizz国产精品| 久久精品免视看| 久久www免费人成看片高清| 欧美调教femdomvk| 亚洲欧美国产三级| 国产宾馆实践打屁股91| 欧美成人vps| 久久精品国产一区二区三 | 国产精品一区二区在线观看网站| 在线免费亚洲电影| 亚洲美女免费视频| 成av人片一区二区| 椎名由奈av一区二区三区| 成人免费va视频| 中文字幕一区二区三区不卡在线| 国产在线一区二区综合免费视频| 日韩午夜三级在线| 麻豆国产精品一区二区三区 | 成人污污视频在线观看| 久久久噜噜噜久噜久久综合| 国产精品中文欧美| 日本一区二区三区四区| 国产电影一区二区三区| 日本一区二区成人| 一本色道a无线码一区v| 一区二区三区中文在线| 欧美日韩成人高清| 看片的网站亚洲| 久久噜噜亚洲综合| 成人av动漫在线| 亚洲高清视频在线| 欧美一区二区三区精品| 久久精品国产免费看久久精品| 日韩视频免费观看高清完整版 | 亚洲精品在线免费观看视频| 国产乱子伦视频一区二区三区| 久久久亚洲欧洲日产国码αv| 韩国女主播一区二区三区| 国产日韩视频一区二区三区| 成人精品免费看| 亚洲.国产.中文慕字在线| 91精品国产一区二区三区香蕉| 国产最新精品免费| 亚洲欧洲日韩av| 欧美一区午夜视频在线观看| 国产永久精品大片wwwapp| 国产精品成人免费在线| 91精品欧美久久久久久动漫| 黄网站免费久久| 一区二区三区在线视频观看58 | 中文在线资源观看网站视频免费不卡| 成人国产精品视频| 日本在线观看不卡视频| 国产亚洲精品aa午夜观看| 在线日韩一区二区| 粉嫩一区二区三区在线看| 五月天中文字幕一区二区| 国产亚洲欧美一区在线观看| 欧美在线观看一区二区| 国产美女视频91| 香蕉久久一区二区不卡无毒影院| 久久精品夜夜夜夜久久| 欧美日韩情趣电影| 99在线精品一区二区三区| 免费高清在线视频一区·| 亚洲人成网站在线| 久久影视一区二区| 在线电影院国产精品| 不卡一卡二卡三乱码免费网站| 日韩精品欧美精品| 亚洲人xxxx| 国产精品美女久久久久久| 日韩欧美美女一区二区三区| 色哟哟国产精品| 懂色av噜噜一区二区三区av| 日本中文在线一区| 亚洲国产成人av网| 亚洲一区二区三区在线| 中文字幕亚洲视频| 国产精品久久看| 久久精品在这里| 精品成a人在线观看| 欧美一区二区三区免费在线看| 欧美中文字幕亚洲一区二区va在线| 国产99一区视频免费| 国产在线精品一区二区夜色| 亚洲不卡在线观看| 亚洲电影欧美电影有声小说| 亚洲人成网站精品片在线观看| 国产精品嫩草影院av蜜臀| www日韩大片| 国产日韩欧美高清在线| 精品国产制服丝袜高跟| 欧美成人a∨高清免费观看| 91麻豆精品国产91| 日韩一区二区三区精品视频 | 狠狠色丁香婷婷综合| 久久精品国产秦先生| 国产在线看一区| 在线观看亚洲a| 色综合久久久网| 91麻豆精品在线观看| 99国产欧美另类久久久精品| 91丝袜国产在线播放| 日本伦理一区二区| 欧美写真视频网站| 欧美一级黄色片| 久久这里只有精品视频网| 亚洲国产精品成人综合| 中文字幕一区二区三区乱码在线| 亚洲人妖av一区二区| 一区二区三区在线视频播放| 一区二区三区美女| 免费的成人av| 国产成人av电影在线观看| 成年人国产精品| 欧美日韩中文字幕一区| 日韩欧美电影一区| 国产精品久久综合| 亚洲午夜激情网站| 久久激情综合网| 国产99一区视频免费| 欧美在线一区二区三区| 精品国产伦一区二区三区免费 | 91丨九色丨蝌蚪丨老版| 在线亚洲+欧美+日本专区| 欧美一区二区三区影视| 国产亚洲1区2区3区| 亚洲一区二区三区在线| 韩国成人福利片在线播放| 成人免费va视频| 欧美三级电影网站| 中文字幕av不卡| 蜜臀av一区二区| 色综合激情五月| 久久综合视频网| 丝袜国产日韩另类美女| 成人午夜激情片|