yum-mirror/VkFFT
git clone https://git.yummers.dev/yum-mirror/VkFFT
ba7001c
master
1//------------------------------------------------------------------------------------------------------------------------------------------------------------- 2// 3// Metal/MTLCommandEncoder.hpp 4// 5// Copyright 2020-2021 Apple Inc. 6// 7// Licensed under the Apache License, Version 2.0 (the "License"); 8// you may not use this file except in compliance with the License. 9// You may obtain a copy of the License at 10// 11// http://www.apache.org/licenses/LICENSE-2.0 12// 13// Unless required by applicable law or agreed to in writing, software 14// distributed under the License is distributed on an "AS IS" BASIS, 15// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 16// See the License for the specific language governing permissions and 17// limitations under the License. 18// 19//------------------------------------------------------------------------------------------------------------------------------------------------------------- 20 21#pragma once 22 23#include "MTLDefines.hpp" 24#include "MTLHeaderBridge.hpp" 25#include "MTLPrivate.hpp" 26 27#include <Foundation/Foundation.hpp> 28 29namespace MTL 30{ 31_MTL_OPTIONS (NS ::UInteger ,ResourceUsage ) { 32ResourceUsageRead = 1 , 33ResourceUsageWrite = 2 , 34ResourceUsageSample = 4 , 35}; 36 37_MTL_OPTIONS (NS ::UInteger ,BarrierScope ) { 38BarrierScopeBuffers = 1 , 39BarrierScopeTextures = 2 , 40BarrierScopeRenderTargets = 4 , 41}; 42 43class CommandEncoder :public NS ::Referencing < CommandEncoder > 44{ 45public : 46class Device * device ()const ; 47 48NS ::String * label ()const ; 49void setLabel (const NS ::String * label ); 50 51void endEncoding (); 52 53void insertDebugSignpost (const NS ::String * string ); 54 55void pushDebugGroup (const NS ::String * string ); 56 57void popDebugGroup (); 58}; 59 60} 61 62// property: device 63_MTL_INLINE MTL ::Device * MTL ::CommandEncoder ::device ()const 64{ 65return Object ::sendMessage < MTL ::Device *> (this ,_MTL_PRIVATE_SEL (device )); 66} 67 68// property: label 69_MTL_INLINE NS ::String * MTL ::CommandEncoder ::label ()const 70{ 71return Object ::sendMessage < NS ::String *> (this ,_MTL_PRIVATE_SEL (label )); 72} 73 74_MTL_INLINE voidMTL ::CommandEncoder ::setLabel (const NS ::String * label ) 75{ 76Object ::sendMessage < void > (this ,_MTL_PRIVATE_SEL (setLabel_ ),label ); 77} 78 79// method: endEncoding 80_MTL_INLINE voidMTL ::CommandEncoder ::endEncoding () 81{ 82Object ::sendMessage < void > (this ,_MTL_PRIVATE_SEL (endEncoding )); 83} 84 85// method: insertDebugSignpost: 86_MTL_INLINE voidMTL ::CommandEncoder ::insertDebugSignpost (const NS ::String * string ) 87{ 88Object ::sendMessage < void > (this ,_MTL_PRIVATE_SEL (insertDebugSignpost_ ),string ); 89} 90 91// method: pushDebugGroup: 92_MTL_INLINE voidMTL ::CommandEncoder ::pushDebugGroup (const NS ::String * string ) 93{ 94Object ::sendMessage < void > (this ,_MTL_PRIVATE_SEL (pushDebugGroup_ ),string ); 95} 96 97// method: popDebugGroup 98_MTL_INLINE voidMTL ::CommandEncoder ::popDebugGroup () 99{ 100Object ::sendMessage < void > (this ,_MTL_PRIVATE_SEL (popDebugGroup )); 101}