Anonymous edits have been disabled on the wiki. If you want to contribute please login or create an account.


Warning for game developers: PCGamingWiki staff members will only ever reach out to you using the official press@pcgamingwiki.com mail address.
Be aware of scammers claiming to be representatives or affiliates of PCGamingWiki who promise a PCGW page for a game key.

Difference between revisions of "Template:API/Documentation"

From PCGamingWiki, the wiki about fixing PC games
m (updated d3d stuff, and added note about DOS row being visible)
(Updated this documentation too, and not just the Editing Guide.)
 
(18 intermediate revisions by 2 users not shown)
Line 2: Line 2:
 
The API template contains information on what APIs and additional features does the game support.
 
The API template contains information on what APIs and additional features does the game support.
  
;Arguments
+
 
* {{Code|direct3d versions}} -
+
;Related templates
* {{Code|directdraw versions}} -
+
{{mm}} {{T|API/switch Direct3D}}
* {{Code|opengl versions}} -
+
{{mm}} {{T|API/switch DOS}}
* {{Code|glide versions}} -
+
 
* {{Code|software mode}} -
 
* {{Code|mantle support}} -
 
* {{Code|metal support}} -
 
* {{Code|vulkan versions}} -
 
* {{Code|dos modes}} -
 
* {{Code|shader model versions}} -
 
* {{Code|64-bit executable}} -
 
  
 
;Supported values
 
;Supported values
 +
 +
''Direct3D versions''
 +
 
