(float r, float g, float b, float a,
boolean depth, boolean stencil)
| 661 | |
| 662 | |
| 663 | protected void clearBackground(float r, float g, float b, float a, |
| 664 | boolean depth, boolean stencil) { |
| 665 | clearColor(r, g, b, a); |
| 666 | if (depth && stencil) { |
| 667 | clearDepth(1); |
| 668 | clearStencil(0); |
| 669 | clear(DEPTH_BUFFER_BIT | STENCIL_BUFFER_BIT | COLOR_BUFFER_BIT); |
| 670 | if (0 < sketch.frameCount) { |
| 671 | clearDepth = true; |
| 672 | clearStencil = true; |
| 673 | } |
| 674 | } else if (depth) { |
| 675 | clearDepth(1); |
| 676 | clear(DEPTH_BUFFER_BIT | COLOR_BUFFER_BIT); |
| 677 | if (0 < sketch.frameCount) { |
| 678 | clearDepth = true; |
| 679 | } |
| 680 | } else if (stencil) { |
| 681 | clearStencil(0); |
| 682 | clear(STENCIL_BUFFER_BIT | COLOR_BUFFER_BIT); |
| 683 | if (0 < sketch.frameCount) { |
| 684 | clearStencil = true; |
| 685 | } |
| 686 | } else { |
| 687 | clear(PGL.COLOR_BUFFER_BIT); |
| 688 | } |
| 689 | if (0 < sketch.frameCount) { |
| 690 | clearColor = true; |
| 691 | } |
| 692 | } |
| 693 | |
| 694 | |
| 695 | protected void beginRender() { |
no test coverage detected