Rev 3807 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 3807 | Rev 3847 | ||
---|---|---|---|
Line 30... | Line 30... | ||
30 | #include "pipe/p_screen.h" |
30 | #include "pipe/p_screen.h" |
31 | #include "state_tracker/graw.h" |
31 | #include "state_tracker/graw.h" |
32 | #include "target-helpers/inline_debug_helper.h" |
32 | #include "target-helpers/inline_debug_helper.h" |
33 | #include "target-helpers/inline_sw_helper.h" |
33 | #include "target-helpers/inline_sw_helper.h" |
34 | #include |
34 | #include |
35 | //#include |
- | |
36 | - | ||
37 | /* |
- | |
38 | static LRESULT CALLBACK |
- | |
39 | window_proc(HWND hWnd, |
- | |
40 | UINT uMsg, |
- | |
41 | WPARAM wParam, |
- | |
42 | LPARAM lParam) |
- | |
43 | { |
- | |
44 | switch (uMsg) { |
- | |
45 | case WM_DESTROY: |
- | |
46 | PostQuitMessage(0); |
- | |
47 | break; |
- | |
48 | - | ||
49 | default: |
- | |
50 | return DefWindowProc(hWnd, uMsg, wParam, lParam); |
- | |
51 | } |
- | |
52 | - | ||
53 | return 0; |
- | |
54 | } |
- | |
55 | */ |
- | |
Line 56... | Line 35... | ||
56 | 35 | ||
57 | static struct { |
36 | static struct { |
58 | void (* draw)(void); |
37 | void (* draw)(void); |
Line 66... | Line 45... | ||
66 | enum pipe_format format, |
45 | enum pipe_format format, |
67 | void **handle) |
46 | void **handle) |
68 | { |
47 | { |
69 | struct sw_winsys *winsys = NULL; |
48 | struct sw_winsys *winsys = NULL; |
70 | struct pipe_screen *screen = NULL; |
49 | struct pipe_screen *screen = NULL; |
- | 50 | struct pipe_loader_device *dev; |
|
- | 51 | int ret; |
|
Line 71... | Line 52... | ||
71 | 52 | ||
72 | if (format != PIPE_FORMAT_B8G8R8X8_UNORM) |
53 | if (format != PIPE_FORMAT_B8G8R8X8_UNORM) |
Line 73... | Line 54... | ||
73 | goto fail; |
54 | goto fail; |
74 | 55 | ||
75 | winsys = kos_create_sw_winsys(); |
56 | winsys = kos_create_sw_winsys(); |
Line -... | Line 57... | ||
- | 57 | if (winsys == NULL) |
|
- | 58 | goto fail; |
|
- | 59 | ||
- | 60 | /* find a hardware device */ |
|
76 | if (winsys == NULL) |
61 | ret = pipe_loader_probe(&dev, 1); |
Line 77... | Line 62... | ||
77 | goto fail; |
62 | |
78 | 63 | /* init a pipe screen */ |
|
Line 79... | Line 64... | ||
79 | screen = sw_screen_create(winsys); |
64 | screen = pipe_loader_create_screen(dev, "drivers"); |