Changeset ab936440 in mainline for kernel/genarch/src/fb/fb.c
- Timestamp:
- 2019-02-12T20:42:42Z (6 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- f31ca47
- Parents:
- 7f7817a9 (diff), 4805495 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - git-author:
- Matthieu Riolo <matthieu.riolo@…> (2019-02-12 20:26:18)
- git-committer:
- Matthieu Riolo <matthieu.riolo@…> (2019-02-12 20:42:42)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified kernel/genarch/src/fb/fb.c ¶
r7f7817a9 rab936440 76 76 (instance)->cols + (col)) 77 77 78 #define BB_NEXT_COL(pos) (++(pos)) 79 78 80 #define GLYPH_POS(instance, glyph, y) \ 79 81 ((glyph) * (instance)->glyphbytes + (y) * (instance)->glyphscanline) … … 270 272 unsigned int x; 271 273 unsigned int col; 274 size_t bb_pos = BB_POS(instance, 0, row); 275 size_t bb_pos1 = BB_POS(instance, 0, row + 1); 272 276 273 277 for (col = 0, x = 0; col < instance->cols; … … 276 280 277 281 if (row < instance->rows - 1) { 278 if (instance->backbuf[ BB_POS(instance, col, row)] ==279 instance->backbuf[ BB_POS(instance, col, row + 1)])280 continue;281 282 glyph = instance->backbuf[ BB_POS(instance, col, row + 1)];282 if (instance->backbuf[bb_pos] == 283 instance->backbuf[bb_pos1]) 284 goto skip; 285 286 glyph = instance->backbuf[bb_pos1]; 283 287 } else 284 288 glyph = 0; … … 287 291 &instance->glyphs[GLYPH_POS(instance, glyph, yd)], 288 292 instance->glyphscanline); 293 skip: 294 BB_NEXT_COL(bb_pos); 295 BB_NEXT_COL(bb_pos1); 289 296 } 290 297 } … … 373 380 unsigned int x; 374 381 unsigned int col; 382 size_t bb_pos = BB_POS(instance, 0, row); 375 383 376 384 for (col = 0, x = 0; col < instance->cols; 377 385 col++, x += FONT_WIDTH) { 378 386 uint16_t glyph = 379 instance->backbuf[ BB_POS(instance, col, row)];387 instance->backbuf[bb_pos]; 380 388 void *dst = &instance->addr[FB_POS(instance, x, y + yd)]; 381 389 void *src = &instance->glyphs[GLYPH_POS(instance, glyph, yd)]; 382 390 memcpy(dst, src, instance->glyphscanline); 391 BB_NEXT_COL(bb_pos); 383 392 } 384 393 }
Note:
See TracChangeset
for help on using the changeset viewer.