godotengine / godotengine/godot

Shader Uniforms Documentation comments do not work when used in gdshaderinc files

Open
#97,844 3 comments 6 reactions 0 assignees View on GitHub
bug documentation topic:shaders
Dominant language
C++
Stars
117k
Forks
26.8k
PR merge metrics
PR metrics pending

Description

### Tested versions

v4.3.stable.official [77dcf97d8]

### System information

Godot v4.3.stable - Windows 10.0.22631 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 4050 Laptop GPU (NVIDIA; 31.0.15.5161) - 12th Gen Intel(R) Core(TM) i7-12650H (16 Threads)

### Issue description

/**
* This is a documentation comment.
*/
uniform bool something = false;

If this piece of shader code lives inside a gdshader file, it works.
Placed in a gdshaderinc file, it doesn't.

### Steps to reproduce

/**
* This is a documentation comment.
*/
uniform bool something = false;

If this piece of shader code lives inside a gdshader file, it works.
Placed in a gdshaderinc file, it doesn't.

### Minimal reproduction project (MRP)

N/A

Contributor guide

Open the contributing guide

Research direction

Start by reproducing the documented uniform example in both a gdshader file and a gdshaderinc file using Godot v4.3. Compare how documentation comments are handled in the two cases; done means the same comment behavior works for both file types.

Written by the indexing model from the issue text.

Assessment

Domain
game-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.