{| class="mw-collapsible mw-collapsed wikitable"
 
{| class="mw-collapsible mw-collapsed wikitable"
 
|-
 
|-
! Direct3D versions
+
! Direct3D versions !! {{W|Direct3D#Overview|Notable new features}} !! Notes !!
 
|-
 
|-
| 2
+
| 2 || Initial version ||
 
|-
 
|-
| 3
+
| 3 || {{W|MMX (instruction set)|MMX-enabled}} rasterizer, new RAMP color allocation algorithm<ref>{{Refurl|url=https://news.microsoft.com/1996/09/25/microsoft-ships-directx-version-3-0/|title=Microsoft Stories - Microsoft Ships DirectX Version 3.0|date=2022-11-27|snippet=The Direct3D API is a rendering engine for real-time 3-D graphics that integrates both a low-level API for polygon and vertex rendering, and a high-level API for manipulation of complex 3-D scenes. Direct3D now includes an MMX-enabled rasterizer for Intel’s next generation of multimedia-enabled CPUs, as well as a new RAMP color allocation algorithm that improves the visual quality of RAMP rasterization.}}</ref> ||
 +
|-
 +
| 5 || Easier-to-use immediate mode ||
 
|-
 
|-
| 4
+
| 6 || Multitexturing, bump mapping, vertex buffers, stencil planes, texture compression ||
|-  
+
|-
| 5
+
| 7 || Hardware Transformation, Clipping and Lighting (TCL/T&L) ||
 +
|-
 +
| 8 || Pixel Shader 1.0 & Vertex Shader 1.0 ||
 +
|-
 +
| 8.0a || Pixel Shader 1.1, Pixel Shader 1.2, Pixel Shader 1.3 ||
 +
|-
 +
| 8.1 || Pixel Shader 1.4 & Vertex Shader 1.1 ||
 
|-
 
|-
| 6
+
| 9 || Shader Model 2.0 (Pixel Shader 2.0 & Vertex Shader 2.0) ||
 
|-
 
|-
| 7
+
| 9.0b || Pixel Shader 2.0b ||
 
|-
 
|-
| 8
+
| 9.0c || Shader Model 3.0 (Pixel Shader 3.0 & Vertex Shader 3.0), GPGPU ||
 
|-
 
|-
| 9
+
| 9Ex || Windows Graphics Foundation 1.0, DXVA 1.0 || Also known as 9.L or 9.0L.
 
|-
 
|-
| 10
+
| 10 || Shader Model 4.0, Windows Graphics Foundation 2.0, DXVA 2.0 ||
 
|-
 
|-
| 10.1
+
| 10.1 || Shader Model 4.1, Windows Graphics Foundation 2.1, DXVA 2.1 ||
 
|-
 
|-
| 11
+
| 11 || Shader Model 5.0, Tessellation, Multithreaded rendering, Compute shaders ||
 
|-
 
|-
| 11.1
+
| 11.1 || Stereoscopic 3D Rendering ||
 
|-
 
|-
| 11.2
+
| 11.2 || Tiled resources ||
 
|-
 
|-
| 11.3
+
| 11.3 || Conservative rasterization ||
 
|-
 
|-
| 11.4
+
| 11.4 || OS-managed shader caching, extended NV12 texture support ||
 
|-
 
|-
| 12.0
+
| 12 || Low-level rendering API, Shader Model 5.1 and 6.0 ||
 
|}
 
|}
 +
{{ii}} The parameter will automatically map DirectX versions over to the appropriate Direct3D version; e.g. {{Code|8.2}} is mapped to {{Code|8.1}} as DirectX 8.2 did not bring a new version of Direct3D.
 +
 +
''OpenGL versions''
  
 
{| class="mw-collapsible mw-collapsed wikitable"
 
{| class="mw-collapsible mw-collapsed wikitable"
 
|-
 
|-
! OpenGL Versions
+
! OpenGL versions !!
 +
|-
 +
| true
 
|-
 
|-
 
| 1.0
 
| 1.0
Line 97: Line 106:
 
| 4.6
 
| 4.6
 
|}
 
|}
 +
 +
''Vulkan versions''
  
 
{| class="mw-collapsible mw-collapsed wikitable"
 
{| class="mw-collapsible mw-collapsed wikitable"
 
|-
 
|-
! Vulkan Versions
+
! Vulkan versions !!
 +
|-
 +
| true
 
|-
 
|-
 
| 1.0
 
| 1.0
Line 107: Line 120:
 
|}
 
|}
  
{{ii}} The DOS row is only shown in the article when a DOS or PC booter release date row is also present in [[PCGamingWiki:Editing guide/The Infobox|the Infobox]].
+
''DOS modes''
 +
 
 
{| class="mw-collapsible mw-collapsed wikitable"
 
{| class="mw-collapsible mw-collapsed wikitable"
 
|-
 
|-
! DOS modes !! Mode description
+
! DOS modes !! Mode description !!
 
|-
 
|-
 
| <code>text</code> || Output drawn by characters rather than pixels.
 
| <code>text</code> || Output drawn by characters rather than pixels.
Line 128: Line 142:
 
| <code>svga</code> || Super Video Graphics Array
 
| <code>svga</code> || Super Video Graphics Array
 
|}
 
|}
 +
{{ii}} The DOS row is only shown in the article when a DOS or PC booter release date row is also present in [[PCGamingWiki:Editing guide/The infobox|the Infobox]].
 +
  
 
;Syntax
 
;Syntax
Line 136: Line 152:
 
|directdraw versions    =  
 
|directdraw versions    =  
 
|directdraw notes      =  
 
|directdraw notes      =  
 +
|wing                  =
 +
|wing notes            =
 
|opengl versions        =  
 
|opengl versions        =  
 
|opengl notes          =  
 
|opengl notes          =  
Line 150: Line 168:
 
|dos modes              =  
 
|dos modes              =  
 
|dos modes notes        =  
 
|dos modes notes        =  
|shader model versions  =  
+
|windows 32-bit exe    =
|shader model notes     =  
+
|windows 64-bit exe    =
|64-bit executable     =  
+
|windows arm app        =  
|64-bit executable notes=  
+
|windows exe notes     =
 +
|mac os x powerpc app  =
 +
|macos intel 32-bit app =  
 +
|macos intel 64-bit app =
 +
|macos arm app          =
 +
|macos app notes        =
 +
|linux powerpc app      =
 +
|linux 32-bit executable=  
 +
|linux 64-bit executable=
 +
|linux arm app          =
 +
|linux 68k app          =
 +
|linux executable notes =
 +
|mac os powerpc app    =
 +
|mac os 68k app        =
 +
|mac os executable notes=  
 
}}
 
}}
 
