View 获取手机GLES10.GL_MAX_TEXTURE_SIZE
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private static int getMaxSizeInternal() { | |
EGL10 egl = (EGL10) EGLContext.getEGL(); | |
EGLDisplay dpy = egl.eglGetDisplay(EGL10.EGL_DEFAULT_DISPLAY); | |
int[] versions = new int[2]; | |
egl.eglInitialize(dpy, versions); | |
EGLConfig[] configs = new EGLConfig[1]; | |
int[] numConfig = new int[1]; | |
egl.eglGetConfigs(dpy, configs, 1, numConfig); |
View GetScreenshot of recyclerView
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Bitmap getScreenshotFromRecyclerView(RecyclerView view) { | |
RecyclerView.Adapter adapter = view.getAdapter(); | |
Bitmap bigBitmap = null; | |
if (adapter != null) { | |
int size = adapter.getItemCount(); | |
int height = 0; | |
Paint paint = new Paint(); | |
int iHeight = 0; | |
final int maxMemory = (int) Runtime.getRuntime().maxMemory(); |
View gist:002e78b1c7f802cb05a0
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
dajfadfadfad |