• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright © 2016 Red Hat.
3  * Copyright © 2016 Bas Nieuwenhuizen
4  * SPDX-License-Identifier: MIT
5  *
6  * based in part on anv driver which is:
7  * Copyright © 2015 Intel Corporation
8  */
9 
10 #ifndef TU_CLEAR_BLIT_H
11 #define TU_CLEAR_BLIT_H
12 
13 #include "tu_common.h"
14 
15 void tu_init_clear_blit_shaders(struct tu_device *dev);
16 
17 void tu_destroy_clear_blit_shaders(struct tu_device *dev);
18 
19 void
20 tu6_clear_lrz(struct tu_cmd_buffer *cmd, struct tu_cs *cs, struct tu_image* image, const VkClearValue *value);
21 
22 void
23 tu6_dirty_lrz_fc(struct tu_cmd_buffer *cmd, struct tu_cs *cs, struct tu_image* image);
24 
25 void
26 tu_resolve_sysmem(struct tu_cmd_buffer *cmd,
27                   struct tu_cs *cs,
28                   const struct tu_image_view *src,
29                   const struct tu_image_view *dst,
30                   uint32_t layer_mask,
31                   uint32_t layers,
32                   const VkRect2D *rect);
33 
34 void
35 tu_clear_sysmem_attachment(struct tu_cmd_buffer *cmd,
36                            struct tu_cs *cs,
37                            uint32_t a,
38                            const VkClearValue *value);
39 
40 void
41 tu_clear_gmem_attachment(struct tu_cmd_buffer *cmd,
42                          struct tu_cs *cs,
43                          uint32_t a,
44                          const VkClearValue *value);
45 
46 void
47 tu_load_gmem_attachment(struct tu_cmd_buffer *cmd,
48                         struct tu_cs *cs,
49                         uint32_t a,
50                         bool cond_exec_allowed,
51                         bool force_load);
52 
53 /* note: gmem store can also resolve */
54 void
55 tu_store_gmem_attachment(struct tu_cmd_buffer *cmd,
56                          struct tu_cs *cs,
57                          uint32_t a,
58                          uint32_t gmem_a,
59                          bool cond_exec_allowed);
60 
61 void
62 tu_choose_gmem_layout(struct tu_cmd_buffer *cmd);
63 
64 #endif /* TU_CLEAR_BLIT_H */
65