'\" t .\" Title: dFdx, dFdy .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: 05/21/2015 .\" Manual: [FIXME: manual] .\" Source: [FIXME: source] .\" Language: English .\" .TH "DFDX, DFDY" "3G" "05/21/2015" "[FIXME: source]" "[FIXME: manual]" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" dFdx,_dFdy \- return the partial derivative of an argument with respect to x or y .SH "DECLARATION" .HP \w'genType\ dFdx('u .BI "genType dFdx(genType\ " "p" ");" .HP \w'genType\ dFdy('u .BI "genType dFdy(genType\ " "p" ");" .HP \w'genType\ dFdxCoarse('u .BI "genType dFdxCoarse(genType\ " "p" ");" .HP \w'genType\ dFdyCoarse('u .BI "genType dFdyCoarse(genType\ " "p" ");" .HP \w'genType\ dFdxFine('u .BI "genType dFdxFine(genType\ " "p" ");" .HP \w'genType\ dFdyFine('u .BI "genType dFdyFine(genType\ " "p" ");" .SH "PARAMETERS" .PP \fIp\fR .RS 4 Specifies the expression of which to take the partial derivative\&. .RE .SH "DESCRIPTION" .PP \fIAvailable only in the fragment shader\fR, these functions return the partial derivative of expression \fIp\fR with respect to the window $x$ coordinate (for \fBdFdx*\fR) and $y$ coordinate (for \fBdFdy*\fR)\&. .PP \fBdFdxFine\fR and \fBdFdyFine\fR calculate derivatives using local differencing based on on the value of \fIp\fR for the current fragment and its immediate neighbor(s)\&. .PP \fBdFdxCoarse\fR and \fBdFdyCoarse\fR calculate derivatives using local differencing based on the value of \fIp\fR for the current fragment\*(Aqs neighbors, and will possibly, but not necessarily, include the value for the current fragment\&. That is, over a given area, the implementation can compute derivatives in fewer unique locations than would be allowed for the corresponding \fBdFdxFine\fR and \fBdFdyFine\fR functions\&. .PP \fBdFdx\fR returns either \fBdFdxCoarse\fR or \fBdFdxFine\fR\&. \fBdFdy\fR returns either \fBdFdyCoarse\fR or \fBdFdyFine\fR\&. The implementation may choose which calculation to perform based upon factors such as performance or the value of the API \fBGL_FRAGMENT_SHADER_DERIVATIVE_HINT\fR hint\&. .PP Expressions that imply higher order derivatives such as dFdx(dFdx(n)) have undefined results, as do mixed\-order derivatives such as dFdx(dFdy(n))\&. It is assumed that the expression \fIp\fR is continuous and therefore, expressions evaluated via non\-uniform control flow may be undefined\&. .SH "VERSION SUPPORT" .TS allbox tab(:); lB cB s s s s s s s s s s s lB cB cB cB cB cB cB cB cB cB cB cB cB. T{ T}:T{ \fBOpenGL Shading Language Version\fR T} T{ \fBFunction Name\fR T}:T{ \fB1\&.10\fR T}:T{ \fB1\&.20\fR T}:T{ \fB1\&.30\fR T}:T{ \fB1\&.40\fR T}:T{ \fB1\&.50\fR T}:T{ \fB3\&.30\fR T}:T{ \fB4\&.00\fR T}:T{ \fB4\&.10\fR T}:T{ \fB4\&.20\fR T}:T{ \fB4\&.30\fR T}:T{ \fB4\&.40\fR T}:T{ \fB4\&.50\fR T} .T& l c c c c c c c c c c c c l c c c c c c c c c c c c l c c c c c c c c c c c c. T{ dFdx T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T} T{ dFdy T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T} T{ dFdxCoarse, dFdxFine, dFdyCoarse, dFdyFine T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ ✔ T} .TE .sp .SH "SEE ALSO" .PP \fBfwidth\fR(), \fBglHint\fR() .SH "COPYRIGHT" .PP Copyright \(co 2011\-2014 Khronos Group\&. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1\&.0, 8 June 1999\&. \m[blue]\fBhttp://opencontent\&.org/openpub/\fR\m[]\&. .SH "COPYRIGHT" .br Copyright \(co 2011-2014 Khronos Group .br