📄 fglfog.ps
字号:
1758(single)X1974(integer)X2222(or)X2314(\257oating-point)X2774(value)X2973(that)X3118(speci\256es)X3420(the)X3544(equation)X3846(to)X3934(be)X1354 4182(used)N1522(to)X1605(compute)X1902(the)X2021(fog)X2149(blend)X2348(factor,)X2577($f$.)X2745(Three)X2954(symbolic)X3268(constants)X3587(are)X3706(accepted:)X3 f1354 4278(GL_LINEAR)N1 f1820(,)X3 f1865(GL_EXP)X1 f2180(,)X2225(and)X3 f2367(GL_EXP2)X1 f2722(.)X2788(The)X2939(equations)X3272(corresponding)X3757(to)X3845(these)X1354 4374(symbolic)N1667(constants)X1985(are)X2104(de\256ned)X2360(below.)X2616(The)X2761(initial)X2967(fog)X3094(mode)X3292(is)X3 f3365(GL_EXP)X1 f3680(.)X3 f554 4508(GL_FOG_DENSITY)N2 f1354(params)X1 f1619(is)X1697(a)X1758(single)X1974(integer)X2222(or)X2314(\257oating-point)X2774(value)X2974(that)X3120(speci\256es)X3422($density$,)X3779(the)X3903(fog)X1354 4604(density)N1617(used)X1796(in)X1890(both)X2064(exponential)X2470(fog)X2608(equations.)X2986(Only)X3177(nonnegative)X3600(densities)X3911(are)X1354 4700(accepted.)N1696(The)X1841(initial)X2047(fog)X2174(density)X2425(is)X2498(1.)X3 f554 4834(GL_FOG_START)N2 f1354(params)X1 f1624(is)X1707(a)X1773(single)X1994(integer)X2247(or)X2344(\257oating-point)X2810(value)X3015(that)X3166(speci\256es)X3473($start$,)X3742(the)X3871(near)X1354 4930(distance)N1637(used)X1804(in)X1886(the)X2004(linear)X2207(fog)X2334(equation.)X2670(The)X2815(initial)X3021(near)X3180(distance)X3463(is)X3536(0.)X3 f554 5064(GL_FOG_END)N2 f1354(params)X1 f1618(is)X1695(a)X1755(single)X1970(integer)X2217(or)X2308(\257oating-point)X2767(value)X2965(that)X3110(speci\256es)X3411($end$,)X3652(the)X3775(far)X3890(dis-)X1354 5160(tance)N1544(used)X1711(in)X1793(the)X1911(linear)X2114(fog)X2241(equation.)X2577(The)X2722(initial)X2928(far)X3038(distance)X3321(is)X3394(1.)X3 f554 5294(GL_FOG_INDEX)N2 f1354(params)X1 f1620(is)X1699(a)X1762(single)X1980(integer)X2230(or)X2324(\257oating-point)X2786(value)X2987(that)X3134(speci\256es)X3437($i)X3526(sub)X3664(f$,)X3778(the)X3903(fog)X1354 5390(color)N1539(index.)X1777(The)X1922(initial)X2128(fog)X2255(index)X2453(is)X2526(0.)X3 f554 5524(GL_FOG_COLOR)N2 f1354(params)X1 f1622(contains)X1917(four)X2079(integer)X2330(or)X2426(\257oating-point)X2890(values)X3124(that)X3273(specify)X3534($C)X3656(sub)X3796(f$,)X3912(the)X1354 5620(fog)N1511(color.)X1765(Integer)X2042(values)X2296(are)X2444(mapped)X2747(linearly)X3041(such)X3237(that)X3406(the)X3553(most)X3757(positive)X1354 5716(representable)N1809(value)X2009(maps)X2204(to)X2292(1.0,)X2438(and)X2580(the)X2704(most)X2885(negative)X3184(representable)X3640(value)X3841(maps)X1354 5812(to)N9 f1449(-)X1 f1493(1.0.)X1666(Floating-point)X2156(values)X2393(are)X2524(mapped)X2810(directly.)X3127(After)X3329(conversion,)X3733(all)X3845(color)X266 6144(Page)N442(1)X3577(July)X3730(22,)X3850(1997)X2 p%%Page: 2 210 s 0 xH 0 xS 1 f10 f0 96(h)N24(hhh)X4176(h)X4200(hhh)X9 s1 f266 480(F)N268(FG)X310(GL)X364(LF)X410(FO)X452(OG)X506(G)X564(\()X566(\()X602(\))X604(\))X1885(U)X1887(UN)X1941(NI)X1995(IX)X2021(X)X2093(S)X2095(Sy)X2137(ys)X2175(st)X2205(te)X2227(em)X2261(m)X2337(V)X2339(V)X3648(F)X3650(FG)X3692(GL)X3746(LF)X3792(FO)X3834(OG)X3888(G)X3946(\()X3948(\()X3984(\))X3986(\))X10 s1354 864(components)N1761(are)X1880(clamped)X2172(to)X2254(the)X2372(range)X2571([0,1].)X2785(The)X2930(initial)X3136(fog)X3263(color)X3448(is)X3521(\(0,)X3628(0,)X3708(0,)X3788(0\).)X554 998(Fog)N707(blends)X945(a)X1010(fog)X1146(color)X1340(with)X1511(each)X1688(rasterized)X2030(pixel)X2219(fragment's)X2596(posttexturing)X3048(color)X3243(using)X3446(a)X3512(blending)X3822(factor)X554 1094($f$.)N725(Factor)X954($f$)X1085(is)X1162(computed)X1502(in)X1588(one)X1728(of)X1819(three)X2004(ways,)X2213(depending)X2571(on)X2675(the)X2797(fog)X2928(mode.)X3170(Let)X3301($z$)X3441(be)X3541(the)X3662(distance)X3948(in)X554 1190(eye)N686(coordinates)X1076(from)X1252(the)X1370(origin)X1581(to)X1663(the)X1781(fragment)X2091(being)X2289(fogged.)X2572(The)X2717(equation)X3013(for)X3 f3127(GL_LINEAR)X1 f3613(fog)X3740(is)X1707 1382(f)N1754(\304=\304)X1873({end)X2047(\304-\304)X2148(z})X2242(over)X2405({end)X2579(\304-\304)X2680(start})X554 1612(The)N699(equation)X995(for)X3 f1109(GL_EXP)X1 f1444(fog)X1571(is)X1804 1804(f)N1851(\304=\304)X1970(e)X2026(**)X2126(\(-\(density)X2458(\304cdot\304)X2670(z\)\))X554 2034(The)N699(equation)X995(for)X3 f1109(GL_EXP2)X1 f1484(fog)X1611(is)X1724 2226(f)N1771(\304=\304)X1890(e)X1946(**)X2046(\(-\(density)X2378(\304cdot\304)X2590(z\))X2673(**)X2773(2\))X554 2456(Regardless)N932(of)X1025(the)X1149(fog)X1282(mode,)X1506($f$)X1639(is)X1718(clamped)X2016(to)X2104(the)X2228(range)X2433([0,1])X2613(after)X2787(it)X2858(is)X2938(computed.)X3321(Then,)X3533(if)X3609(the)X3734(GL)X3868(is)X3948(in)X554 2552(RGBA)N796(color)X981(mode,)X1199(the)X1317(fragment's)X1685(color)X1870($C)X1983(sub)X2114(r$)X2201(is)X2274(replaced)X2567(by)X1544 2744({C)N1655(sub)X1786(r})X1871(prime)X2078(\304=\304)X2197(f)X2244(C)X2317(sub)X2448(r)X2495(+)X2560(\(1)X2647(-)X2694(f\))X2768(C)X2841(sub)X2972(f)X554 2878(In)N641(color)X826(index)X1024(mode,)X1242(the)X1360(fragment's)X1728(color)X1913(index)X2111($i)X2193(sub)X2324(r$)X2411(is)X2484(replaced)X2777(by)X1614 3070({i)N1694(sub)X1825(r})X1910(prime)X2117(\304=\304)X2236(i)X2278(sub)X2409(r)X2456(+)X2521(\(1)X2608(-)X2655(f\))X2729(i)X2771(sub)X2902(f)X9 s266 3204(E)N268(ER)X314(RR)X364(RO)X414(OR)X468(RS)X518(S)X3 f10 s554 3300(GL_INVALID_ENUM)N1 f1364(is)X1440(generated)X1776(if)X2 f1849(pname)X1 f2087(is)X2164(not)X2290(an)X2390(accepted)X2696(value,)X2914(or)X3005(if)X2 f3078(pname)X1 f3316(is)X3 f3393(GL_FOG_MODE)X1 f554 3396(and)N2 f690(params)X1 f950(is)X1023(not)X1145(an)X1241(accepted)X1543(value.)X3 f554 3530(GL_INVALID_VALUE)N1 f1396(is)X1469(generated)X1802(if)X2 f1871(pname)X1 f2105(is)X3 f2178(GL_FOG_DENSITY)X1 f2901(,)X2941(and)X2 f3077(params)X1 f3337(is)X3410(negative.)X3 f554 3664(GL_INVALID_OPERATION)N1 f1606(is)X1685(generated)X2024(if)X3 f2099(fglFog)X1 f2343(is)X2422(executed)X2734(between)X3028(the)X3152(execution)X3490(of)X3 f3583(fglBegin)X1 f3894(and)X554 3760(the)N672(corresponding)X1151(execution)X1483(of)X3 f1570(fglEnd)X1 f1800(.)X9 s266 3894(A)N268(AS)X322(SS)X364(SO)X406(OC)X460(CI)X510(IA)X536(AT)X590(TE)X636(ED)X682(D)X766(G)X768(GE)X822(ET)X868(TS)X914(S)X3 f10 s554 3990(fglIsEnabled)N1 f1008(with)X1170(argument)X3 f1493(GL_FOG)X554 4086(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_COLOR)X554 4182(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_INDEX)X554 4278(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_DENSITY)X554 4374(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_START)X554 4470(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_END)X554 4566(fglGet)N1 f788(with)X950(argument)X3 f1273(GL_FOG_MODE)X1 f9 s266 4700(S)N268(SE)X310(EE)X356(E)X432(A)X434(AL)X488(LS)X534(SO)X576(O)X3 f10 s554 4796(fglEnable)N1 f266 6144(July)N419(22,)X539(1997)X3794(Page)X3970(2)X10 f0 6428(h)N24(hhh)X4176(h)X4200(hhh)X2 p%%Trailerxtxs
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -