DoxigAlpha

location

Forms the main linkage for input and output address spaces. ptr must be a reference to variable or struct field.

Function parameters

Parameters

#
ptr:anytype
loc:u32

Type definitions in this namespace

Types

#

Forms the main linkage for `input` and `output` address spaces.

Functions

#
location
Forms the main linkage for `input` and `output` address spaces.
binding
Forms the main linkage for `input` and `output` address spaces.
executionMode
Declare the mode entry point executes in.

= @extern(*addrspace(.input) @Vector(4, f32), .{ .name = "position" })

Values

#
position_in
= @extern(*addrspace(.input) @Vector(4, f32), .{ .name = "position" })
position_out
= @extern(*addrspace(.output) @Vector(4, f32), .{ .name = "position" })
point_size_in
= @extern(*addrspace(.input) f32, .{ .name = "point_size" })
point_size_out
= @extern(*addrspace(.output) f32, .{ .name = "point_size" })

Source

Implementation

#
pub fn location(comptime ptr: anytype, comptime loc: u32) void {
    asm volatile (
        \\OpDecorate %ptr Location $loc
        :
        : [ptr] "" (ptr),
          [loc] "c" (loc),
    );
}