You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

167 lines
7.6 KiB

5 years ago
  1. /* --COPYRIGHT--,BSD
  2. * Copyright (c) 2013, Texas Instruments Incorporated
  3. * All rights reserved.
  4. *
  5. * Redistribution and use in source and binary forms, with or without
  6. * modification, are permitted provided that the following conditions
  7. * are met:
  8. *
  9. * * Redistributions of source code must retain the above copyright
  10. * notice, this list of conditions and the following disclaimer.
  11. *
  12. * * Redistributions in binary form must reproduce the above copyright
  13. * notice, this list of conditions and the following disclaimer in the
  14. * documentation and/or other materials provided with the distribution.
  15. *
  16. * * Neither the name of Texas Instruments Incorporated nor the names of
  17. * its contributors may be used to endorse or promote products derived
  18. * from this software without specific prior written permission.
  19. *
  20. * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  21. * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
  22. * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  23. * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
  24. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  25. * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  26. * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
  27. * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
  28. * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
  29. * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
  30. * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  31. * --/COPYRIGHT--*/
  32. #include "grlib.h"
  33. //*****************************************************************************
  34. //
  35. // Details of this font:
  36. // Style: fixed
  37. // Size: 8 point
  38. // Bold: no
  39. // Italic: no
  40. // Memory usage: 960 bytes
  41. //
  42. //*****************************************************************************
  43. //*****************************************************************************
  44. //
  45. // The uncompressed data for the fixed-point 6x8 font.
  46. //
  47. //*****************************************************************************
  48. static const unsigned char g_pucFontFixed6x8Data[760] =
  49. {
  50. 8, 6, 0, 0, 0, 0, 0, 0, 8, 6, 32, 130,
  51. 8, 0, 2, 0, 8, 6, 81, 69, 0, 0, 0, 0,
  52. 8, 6, 81, 79, 148, 249, 69, 0, 8, 6, 33, 234,
  53. 28, 43, 194, 0, 8, 6, 195, 33, 8, 66, 97, 128,
  54. 8, 6, 98, 74, 16, 170, 70, 128, 8, 6, 96, 132,
  55. 0, 0, 0, 0, 8, 6, 16, 132, 16, 64, 129, 0,
  56. 8, 6, 64, 129, 4, 16, 132, 0, 8, 6, 0, 138,
  57. 156, 168, 128, 0, 8, 6, 0, 130, 62, 32, 128, 0,
  58. 8, 6, 0, 0, 0, 96, 132, 0, 8, 6, 0, 0,
  59. 62, 0, 0, 0, 8, 6, 0, 0, 0, 1, 134, 0,
  60. 8, 6, 0, 33, 8, 66, 0, 0, 8, 6, 114, 41,
  61. 170, 202, 39, 0, 8, 6, 33, 130, 8, 32, 135, 0,
  62. 8, 6, 114, 32, 132, 33, 15, 128, 8, 6, 248, 66,
  63. 4, 10, 39, 0, 8, 6, 16, 197, 36, 248, 65, 0,
  64. 8, 6, 250, 15, 2, 10, 39, 0, 8, 6, 49, 8,
  65. 60, 138, 39, 0, 8, 6, 248, 33, 8, 65, 4, 0,
  66. 8, 6, 114, 40, 156, 138, 39, 0, 8, 6, 114, 40,
  67. 158, 8, 70, 0, 8, 6, 1, 134, 0, 97, 128, 0,
  68. 8, 6, 1, 134, 0, 96, 132, 0, 8, 6, 16, 132,
  69. 32, 64, 129, 0, 8, 6, 0, 15, 128, 248, 0, 0,
  70. 8, 6, 64, 129, 2, 16, 132, 0, 8, 6, 114, 32,
  71. 132, 32, 2, 0, 8, 6, 114, 32, 154, 170, 167, 0,
  72. 8, 6, 114, 40, 162, 250, 40, 128, 8, 6, 242, 40,
  73. 188, 138, 47, 0, 8, 6, 114, 40, 32, 130, 39, 0,
  74. 8, 6, 226, 72, 162, 138, 78, 0, 8, 6, 250, 8,
  75. 60, 130, 15, 128, 8, 6, 250, 8, 60, 130, 8, 0,
  76. 8, 6, 114, 40, 46, 138, 39, 128, 8, 6, 138, 40,
  77. 190, 138, 40, 128, 8, 6, 112, 130, 8, 32, 135, 0,
  78. 8, 6, 56, 65, 4, 18, 70, 0, 8, 6, 138, 74,
  79. 48, 162, 72, 128, 8, 6, 130, 8, 32, 130, 15, 128,
  80. 8, 6, 139, 106, 170, 138, 40, 128, 8, 6, 138, 44,
  81. 170, 154, 40, 128, 8, 6, 114, 40, 162, 138, 39, 0,
  82. 8, 6, 242, 40, 188, 130, 8, 0, 8, 6, 114, 40,
  83. 162, 170, 70, 128, 8, 6, 242, 40, 188, 162, 72, 128,
  84. 8, 6, 122, 8, 28, 8, 47, 0, 8, 6, 248, 130,
  85. 8, 32, 130, 0, 8, 6, 138, 40, 162, 138, 39, 0,
  86. 8, 6, 138, 40, 162, 137, 66, 0, 8, 6, 138, 40,
  87. 170, 170, 165, 0, 8, 6, 138, 37, 8, 82, 40, 128,
  88. 8, 6, 138, 40, 148, 32, 130, 0, 8, 6, 248, 33,
  89. 8, 66, 15, 128, 8, 6, 113, 4, 16, 65, 7, 0,
  90. 8, 6, 2, 4, 8, 16, 32, 0, 8, 6, 112, 65,
  91. 4, 16, 71, 0, 8, 6, 33, 72, 128, 0, 0, 0,
  92. 8, 6, 0, 0, 0, 0, 15, 128, 8, 6, 64, 129,
  93. 0, 0, 0, 0, 8, 6, 0, 7, 2, 122, 39, 128,
  94. 8, 6, 130, 11, 50, 138, 47, 0, 8, 6, 0, 7,
  95. 32, 130, 39, 0, 8, 6, 8, 38, 166, 138, 39, 128,
  96. 8, 6, 0, 7, 34, 250, 7, 0, 8, 6, 49, 36,
  97. 56, 65, 4, 0, 8, 6, 1, 232, 162, 120, 39, 0,
  98. 8, 6, 130, 11, 50, 138, 40, 128, 8, 6, 32, 6,
  99. 8, 32, 135, 0, 8, 6, 16, 3, 4, 18, 70, 0,
  100. 8, 6, 130, 9, 40, 194, 137, 0, 8, 6, 96, 130,
  101. 8, 32, 135, 0, 8, 6, 0, 13, 42, 170, 40, 128,
  102. 8, 6, 0, 11, 50, 138, 40, 128, 8, 6, 0, 7,
  103. 34, 138, 39, 0, 8, 6, 0, 15, 34, 242, 8, 0,
  104. 8, 6, 0, 6, 166, 120, 32, 128, 8, 6, 0, 11,
  105. 50, 130, 8, 0, 8, 6, 0, 7, 32, 112, 47, 0,
  106. 8, 6, 65, 14, 16, 65, 35, 0, 8, 6, 0, 8,
  107. 162, 138, 102, 128, 8, 6, 0, 8, 162, 137, 66, 0,
  108. 8, 6, 0, 8, 162, 170, 165, 0, 8, 6, 0, 8,
  109. 148, 33, 72, 128, 8, 6, 0, 8, 162, 120, 39, 0,
  110. 8, 6, 0, 15, 132, 33, 15, 128, 8, 6, 16, 130,
  111. 16, 32, 129, 0, 8, 6, 32, 130, 8, 32, 130, 0,
  112. 8, 6, 64, 130, 4, 32, 132, 0, 8, 6, 66, 161,
  113. 0, 0, 0, 0,
  114. };
  115. //*****************************************************************************
  116. //
  117. // The font definition for the fixed-point 6x8 font.
  118. //
  119. //*****************************************************************************
  120. const tFont g_sFontFixed6x8 =
  121. {
  122. //
  123. // The format of the font.
  124. //
  125. FONT_FMT_UNCOMPRESSED,
  126. //
  127. // The maximum width of the font.
  128. //
  129. 6,
  130. //
  131. // The height of the font.
  132. //
  133. 8,
  134. //
  135. // The baseline of the font.
  136. //
  137. 7,
  138. //
  139. // The offset to each character in the font.
  140. //
  141. {
  142. 0, 8, 16, 24, 32, 40, 48, 56,
  143. 64, 72, 80, 88, 96, 104, 112, 120,
  144. 128, 136, 144, 152, 160, 168, 176, 184,
  145. 192, 200, 208, 216, 224, 232, 240, 248,
  146. 256, 264, 272, 280, 288, 296, 304, 312,
  147. 320, 328, 336, 344, 352, 360, 368, 376,
  148. 384, 392, 400, 408, 416, 424, 432, 440,
  149. 448, 456, 464, 472, 480, 488, 496, 504,
  150. 512, 520, 528, 536, 544, 552, 560, 568,
  151. 576, 584, 592, 600, 608, 616, 624, 632,
  152. 640, 648, 656, 664, 672, 680, 688, 696,
  153. 704, 712, 720, 728, 736, 744, 752,
  154. },
  155. //
  156. // A pointer to the actual font data
  157. //
  158. g_pucFontFixed6x8Data
  159. };