summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKushal K S V S <kkushal32@gmail.com>2017-06-15 15:06:44 +0530
committerKushal K S V S <kkushal32@gmail.com>2017-07-09 13:20:12 +0530
commit87370ddb29373aa973619c7c277ea367ad10f520 (patch)
tree4b83edb1a17f2011b207f38290fd1a7907dcda7f
parentf1238be190d0bf2e08680de26423667cd23861ab (diff)
downloadfreetype2-87370ddb29373aa973619c7c277ea367ad10f520.tar.gz
Modified LCD_V rendering
-rw-r--r--tests/make_bitmap/bitmap.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/tests/make_bitmap/bitmap.c b/tests/make_bitmap/bitmap.c
index fc5940935..4217c3c16 100644
--- a/tests/make_bitmap/bitmap.c
+++ b/tests/make_bitmap/bitmap.c
@@ -160,13 +160,13 @@ void Write_Bitmap_Data_LCD_V_BGR (FT_Bitmap * bitmap) {
int i,j,k,step;
char value;
- step = bitmap->rows - 1;
+ step = 0;
- while ( step > 0 ){
+ while ( step < bitmap->rows ){
for (i = 0; i < bitmap->width; i++)
{
- for (j = step - 2; j <= step; ++j)
+ for (j = step ; j < step + 3; ++j)
{
value = 0xff - bitmap->buffer[(j * bitmap->pitch) + i];
fwrite (&value, 1, 1,fp);
@@ -177,7 +177,7 @@ void Write_Bitmap_Data_LCD_V_BGR (FT_Bitmap * bitmap) {
value = 0xff;
fwrite (&value, 1, 1,fp);
}
- step = step - 3;
+ step = step + 3; // Jumping 3 rows up
}
fclose(fp);
@@ -189,13 +189,13 @@ void Write_Bitmap_Data_LCD_V_RGB (FT_Bitmap * bitmap) {
int i,j,k,step;
char value;
- step = bitmap->rows - 1;
+ step = 0;
- while ( step > 0 ){
+ while ( step < bitmap->rows ){
for (i = 0; i < bitmap->width; i++)
{
- for (j = step; j > step - 3; --j)
+ for (j = step + 2 ; j >= step; --j)
{
value = 0xff - bitmap->buffer[(j * bitmap->pitch) + i];
fwrite (&value, 1, 1,fp);
@@ -206,7 +206,7 @@ void Write_Bitmap_Data_LCD_V_RGB (FT_Bitmap * bitmap) {
value = 0xff;
fwrite (&value, 1, 1,fp);
}
- step = step - 3;
+ step = step + 3; // Jumping 3 rows up
}
fclose(fp);