Browse Source

display: minor doc fix and code cleanup

rdb 2 years ago
parent
commit
87b46a61ed
1 changed files with 5 additions and 7 deletions
  1. 5 7
      panda/src/display/graphicsOutput.cxx

+ 5 - 7
panda/src/display/graphicsOutput.cxx

@@ -1113,8 +1113,9 @@ clear_pipe() {
 
 /**
  * Changes the x_size and y_size, then recalculates structures that depend on
- * size.  The recalculation currently includes: - compute_pixels on all the
- * graphics regions.  - updating the texture card, if one is present.
+ * size.  The recalculation currently includes:
+ *  - compute_pixels on all the graphics regions.
+ *  - updating the texture card, if one is present.
  */
 void GraphicsOutput::
 set_size_and_recalc(int x, int y) {
@@ -1126,11 +1127,8 @@ set_size_and_recalc(int x, int y) {
   int fb_x_size = get_fb_x_size();
   int fb_y_size = get_fb_y_size();
 
-  TotalDisplayRegions::iterator dri;
-  for (dri = _total_display_regions.begin();
-       dri != _total_display_regions.end();
-       ++dri) {
-    (*dri)->compute_pixels_all_stages(fb_x_size, fb_y_size);
+  for (DisplayRegion *dr : _total_display_regions) {
+    dr->compute_pixels_all_stages(fb_x_size, fb_y_size);
   }
 
   if (_texture_card != nullptr && _texture_card->get_num_geoms() > 0) {