OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [tags/] [nog_patch_71/] [or1ksim/] [peripheral/] [fb.c] - Diff between revs 859 and 867

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 859 Rev 867
Line 225... Line 225...
  /* Data is stored upside down */
  /* Data is stored upside down */
  for (y = sy - 1; y >= 0; y--) {
  for (y = sy - 1; y >= 0; y--) {
    unsigned char line[FB_SIZEX][3];
    unsigned char line[FB_SIZEX][3];
    for (x = 0; x < sx; x++)
    for (x = 0; x < sx; x++)
      if (y >= cameray && x >= camerax && y < cameray + CAM_SIZEY && x < camerax + CAM_SIZEX) {
      if (y >= cameray && x >= camerax && y < cameray + CAM_SIZEY && x < camerax + CAM_SIZEX) {
        int add = cam_addr + (x - camerax + (y - cameray) * CAM_SIZEX) * 2;
        int add = (cam_addr + (x - camerax + (y - cameray) * CAM_SIZEX) * 2) ^ 2;
        unsigned short d = evalsim_mem16 (add);
        unsigned short d = evalsim_mem16 (add);
        line[x][0] = ((d >> 0) & 0x1f) << 3;  /* Blue */
        line[x][0] = ((d >> 0) & 0x1f) << 3;  /* Blue */
        line[x][1] = ((d >> 5) & 0x3f) << 2;  /* Green */
        line[x][1] = ((d >> 5) & 0x3f) << 2;  /* Green */
        line[x][2] = ((d >> 11) & 0x1f) << 3; /* Red */
        line[x][2] = ((d >> 11) & 0x1f) << 3; /* Red */
      } else {
      } else {

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.