-
- All Implemented Interfaces:
-
com.qmdeve.blurview.Blur
public class BlurNative implements Blur
Native blur implementation, Gaussian blur through JNI call cpp code
-
-
Field Summary
Fields Modifier and Type Field Description private intblurRounds
-
Method Summary
Modifier and Type Method Description intgetBlurRounds()Get the current number of blur rounds voidsetBlurRounds(int rounds)Set the number of blur iterationsEach iteration applies both horizontal and vertical blur passesMore iterations = stronger blur effect static native voidblur(Object bitmap, int radius, int threadCount, int threadIndex, int round)booleanprepare(Bitmap buffer, float radius)voidrelease()voidblur(Bitmap input, Bitmap output)-
-
Method Detail
-
getBlurRounds
int getBlurRounds()
Get the current number of blur rounds
-
setBlurRounds
void setBlurRounds(int rounds)
Set the number of blur iterationsEach iteration applies both horizontal and vertical blur passesMore iterations = stronger blur effect
- Parameters:
rounds- Number of blur iterations (1-15)
-
blur
static native void blur(Object bitmap, int radius, int threadCount, int threadIndex, int round)
- Parameters:
bitmap- Bitmap objects to be blurredradius- Blur radiusthreadCount- Total number of threadsthreadIndex- Current thread indexround- Blur round
-
release
void release()
-
-
-
-