开发者

Need help in following code snippet

开发者 https://www.devze.com 2023-03-25 20:48 出处:网络
I am trying to call a static function cropImage here is how it looks.. public static Image CropImage(Image img, Rectangle cropArea)

I am trying to call a static function cropImage here is how it looks..

 public static Image CropImage(Image img, Rectangle cropArea)
 {
        logic goes here..
 }

I want to call this function to crop am i开发者_运维百科mage how can I do this? When I tried like this

Rectangle objRect=new Rectangle(20,10,200,100);
static_className.CropImage(image,objRect);

I got an error saying invalid argument.


Image oldImg;

Rectangle objrect=new Rectangle(20,10,200,100);
Image newImage=static_className.cropImage(oldImg,objrect);
0

精彩评论

暂无评论...
验证码 换一张
取 消