Home >Java >javaTutorial >How to add reflection to pictures in Java (code attached)
The content of this article is about how to add reflection to pictures in Java (with code). It has certain reference value. Friends in need can refer to it. I hope it will be helpful to you.
Effect
The effect when the reflection rate is 90%:
Reflection The effect when the rate is 10%:
Implementation principle
The reflection rate is passed into Reflection as the parameter rate button's event handling function:
CreateImageWithReflection This Java method will create a reflectionImage corresponding to the height for display based on the incoming reflection rate parameter rate. Reflection, the finally returned Bitmap is a union image that contains the original image file and the reflection effect:
of this project file Full path: https://github.com/i042416/im...
The above is the detailed content of How to add reflection to pictures in Java (code attached). For more information, please follow other related articles on the PHP Chinese website!