sbylib ~master (2020-02-29T08:12:18Z)
Dub
Repo
TestCompute
sbylib
graphics
compute
testcompute
Undocumented in source.
class
TestCompute :
Compute
{
mixin
ShaderSource
!(
ShaderStage
.
Compute
,
q{
#version
450
layout
(
local_size_x
=
16
,
local_size_y
=
1
,
local_size_z
=
1
)
in
;
layout
(
std140
)
struct
Data
{
vec3
a
;
vec3
b
;
float
c
; };
layout
(
binding
=
0
)
readonly
buffer
Input
{
int
len
;
Data
data
[]; }
inputData
;
layout
(
binding
=
1
)
writeonly
buffer
Output
{
int
len
;
Data
data
[]; }
outputData
;
void
main
() {
outputData
.
data
[
gl_GlobalInvocationID
.
x
] =
inputData
.
data
[
gl_GlobalInvocationID
.
x
]; }
}
)
;
struct
Data
;
struct
Input
;
struct
Output
;
@
storage
@
stage
(
ShaderStage
.
Compute
)
@
binding
(0)
Input
input
;
@
storage
@
stage
(
ShaderStage
.
Compute
)
@
binding
(1)
Output
output
;
mixin
MaxObjects
!(
1
)
;
mixin
Instance
;
}
Members
Mixins
__anonymous
mixin
ShaderSource
!(
ShaderStage
.
Compute
,
q{
#version
450
layout
(
local_size_x
=
16
,
local_size_y
=
1
,
local_size_z
=
1
)
in
;
layout
(
std140
)
struct
Data
{
vec3
a
;
vec3
b
;
float
c
; };
layout
(
binding
=
0
)
readonly
buffer
Input
{
int
len
;
Data
data
[]; }
inputData
;
layout
(
binding
=
1
)
writeonly
buffer
Output
{
int
len
;
Data
data
[]; }
outputData
;
void
main
() {
outputData
.
data
[
gl_GlobalInvocationID
.
x
] =
inputData
.
data
[
gl_GlobalInvocationID
.
x
]; }
}
)
Undocumented in source.
__anonymous
mixin
Instance
Undocumented in source.
__anonymous
mixin
MaxObjects
!(
1
)
Undocumented in source.
Structs
Data
struct
Data
Undocumented in source.
Input
struct
Input
Undocumented in source.
Output
struct
Output
Undocumented in source.
Variables
input
Input
input
;
Undocumented in source.
output
Output
output
;
Undocumented in source.
Inherited Members
From Compute
__anonymous
mixin
Descriptor
Undocumented in source.
pipelineLayout
PipelineLayout
pipelineLayout
;
Undocumented in source.
pipeline
Pipeline
pipeline
;
Undocumented in source.
__anonymous
mixin
ImplReleaseOwn
Undocumented in source.
Instance
mixintemplate
Instance
()
Undocumented in source.
Meta
Source
See Implementation
sbylib
graphics
compute
testcompute
classes
TestCompute