ComfyUI > Nodes > GLSL Nodes > glslUniforms

ComfyUI Node: glslUniforms

Class Name

glslUniforms

Category
GLSL
Author
Patricio Gonzalez Vivo (Account age: 5109days)
Extension
GLSL Nodes
Latest Updated
2024-07-21
Github Stars
0.12K

How to Install GLSL Nodes

Install this extension via the ComfyUI Manager by searching for GLSL Nodes
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter GLSL Nodes in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • High-speed GPU machines
  • 200+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 50+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

glslUniforms Description

Facilitates GLSL uniform integration and management for dynamic shader effects.

glslUniforms:

The glslUniforms node is designed to facilitate the integration and management of GLSL (OpenGL Shading Language) uniforms within your shader programs. This node allows you to define and pass various types of uniform variables, such as textures and values, to your GLSL shaders, enabling dynamic and flexible rendering effects. By using this node, you can easily manage and update shader parameters, ensuring that your shaders receive the necessary data to produce the desired visual outcomes. The glslUniforms node is particularly useful for AI artists who want to create complex visual effects without delving deeply into the technical intricacies of GLSL programming.

glslUniforms Input Parameters:

u_tex0

This parameter allows you to input an image texture that can be used within your GLSL shader. You can provide multiple images if needed. The texture will be accessible in the shader as a uniform variable, enabling you to apply various image-based effects. There is no specific minimum or maximum value for this parameter, and it can accept any valid image input.

u_tex1

Similar to u_tex0, this parameter allows you to input an additional image texture for use within your GLSL shader. You can provide multiple images if needed. This texture will also be accessible as a uniform variable in the shader, allowing for more complex image-based effects. There is no specific minimum or maximum value for this parameter, and it can accept any valid image input.

u_tex2

This parameter functions like u_tex0 and u_tex1, allowing you to input yet another image texture for use within your GLSL shader. Multiple images can be provided if needed. The texture will be accessible as a uniform variable in the shader, enabling further image-based effects. There is no specific minimum or maximum value for this parameter, and it can accept any valid image input.

u_tex3

This parameter allows you to input a fourth image texture for use within your GLSL shader, similar to u_tex0, u_tex1, and u_tex2. Multiple images can be provided if needed. The texture will be accessible as a uniform variable in the shader, allowing for even more complex image-based effects. There is no specific minimum or maximum value for this parameter, and it can accept any valid image input.

u_val0

This parameter allows you to input a value that can be used within your GLSL shader. The value can be of any type (e.g., int, float, list, or tuple) and will be accessible as a uniform variable in the shader. This enables you to pass various types of data to your shader, such as numerical values or vectors. There is no specific minimum or maximum value for this parameter, and it can accept any valid input.

u_val1

Similar to u_val0, this parameter allows you to input an additional value for use within your GLSL shader. The value can be of any type and will be accessible as a uniform variable in the shader. This enables you to pass more data to your shader, such as additional numerical values or vectors. There is no specific minimum or maximum value for this parameter, and it can accept any valid input.

u_val2

This parameter functions like u_val0 and u_val1, allowing you to input yet another value for use within your GLSL shader. The value can be of any type and will be accessible as a uniform variable in the shader. This enables you to pass even more data to your shader, such as further numerical values or vectors. There is no specific minimum or maximum value for this parameter, and it can accept any valid input.

u_val3

This parameter allows you to input a fourth value for use within your GLSL shader, similar to u_val0, u_val1, and u_val2. The value can be of any type and will be accessible as a uniform variable in the shader. This enables you to pass additional data to your shader, such as more numerical values or vectors. There is no specific minimum or maximum value for this parameter, and it can accept any valid input.

glslUniforms Output Parameters:

uniforms

The output of the glslUniforms node is a GLSL_CONTEXT object, which contains all the defined uniforms and textures. This context object is essential for rendering your GLSL shaders, as it provides the necessary data for the shaders to produce the desired visual effects. The uniforms output ensures that all the input parameters are correctly passed to the shader, enabling dynamic and flexible rendering.

glslUniforms Usage Tips:

  • Ensure that the image textures provided to u_tex0, u_tex1, u_tex2, and u_tex3 are of appropriate resolution and format for your shader to process them effectively.
  • Use the value parameters (u_val0, u_val1, u_val2, u_val3) to pass dynamic data to your shader, such as time, resolution, or other variables that can change during rendering.
  • Combine multiple textures and values to create complex and dynamic visual effects in your GLSL shaders.

glslUniforms Common Errors and Solutions:

Invalid texture input

  • Explanation: The provided texture input is not a valid image or is in an unsupported format.
  • Solution: Ensure that the texture input is a valid image file and is in a format supported by your GLSL shader.

Invalid value input

  • Explanation: The provided value input is not of a supported type or format.
  • Solution: Ensure that the value input is of a supported type (e.g., int, float, list, or tuple) and is formatted correctly.

Missing uniform variable in shader

  • Explanation: The shader does not contain a uniform variable that matches the provided input parameter name.
  • Solution: Ensure that the shader code includes uniform variables that match the names of the input parameters provided to the glslUniforms node.

Shader compilation error

  • Explanation: There is an error in the GLSL shader code, preventing it from compiling correctly.
  • Solution: Check the shader code for syntax errors or unsupported features and correct them before using the glslUniforms node.

glslUniforms Related Nodes

Go back to the extension to check out more related nodes.
GLSL Nodes
RunComfy

© Copyright 2024 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals.