开发者

Rotate Arrow 180 degree android

开发者 https://www.devze.com 2023-04-10 02:09 出处:网络
how can i rotate image with 180 degree like :: 开发者_如何学Python Thanks NikUse this int w = oldBitmap.getWidth();

how can i rotate image with 180 degree like ::

开发者_如何学Python

Rotate Arrow 180 degree android

Thanks

Nik


Use this

            int w = oldBitmap.getWidth();
    int h = oldBitmap.getHeight();
    String filePath = null;
    Matrix mtx = new Matrix();

    mtx.postRotate(180);

    oldBitmap = Bitmap.createBitmap(oldBitmap, 0, 0, w, h, mtx, true);

Cheers!!!

0

精彩评论

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

关注公众号