📖 WIPIVERSE

🔍 Currently registered entries: 57,388건

CG(X)

CG(X) refers to a variety of computer graphics APIs and shading languages developed by NVIDIA. The term "CG" is a shorthand for "C for Graphics," reflecting the C-like syntax employed by these technologies. The (X) portion denotes a broader family and potentially future iterations. Historically, the most well-known instance is Cg, but the CG(X) notation aims to encompass related technologies.

While Cg was a prominent early entry, it has since been superseded by other shading languages, notably HLSL (High-Level Shading Language) developed by Microsoft and GLSL (OpenGL Shading Language). Despite being less widely used in modern development, Cg's influence is evident in the design of these newer languages.

Key characteristics associated with CG(X), particularly in the context of its original form (Cg), include:

  • C-like Syntax: The language adopted a syntax resembling the C programming language, making it relatively accessible to programmers familiar with C/C++. This facilitated a quicker adoption compared to assembly-level shader programming.

  • Cross-Platform Compatibility (Historically): Cg was designed to work with both OpenGL and DirectX graphics APIs, offering a degree of platform independence for shader development. While this was a key advantage at the time, the rise of native languages (HLSL for DirectX, GLSL for OpenGL) diminished this advantage.

  • Shader Development: The primary purpose of CG(X) languages is to define shaders. Shaders are small programs that run on the GPU (Graphics Processing Unit) and control how objects are rendered. They determine aspects such as lighting, textures, and special effects.

  • Vertex and Fragment Shaders: CG(X) languages are used to write both vertex shaders and fragment (pixel) shaders. Vertex shaders manipulate the geometry of objects, while fragment shaders determine the color of each pixel.

The CG(X) notation is sometimes used to refer to NVIDIA's broader efforts in the domain of programmable shaders and graphics languages, even beyond the specific Cg language. While Cg itself is less prevalent today, its legacy continues to influence shader development practices and the design of modern shading languages.