Display FB profile pic in circular image view in Application

后端 未结 7 1181
刺人心
刺人心 2020-11-29 06:21

I am trying to get the profile pic of a user from FB and display it in a circular image on my app.I am able to retrieve and display the display pic in ProfilePictureView wid

7条回答
  •  攒了一身酷
    2020-11-29 06:56

    You can adapt gusridd answer with some PNG file (with transparency in the middle) using FrameLayout approach. Instead of using vector (API +21), drawable/subtracted_circle will be a file at res/drawable/subtracted_circle.png. Even tough you need to generate this file, you can use any shape you want. You also need to use the same color of your background in the picture.

    
    
    
    
    
    
     
    

    res/drawable/subtracted_circle.png

提交回复
热议问题