Mercurial > hg > Members > e085722 > Cerium
comparison Renderer/Engine/ps3fb/cp_fb.h @ 0:04e28d8d3c6f
first commit
author | Daiki KINJYO <e085722@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 08 Nov 2010 01:23:25 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:04e28d8d3c6f |
---|---|
1 // cp_fb.h | |
2 // | |
3 // Copyright (c) 2006, Mike Acton <macton@cellperformance.com> | |
4 // | |
5 // Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated | |
6 // documentation files (the "Software"), to deal in the Software without restriction, including without | |
7 // limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of | |
8 // the Software, and to permit persons to whom the Software is furnished to do so, subject to the following | |
9 // conditions: | |
10 // | |
11 // The above copyright notice and this permission notice shall be included in all copies or substantial | |
12 // portions of the Software. | |
13 // | |
14 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT | |
15 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO | |
16 // EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN | |
17 // AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE | |
18 // OR OTHER DEALINGS IN THE SOFTWARE. | |
19 | |
20 #ifndef CP_FB_H | |
21 #define CP_FB_H | |
22 | |
23 #if defined(__cplusplus) | |
24 extern "C" | |
25 { | |
26 #endif | |
27 | |
28 typedef struct cp_fb cp_fb; | |
29 | |
30 struct cp_fb | |
31 { | |
32 uint32_t w; | |
33 uint32_t h; | |
34 uint32_t stride; | |
35 uintptr_t start_addr; | |
36 uintptr_t draw_addr[2]; | |
37 uint32_t size; | |
38 int fd; | |
39 }; | |
40 | |
41 int cp_fb_open( cp_fb* const restrict fb ); | |
42 void cp_fb_close( const cp_fb* const restrict fb ); | |
43 void cp_fb_wait_vsync( cp_fb* const restrict fb ); | |
44 void cp_fb_flip( cp_fb* const restrict fb, unsigned long field_ndx ); | |
45 | |
46 #if defined(__cplusplus) | |
47 } | |
48 #endif | |
49 | |
50 #endif /* CP_FB_H */ | |
51 |