... | @@ -93,7 +93,7 @@ Note that, all external methods for CommLCD engine should return zero for succes |
... | @@ -93,7 +93,7 @@ Note that, all external methods for CommLCD engine should return zero for succes |
|
mode according to your settings in the MiniGUI runtime configuration, e.g.,
|
|
mode according to your settings in the MiniGUI runtime configuration, e.g.,
|
|
`defaultmode=240x320-32bpp`.
|
|
`defaultmode=240x320-32bpp`.
|
|
|
|
|
|
In our sample, it creates the anonymous memory map by calling `mmap` system
|
|
In our sample, it creates an anonymous memory map by calling `mmap` system
|
|
call and returns the video information via `struct commlcd_info* li`:
|
|
call and returns the video information via `struct commlcd_info* li`:
|
|
|
|
|
|
int __commlcd_drv_getinfo (struct commlcd_info *li, int width, int height, int depth)
|
|
int __commlcd_drv_getinfo (struct commlcd_info *li, int width, int height, int depth)
|
... | @@ -114,7 +114,7 @@ call and returns the video information via `struct commlcd_info* li`: |
... | @@ -114,7 +114,7 @@ call and returns the video information via `struct commlcd_info* li`: |
|
return 0;
|
|
return 0;
|
|
}
|
|
}
|
|
|
|
|
|
You need fill the all fields of `struct commlcd_info* li` with the correct
|
|
You need to fill the all fields of `struct commlcd_info* li` with the correct
|
|
values:
|
|
values:
|
|
|
|
|
|
* `type`: The video mode type. Currently, CommLCD supports the following modes:
|
|
* `type`: The video mode type. Currently, CommLCD supports the following modes:
|
... | @@ -140,7 +140,7 @@ values: |
... | @@ -140,7 +140,7 @@ values: |
|
|
|
|
|
#### Setting palette
|
|
#### Setting palette
|
|
|
|
|
|
If the color depth of the video mode is less than 15 (`COMMLCD_PSEUDO_RGB332`),
|
|
If the color depth of the video mode is 8 (`COMMLCD_PSEUDO_RGB332`),
|
|
`__commlcd_drv_setclut` function will be called to set the palette.
|
|
`__commlcd_drv_setclut` function will be called to set the palette.
|
|
|
|
|
|
In our sample, this method does nothing and returns zero:
|
|
In our sample, this method does nothing and returns zero:
|
... | @@ -285,3 +285,4 @@ In our sample, it destroys the anonymous memory map and returns zero: |
... | @@ -285,3 +285,4 @@ In our sample, it destroys the anonymous memory map and returns zero: |
|
## References
|
|
## References
|
|
|
|
|
|
* [GAL and IAL Engines](http://wiki.minigui.com/twiki/bin/view/Products/MiniGUIPGV32Part5Chapter03)
|
|
* [GAL and IAL Engines](http://wiki.minigui.com/twiki/bin/view/Products/MiniGUIPGV32Part5Chapter03)
|
|
|
|
|