A screen is displayed when screenmanager. Draw (canvas) is used because
Canvas. drawtexturedrect (canvas. region, _ primarytarget, _ primarytarget. region, coloru. Blank );
During this process, the screen will be painted. If you do not execute this process, the screen will not be generated. The reason why the screen is not that there is a problem in this process, but screenmanager is being executed. some parameters in draw (canvas) are not correctly configured. After many attempts, such as setting backgroundsprite or setting the background color to backgroundcolor = "# f000" (in the configuration file: "design. layout. to <scene backgroundcolor = "# f000">.
In the process of solving this problem, I also found that in the official example of PacMan. CS screen. update (time. frametime); this process is commented out, will also cause the screen. In fact, screenmanager. draw (canvas) is mainly caused by drawtexturedrect. My level is limited and I am not sure why this process will cause the screen. In order not to change its source code, you can only analyze the cause one by one, test more, comment more, and try to find a solution more or less.
Original Works from the effort to be lazy, reprint please explain the source of the article: http://www.cnblogs.com/kfarvid/