</nowiki></pre>
 
</nowiki></pre>
  
;Related templates
+
 
* [[Template:API/switch_Direct3D]];
+
==Parameters marked as obsolete==
* [[Template:API/switch DOS]].
+
 
 +
===Shader model===
 +
 
 +
As of November 27, 2022 both {{Code|shader model versions}} and {{Code|shader model notes}} was marked as obsolete due to its unreliable nature, with games often providing fallbacks automatically to older versions, and irrelevance in modern gaming landscape. Support for the parameters may or may not be removed entirely in the future. The documentation is stored below for historical purposes:
 +
 
 +
{| class="wikitable"
 +
|-
 +
! Field || Definition || How to find || Notes
 +
|-
 +
| Shader model versions || The versions of the [[Wikipedia:High-level shader language|High-level shader language]] the game supports. || Check the system requirements for the game. The DirectX version required can determine the Shader model used (see [[#DirectX and associated Shader model versions|DirectX and associated Shader model versions]]). || Also called the High-level shading language (HLSL) or Shader model. Only for games using Direct3D 8 or newer. Most games use just one version, but some have support for multiple.
 +
|-
 +
|}
 +
 
 +
;DirectX and associated Shader model versions
 +
For 3D games using DirectX, the Shader model field must be filled in. However, the Shader model version used may not be provided by the developer.
 +
 
 +
Unless otherwise specified, the associated Shader model version is what that version of DirectX is using.
 +
 
 +
{| class="wikitable"
 +
|-
 +
! DirectX version || Associated Shader model version
 +
|-
 +
| 8.0 || 1.0 and 1.1
 +
|-
 +
| 8.0a || 1.3
 +
|-
 +
| 8.1 || 1.4
 +
|-
 +
| 9.0 || 2.0
 +
|-
 +
| 9.0a || 2.0a
 +
|-
 +
| 9.0b || 2.0b
 +
|-
 +
| 9.0c || 3.0
 +
|-
 +
| 10.0 || 4.0
 +
|-
 +
| 10.1 || 4.1
 +
|-
 +
| 11.x || 5.0
 +
|-
 +
| 12.x || 5.1, 6.x
 +
|}
 +
 
 +
{{References}}
  
 
<includeonly>[[Category:Table templates]]</includeonly>
 
<includeonly>[[Category:Table templates]]</includeonly>
 
<noinclude>[[Category:Documentation templates]]</noinclude>
 
<noinclude>[[Category:Documentation templates]]</noinclude>

Latest revision as of 08:50, 20 March 2023

Description

The API template contains information on what APIs and additional features does the game support.


Related templates
{{API/switch Direct3D}}
{{API/switch DOS}}


Supported values

Direct3D versions

Direct3D versions Notable new features Notes
2 Initial version
3 MMX-enabled rasterizer, new RAMP color allocation algorithm[1]
5 Easier-to-use immediate mode
6 Multitexturing, bump mapping, vertex buffers, stencil planes, texture compression
7 Hardware Transformation, Clipping and Lighting (TCL/T&L)
8 Pixel Shader 1.0 & Vertex Shader 1.0
8.0a Pixel Shader 1.1, Pixel Shader 1.2, Pixel Shader 1.3
8.1 Pixel Shader 1.4 & Vertex Shader 1.1
9 Shader Model 2.0 (Pixel Shader 2.0 & Vertex Shader 2.0)
9.0b Pixel Shader 2.0b
9.0c Shader Model 3.0 (Pixel Shader 3.0 & Vertex Shader 3.0), GPGPU
9Ex Windows Graphics Foundation 1.0, DXVA 1.0 Also known as 9.L or 9.0L.
10 Shader Model 4.0, Windows Graphics Foundation 2.0, DXVA 2.0
10.1 Shader Model 4.1, Windows Graphics Foundation 2.1, DXVA 2.1
11 Shader Model 5.0, Tessellation, Multithreaded rendering, Compute shaders
11.1 Stereoscopic 3D Rendering
11.2 Tiled resources
11.3 Conservative rasterization
11.4 OS-managed shader caching, extended NV12 texture support
12 Low-level rendering API, Shader Model 5.1 and 6.0
The parameter will automatically map DirectX versions over to the appropriate Direct3D version; e.g. 8.2 is mapped to 8.1 as DirectX 8.2 did not bring a new version of Direct3D.

OpenGL versions

OpenGL versions
true
1.0
1.1
1.2
1.2.1
1.3
1.4
1.5
2.0
2.1
3.0
3.1
3.2
3.3
4.0
4.1
4.2
4.3
4.4
4.5
4.6

Vulkan versions

Vulkan versions
true
1.0
1.1

DOS modes

DOS modes Mode description
text Output drawn by characters rather than pixels.
hgc Hercules Graphics Card
cga Color Graphics Adapter
mcga Multi-Color Graphics Array
ega Enhanced Graphics Adapter
tga Tandy Graphics Adapter
vga Video Graphics Array
svga Super Video Graphics Array
The DOS row is only shown in the article when a DOS or PC booter release date row is also present in the Infobox.


Syntax
{{API
|direct3d versions      = 
|direct3d notes         = 
|directdraw versions    = 
|directdraw notes       = 
|wing                   = 
|wing notes             = 
|opengl versions        = 
|opengl notes           = 
|glide versions         = 
|glide notes            = 
|software mode          = 
|software mode notes    = 
|mantle support         = 
|mantle support notes   = 
|metal support          = 
|metal support notes    = 
|vulkan versions        = 
|vulkan notes           = 
|dos modes              = 
|dos modes notes        = 
|windows 32-bit exe     = 
|windows 64-bit exe     = 
|windows arm app        = 
|windows exe notes      = 
|mac os x powerpc app   = 
|macos intel 32-bit app = 
|macos intel 64-bit app = 
|macos arm app          = 
|macos app notes        = 
|linux powerpc app      = 
|linux 32-bit executable= 
|linux 64-bit executable= 
|linux arm app          = 
|linux 68k app          = 
|linux executable notes = 
|mac os powerpc app     =
|mac os 68k app         = 
|mac os executable notes= 
}}


Parameters marked as obsolete

Shader model

As of November 27, 2022 both shader model versions and shader model notes was marked as obsolete due to its unreliable nature, with games often providing fallbacks automatically to older versions, and irrelevance in modern gaming landscape. Support for the parameters may or may not be removed entirely in the future. The documentation is stored below for historical purposes:

Field Definition How to find Notes
Shader model versions The versions of the High-level shader language the game supports. Check the system requirements for the game. The DirectX version required can determine the Shader model used (see DirectX and associated Shader model versions). Also called the High-level shading language (HLSL) or Shader model. Only for games using Direct3D 8 or newer. Most games use just one version, but some have support for multiple.
DirectX and associated Shader model versions

For 3D games using DirectX, the Shader model field must be filled in. However, the Shader model version used may not be provided by the developer.

Unless otherwise specified, the associated Shader model version is what that version of DirectX is using.

DirectX version Associated Shader model version
8.0 1.0 and 1.1
8.0a 1.3
8.1 1.4
9.0 2.0
9.0a 2.0a
9.0b 2.0b
9.0c 3.0
10.0 4.0
10.1 4.1
11.x 5.0
12.x 5.1, 6.x


References

  1. Microsoft Stories - Microsoft Ships DirectX Version 3.0 - last accessed on 2022-11-27
    "The Direct3D API is a rendering engine for real-time 3-D graphics that integrates both a low-level API for polygon and vertex rendering, and a high-level API for manipulation of complex 3-D scenes. Direct3D now includes an MMX-enabled rasterizer for Intel’s next generation of multimedia-enabled CPUs, as well as a new RAMP color allocation algorithm that improves the visual quality of RAMP rasterization."