[libbluray-devel] BDGraphics: optimized fillRect()
Ian Curtis
git at videolan.org
Wed Mar 19 15:55:07 CET 2014
libbluray | branch: master | Ian Curtis <i.curtis at gmail.com> | Wed Mar 19 16:20:38 2014 +0200| [904a5e5b8fc9b5bfc5f9f0db0f1936de85fd2a54] | committer: hpi1
BDGraphics: optimized fillRect()
> http://git.videolan.org/gitweb.cgi/libbluray.git/?a=commit;h=904a5e5b8fc9b5bfc5f9f0db0f1936de85fd2a54
---
src/libbluray/bdj/java-j2me/java/awt/BDGraphics.java | 3 +--
src/libbluray/bdj/java-j2se/java/awt/BDGraphics.java | 3 +--
2 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/src/libbluray/bdj/java-j2me/java/awt/BDGraphics.java b/src/libbluray/bdj/java-j2me/java/awt/BDGraphics.java
index a3e47a0..7b50208 100644
--- a/src/libbluray/bdj/java-j2me/java/awt/BDGraphics.java
+++ b/src/libbluray/bdj/java-j2me/java/awt/BDGraphics.java
@@ -437,8 +437,7 @@ class BDGraphics extends Graphics2D implements ConstrainableGraphics {
h = rect.height;
int rgb = foreground.getRGB();
for (int Y = y; Y < (y + h); Y++)
- for (int X = x; X < (x + w); X++)
- drawPointN(X, Y, rgb);
+ drawSpanN(x, Y, w, rgb);
}
public void drawRect(int x, int y, int w, int h) {
diff --git a/src/libbluray/bdj/java-j2se/java/awt/BDGraphics.java b/src/libbluray/bdj/java-j2se/java/awt/BDGraphics.java
index 1d7d747..f5931bf 100644
--- a/src/libbluray/bdj/java-j2se/java/awt/BDGraphics.java
+++ b/src/libbluray/bdj/java-j2se/java/awt/BDGraphics.java
@@ -519,8 +519,7 @@ class BDGraphics extends Graphics2D implements ConstrainableGraphics {
h = rect.height;
int rgb = foreground.getRGB();
for (int Y = y; Y < (y + h); Y++)
- for (int X = x; X < (x + w); X++)
- drawPointN(X, Y, rgb);
+ drawSpanN(x, Y, w, rgb);
}
public void drawRect(int x, int y, int w, int h) {
More information about the libbluray-devel
mailing list