• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #pragma once
2 
3 #include <vector>
4 
5 #include <GLES2/gl2.h>
6 
7 class ColorBuffer;
8 
9 // Posting
10 enum class PostCmd {
11     Post = 0,
12     Viewport = 1,
13     Compose = 2,
14     Clear = 3,
15     Screenshot = 4,
16     Exit = 5,
17 };
18 
19 struct Post {
20     PostCmd cmd;
21     int composeVersion;
22     std::vector<char> composeBuffer;
23     union {
24         ColorBuffer* cb;
25         struct {
26             int width;
27             int height;
28         } viewport;
29         struct {
30             ColorBuffer* cb;
31             int screenwidth;
32             int screenheight;
33             GLenum format;
34             GLenum type;
35             int rotation;
36             void* pixels;
37         } screenshot;
38     };
39 };
40 
41