SHARE
TWEET

Untitled

a guest Oct 8th, 2015 82 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. fooBuffer.begin();
  2. Gdx.gl.glClearColor(1, 0, 1, 1);
  3. Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT | GL20.GL_DEPTH_BUFFER_BIT);
  4.  
  5. barBatch.begin(camera);
  6. barBatch.render(instances.get(3));
  7. barBatch.end();
  8. // screenshot code here results in the expected alpha of the model
  9. fooBuffer.end();
  10.  
  11. Texture texture = fooBuffer.getColorBufferTexture();
  12.  
  13. edgeBuffer.begin();
  14. Gdx.gl.glClearColor(0, 1, 1, 1);
  15. Gdx.gl.glClear(GL20.GL_COLOR_BUFFER_BIT | GL20.GL_DEPTH_BUFFER_BIT);
  16. edgeBatch.begin();
  17. edgeBatch.draw(texture, 0, 0, 200, 200);
  18. edgeBatch.end();
  19. // screenshot code here results in a black screen
  20. edgeBuffer.end();
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top