Each SurfaceData object holds a StateTrackableDelegate object which tracks both changes to the content of the pixels of this surface and changes to the overall state of the pixels - such as becoming invalid or losing the surface. The delegate is marked "dirty" whenever the setSurfaceLost() or invalidate() methods are called and should also be marked "dirty" by the rendering pipelines whenever they modify the pixels of this SurfaceData.
If you get a StateTracker from a SurfaceData and it reports that it is still "current", then you can trust that the pixels have not changed and that the SurfaceData is still valid and has not lost its underlying storage (surfaceLost) since you retrieved the tracker.
|
|
|
|