?? lcdpm332.lst
字號:
C51 COMPILER V8.05a LCDPM332 04/11/2008 14:18:22 PAGE 1
C51 COMPILER V8.05a, COMPILATION OF MODULE LCDPM332
OBJECT MODULE PLACED IN LCDPM332.obj
COMPILER INVOKED BY: D:\Program Files\keil\C51\BIN\C51.EXE gui\ConvertColor\LCDPM332.c LARGE BROWSE MDU_F120 DEBUG OBJEC
-TEXTEND PRINT(.\LCDPM332.lst) OBJECT(LCDPM332.obj)
line level source
1 /*
2 *********************************************************************************************************
3 * uC/GUI
4 * Universal graphic software for embedded applications
5 *
6 * (c) Copyright 2002, Micrium Inc., Weston, FL
7 * (c) Copyright 2002, SEGGER Microcontroller Systeme GmbH
8 *
9 * 礐/GUI is protected by international copyright laws. Knowledge of the
10 * source code may not be used to write a similar product. This file may
11 * only be used in accordance with a license and should not be redistributed
12 * in any way. We appreciate your understanding and fairness.
13 *
14 ----------------------------------------------------------------------
15 File : LCDPM332.C
16 Purpose : Color conversion routines for -332 mode
17 ---------------------------END-OF-HEADER------------------------------
18 */
19
20 #include <stddef.h> /* needed for definition of NULL */
21 #include "gui\Core\LCD_Protected.h" /* inter modul definitions */
22
23 /*********************************************************************
24 *
25 * LCD_FIXEDPALETTE == -332
26 *
27 * 256 colors RRRGGGBB
28 *
29 **********************************************************************
30 */
31
32 int LCD_Color2Index_M332(LCD_COLOR Color) {
33 1 int r, g, b;
34 1 r = Color & 255;
35 1 g = (Color >> 8 ) & 255;
36 1 b = Color >> 16;
37 1 r = (r * 7 + 127) / 255;
38 1 g = (g * 7 + 127) / 255;
39 1 b = (b + 42) / 85;
40 1 return b + (g << 2) + (r << 5);
41 1 }
42
43 LCD_COLOR LCD_Index2Color_M332(int Index) {
44 1 int r, g, b;
45 1 b = (Index & 3) * 85;
46 1 g = ((Index >> 2) & 7) * 255 / 7;
47 1 r = ((Index >> 5) & 7) * 255 / 7;
48 1 return r + (g << 8) + (((U32)b) << 16);
49 1 }
50
MODULE INFORMATION: STATIC OVERLAYABLE
CODE SIZE = 361 ----
C51 COMPILER V8.05a LCDPM332 04/11/2008 14:18:22 PAGE 2
CONSTANT SIZE = ---- ----
XDATA SIZE = ---- 14
PDATA SIZE = ---- ----
DATA SIZE = ---- ----
IDATA SIZE = ---- ----
BIT SIZE = ---- ----
END OF MODULE INFORMATION.
C51 COMPILATION COMPLETE. 0 WARNING(S), 0 ERROR(S)
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -