easisi
December 12, 2022, 4:23pm
#1
hey people,
im currently writing some GLSL code that should ingest more than 16 input samplers. somehow this limit is crazy low on macOS atm.
i’m not super into these things but apparently there is a feature in Metal called „Argument Buffers“ which is also accessible in MoltenVK and drastically increases the max sampler count. (useMetalArgumentBuffers)
/**
* Controls whether MoltenVK should use Metal argument buffers for resources defined in
* descriptor sets, if Metal argument buffers are supported on the platform. Using Metal
* argument buffers dramatically increases the number of buffers, textures and samplers
* that can be bound to a pipeline shader, and in most cases improves performance. If this
* setting is enabled, MoltenVK will use Metal argument buffers to bind resources to the
* shaders. If this setting is disabled, MoltenVK will bind resources to shaders discretely.
*
* NOTE: Currently, Metal argument buffer support is in beta stage, and is only supported
* on macOS 11.0 (Big Sur) or later, or on older versions of macOS using an Intel GPU.
* Metal argument buffers support is not available on iOS. Development to support iOS
* and a wider combination of GPU's on older macOS versions is under way.
*
* The value of this parameter must be changed before creating a VkInstance,
* for the change to take effect.
*
* The initial value or this parameter is set by the
* MVK_CONFIG_USE_METAL_ARGUMENT_BUFFERS
* runtime environment variable or MoltenVK compile-time build setting.
* If neither is set, this setting is enabled by default, and MoltenVK will not
This file has been truncated. show original
could this be an easy fix for us mac users or lies the problem deeper ?