欧美一区二区三区老妇人-欧美做爰猛烈大尺度电-99久久夜色精品国产亚洲a-亚洲福利视频一区二区

C#圖像處理

 一、生成圖片并實(shí)現(xiàn)顏色漸變效果

創(chuàng)新互聯(lián)建站是一家業(yè)務(wù)范圍包括IDC托管業(yè)務(wù),虛擬空間、主機(jī)租用、主機(jī)托管,四川、重慶、廣東電信服務(wù)器租用,成都服務(wù)器托管,成都網(wǎng)通服務(wù)器托管,成都服務(wù)器租用,業(yè)務(wù)范圍遍及中國(guó)大陸、港澳臺(tái)以及歐美等多個(gè)國(guó)家及地區(qū)的互聯(lián)網(wǎng)數(shù)據(jù)服務(wù)公司。

    Response.Clear();  
   Bitmap imgOutput = new Bitmap(100, 50);  
   Graphics gic = Graphics.FromImage(imgOutput); 
   gic.Clear(Color.BlueViolet); 
   gic.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias; 
   gic.DrawString("漸變圖形", new Font("黑體",16,FontStyle.Italic),new SolidBrush(Color.White),new PointF(2,2));  
   gic.FillRectangle(new System.Drawing.Drawing2D.LinearGradientBrush(new Point(0,0), new Point(100,50), Color.FromArgb(0,0,0,0),Color.FromArgb(255,255,255,255)),0,0,100,50);  
   imgOutput.Save(Response.OutputStream, System.Drawing.Imaging.ImageFormat.Jpeg); 
   gic.Dispose();  
   imgOutput.Dispose();  
   Response.End();  
二、對(duì)圖片進(jìn)行反轉(zhuǎn)
    System.Drawing.Image drawp_w_picpath = System.Drawing.Image.FromFile(photopath);//photopath表示圖片的物理地址
   drawp_w_picpath.RotateFlip(RotateFlipType.Rotate270FlipNone);
    if(File.Exists(photopath))
   {
        File.SetAttributes(photopath,FileAttributes.Normal);
        File.Delete(photopath);
   }
   drawp_w_picpath.Save(photopath,System.Drawing.Imaging.ImageFormat.Jpeg);
   drawp_w_picpath.Dispose();
三、對(duì)圖片進(jìn)行縮放
    System.Drawing.Image drawp_w_picpath = System.Drawing.Image.FromFile(photopath);
   Bitmap imgOutput = new Bitmap(drawp_w_picpath,60,30);
   imgOutput.Save(newphotppath, System.Drawing.Imaging.ImageFormat.Jpeg);  
   imgOutput.Dispose();  
   Response.End(); 
其他還有一些畫線、畫矩形、畫圓等的函數(shù)和方法都可以在System.Drawing中找到;

網(wǎng)站名稱:C#圖像處理
轉(zhuǎn)載來(lái)于:http://chinadenli.net/article4/gsgpie.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供品牌網(wǎng)站設(shè)計(jì)標(biāo)簽優(yōu)化網(wǎng)站排名自適應(yīng)網(wǎng)站營(yíng)銷型網(wǎng)站建設(shè)ChatGPT

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請(qǐng)盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如需處理請(qǐng)聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來(lái)源: 創(chuàng)新互聯(lián)

網(wǎng)站優(yōu)化排名