久久―日本道色综合久久,亚洲欧美精品在线,狼狼色丁香久久婷婷综合五月,香蕉人人超,日本网站黄,国产在线观看不卡免费高清,无遮挡的毛片免费

2023信創(chuàng)獨角獸企業(yè)100強(qiáng)
全世界各行各業(yè)聯(lián)合起來,internet一定要實現(xiàn)!

用C++ 開發(fā)特殊的屏幕顯示效果

2004-02-14 eNet&Ciweek

7、在Items5的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item5Click(TObject *Sender)

  {                        //圖像從左移入//

   Form1->Refresh( );

  for(i=Bitmap1->Width;i>=0;i--)

   {

   Dest1=Rect(0,0,Bitmap1->Width-i,Bitmap1->Height);

   Source1=Rect(i,0,Bitmap1->Width,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

  }

  8、在Items6的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item6Click(TObject *Sender)

  {                        //圖像從右移入//

   Form1->Refresh( );

  for(i=0;i<=Bitmap1->Width;i++)

   {

   Dest1=Rect(Bitmap1->Width-i,0,Bitmap1->Width,

         Bitmap1->Height);

   Source1=Rect(0,0,i,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

  }

  9、在Items7的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item7Click(TObject *Sender)

  {                       //圖像從上移入//

  Form1->Refresh( );

  for(i=0;i<=Bitmap1->Height;i++)

   {

   Dest1 =Rect(0,0,Bitmap1->Width,i);

   Source1 =Rect(0,Bitmap1->Height-i,Bitmap1->Width,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

  }

  10、在Items8的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item8Click(TObject *Sender)

  {                       //圖像從下移入//

  Form1->Refresh( );

   for(i=0;i<=Bitmap1->Height;i++)

   {

   Dest1 =Rect(0,Bitmap1->Height-i,Bitmap1->Width,

         Bitmap1->Height);

   Source1 =Rect(0,0,Bitmap1->Width,i);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

    }

  11、在Items9的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item9Click(TObject *Sender)

  {                       //圖像從左刷屏顯示//

  Form1->Refresh( );

  for(i=0;i<=Bitmap1->Width;i++)

   {

   Dest1 =Rect(0,0,i,Bitmap1->Height);

   Source1 =Rect(0,0,i,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

  }

   }

  12、在Items10的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item10Click(TObject *Sender)

  {                     //圖像從右刷屏顯示//

  Form1->Refresh( );

  for(i=Bitmap1->Width;i>=0;i--)

   {

   Dest1 =Rect(i+0,0,0+Bitmap1->Width,0+Bitmap1->Height);

   Source1 =Rect(i,0,Bitmap1->Width,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

  }

  13、在Items11的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item11Click(TObject *Sender)

  {                     //圖像從上刷屏顯示//

  Form1->Refresh( );

   for(i=0;i<=Bitmap1->Height;i++)

   {

   Dest1 =Rect(0,0,Bitmap1->Width+0,i+0);

   Source1 =Rect(0,0,Bitmap1->Width,i);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

  }

  }

  14、在Items12的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item12Click(TObject *Sender)

  {                   //圖像從下刷屏顯示//

  Form1->Refresh( );

   for(i=Bitmap1->Height;i>=0;i--)

   {

   Dest1 =Rect(0,i+0,Bitmap1->Width+0,Bitmap1->Height+0);

   Source1 =Rect(0,i,Bitmap1->Width,Bitmap1->Height);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

  }

  15、在Items13的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item13Click(TObject *Sender)

  {                   //圖像從上往下流水//

  Form1->Refresh( );

  for(i=Bitmap1->Height;i>=0;i--)

   {

   Source1 =Rect(0,i,Bitmap1->Width,i+1);

   for(int j1=0;j1<=i;j1++)

   {

   Dest1 =Rect(0 ,j1,Bitmap1->Width+0,j+1);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

   }

  }

  16、在Items14的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item14Click(TObject *Sender)

  {                    //圖像從下往上流水//

  Form1->Refresh( );

   for(i=0;i<=Bitmap1->Height;i++)

   {

   Source1 =Rect(0,i,Bitmap1->Width,i+1);

   for(int j1=Bitmap1->Height-1;j1>=i;j1--)

   {

   Dest1 =Rect(0,j1,Bitmap1->Width,j1+1);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   for(j=0;j<10000;j++);

   }

   }

  }

  17、在Items15的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item15Click(TObject *Sender)

  {                   //圖像圓形展出//

  Form1->Refresh( );

   int j1=sqrt(Bitmap1->Width*Bitmap1->Width+

       Bitmap1->Height*Bitmap1->Height)/2+4;

   for (i=1;i

   {

   MyRgn=CreateEllipticRgn(Bitmap1->Width/2-i,

               Bitmap1->Height/2-i,

               Bitmap1->Width/2+i,

               Bitmap1->Height/2+i);

   SelectObject(Canvas->Handle,MyRgn);

   Canvas->Draw(0,0,Bitmap1);

   DeleteObject(MyRgn);

   for(j=0;j<10000;j++);

   }

  }

  18、在Items16的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item16Click(TObject *Sender)

  {                   //圖像左右錯移//

  Form1->Refresh( );

   HeightHalf=Bitmap1->Height/2+Bitmap1->Height%2;

   Source1=Rect(0,0,Bitmap1->Width,HeightHalf);

   Source2=Rect(0,HeightHalf,Bitmap1->Width,Bitmap1->Height);

   for(i=0;i<=Bitmap1->Width;i++)

   {

   Dest1=Rect(0-Bitmap1->Width+i,0,i,0+HeightHalf);

   Dest2=Rect(Bitmap1->Width-i,HeightHalf,

         Bitmap1->Width+Bitmap1->Width-i,

         Bitmap1->Height+0);

   Form1->Canvas->MoveTo(0-Bitmap1->Width+i-1,0);

   Form1->Canvas->LineTo(0-Bitmap1->Width+i-1,HeightHalf);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   Form1->Canvas->MoveTo(

           Bitmap1->Width+Bitmap1->Width-i,0);

   Form1->Canvas->LineTo(

    Bitmap1->Width+Bitmap1->Width-i,Bitmap1->Height);

  

   Form1->Canvas->CopyRect(Dest2,Bitmap1->Canvas,Source2);

   for(j=0;j<10000;j++);

   }

  }

  19、在Items17的OnClieck事件中添加如下代碼:

  void__fastcall TForm1::Item17Click(TObject *Sender)

  {                    //圖像上下錯移//

   Form1->Refresh( );

  WideHalf=Bitmap1->Width/2+Bitmap1->Width%2;

   Source1=Rect(0,0,WideHalf,Bitmap1->Height);

   Source2=Rect(WideHalf,0,Bitmap1->Width,Bitmap1->Height);

   for(i=0;i<=Bitmap1->Height;i++)

   {

   Dest1=Rect(0,0-Bitmap1->Height+i,WideHalf,0+i);

   Dest2=Rect(WideHalf,

         Bitmap1->Height-i,

         Bitmap1->Width,

         Bitmap1->Height+Bitiap1(>Ighdht)k-;   &'Biym1->Canvas->MoveTo(0,0-Bitmap1->Height+i-1);

   Form1->Canvas->LineTo(WideHalf,

                   0-Bitmap1->Height+i-1);

   Form1->Canvas->CopyRect(Dest1,Bitmap1->Canvas,Source1);

   Form1->Canvas->MoveTo(WideHalf,

                   Bitmap1->Height+Bitmap1->Height-i);

   Form1->Canvas->LineTo(Bitmap1->Width,

                   Bitmap1->Height+Bitmap1->Height-i);

   Form1->Canvas->CopyRect(Dest2,Bitmap1->Canvas,Source2);

   for(j=0;j<10000;j++);

  }

  }

以上程序在C++ Builder5.0Enterpriseh和Win98/WinME通過。

相關(guān)頻道: eNews

您對本文或本站有任何意見,請在下方提交,謝謝!

投稿信箱:tougao@enet16.com