Canvas 및 canvas.scale (Scale, Scale)을 사용하여 이미지 품질 문제가 발생했습니다.Canvas 및 canvas.scale (스케일, 스케일)을 사용하여 이미지 화질 문제;
안드로이드 : 그들은 정확히 다음과 같이 실행
내가 비트 맵을 다시 크기를 조정할 때 나는 이미지 품질 문제의 모든 게시물을 읽고 생각하지만, 도움이하지 않는 것으로 크기를 조정할 이미지의 품질 Canvas 축척 (float 축척)으로 축척 할 때.
이미지 품질 게시물에서 제안한 여러 가지 옵션을 시도했습니다.
BitmapFactory.Options options = new BitmapFactory.Options();
options.inJustDecodeBounds = false;
options.inDither = false;
options.inSampleSize = 1;
options.inScaled = false;
options.inPreferredConfig = Bitmap.Config.ARGB_8888;//I thought this would do it
CurrentPicture = BitmapFactory.decodeFile(path, options);//Also tried decodeStream()
PicturePaint = new Paint();
//PicturePaint = new Paint(Paint.FILTER_BITMAP_FLAG); //I also tried this
//PicturePaint = new Paint(Paint.ANTI_ALIAS_FLAG); //I also tried this
canvas.scale(Scale, Scale);
canvas.drawBitmap(CurrentPicture, 0, 0, PicturePaint);
저는 이것이 내 목표를 달성하는 데있어 마지막 장벽이라고 생각합니다. 이미지 품질 문제를 해결할 수 없다면 문제가 생길 수 있습니다. 어떤 도움을 주셔서 감사합니다.
감사합니다.
시스템에서 사진을 게시 할 수 없으므로 다음 링크가 있습니다.
코드를 제공해 주셔서 감사합니다. 정말 감사. 나는 그것이 효과가 있다고 믿는다. 시도했을 때 용의자가 됨 PicturePaint = new Paint (Paint.FILTER_BITMAP_FLAG); PicturePaint = 새로운 PaintPaint.ANTI_ALIAS_FLAG); 비트 맵을 Bitmap.Config.ARGB_8888로 설정하지 않았습니다. – user1133277
ok ................... – Ramz