Commit 43f749f241748675dc3e7b5280c88fba04dfc7ef
- Diff rendering mode:
- inline
- side by side
examples/lbm_presenter.py
(3 / 2)
|   | |||
| 47 | 47 | self._vscale = 0.005 | |
| 48 | 48 | self._vismode = 4 | |
| 49 | 49 | ||
| 50 | def _draw_field(self, field, srf, b, vismode, width, height): | ||
| 50 | def _draw_field(self, field, srf, b, unused_map, vismode, width, height): | ||
| 51 | 51 | # Rotate the field to the correct position. | |
| 52 | 52 | field = numpy.rot90(field.astype(numpy.float32), 3) | |
| 53 | 53 | a = pygame.surfarray.pixels3d(srf) | |
| … | … | ||
| 119 | 119 | ||
| 120 | 120 | def _init_vis_2d(self): | |
| 121 | 121 | self.vis = Fluid2DVisPresentation(self, self.options.scr_w, self.options.scr_h, | |
| 122 | self.options.scr_depth, self.options.lat_nx, self.options.lat_ny) | ||
| 122 | self.options.scr_depth, self.options.lat_nx, self.options.lat_ny, | ||
| 123 | self.options.scr_scale) | ||
| 123 | 124 | ||
| 124 | 125 | if __name__ == '__main__': | |
| 125 | 126 | sim = LPresSim(LBMGeoPoiseuille) |

