How to blur imageview in android

后端 未结 10 2006
南笙
南笙 2020-12-05 10:54

I have an imageview and i set Image Resources programmatically like this:

int resourceId = getResources().getIdentifier(\"imagename\", \"drawable\", \"mypack         


        
10条回答
  •  无人及你
    2020-12-05 11:49

    Just simply use this library https://github.com/ChathuraHettiarachchi/BlurIM , I was having problem with BlurTransformation class had errors thats why couldn't use Glide transformation but this works fine.

    BlurImage.withContext(this)
         .blurFromResource(R.drawable.YOUR_RESOURCE)
         .into(imageView);
    

提交回复
热议问题