Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8252758

Lanai: Optimize index calculation while copying glyphs

XMLWordPrintable

    • 2d
    • b22
    • generic
    • os_x

      At many places where we are using replaceRegion to copy glyph into MTLTexture we have used literals for index update.

      Update them to use loop increment like :
      for (int i = 0; i < (w * h); i++) {
                          imageData[dstIndex++] = 0xFF;
                          imageData[dstIndex++] = glyph->image[srcIndex++];
                          imageData[dstIndex++] = glyph->image[srcIndex++];
                          imageData[dstIndex++] = glyph->image[srcIndex++];
      }

            jdv Jayathirth D V
            jdv Jayathirth D V
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: