Advertisement
Guest User

Untitled

a guest
May 25th, 2016
140
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.74 KB | None | 0 0
  1. while (true) {
  2.  
  3. start = System.nanoTime();
  4.  
  5. // g2dScrollArea.setColor(scrollAreaBackgroundColor);
  6. // g2dScrollArea.fillRect(0, 0, bufferedImage.getWidth(), bufferedImage.getHeight());
  7. // g2dScrollArea.setColor(scrollAreaBorderColor);
  8. // g2dScrollArea.drawLine(bufferedImage.getWidth() - 1, 0, bufferedImage.getWidth() - 1, bufferedImage.getHeight());
  9. //
  10. // for (int i = 0; i < byteBuffer.capacity(); i += Vec4ub.SIZE) {
  11. // byteBuffer
  12. // .put(i + 0, (byte) 200)
  13. // .put(i + 1, (byte) 200)
  14. // .put(i + 2, (byte) 200)
  15. // .put(i + 3, (byte) 10);
  16. // }
  17. ////
  18. // for (int i = 0; i < 768; i++) {
  19. // byteBuffer
  20. // .put(i * 1024 + 0, (byte) 100)
  21. // .put(i * 1024 + 1, (byte) 100)
  22. // .put(i * 1024 + 2, (byte) 100)
  23. // .put(i * 1024 + 3, (byte) 100);
  24. // }
  25. for (int i = 0; i < bytes.length; i += Vec4ub.SIZE) {
  26. bytes[i + 0]= (byte) 200;
  27. bytes[i + 1]= (byte) 200;
  28. bytes[i + 2]= (byte) 200;
  29. bytes[i + 3]= (byte) 10;
  30. }
  31. //
  32. for (int i = 0; i < 768; i++) {
  33. bytes[i*1024 + 0]= (byte) 100;
  34. bytes[i*1024 + 1]= (byte) 100;
  35. bytes[i*1024 + 2]= (byte) 100;
  36. bytes[i*1024 + 3]= (byte) 100;
  37. }
  38.  
  39. total = System.nanoTime() - start;
  40.  
  41. System.out.println(total + " ns");
  42. // System.out.println(EC_UnitFormatter.nanoToString(total));
  43. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement