问题描述
我有一个绘制作为背景GLSurfaceView,但是当没有surfaceView.setZOrderOnTop呈现只,背景是可见(真)
I have a GLSurfaceView with a drawable as background, however only the background is visible when rendered without surfaceView.setZOrderOnTop(true)
我要避免使用setZOrderOnTop(真),因为是静态的TextView的正对GLSurfaceView的顶部使用。
I need to avoid using setZOrderOnTop(true) because there are static TextView's being used on top of the GLSurfaceView.
对于得到这个任何建议工作?
Any suggestions for getting this to work?
推荐答案
GLSurfaceView真的不能有一个背景。从表面上看工作方式是通过削减通过你的活动窗口有一个洞,显示出背后的另一面。设置setZOrderOnTop(真)移动活动的窗口上方的表面。
GLSurfaceView cannot really have a background. The way a surface view works is by cutting a hole through your Activity's window and showing another surface behind. Setting setZOrderOnTop(true) moves the surface above the Activity's window.
这篇关于Android的GLSurfaceView与绘制背景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!