diff --git a/src/ast/texture.h b/src/ast/texture.h index c8c871f4c4..4c2270e010 100644 --- a/src/ast/texture.h +++ b/src/ast/texture.h @@ -47,11 +47,16 @@ std::ostream& operator<<(std::ostream& out, TextureDimension dim); /// @return true if the given TextureDimension is an array texture bool IsTextureArray(TextureDimension dim); -/// Returns the number of axes in the coordinate for a dimensionality. +/// Returns the number of axes in the coordinate used for accessing +/// the texture, where an access is one of: sampling, fetching, load, +/// or store. /// None -> 0 /// 1D -> 1 /// 2D, 2DArray -> 2 /// 3D, Cube, CubeArray -> 3 +/// Note: To sample a cube texture, the coordinate has 3 dimensions, +/// but textureDimensions on a cube or cube array returns a 2-element +/// size, representing the (x,y) size of each cube face, in texels. /// @param dim the TextureDimension to query /// @return number of dimensions in a coordinate for the dimensionality int NumCoordinateAxes(TextureDimension dim);