yum-mirror/VkFFT
git clone https://git.yummers.dev/yum-mirror/VkFFT
ba7001c
master
1//------------------------------------------------------------------------------------------------------------------------------------------------------------- 2// 3// Metal/MTLFunctionConstantValues.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 29#include "MTLArgument.hpp" 30 31namespace MTL 32{ 33class FunctionConstantValues : public NS :: Copying < FunctionConstantValues > 34{ 35public : 36static class FunctionConstantValues * alloc () ; 37 38class FunctionConstantValues * init () ; 39 40void setConstantValue ( const void * value , MTL :: DataType type , NS :: UInteger index ) ; 41 42void setConstantValues ( const void * values , MTL :: DataType type , NS :: Range range ) ; 43 44void setConstantValue ( const void * value , MTL :: DataType type , const NS :: String * name ) ; 45 46void reset () ; 47} ; 48 49} 50 51// static method: alloc 52_MTL_INLINE MTL :: FunctionConstantValues * MTL :: FunctionConstantValues :: alloc () 53{ 54return NS :: Object :: alloc < MTL :: FunctionConstantValues > ( _MTL_PRIVATE_CLS ( MTLFunctionConstantValues )) ; 55} 56 57// method: init 58_MTL_INLINE MTL :: FunctionConstantValues * MTL :: FunctionConstantValues :: init () 59{ 60return NS :: Object :: init < MTL :: FunctionConstantValues > () ; 61} 62 63// method: setConstantValue:type:atIndex: 64_MTL_INLINE void MTL :: FunctionConstantValues :: setConstantValue ( const void * value , MTL :: DataType type , NS :: UInteger index ) 65{ 66Object :: sendMessage < void > ( this , _MTL_PRIVATE_SEL ( setConstantValue_type_atIndex_ ) , value , type , index ) ; 67} 68 69// method: setConstantValues:type:withRange: 70_MTL_INLINE void MTL :: FunctionConstantValues :: setConstantValues ( const void * values , MTL :: DataType type , NS :: Range range ) 71{ 72Object :: sendMessage < void > ( this , _MTL_PRIVATE_SEL ( setConstantValues_type_withRange_ ) , values , type , range ) ; 73} 74 75// method: setConstantValue:type:withName: 76_MTL_INLINE void MTL :: FunctionConstantValues :: setConstantValue ( const void * value , MTL :: DataType type , const NS :: String * name ) 77{ 78Object :: sendMessage < void > ( this , _MTL_PRIVATE_SEL ( setConstantValue_type_withName_ ) , value , type , name ) ; 79} 80 81// method: reset 82_MTL_INLINE void MTL :: FunctionConstantValues :: reset () 83{ 84Object :: sendMessage < void > ( this , _MTL_PRIVATE_SEL ( reset )) ; 85}