这篇教程C++ DrawScreen函数代码示例写得很实用,希望能帮到您。
本文整理汇总了C++中DrawScreen函数的典型用法代码示例。如果您正苦于以下问题:C++ DrawScreen函数的具体用法?C++ DrawScreen怎么用?C++ DrawScreen使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。 在下文中一共展示了DrawScreen函数的30个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。 示例1: Button28OnClickvoid Button28OnClick() { unsigned char l,cnt[4]; if(i==6) { if(a==0) { a=1; i=0; InitMCU(); SF_Start(); SF_mem(); Write_Log("Security armed"); } else { i=0; InitMCU(); SF_Start(); SF_rem(); Write_Log("Security disarmed"); } DrawScreen(&System_Log_Screen); Delay_ms(2000); strcpy(Label24.Caption," "); hom=1; DrawScreen(&Home); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例2: SF_memvoid SF_mem(){ unsigned char i,l,cnt[4]; long adr=0x111111; for(i=0;i<6;i++) { SerialFlash_WriteByte(arm[i],adr); adr+=0x000020; } strcpy(Label24.Caption," ******"); DrawScreen(&System_Log_Screen); for(l=0;l<10;l++) { ByteToStr(10-l,cnt); strcpy(Label25.Caption," "); strcat(Label25.Caption,cnt); DrawScreen(&System_Log_Screen); FT812_Sound_SetAndPlay(_FT812_SOUND_CLICK,_FT812_SOUND_PITCH_B3,vol); Delay_ms(1000); } Box30.Color=0x00FF0000; Box36.Color=0x00FF0000; Image65.Visible=0; Image66.Visible=1; strcpy(Label25.Caption," ARMED"); strcpy(Label8.Caption," ARMED");}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:27,
示例3: Gameplay/** * Runs the game. * @param track file * @return */int Gameplay(FILE* track){ int sleeptime = START_PERIOD; int freeze = 0; size_t count = 0; unsigned planepos = SCREEN_WIDTH / 2; DrawScreen(); while (1) { usleep(sleeptime); if (sleeptime > 100 * 1000) sleeptime = sleeptime - sleeptime / 20; if (input.key_pressed == quit) //TODO: Handle quit { break; } if (freeze) { continue; } if (!ScrollScreen(track)) { mvprintw(SCREEN_HEIGHT / 2, 10, " Track completed! "); refresh(); freeze = 1; continue; } pthread_mutex_lock(&input.lock); if ((input.key_pressed == left) && planepos > 0) // TODO: Handle left movement { planepos--; input.key_pressed = not_pressed; } if ((input.key_pressed == right) && planepos < SCREEN_WIDTH - 1) // TODO: Handle right movement { planepos++; input.key_pressed = not_pressed; } pthread_mutex_unlock(&input.lock); if (screen[SCREEN_WIDTH * (SCREEN_HEIGHT - 1) + planepos] == OBSTACLE) { // Ohhh no... Crash! mvprintw(SCREEN_HEIGHT / 2, 10, " CRASH! Game over. "); refresh(); freeze = 1; continue; } screen[SCREEN_WIDTH * (SCREEN_HEIGHT - 1) + planepos] = PLANE; DrawScreen(); mvprintw(0, 0, " %zu ", count++); refresh(); } return 0;}
开发者ID:tachyo,项目名称:SNP,代码行数:65,
示例4: DrawScreenbool OpenGLSWFrameBuffer::Wiper_Crossfade::Run(int ticks, OpenGLSWFrameBuffer *fb){ Clock += ticks; // Put the initial screen back to the buffer. DrawScreen(fb, fb->InitialWipeScreen); // Draw the new screen on top of it. DrawScreen(fb, fb->FinalWipeScreen, GL_FUNC_ADD, ColorValue(0,0,0,Clock / 32.f), ColorRGBA(255,255,255,0)); return Clock >= 32;}
开发者ID:Xane123,项目名称:world-of-kirbycraft,代码行数:12,
示例5: DrawScreenbool D3DFB::Wiper_Crossfade::Run(int ticks, D3DFB *fb){ Clock += ticks; // Put the initial screen back to the buffer. DrawScreen(fb, fb->InitialWipeScreen); // Draw the new screen on top of it. DrawScreen(fb, fb->FinalWipeScreen, D3DBLENDOP_ADD, D3DCOLOR_COLORVALUE(0,0,0,Clock / 32.f), D3DCOLOR_RGBA(255,255,255,0)); return Clock >= 32;}
开发者ID:BadSanta1980,项目名称:gzdoom,代码行数:13,
示例6: CircleButton7OnPressvoid CircleButton7OnPress() { if((Box62.Left+Box62.Width)>=(Box64.Left+Box64.Width)) Box64.Left+=1; d_l[choice_t]=0+(int)floor((Box64.Left-219)*100/197); dim_l[choice_t]=Box64.Left; IntToStr(d_l[choice_t],Label97.Caption); DrawScreen(&Light_Mode);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例7: whilevoidApp::Run(){ // // Initialize the event handler // EventManager eventHandler; // Main game loop while(1) { // // Draw the next screen // DrawScreen(); // Step the physics world PhysicsWorld::GetInstance()->Step(1.0 / 60.0); // Sleep SDL_Delay(1000.0 / 60.0); // // Handle events // while(eventHandler.IsEventWaiting()) eventHandler.HandleEvent(); } }
开发者ID:pkonneker,项目名称:Open2dAdventure,代码行数:32,
示例8: SM_BT_MMClickvoid SM_BT_MMClick() {// Go back to Main ScreenCounterflag = 0;remote_mod=0;DrawScreen(&MainMenu);}
开发者ID:whuang86cn,项目名称:uC_Dev,代码行数:7,
示例9: doSettingsvoid doSettings() { BLED_Fade_Out(); DrawScreen(&Settings); BLED_Fade_In(); Logger_State = 2;}
开发者ID:jemmicat,项目名称:Ducati_Mikro,代码行数:7,
示例10: ChangeResolutionvoid ChangeResolution(){if (bFullScreen) { if (vmVideoMode==vmGraph512) sfScreen = SDL_SetVideoMode(512, 384, 8, SDL_SWSURFACE | SDL_FULLSCREEN | SDL_HWPALETTE); else if (vmVideoMode==vmGraph800) sfScreen = SDL_SetVideoMode(800, 600, 8, SDL_SWSURFACE | SDL_FULLSCREEN | SDL_HWPALETTE); else sfScreen = SDL_SetVideoMode(640, 480, 8, SDL_SWSURFACE | SDL_FULLSCREEN | SDL_HWPALETTE); SDL_ShowCursor(SDL_DISABLE); }else { if (vmVideoMode==vmGraph512) sfScreen = SDL_SetVideoMode(512, 384, 8, SDL_SWSURFACE | SDL_HWPALETTE); else if (vmVideoMode==vmGraph800) sfScreen = SDL_SetVideoMode(800, 600, 8, SDL_SWSURFACE | SDL_HWPALETTE); else sfScreen = SDL_SetVideoMode(640, 480, 8, SDL_SWSURFACE | SDL_HWPALETTE); SDL_ShowCursor(SDL_ENABLE); }//printf("w=%d, h=%d, pitch=%d/n",SDL_GetVideoSurface()->w,SDL_GetVideoSurface()->h,SDL_GetVideoSurface()->pitch);SetPalette();DrawScreen();}
开发者ID:timtashpulatov,项目名称:emu80,代码行数:35,
示例11: Button40OnClickvoid Button40OnClick() { char i; if(ti!=1 && tim[1]!=1) { ti=1; dat=2; Button39.Color=0x00800000; Button40.Color=0x00FF0000; Button41.Color=0x00800000; Button42.Color=0x00800000; Button46.Color=0x00800000; Label34.Font_Color=0x00FFFFFF; Label44.Font_Color=0x00400000; Label45.Font_Color=0x00FFFFFF; Label71.Font_Color=0x00FFFFFF; Label72.Font_Color=0x00FFFFFF; strcpy(Label44.Caption,"Minutes: "); datum.min=0; for(i=2;i<4;i++) { date[i]=0; } DrawScreen(&Settings_Screen); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例12: Button39OnClickvoid Button39OnClick() { char i; if(ti!=0 && tim[0]!=1) { ti=0; dat=0; Button39.Color=0x00FF0000; Button40.Color=0x00800000; Button41.Color=0x00800000; Button42.Color=0x00800000; Button46.Color=0x00800000; Label34.Font_Color=0x00400000; Label44.Font_Color=0x00FFFFFF; Label45.Font_Color=0x00FFFFFF; Label71.Font_Color=0x00FFFFFF; Label72.Font_Color=0x00FFFFFF; strcpy(Label34.Caption,"Hour: "); datum.hour=0; for(i=0;i<2;i++) { date[i]=0; } DrawScreen(&Settings_Screen); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例13: Button11OnClickvoid Button11OnClick() { unsigned char i; strcpy(Label73.Caption,""); strcpy(Label75.Caption,""); strcpy(Label76.Caption,""); strcpy(Label77.Caption,""); strcpy(Label78.Caption,""); strcpy(Label34.Caption,"Hours: "); strcpy(Label44.Caption,"Minutes: "); strcpy(Label45.Caption,"Day: "); strcpy(Label71.Caption,"Month: "); strcpy(Label72.Caption,"Year: "); for(i=0;i<12;i++) { date[i]=0; } for(i=0;i<5;i++) { tim[i]=0; } dat=0; datum.hour=0; datum.min=0; datum.day=0; datum.mon=0; datum.year=0; Button39OnClick(); DrawScreen(&Settings_Screen); }
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:27,
示例14: Box24OnClickvoid Box24OnClick() { CheckBox1.Checked=1-CheckBox1.Checked; DrawScreen(&Keyboard_Screen); vol=255-vol; FT812_Sound_SetAndPlay(_FT812_SOUND_XYLOPHONE,_FT812_SOUND_PITCH_B3,vol); Delay_ms(1000);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例15: Button27OnClickvoid Button27OnClick() { char cnt; for(cnt=0;cnt<=5;cnt++) arm[cnt]=0; i=0; strcpy(Label24.Caption,""); DrawScreen(&System_Log_Screen);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例16: CircleButton8OnPressvoid CircleButton8OnPress() { if((Box63.Left+Box63.Width)>=(Box65.Left+Box65.Width)) Box65.Left+=1; h_l[choice_t]=15+(int)floor((Box65.Left-219)*15/197); hum_l[choice_t]=Box65.Left; IntToStr(h_l[choice_t],Label98.Caption); DrawScreen(&Light_Mode);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例17: mainint main(void) { // Initialise the clock to have a /1 prescaler and use the external crystal clock source for accuracy. CLK_DeInit(); CLK_SYSCLKConfig(CLK_PRESCALER_CPUDIV1); CLK_ClockSwitchConfig(CLK_SWITCHMODE_AUTO, CLK_SOURCE_HSE, DISABLE, CLK_CURRENTCLOCKSTATE_DISABLE); // Reset ("de-initialise") GPIO port D. GPIO_DeInit(GPIOD); // Initialise pin 0 of port D by setting it as: // - an output pin, // - using a push-pull driver, // - at a low logic level (0V), and // - 10MHz. GPIO_Init(GPIOD, GPIO_PIN_0, GPIO_MODE_OUT_PP_LOW_FAST); LCDInit(); // Init the LCD DecodeInit(); // Init the GPS decoding DrawScreen(); // Setup Screen and Buffer // Infinite loop. for(;;) { // Blink Debug LED GPIO_WriteReverse(GPIOD, GPIO_PIN_0); DrawDemo(); }}
开发者ID:KNVRK,项目名称:STM8SProjects,代码行数:28,
示例18: Button41OnClickvoid Button41OnClick() { char i; if(ti!=2 && tim[2]!=1) { ti=2; dat=4; Button39.Color=0x00800000; Button40.Color=0x00800000; Button41.Color=0x00FF0000; Button42.Color=0x00800000; Button46.Color=0x00800000; Label34.Font_Color=0x00FFFFFF; Label44.Font_Color=0x00FFFFFF; Label45.Font_Color=0x00400000; Label71.Font_Color=0x00FFFFFF; Label72.Font_Color=0x00FFFFFF; strcpy(Label45.Caption,"Day: "); datum.day=0; for(i=4;i<6;i++) { date[i]=0; } DrawScreen(&Settings_Screen); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例19: doPrevScreenvoid doPrevScreen() { BLED_Fade_Out(); DrawScreen(&Speedometer); BLED_Fade_In(); Logger_State = 0;}
开发者ID:jemmicat,项目名称:Ducati_Mikro,代码行数:7,
示例20: Button42OnClickvoid Button42OnClick() { char i; if(ti!=3 && tim[3]!=1) { ti=3; dat=6; Button39.Color=0x00800000; Button40.Color=0x00800000; Button41.Color=0x00800000; Button42.Color=0x00FF0000; Button46.Color=0x00800000; Label34.Font_Color=0x00FFFFFF; Label44.Font_Color=0x00FFFFFF; Label45.Font_Color=0x00FFFFFF; Label71.Font_Color=0x00400000; Label72.Font_Color=0x00FFFFFF; strcpy(Label71.Caption,"Month: "); datum.mon=0; for(i=6;i<8;i++) { date[i]=0; } DrawScreen(&Settings_Screen); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例21: doSensorTestvoid doSensorTest() { BLED_Fade_Out(); DrawScreen(&Sensor_test); BLED_Fade_In(); Logger_State = 4;}
开发者ID:jemmicat,项目名称:Ducati_Mikro,代码行数:7,
示例22: Button46OnClickvoid Button46OnClick() { char i; if(ti!=4 && tim[4]!=1) { ti=4; dat=8; Button39.Color=0x00800000; Button40.Color=0x00800000; Button41.Color=0x00800000; Button42.Color=0x00800000; Button46.Color=0x00FF0000; Label34.Font_Color=0x00FFFFFF; Label44.Font_Color=0x00FFFFFF; Label45.Font_Color=0x00FFFFFF; Label71.Font_Color=0x00FFFFFF; Label72.Font_Color=0x00400000; strcpy(Label72.Caption,"Year: "); datum.year=0; for(i=8;i<12;i++) { date[i]=0; } DrawScreen(&Settings_Screen); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:25,
示例23: BeginPaintvoid CDrawableWidget::OnPaint(){ // CButton::OnPaint(); BeginPaint(&m_ps); DrawScreen(); EndPaint(&m_ps);}
开发者ID:pkch,项目名称:mfc-and-opengl-fixed-function-toolkit-and-grad-school-projects,代码行数:7,
示例24: Button12OnClickvoid Button12OnClick() { strcpy(Label23.Caption,Label94.Caption); strcat(Label23.Caption,"h"); gr_pow=0; hom=1; DrawScreen(&Home); }
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例25: CopyToClipBoardvoid CopyToClipBoard( MainWndInfo *info ) { HBITMAP copy; HBITMAP old_bitmap; HDC dc; HDC mdc; POINT origin = { 0, 0 }; /* clone the bitmap */ dc = info->screen->memdc; mdc = CreateCompatibleDC( dc ); copy = CreateCompatibleBitmap( dc, info->wndsize.x, info->wndsize.y ); old_bitmap = SelectObject( mdc, copy ); DrawScreen( info->screen, mdc, &origin, &info->wndsize, &origin, &info->magsize ); SelectObject( mdc, old_bitmap ); DeleteDC( mdc ); /* add the bitmap */ OpenClipboard( info->screen->hwnd ); EmptyClipboard(); SetClipboardData( CF_BITMAP, copy ); CloseClipboard();}
开发者ID:ABratovic,项目名称:open-watcom-v2,代码行数:28,
示例26: CircleButton3OnPressvoid CircleButton3OnPress() { if((Box47.Left+Box47.Width)>=(Box23.Left+Box23.Width)) Box23.Left+=1; t_t[choice_t]=15+(int)floor((Box23.Left-219)*15/197); temp_t[choice_t]=Box23.Left; IntToStr(t_t[choice_t],Label95.Caption); DrawScreen(&Temperature_Mode);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例27: CircleButton4OnPressvoid CircleButton4OnPress() { if((Box48.Left+Box48.Width)>=(Box49.Left+Box49.Width)) Box49.Left+=1; h_t[choice_t]=20+(int)floor((Box49.Left-219)*60/197); hum_t[choice_t]=Box49.Left; IntToStr(h_t[choice_t],Label96.Caption); DrawScreen(&Temperature_Mode);}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:7,
示例28: SF_remvoid SF_rem(){ unsigned char i,temp[6]; char txte[4],txtex[4]; int val=0; long adr=0x111111; for(i=0;i<6;i++) { temp[i] = SerialFlash_ReadByte(adr); ByteToStr(temp[i],txte); ByteToStr(arm[i],txtex); if(temp[i]!=arm[i]) val=1; adr+=0x000020; } Delay_ms(3000); for(i=0;i<6;i++) arm[i]=0; strcpy(Label24.Caption,""); DrawScreen(&System_Log_Screen); if(val==0) { a=0; Box30.Color=0x00008040; Box36.Color=0x00008040; Image65.Visible=1; Image66.Visible=0; strcpy(Label25.Caption,"DISARMED"); strcpy(Label8.Caption,"DISARMED"); }}
开发者ID:MikroElektronika,项目名称:mikromedia_HMI,代码行数:29,
示例29: SS_BT_RMClickvoid SS_BT_RMClick() {//remote_mod=1; UART1_Write_Text("Remote");DrawScreen(&RemoteMode);}
开发者ID:whuang86cn,项目名称:uC_Dev,代码行数:7,
示例30: mainint main(int argc, char **argv) { ros::init(argc, argv, "HumanInterface"); //Creates a node named "HumanInterface" ros::NodeHandle n; pose_sub = n.subscribe("/motion/Odometry", 1000, receive_pose_estimate); pose_target_sub = n.subscribe("/motion/Speed", 1000, receive_pose_target); cv::Mat screen(HEIGHT,WIDTH,CV_8UC1,cv::Scalar(0)); cv::cvtColor(screen, screen, CV_GRAY2BGR); //ros::Rate loop_rate(30); // frequency cv::imshow("Human Interface", screen); cv::waitKey(1); int time_old = ros::Time::now().nsec; while (ros::ok()) { if (ros::Time::now().nsec-time_old > 100E6 && redraw) { time_old = ros::Time::now().nsec ; DrawScreen(screen); redraw = false; } //loop_rate.sleep(); // Sleep for 10 ms ros::spinOnce(); // Process ros messages } return EXIT_SUCCESS;}
开发者ID:TheiaRobo,项目名称:Theia,代码行数:29,
注:本文中的DrawScreen函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 C++ DrawShape函数代码示例 C++ DrawScene函数代码示例 |