glext.pp 472 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277827882798280828182828283828482858286828782888289829082918292829382948295829682978298829983008301830283038304830583068307830883098310831183128313831483158316831783188319832083218322832383248325832683278328832983308331833283338334833583368337833883398340834183428343834483458346834783488349835083518352835383548355835683578358835983608361836283638364836583668367836883698370837183728373837483758376837783788379838083818382838383848385838683878388838983908391839283938394839583968397839883998400840184028403840484058406840784088409841084118412841384148415841684178418841984208421842284238424842584268427842884298430843184328433843484358436843784388439844084418442844384448445844684478448844984508451845284538454845584568457845884598460846184628463846484658466846784688469847084718472847384748475847684778478847984808481848284838484848584868487848884898490849184928493849484958496849784988499850085018502850385048505850685078508850985108511851285138514851585168517851885198520852185228523852485258526852785288529853085318532853385348535853685378538853985408541854285438544854585468547854885498550855185528553855485558556855785588559856085618562856385648565856685678568856985708571857285738574857585768577857885798580858185828583858485858586858785888589859085918592859385948595859685978598859986008601860286038604860586068607860886098610861186128613861486158616861786188619862086218622862386248625862686278628862986308631863286338634863586368637863886398640864186428643864486458646864786488649865086518652865386548655865686578658865986608661866286638664866586668667866886698670867186728673867486758676867786788679868086818682868386848685868686878688868986908691869286938694869586968697869886998700870187028703870487058706870787088709871087118712871387148715871687178718871987208721872287238724872587268727872887298730873187328733873487358736873787388739874087418742874387448745874687478748874987508751875287538754875587568757875887598760876187628763876487658766876787688769877087718772877387748775877687778778877987808781878287838784878587868787878887898790879187928793879487958796879787988799880088018802880388048805880688078808880988108811881288138814881588168817881888198820882188228823882488258826882788288829883088318832883388348835883688378838883988408841884288438844884588468847884888498850885188528853885488558856885788588859886088618862886388648865886688678868886988708871887288738874887588768877887888798880888188828883888488858886888788888889889088918892889388948895889688978898889989008901890289038904890589068907890889098910891189128913891489158916891789188919892089218922892389248925892689278928892989308931893289338934893589368937893889398940894189428943894489458946894789488949895089518952895389548955895689578958895989608961896289638964896589668967896889698970897189728973897489758976897789788979898089818982898389848985898689878988898989908991899289938994899589968997899889999000900190029003900490059006900790089009901090119012901390149015901690179018901990209021902290239024902590269027902890299030903190329033903490359036903790389039904090419042904390449045904690479048904990509051905290539054905590569057905890599060906190629063906490659066906790689069907090719072907390749075907690779078907990809081908290839084908590869087908890899090909190929093909490959096909790989099910091019102910391049105910691079108910991109111911291139114911591169117911891199120912191229123912491259126912791289129913091319132913391349135913691379138913991409141914291439144914591469147914891499150915191529153915491559156915791589159916091619162916391649165916691679168916991709171917291739174917591769177917891799180918191829183918491859186918791889189919091919192919391949195919691979198919992009201920292039204920592069207920892099210921192129213921492159216921792189219922092219222922392249225922692279228922992309231923292339234923592369237923892399240924192429243924492459246924792489249925092519252925392549255925692579258925992609261926292639264926592669267926892699270927192729273927492759276927792789279928092819282928392849285928692879288928992909291929292939294929592969297929892999300930193029303930493059306930793089309931093119312931393149315931693179318931993209321932293239324932593269327932893299330933193329333933493359336933793389339934093419342934393449345934693479348934993509351935293539354935593569357935893599360936193629363936493659366936793689369937093719372937393749375937693779378937993809381938293839384938593869387938893899390939193929393939493959396939793989399940094019402940394049405940694079408940994109411941294139414941594169417941894199420942194229423942494259426942794289429943094319432943394349435943694379438943994409441944294439444944594469447944894499450945194529453945494559456945794589459946094619462946394649465946694679468946994709471947294739474947594769477947894799480948194829483948494859486948794889489949094919492949394949495949694979498949995009501950295039504950595069507950895099510951195129513951495159516951795189519952095219522952395249525952695279528952995309531953295339534953595369537953895399540954195429543954495459546954795489549955095519552955395549555955695579558955995609561956295639564956595669567956895699570957195729573957495759576957795789579958095819582958395849585958695879588958995909591959295939594959595969597959895999600960196029603960496059606960796089609961096119612961396149615961696179618961996209621962296239624962596269627962896299630963196329633963496359636963796389639964096419642964396449645964696479648964996509651965296539654965596569657965896599660966196629663966496659666966796689669967096719672967396749675967696779678967996809681968296839684968596869687968896899690969196929693969496959696969796989699970097019702970397049705970697079708970997109711971297139714971597169717971897199720972197229723972497259726972797289729973097319732973397349735973697379738973997409741974297439744974597469747974897499750975197529753975497559756975797589759976097619762976397649765976697679768976997709771977297739774977597769777977897799780978197829783978497859786978797889789979097919792979397949795979697979798979998009801980298039804980598069807980898099810981198129813981498159816981798189819982098219822982398249825982698279828982998309831983298339834983598369837983898399840984198429843984498459846984798489849985098519852985398549855985698579858985998609861986298639864986598669867986898699870987198729873987498759876987798789879988098819882988398849885988698879888988998909891989298939894989598969897989898999900990199029903990499059906990799089909991099119912991399149915991699179918991999209921992299239924992599269927992899299930993199329933993499359936993799389939994099419942994399449945994699479948994999509951995299539954995599569957995899599960996199629963996499659966996799689969997099719972997399749975997699779978997999809981998299839984998599869987998899899990999199929993999499959996999799989999100001000110002100031000410005100061000710008100091001010011100121001310014100151001610017100181001910020100211002210023100241002510026100271002810029100301003110032100331003410035100361003710038100391004010041100421004310044100451004610047100481004910050100511005210053100541005510056100571005810059100601006110062100631006410065100661006710068100691007010071100721007310074100751007610077100781007910080100811008210083100841008510086100871008810089100901009110092100931009410095100961009710098100991010010101101021010310104101051010610107101081010910110101111011210113101141011510116101171011810119101201012110122101231012410125101261012710128101291013010131101321013310134101351013610137101381013910140101411014210143101441014510146101471014810149101501015110152101531015410155101561015710158101591016010161101621016310164101651016610167101681016910170101711017210173101741017510176101771017810179101801018110182101831018410185101861018710188101891019010191101921019310194101951019610197101981019910200102011020210203102041020510206102071020810209102101021110212102131021410215102161021710218102191022010221102221022310224102251022610227102281022910230102311023210233102341023510236102371023810239102401024110242102431024410245102461024710248102491025010251102521025310254102551025610257102581025910260102611026210263102641026510266102671026810269102701027110272102731027410275102761027710278102791028010281102821028310284102851028610287102881028910290102911029210293102941029510296102971029810299103001030110302103031030410305103061030710308103091031010311103121031310314103151031610317103181031910320103211032210323103241032510326103271032810329103301033110332103331033410335103361033710338103391034010341103421034310344103451034610347103481034910350103511035210353103541035510356103571035810359103601036110362103631036410365103661036710368103691037010371103721037310374103751037610377103781037910380103811038210383103841038510386103871038810389103901039110392103931039410395103961039710398103991040010401104021040310404104051040610407104081040910410104111041210413104141041510416104171041810419104201042110422104231042410425104261042710428104291043010431104321043310434104351043610437104381043910440104411044210443104441044510446104471044810449104501045110452104531045410455104561045710458104591046010461104621046310464104651046610467104681046910470104711047210473104741047510476104771047810479104801048110482104831048410485104861048710488104891049010491104921049310494104951049610497104981049910500105011050210503105041050510506105071050810509105101051110512105131051410515105161051710518105191052010521105221052310524105251052610527105281052910530105311053210533105341053510536105371053810539105401054110542105431054410545105461054710548105491055010551105521055310554105551055610557105581055910560105611056210563105641056510566105671056810569105701057110572105731057410575105761057710578105791058010581105821058310584105851058610587105881058910590105911059210593105941059510596105971059810599106001060110602106031060410605106061060710608106091061010611106121061310614106151061610617106181061910620106211062210623106241062510626106271062810629106301063110632106331063410635106361063710638106391064010641106421064310644106451064610647106481064910650106511065210653106541065510656106571065810659106601066110662106631066410665106661066710668106691067010671106721067310674106751067610677106781067910680106811068210683106841068510686106871068810689106901069110692106931069410695106961069710698106991070010701107021070310704107051070610707107081070910710107111071210713107141071510716107171071810719107201072110722107231072410725107261072710728107291073010731107321073310734107351073610737107381073910740107411074210743107441074510746107471074810749107501075110752107531075410755107561075710758107591076010761107621076310764107651076610767107681076910770107711077210773107741077510776107771077810779107801078110782107831078410785107861078710788107891079010791107921079310794107951079610797107981079910800108011080210803108041080510806108071080810809108101081110812108131081410815108161081710818108191082010821108221082310824108251082610827108281082910830108311083210833108341083510836108371083810839108401084110842108431084410845108461084710848108491085010851108521085310854108551085610857108581085910860108611086210863108641086510866108671086810869108701087110872108731087410875108761087710878108791088010881108821088310884108851088610887108881088910890108911089210893108941089510896108971089810899109001090110902109031090410905109061090710908109091091010911109121091310914109151091610917109181091910920109211092210923109241092510926109271092810929109301093110932109331093410935109361093710938109391094010941109421094310944109451094610947109481094910950109511095210953109541095510956109571095810959109601096110962109631096410965109661096710968109691097010971109721097310974109751097610977109781097910980109811098210983109841098510986109871098810989109901099110992109931099410995109961099710998109991100011001110021100311004110051100611007110081100911010110111101211013110141101511016110171101811019110201102111022110231102411025110261102711028110291103011031110321103311034110351103611037110381103911040110411104211043110441104511046110471104811049110501105111052110531105411055110561105711058110591106011061110621106311064110651106611067110681106911070110711107211073110741107511076110771107811079110801108111082110831108411085110861108711088110891109011091110921109311094110951109611097110981109911100111011110211103111041110511106111071110811109111101111111112111131111411115111161111711118111191112011121111221112311124111251112611127111281112911130111311113211133111341113511136111371113811139111401114111142111431114411145111461114711148111491115011151111521115311154111551115611157111581115911160111611116211163111641116511166111671116811169111701117111172111731117411175111761117711178111791118011181111821118311184111851118611187111881118911190111911119211193111941119511196111971119811199112001120111202112031120411205112061120711208112091121011211112121121311214112151121611217112181121911220112211122211223112241122511226112271122811229112301123111232112331123411235112361123711238112391124011241112421124311244112451124611247112481124911250112511125211253112541125511256112571125811259112601126111262112631126411265112661126711268112691127011271112721127311274112751127611277112781127911280112811128211283112841128511286112871128811289112901129111292112931129411295112961129711298112991130011301113021130311304113051130611307113081130911310113111131211313113141131511316113171131811319113201132111322113231132411325113261132711328113291133011331113321133311334113351133611337113381133911340113411134211343113441134511346113471134811349113501135111352113531135411355113561135711358113591136011361113621136311364113651136611367113681136911370113711137211373113741137511376113771137811379113801138111382113831138411385113861138711388113891139011391113921139311394113951139611397113981139911400
  1. {
  2. Adaption of the delphi3d.net OpenGL units to FreePascal
  3. Sebastian Guenther ([email protected]) in 2002
  4. These units are free to use
  5. }
  6. {$MACRO ON}
  7. {$MODE Delphi}
  8. {$IFDEF Windows}
  9. {$DEFINE extdecl:=stdcall }
  10. {$ELSE}
  11. {$DEFINE extdecl:=cdecl }
  12. {$ENDIF}
  13. unit GLext;
  14. (**************************************************
  15. * OpenGL extension loading library *
  16. * Generated by MetaGLext, written by Tom Nuydens *
  17. * ([email protected] -- http://www.delphi3d.net *
  18. **************************************************)
  19. //*** Generated on 10/11/2002
  20. interface
  21. uses
  22. SysUtils,
  23. {$IFDEF Windows}
  24. Windows,
  25. {$ELSE}
  26. dynlibs,
  27. {$ENDIF}
  28. GL;
  29. {$IFDEF Windows}
  30. { Declared in Windows unit as well in FPC; but declared here as well, to be
  31. fully compatible to upstream version - sg }
  32. function wglGetProcAddress(proc: PChar): Pointer; extdecl; external 'OpenGL32.dll';
  33. {$ELSE}
  34. function wglGetProcAddress(proc: PChar): Pointer;
  35. {$ENDIF}
  36. // Test if the given extension name is present in the given extension string.
  37. function glext_ExtensionSupported(const extension: String; const searchIn: String): Boolean;
  38. // Load the extension with the given name.
  39. function glext_LoadExtension(ext: String): Boolean;
  40. type
  41. GLcharARB = Char;
  42. TGLcharARB = GLcharARB;
  43. PGLcharARB = ^GLcharARB;
  44. PPGLchar = ^PGLchar;
  45. {$ifdef DARWIN}
  46. GLHandleARB = Pointer; // defined as void * in OpenGL.framework/glext.h
  47. {$else}
  48. GLhandleARB = Cardinal;
  49. {$endif}
  50. TGLhandleARB = GLhandleARB;
  51. PGLhandleARB = ^GLhandleARB;
  52. GLintptr = PtrInt;
  53. TGLintptr = GLintptr;
  54. PGLintptr = ^GLintptr;
  55. GLsizeiptr = PtrInt;
  56. TGLsizeiptr = GLsizeiptr;
  57. PGLsizeiptr = ^GLsizeiptr;
  58. GLchar = Char;
  59. TGLchar = GLchar;
  60. PGLchar = Pchar;
  61. GLint64 = Int64;
  62. TGLint64 = GLint64;
  63. PGLint64 = ^GLint64;
  64. GLuint64 = QWord;
  65. TGLuint64 = GLuint64;
  66. PGLuint64 = ^GLuint64;
  67. //***** GL_version_1_2 *****//
  68. const
  69. GL_UNSIGNED_BYTE_3_3_2 = $8032;
  70. GL_UNSIGNED_SHORT_4_4_4_4 = $8033;
  71. GL_UNSIGNED_SHORT_5_5_5_1 = $8034;
  72. GL_UNSIGNED_INT_8_8_8_8 = $8035;
  73. GL_UNSIGNED_INT_10_10_10_2 = $8036;
  74. GL_RESCALE_NORMAL = $803A;
  75. GL_UNSIGNED_BYTE_2_3_3_REV = $8362;
  76. GL_UNSIGNED_SHORT_5_6_5 = $8363;
  77. GL_UNSIGNED_SHORT_5_6_5_REV = $8364;
  78. GL_UNSIGNED_SHORT_4_4_4_4_REV = $8365;
  79. GL_UNSIGNED_SHORT_1_5_5_5_REV = $8366;
  80. GL_UNSIGNED_INT_8_8_8_8_REV = $8367;
  81. GL_UNSIGNED_INT_2_10_10_10_REV = $8368;
  82. GL_BGR = $80E0;
  83. GL_BGRA = $80E1;
  84. GL_MAX_ELEMENTS_VERTICES = $80E8;
  85. GL_MAX_ELEMENTS_INDICES = $80E9;
  86. GL_CLAMP_TO_EDGE = $812F;
  87. GL_TEXTURE_MIN_LOD = $813A;
  88. GL_TEXTURE_MAX_LOD = $813B;
  89. GL_TEXTURE_BASE_LEVEL = $813C;
  90. GL_TEXTURE_MAX_LEVEL = $813D;
  91. GL_LIGHT_MODEL_COLOR_CONTROL = $81F8;
  92. GL_SINGLE_COLOR = $81F9;
  93. GL_SEPARATE_SPECULAR_COLOR = $81FA;
  94. GL_SMOOTH_POINT_SIZE_RANGE = $0B12;
  95. GL_SMOOTH_POINT_SIZE_GRANULARITY = $0B13;
  96. GL_SMOOTH_LINE_WIDTH_RANGE = $0B22;
  97. GL_SMOOTH_LINE_WIDTH_GRANULARITY = $0B23;
  98. GL_ALIASED_POINT_SIZE_RANGE = $846D;
  99. GL_ALIASED_LINE_WIDTH_RANGE = $846E;
  100. GL_PACK_SKIP_IMAGES = $806B;
  101. GL_PACK_IMAGE_HEIGHT = $806C;
  102. GL_UNPACK_SKIP_IMAGES = $806D;
  103. GL_UNPACK_IMAGE_HEIGHT = $806E;
  104. GL_TEXTURE_3D = $806F;
  105. GL_PROXY_TEXTURE_3D = $8070;
  106. GL_TEXTURE_DEPTH = $8071;
  107. GL_TEXTURE_WRAP_R = $8072;
  108. GL_MAX_3D_TEXTURE_SIZE = $8073;
  109. var
  110. glBlendColor: procedure(red: GLclampf; green: GLclampf; blue: GLclampf; alpha: GLclampf); extdecl;
  111. glBlendEquation: procedure(mode: GLenum); extdecl;
  112. glDrawRangeElements: procedure(mode: GLenum; start: GLuint; _end: GLuint; count: GLsizei; _type: GLenum; const indices: PGLvoid); extdecl;
  113. glColorTable: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; format: GLenum; _type: GLenum; const table: PGLvoid); extdecl;
  114. glColorTableParameterfv: procedure(target: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  115. glColorTableParameteriv: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  116. glCopyColorTable: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei); extdecl;
  117. glGetColorTable: procedure(target: GLenum; format: GLenum; _type: GLenum; table: PGLvoid); extdecl;
  118. glGetColorTableParameterfv: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  119. glGetColorTableParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  120. glColorSubTable: procedure(target: GLenum; start: GLsizei; count: GLsizei; format: GLenum; _type: GLenum; const data: PGLvoid); extdecl;
  121. glCopyColorSubTable: procedure(target: GLenum; start: GLsizei; x: GLint; y: GLint; width: GLsizei); extdecl;
  122. glConvolutionFilter1D: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; format: GLenum; _type: GLenum; const image: PGLvoid); extdecl;
  123. glConvolutionFilter2D: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei; format: GLenum; _type: GLenum; const image: PGLvoid); extdecl;
  124. glConvolutionParameterf: procedure(target: GLenum; pname: GLenum; params: GLfloat); extdecl;
  125. glConvolutionParameterfv: procedure(target: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  126. glConvolutionParameteri: procedure(target: GLenum; pname: GLenum; params: GLint); extdecl;
  127. glConvolutionParameteriv: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  128. glCopyConvolutionFilter1D: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei); extdecl;
  129. glCopyConvolutionFilter2D: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei; height: GLsizei); extdecl;
  130. glGetConvolutionFilter: procedure(target: GLenum; format: GLenum; _type: GLenum; image: PGLvoid); extdecl;
  131. glGetConvolutionParameterfv: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  132. glGetConvolutionParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  133. glGetSeparableFilter: procedure(target: GLenum; format: GLenum; _type: GLenum; row: PGLvoid; column: PGLvoid; span: PGLvoid); extdecl;
  134. glSeparableFilter2D: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei; format: GLenum; _type: GLenum; const row: PGLvoid; const column: PGLvoid); extdecl;
  135. glGetHistogram: procedure(target: GLenum; reset: GLboolean; format: GLenum; _type: GLenum; values: PGLvoid); extdecl;
  136. glGetHistogramParameterfv: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  137. glGetHistogramParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  138. glGetMinmax: procedure(target: GLenum; reset: GLboolean; format: GLenum; _type: GLenum; values: PGLvoid); extdecl;
  139. glGetMinmaxParameterfv: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  140. glGetMinmaxParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  141. glHistogram: procedure(target: GLenum; width: GLsizei; internalformat: GLenum; sink: GLboolean); extdecl;
  142. glMinmax: procedure(target: GLenum; internalformat: GLenum; sink: GLboolean); extdecl;
  143. glResetHistogram: procedure(target: GLenum); extdecl;
  144. glResetMinmax: procedure(target: GLenum); extdecl;
  145. glTexImage3D: procedure(target: GLenum; level: GLint; internalformat: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; border: GLint; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  146. glTexSubImage3D: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; zoffset: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  147. glCopyTexSubImage3D: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; zoffset: GLint; x: GLint; y: GLint; width: GLsizei; height: GLsizei); extdecl;
  148. function Load_GL_version_1_2: Boolean;
  149. //***** GL_ARB_imaging *****//
  150. const
  151. GL_CONSTANT_COLOR = $8001;
  152. GL_ONE_MINUS_CONSTANT_COLOR = $8002;
  153. GL_CONSTANT_ALPHA = $8003;
  154. GL_ONE_MINUS_CONSTANT_ALPHA = $8004;
  155. GL_BLEND_COLOR = $8005;
  156. GL_FUNC_ADD = $8006;
  157. GL_MIN = $8007;
  158. GL_MAX = $8008;
  159. GL_BLEND_EQUATION = $8009;
  160. GL_FUNC_SUBTRACT = $800A;
  161. GL_FUNC_REVERSE_SUBTRACT = $800B;
  162. GL_CONVOLUTION_1D = $8010;
  163. GL_CONVOLUTION_2D = $8011;
  164. GL_SEPARABLE_2D = $8012;
  165. GL_CONVOLUTION_BORDER_MODE = $8013;
  166. GL_CONVOLUTION_FILTER_SCALE = $8014;
  167. GL_CONVOLUTION_FILTER_BIAS = $8015;
  168. GL_REDUCE = $8016;
  169. GL_CONVOLUTION_FORMAT = $8017;
  170. GL_CONVOLUTION_WIDTH = $8018;
  171. GL_CONVOLUTION_HEIGHT = $8019;
  172. GL_MAX_CONVOLUTION_WIDTH = $801A;
  173. GL_MAX_CONVOLUTION_HEIGHT = $801B;
  174. GL_POST_CONVOLUTION_RED_SCALE = $801C;
  175. GL_POST_CONVOLUTION_GREEN_SCALE = $801D;
  176. GL_POST_CONVOLUTION_BLUE_SCALE = $801E;
  177. GL_POST_CONVOLUTION_ALPHA_SCALE = $801F;
  178. GL_POST_CONVOLUTION_RED_BIAS = $8020;
  179. GL_POST_CONVOLUTION_GREEN_BIAS = $8021;
  180. GL_POST_CONVOLUTION_BLUE_BIAS = $8022;
  181. GL_POST_CONVOLUTION_ALPHA_BIAS = $8023;
  182. GL_HISTOGRAM = $8024;
  183. GL_PROXY_HISTOGRAM = $8025;
  184. GL_HISTOGRAM_WIDTH = $8026;
  185. GL_HISTOGRAM_FORMAT = $8027;
  186. GL_HISTOGRAM_RED_SIZE = $8028;
  187. GL_HISTOGRAM_GREEN_SIZE = $8029;
  188. GL_HISTOGRAM_BLUE_SIZE = $802A;
  189. GL_HISTOGRAM_ALPHA_SIZE = $802B;
  190. GL_HISTOGRAM_LUMINANCE_SIZE = $802C;
  191. GL_HISTOGRAM_SINK = $802D;
  192. GL_MINMAX = $802E;
  193. GL_MINMAX_FORMAT = $802F;
  194. GL_MINMAX_SINK = $8030;
  195. GL_TABLE_TOO_LARGE = $8031;
  196. GL_COLOR_MATRIX = $80B1;
  197. GL_COLOR_MATRIX_STACK_DEPTH = $80B2;
  198. GL_MAX_COLOR_MATRIX_STACK_DEPTH = $80B3;
  199. GL_POST_COLOR_MATRIX_RED_SCALE = $80B4;
  200. GL_POST_COLOR_MATRIX_GREEN_SCALE = $80B5;
  201. GL_POST_COLOR_MATRIX_BLUE_SCALE = $80B6;
  202. GL_POST_COLOR_MATRIX_ALPHA_SCALE = $80B7;
  203. GL_POST_COLOR_MATRIX_RED_BIAS = $80B8;
  204. GL_POST_COLOR_MATRIX_GREEN_BIAS = $80B9;
  205. GL_POST_COLOR_MATRIX_BLUE_BIAS = $80BA;
  206. GL_POST_COLOR_MATIX_ALPHA_BIAS = $80BB;
  207. GL_COLOR_TABLE = $80D0;
  208. GL_POST_CONVOLUTION_COLOR_TABLE = $80D1;
  209. GL_POST_COLOR_MATRIX_COLOR_TABLE = $80D2;
  210. GL_PROXY_COLOR_TABLE = $80D3;
  211. GL_PROXY_POST_CONVOLUTION_COLOR_TABLE = $80D4;
  212. GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE = $80D5;
  213. GL_COLOR_TABLE_SCALE = $80D6;
  214. GL_COLOR_TABLE_BIAS = $80D7;
  215. GL_COLOR_TABLE_FORMAT = $80D8;
  216. GL_COLOR_TABLE_WIDTH = $80D9;
  217. GL_COLOR_TABLE_RED_SIZE = $80DA;
  218. GL_COLOR_TABLE_GREEN_SIZE = $80DB;
  219. GL_COLOR_TABLE_BLUE_SIZE = $80DC;
  220. GL_COLOR_TABLE_ALPHA_SIZE = $80DD;
  221. GL_COLOR_TABLE_LUMINANCE_SIZE = $80DE;
  222. GL_COLOR_TABLE_INTENSITY_SIZE = $80DF;
  223. GL_IGNORE_BORDER = $8150;
  224. GL_CONSTANT_BORDER = $8151;
  225. GL_WRAP_BORDER = $8152;
  226. GL_REPLICATE_BORDER = $8153;
  227. GL_CONVOLUTION_BORDER_COLOR = $8154;
  228. function Load_GL_ARB_imaging: Boolean;
  229. //***** GL_version_1_3 *****//
  230. const
  231. GL_TEXTURE0 = $84C0;
  232. GL_TEXTURE1 = $84C1;
  233. GL_TEXTURE2 = $84C2;
  234. GL_TEXTURE3 = $84C3;
  235. GL_TEXTURE4 = $84C4;
  236. GL_TEXTURE5 = $84C5;
  237. GL_TEXTURE6 = $84C6;
  238. GL_TEXTURE7 = $84C7;
  239. GL_TEXTURE8 = $84C8;
  240. GL_TEXTURE9 = $84C9;
  241. GL_TEXTURE10 = $84CA;
  242. GL_TEXTURE11 = $84CB;
  243. GL_TEXTURE12 = $84CC;
  244. GL_TEXTURE13 = $84CD;
  245. GL_TEXTURE14 = $84CE;
  246. GL_TEXTURE15 = $84CF;
  247. GL_TEXTURE16 = $84D0;
  248. GL_TEXTURE17 = $84D1;
  249. GL_TEXTURE18 = $84D2;
  250. GL_TEXTURE19 = $84D3;
  251. GL_TEXTURE20 = $84D4;
  252. GL_TEXTURE21 = $84D5;
  253. GL_TEXTURE22 = $84D6;
  254. GL_TEXTURE23 = $84D7;
  255. GL_TEXTURE24 = $84D8;
  256. GL_TEXTURE25 = $84D9;
  257. GL_TEXTURE26 = $84DA;
  258. GL_TEXTURE27 = $84DB;
  259. GL_TEXTURE28 = $84DC;
  260. GL_TEXTURE29 = $84DD;
  261. GL_TEXTURE30 = $84DE;
  262. GL_TEXTURE31 = $84DF;
  263. GL_ACTIVE_TEXTURE = $84E0;
  264. GL_CLIENT_ACTIVE_TEXTURE = $84E1;
  265. GL_MAX_TEXTURE_UNITS = $84E2;
  266. GL_TRANSPOSE_MODELVIEW_MATRIX = $84E3;
  267. GL_TRANSPOSE_PROJECTION_MATRIX = $84E4;
  268. GL_TRANSPOSE_TEXTURE_MATRIX = $84E5;
  269. GL_TRANSPOSE_COLOR_MATRIX = $84E6;
  270. GL_MULTISAMPLE = $809D;
  271. GL_SAMPLE_ALPHA_TO_COVERAGE = $809E;
  272. GL_SAMPLE_ALPHA_TO_ONE = $809F;
  273. GL_SAMPLE_COVERAGE = $80A0;
  274. GL_SAMPLE_BUFFERS = $80A8;
  275. GL_SAMPLES = $80A9;
  276. GL_SAMPLE_COVERAGE_VALUE = $80AA;
  277. GL_SAMPLE_COVERAGE_INVERT = $80AB;
  278. GL_MULTISAMPLE_BIT = $20000000;
  279. GL_NORMAL_MAP = $8511;
  280. GL_REFLECTION_MAP = $8512;
  281. GL_TEXTURE_CUBE_MAP = $8513;
  282. GL_TEXTURE_BINDING_CUBE_MAP = $8514;
  283. GL_TEXTURE_CUBE_MAP_POSITIVE_X = $8515;
  284. GL_TEXTURE_CUBE_MAP_NEGATIVE_X = $8516;
  285. GL_TEXTURE_CUBE_MAP_POSITIVE_Y = $8517;
  286. GL_TEXTURE_CUBE_MAP_NEGATIVE_Y = $8518;
  287. GL_TEXTURE_CUBE_MAP_POSITIVE_Z = $8519;
  288. GL_TEXTURE_CUBE_MAP_NEGATIVE_Z = $851A;
  289. GL_PROXY_TEXTURE_CUBE_MAP = $851B;
  290. GL_MAX_CUBE_MAP_TEXTURE_SIZE = $851C;
  291. GL_COMPRESSED_ALPHA = $84E9;
  292. GL_COMPRESSED_LUMINANCE = $84EA;
  293. GL_COMPRESSED_LUMINANCE_ALPHA = $84EB;
  294. GL_COMPRESSED_INTENSITY = $84EC;
  295. GL_COMPRESSED_RGB = $84ED;
  296. GL_COMPRESSED_RGBA = $84EE;
  297. GL_TEXTURE_COMPRESSION_HINT = $84EF;
  298. GL_TEXTURE_COMPRESSED_IMAGE_SIZE = $86A0;
  299. GL_TEXTURE_COMPRESSED = $86A1;
  300. GL_NUM_COMPRESSED_TEXTURE_FORMATS = $86A2;
  301. GL_COMPRESSED_TEXTURE_FORMATS = $86A3;
  302. GL_CLAMP_TO_BORDER = $812D;
  303. GL_CLAMP_TO_BORDER_SGIS = $812D;
  304. GL_COMBINE = $8570;
  305. GL_COMBINE_RGB = $8571;
  306. GL_COMBINE_ALPHA = $8572;
  307. GL_SOURCE0_RGB = $8580;
  308. GL_SOURCE1_RGB = $8581;
  309. GL_SOURCE2_RGB = $8582;
  310. GL_SOURCE0_ALPHA = $8588;
  311. GL_SOURCE1_ALPHA = $8589;
  312. GL_SOURCE2_ALPHA = $858A;
  313. GL_OPERAND0_RGB = $8590;
  314. GL_OPERAND1_RGB = $8591;
  315. GL_OPERAND2_RGB = $8592;
  316. GL_OPERAND0_ALPHA = $8598;
  317. GL_OPERAND1_ALPHA = $8599;
  318. GL_OPERAND2_ALPHA = $859A;
  319. GL_RGB_SCALE = $8573;
  320. GL_ADD_SIGNED = $8574;
  321. GL_INTERPOLATE = $8575;
  322. GL_SUBTRACT = $84E7;
  323. GL_CONSTANT = $8576;
  324. GL_PRIMARY_COLOR = $8577;
  325. GL_PREVIOUS = $8578;
  326. GL_DOT3_RGB = $86AE;
  327. GL_DOT3_RGBA = $86AF;
  328. var
  329. glActiveTexture: procedure(texture: GLenum); extdecl;
  330. glClientActiveTexture: procedure(texture: GLenum); extdecl;
  331. glMultiTexCoord1d: procedure(target: GLenum; s: GLdouble); extdecl;
  332. glMultiTexCoord1dv: procedure(target: GLenum; const v: PGLdouble); extdecl;
  333. glMultiTexCoord1f: procedure(target: GLenum; s: GLfloat); extdecl;
  334. glMultiTexCoord1fv: procedure(target: GLenum; const v: PGLfloat); extdecl;
  335. glMultiTexCoord1i: procedure(target: GLenum; s: GLint); extdecl;
  336. glMultiTexCoord1iv: procedure(target: GLenum; const v: PGLint); extdecl;
  337. glMultiTexCoord1s: procedure(target: GLenum; s: GLshort); extdecl;
  338. glMultiTexCoord1sv: procedure(target: GLenum; const v: PGLshort); extdecl;
  339. glMultiTexCoord2d: procedure(target: GLenum; s: GLdouble; t: GLdouble); extdecl;
  340. glMultiTexCoord2dv: procedure(target: GLenum; const v: PGLdouble); extdecl;
  341. glMultiTexCoord2f: procedure(target: GLenum; s: GLfloat; t: GLfloat); extdecl;
  342. glMultiTexCoord2fv: procedure(target: GLenum; const v: PGLfloat); extdecl;
  343. glMultiTexCoord2i: procedure(target: GLenum; s: GLint; t: GLint); extdecl;
  344. glMultiTexCoord2iv: procedure(target: GLenum; const v: PGLint); extdecl;
  345. glMultiTexCoord2s: procedure(target: GLenum; s: GLshort; t: GLshort); extdecl;
  346. glMultiTexCoord2sv: procedure(target: GLenum; const v: PGLshort); extdecl;
  347. glMultiTexCoord3d: procedure(target: GLenum; s: GLdouble; t: GLdouble; r: GLdouble); extdecl;
  348. glMultiTexCoord3dv: procedure(target: GLenum; const v: PGLdouble); extdecl;
  349. glMultiTexCoord3f: procedure(target: GLenum; s: GLfloat; t: GLfloat; r: GLfloat); extdecl;
  350. glMultiTexCoord3fv: procedure(target: GLenum; const v: PGLfloat); extdecl;
  351. glMultiTexCoord3i: procedure(target: GLenum; s: GLint; t: GLint; r: GLint); extdecl;
  352. glMultiTexCoord3iv: procedure(target: GLenum; const v: PGLint); extdecl;
  353. glMultiTexCoord3s: procedure(target: GLenum; s: GLshort; t: GLshort; r: GLshort); extdecl;
  354. glMultiTexCoord3sv: procedure(target: GLenum; const v: PGLshort); extdecl;
  355. glMultiTexCoord4d: procedure(target: GLenum; s: GLdouble; t: GLdouble; r: GLdouble; q: GLdouble); extdecl;
  356. glMultiTexCoord4dv: procedure(target: GLenum; const v: PGLdouble); extdecl;
  357. glMultiTexCoord4f: procedure(target: GLenum; s: GLfloat; t: GLfloat; r: GLfloat; q: GLfloat); extdecl;
  358. glMultiTexCoord4fv: procedure(target: GLenum; const v: PGLfloat); extdecl;
  359. glMultiTexCoord4i: procedure(target: GLenum; s: GLint; t: GLint; r: GLint; q: GLint); extdecl;
  360. glMultiTexCoord4iv: procedure(target: GLenum; const v: PGLint); extdecl;
  361. glMultiTexCoord4s: procedure(target: GLenum; s: GLshort; t: GLshort; r: GLshort; q: GLshort); extdecl;
  362. glMultiTexCoord4sv: procedure(target: GLenum; const v: PGLshort); extdecl;
  363. glLoadTransposeMatrixf: procedure(const m: PGLfloat); extdecl;
  364. glLoadTransposeMatrixd: procedure(const m: PGLdouble); extdecl;
  365. glMultTransposeMatrixf: procedure(const m: PGLfloat); extdecl;
  366. glMultTransposeMatrixd: procedure(const m: PGLdouble); extdecl;
  367. glSampleCoverage: procedure(value: GLclampf; invert: GLboolean); extdecl;
  368. glCompressedTexImage3D: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; height: GLsizei; depth: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  369. glCompressedTexImage2D: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; height: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  370. glCompressedTexImage1D: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  371. glCompressedTexSubImage3D: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; zoffset: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  372. glCompressedTexSubImage2D: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; width: GLsizei; height: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  373. glCompressedTexSubImage1D: procedure(target: GLenum; level: GLint; xoffset: GLint; width: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  374. glGetCompressedTexImage: procedure(target: GLenum; level: GLint; img: PGLvoid); extdecl;
  375. function Load_GL_version_1_3: Boolean;
  376. //***** GL_ARB_multitexture *****//
  377. const
  378. GL_TEXTURE0_ARB = $84C0;
  379. GL_TEXTURE1_ARB = $84C1;
  380. GL_TEXTURE2_ARB = $84C2;
  381. GL_TEXTURE3_ARB = $84C3;
  382. GL_TEXTURE4_ARB = $84C4;
  383. GL_TEXTURE5_ARB = $84C5;
  384. GL_TEXTURE6_ARB = $84C6;
  385. GL_TEXTURE7_ARB = $84C7;
  386. GL_TEXTURE8_ARB = $84C8;
  387. GL_TEXTURE9_ARB = $84C9;
  388. GL_TEXTURE10_ARB = $84CA;
  389. GL_TEXTURE11_ARB = $84CB;
  390. GL_TEXTURE12_ARB = $84CC;
  391. GL_TEXTURE13_ARB = $84CD;
  392. GL_TEXTURE14_ARB = $84CE;
  393. GL_TEXTURE15_ARB = $84CF;
  394. GL_TEXTURE16_ARB = $84D0;
  395. GL_TEXTURE17_ARB = $84D1;
  396. GL_TEXTURE18_ARB = $84D2;
  397. GL_TEXTURE19_ARB = $84D3;
  398. GL_TEXTURE20_ARB = $84D4;
  399. GL_TEXTURE21_ARB = $84D5;
  400. GL_TEXTURE22_ARB = $84D6;
  401. GL_TEXTURE23_ARB = $84D7;
  402. GL_TEXTURE24_ARB = $84D8;
  403. GL_TEXTURE25_ARB = $84D9;
  404. GL_TEXTURE26_ARB = $84DA;
  405. GL_TEXTURE27_ARB = $84DB;
  406. GL_TEXTURE28_ARB = $84DC;
  407. GL_TEXTURE29_ARB = $84DD;
  408. GL_TEXTURE30_ARB = $84DE;
  409. GL_TEXTURE31_ARB = $84DF;
  410. GL_ACTIVE_TEXTURE_ARB = $84E0;
  411. GL_CLIENT_ACTIVE_TEXTURE_ARB = $84E1;
  412. GL_MAX_TEXTURE_UNITS_ARB = $84E2;
  413. var
  414. glActiveTextureARB: procedure(texture: GLenum); extdecl;
  415. glClientActiveTextureARB: procedure(texture: GLenum); extdecl;
  416. glMultiTexCoord1dARB: procedure(target: GLenum; s: GLdouble); extdecl;
  417. glMultiTexCoord1dvARB: procedure(target: GLenum; const v: PGLdouble); extdecl;
  418. glMultiTexCoord1fARB: procedure(target: GLenum; s: GLfloat); extdecl;
  419. glMultiTexCoord1fvARB: procedure(target: GLenum; const v: PGLfloat); extdecl;
  420. glMultiTexCoord1iARB: procedure(target: GLenum; s: GLint); extdecl;
  421. glMultiTexCoord1ivARB: procedure(target: GLenum; const v: PGLint); extdecl;
  422. glMultiTexCoord1sARB: procedure(target: GLenum; s: GLshort); extdecl;
  423. glMultiTexCoord1svARB: procedure(target: GLenum; const v: PGLshort); extdecl;
  424. glMultiTexCoord2dARB: procedure(target: GLenum; s: GLdouble; t: GLdouble); extdecl;
  425. glMultiTexCoord2dvARB: procedure(target: GLenum; const v: PGLdouble); extdecl;
  426. glMultiTexCoord2fARB: procedure(target: GLenum; s: GLfloat; t: GLfloat); extdecl;
  427. glMultiTexCoord2fvARB: procedure(target: GLenum; const v: PGLfloat); extdecl;
  428. glMultiTexCoord2iARB: procedure(target: GLenum; s: GLint; t: GLint); extdecl;
  429. glMultiTexCoord2ivARB: procedure(target: GLenum; const v: PGLint); extdecl;
  430. glMultiTexCoord2sARB: procedure(target: GLenum; s: GLshort; t: GLshort); extdecl;
  431. glMultiTexCoord2svARB: procedure(target: GLenum; const v: PGLshort); extdecl;
  432. glMultiTexCoord3dARB: procedure(target: GLenum; s: GLdouble; t: GLdouble; r: GLdouble); extdecl;
  433. glMultiTexCoord3dvARB: procedure(target: GLenum; const v: PGLdouble); extdecl;
  434. glMultiTexCoord3fARB: procedure(target: GLenum; s: GLfloat; t: GLfloat; r: GLfloat); extdecl;
  435. glMultiTexCoord3fvARB: procedure(target: GLenum; const v: PGLfloat); extdecl;
  436. glMultiTexCoord3iARB: procedure(target: GLenum; s: GLint; t: GLint; r: GLint); extdecl;
  437. glMultiTexCoord3ivARB: procedure(target: GLenum; const v: PGLint); extdecl;
  438. glMultiTexCoord3sARB: procedure(target: GLenum; s: GLshort; t: GLshort; r: GLshort); extdecl;
  439. glMultiTexCoord3svARB: procedure(target: GLenum; const v: PGLshort); extdecl;
  440. glMultiTexCoord4dARB: procedure(target: GLenum; s: GLdouble; t: GLdouble; r: GLdouble; q: GLdouble); extdecl;
  441. glMultiTexCoord4dvARB: procedure(target: GLenum; const v: PGLdouble); extdecl;
  442. glMultiTexCoord4fARB: procedure(target: GLenum; s: GLfloat; t: GLfloat; r: GLfloat; q: GLfloat); extdecl;
  443. glMultiTexCoord4fvARB: procedure(target: GLenum; const v: PGLfloat); extdecl;
  444. glMultiTexCoord4iARB: procedure(target: GLenum; s: GLint; t: GLint; r: GLint; q: GLint); extdecl;
  445. glMultiTexCoord4ivARB: procedure(target: GLenum; const v: PGLint); extdecl;
  446. glMultiTexCoord4sARB: procedure(target: GLenum; s: GLshort; t: GLshort; r: GLshort; q: GLshort); extdecl;
  447. glMultiTexCoord4svARB: procedure(target: GLenum; const v: PGLshort); extdecl;
  448. function Load_GL_ARB_multitexture: Boolean;
  449. //***** GL_ARB_transpose_matrix *****//
  450. const
  451. GL_TRANSPOSE_MODELVIEW_MATRIX_ARB = $84E3;
  452. GL_TRANSPOSE_PROJECTION_MATRIX_ARB = $84E4;
  453. GL_TRANSPOSE_TEXTURE_MATRIX_ARB = $84E5;
  454. GL_TRANSPOSE_COLOR_MATRIX_ARB = $84E6;
  455. var
  456. glLoadTransposeMatrixfARB: procedure(m: PGLfloat); extdecl;
  457. glLoadTransposeMatrixdARB: procedure(m: PGLdouble); extdecl;
  458. glMultTransposeMatrixfARB: procedure(m: PGLfloat); extdecl;
  459. glMultTransposeMatrixdARB: procedure(m: PGLdouble); extdecl;
  460. function Load_GL_ARB_transpose_matrix: Boolean;
  461. //***** GL_ARB_multisample *****//
  462. const
  463. WGL_SAMPLE_BUFFERS_ARB = $2041;
  464. WGL_SAMPLES_ARB = $2042;
  465. GL_MULTISAMPLE_ARB = $809D;
  466. GL_SAMPLE_ALPHA_TO_COVERAGE_ARB = $809E;
  467. GL_SAMPLE_ALPHA_TO_ONE_ARB = $809F;
  468. GL_SAMPLE_COVERAGE_ARB = $80A0;
  469. GL_MULTISAMPLE_BIT_ARB = $20000000;
  470. GL_SAMPLE_BUFFERS_ARB = $80A8;
  471. GL_SAMPLES_ARB = $80A9;
  472. GL_SAMPLE_COVERAGE_VALUE_ARB = $80AA;
  473. GL_SAMPLE_COVERAGE_INVERT_ARB = $80AB;
  474. var
  475. glSampleCoverageARB: procedure(value: GLclampf; invert: GLboolean); extdecl;
  476. function Load_GL_ARB_multisample: Boolean;
  477. //***** GL_ARB_texture_env_add *****//
  478. function Load_GL_ARB_texture_env_add: Boolean;
  479. {$IFDEF Windows}
  480. //***** WGL_ARB_extensions_string *****//
  481. var
  482. wglGetExtensionsStringARB: function(hdc: HDC): Pchar; extdecl;
  483. function Load_WGL_ARB_extensions_string: Boolean;
  484. //***** WGL_ARB_buffer_region *****//
  485. const
  486. WGL_FRONT_COLOR_BUFFER_BIT_ARB = $0001;
  487. WGL_BACK_COLOR_BUFFER_BIT_ARB = $0002;
  488. WGL_DEPTH_BUFFER_BIT_ARB = $0004;
  489. WGL_STENCIL_BUFFER_BIT_ARB = $0008;
  490. var
  491. wglCreateBufferRegionARB: function(hDC: HDC; iLayerPlane: GLint; uType: GLuint): THandle; extdecl;
  492. wglDeleteBufferRegionARB: procedure(hRegion: THandle); extdecl;
  493. wglSaveBufferRegionARB: function(hRegion: THandle; x: GLint; y: GLint; width: GLint; height: GLint): BOOL; extdecl;
  494. wglRestoreBufferRegionARB: function(hRegion: THandle; x: GLint; y: GLint; width: GLint; height: GLint; xSrc: GLint; ySrc: GLint): BOOL; extdecl;
  495. function Load_WGL_ARB_buffer_region: Boolean;
  496. {$ENDIF}
  497. //***** GL_ARB_texture_cube_map *****//
  498. const
  499. GL_NORMAL_MAP_ARB = $8511;
  500. GL_REFLECTION_MAP_ARB = $8512;
  501. GL_TEXTURE_CUBE_MAP_ARB = $8513;
  502. GL_TEXTURE_BINDING_CUBE_MAP_ARB = $8514;
  503. GL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB = $8515;
  504. GL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB = $8516;
  505. GL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB = $8517;
  506. GL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB = $8518;
  507. GL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB = $8519;
  508. GL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB = $851A;
  509. GL_PROXY_TEXTURE_CUBE_MAP_ARB = $851B;
  510. GL_MAX_CUBE_MAP_TEXTURE_SIZE_ARB = $851C;
  511. function Load_GL_ARB_texture_cube_map: Boolean;
  512. //***** GL_ARB_depth_texture *****//
  513. const
  514. GL_DEPTH_COMPONENT16_ARB = $81A5;
  515. GL_DEPTH_COMPONENT24_ARB = $81A6;
  516. GL_DEPTH_COMPONENT32_ARB = $81A7;
  517. GL_TEXTURE_DEPTH_SIZE_ARB = $884A;
  518. GL_DEPTH_TEXTURE_MODE_ARB = $884B;
  519. function Load_GL_ARB_depth_texture: Boolean;
  520. //***** GL_ARB_point_parameters *****//
  521. const
  522. GL_POINT_SIZE_MIN_ARB = $8126;
  523. GL_POINT_SIZE_MAX_ARB = $8127;
  524. GL_POINT_FADE_THRESHOLD_SIZE_ARB = $8128;
  525. GL_POINT_DISTANCE_ATTENUATION_ARB = $8129;
  526. var
  527. glPointParameterfARB: procedure(pname: GLenum; param: GLfloat); extdecl;
  528. glPointParameterfvARB: procedure(pname: GLenum; params: PGLfloat); extdecl;
  529. function Load_GL_ARB_point_parameters: Boolean;
  530. //***** GL_ARB_shadow *****//
  531. const
  532. GL_TEXTURE_COMPARE_MODE_ARB = $884C;
  533. GL_TEXTURE_COMPARE_FUNC_ARB = $884D;
  534. GL_COMPARE_R_TO_TEXTURE_ARB = $884E;
  535. function Load_GL_ARB_shadow: Boolean;
  536. //***** GL_ARB_shadow_ambient *****//
  537. const
  538. GL_TEXTURE_COMPARE_FAIL_VALUE_ARB = $80BF;
  539. function Load_GL_ARB_shadow_ambient: Boolean;
  540. //***** GL_ARB_texture_border_clamp *****//
  541. const
  542. GL_CLAMP_TO_BORDER_ARB = $812D;
  543. function Load_GL_ARB_texture_border_clamp: Boolean;
  544. //***** GL_ARB_texture_compression *****//
  545. const
  546. GL_COMPRESSED_ALPHA_ARB = $84E9;
  547. GL_COMPRESSED_LUMINANCE_ARB = $84EA;
  548. GL_COMPRESSED_LUMINANCE_ALPHA_ARB = $84EB;
  549. GL_COMPRESSED_INTENSITY_ARB = $84EC;
  550. GL_COMPRESSED_RGB_ARB = $84ED;
  551. GL_COMPRESSED_RGBA_ARB = $84EE;
  552. GL_TEXTURE_COMPRESSION_HINT_ARB = $84EF;
  553. GL_TEXTURE_COMPRESSED_IMAGE_SIZE_ARB = $86A0;
  554. GL_TEXTURE_COMPRESSED_ARB = $86A1;
  555. GL_NUM_COMPRESSED_TEXTURE_FORMATS_ARB = $86A2;
  556. GL_COMPRESSED_TEXTURE_FORMATS_ARB = $86A3;
  557. var
  558. glCompressedTexImage3DARB: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; height: GLsizei; depth: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  559. glCompressedTexImage2DARB: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; height: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  560. glCompressedTexImage1DARB: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; border: GLint; imageSize: GLsizei; const data: PGLvoid); extdecl;
  561. glCompressedTexSubImage3DARB: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; zoffset: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  562. glCompressedTexSubImage2DARB: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; width: GLsizei; height: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  563. glCompressedTexSubImage1DARB: procedure(target: GLenum; level: GLint; xoffset: GLint; width: GLsizei; format: GLenum; imageSize: GLsizei; const data: PGLvoid); extdecl;
  564. glGetCompressedTexImageARB: procedure(target: GLenum; lod: GLint; img: PGLvoid); extdecl;
  565. function Load_GL_ARB_texture_compression: Boolean;
  566. //***** GL_ARB_texture_env_combine *****//
  567. const
  568. GL_COMBINE_ARB = $8570;
  569. GL_COMBINE_RGB_ARB = $8571;
  570. GL_COMBINE_ALPHA_ARB = $8572;
  571. GL_SOURCE0_RGB_ARB = $8580;
  572. GL_SOURCE1_RGB_ARB = $8581;
  573. GL_SOURCE2_RGB_ARB = $8582;
  574. GL_SOURCE0_ALPHA_ARB = $8588;
  575. GL_SOURCE1_ALPHA_ARB = $8589;
  576. GL_SOURCE2_ALPHA_ARB = $858A;
  577. GL_OPERAND0_RGB_ARB = $8590;
  578. GL_OPERAND1_RGB_ARB = $8591;
  579. GL_OPERAND2_RGB_ARB = $8592;
  580. GL_OPERAND0_ALPHA_ARB = $8598;
  581. GL_OPERAND1_ALPHA_ARB = $8599;
  582. GL_OPERAND2_ALPHA_ARB = $859A;
  583. GL_RGB_SCALE_ARB = $8573;
  584. GL_ADD_SIGNED_ARB = $8574;
  585. GL_INTERPOLATE_ARB = $8575;
  586. GL_SUBTRACT_ARB = $84E7;
  587. GL_CONSTANT_ARB = $8576;
  588. GL_PRIMARY_COLOR_ARB = $8577;
  589. GL_PREVIOUS_ARB = $8578;
  590. function Load_GL_ARB_texture_env_combine: Boolean;
  591. //***** GL_ARB_texture_env_crossbar *****//
  592. function Load_GL_ARB_texture_env_crossbar: Boolean;
  593. //***** GL_ARB_texture_env_dot3 *****//
  594. const
  595. GL_DOT3_RGB_ARB = $86AE;
  596. GL_DOT3_RGBA_ARB = $86AF;
  597. function Load_GL_ARB_texture_env_dot3: Boolean;
  598. //***** GL_ARB_texture_mirrored_repeat *****//
  599. const
  600. GL_MIRRORED_REPEAT_ARB = $8370;
  601. function Load_GL_ARB_texture_mirrored_repeat: Boolean;
  602. //***** GL_ARB_vertex_blend *****//
  603. const
  604. GL_MAX_VERTEX_UNITS_ARB = $86A4;
  605. GL_ACTIVE_VERTEX_UNITS_ARB = $86A5;
  606. GL_WEIGHT_SUM_UNITY_ARB = $86A6;
  607. GL_VERTEX_BLEND_ARB = $86A7;
  608. GL_MODELVIEW0_ARB = $1700;
  609. GL_MODELVIEW1_ARB = $850A;
  610. GL_MODELVIEW2_ARB = $8722;
  611. GL_MODELVIEW3_ARB = $8723;
  612. GL_MODELVIEW4_ARB = $8724;
  613. GL_MODELVIEW5_ARB = $8725;
  614. GL_MODELVIEW6_ARB = $8726;
  615. GL_MODELVIEW7_ARB = $8727;
  616. GL_MODELVIEW8_ARB = $8728;
  617. GL_MODELVIEW9_ARB = $8729;
  618. GL_MODELVIEW10_ARB = $872A;
  619. GL_MODELVIEW11_ARB = $872B;
  620. GL_MODELVIEW12_ARB = $872C;
  621. GL_MODELVIEW13_ARB = $872D;
  622. GL_MODELVIEW14_ARB = $872E;
  623. GL_MODELVIEW15_ARB = $872F;
  624. GL_MODELVIEW16_ARB = $8730;
  625. GL_MODELVIEW17_ARB = $8731;
  626. GL_MODELVIEW18_ARB = $8732;
  627. GL_MODELVIEW19_ARB = $8733;
  628. GL_MODELVIEW20_ARB = $8734;
  629. GL_MODELVIEW21_ARB = $8735;
  630. GL_MODELVIEW22_ARB = $8736;
  631. GL_MODELVIEW23_ARB = $8737;
  632. GL_MODELVIEW24_ARB = $8738;
  633. GL_MODELVIEW25_ARB = $8739;
  634. GL_MODELVIEW26_ARB = $873A;
  635. GL_MODELVIEW27_ARB = $873B;
  636. GL_MODELVIEW28_ARB = $873C;
  637. GL_MODELVIEW29_ARB = $873D;
  638. GL_MODELVIEW30_ARB = $873E;
  639. GL_MODELVIEW31_ARB = $873F;
  640. GL_CURRENT_WEIGHT_ARB = $86A8;
  641. GL_WEIGHT_ARRAY_TYPE_ARB = $86A9;
  642. GL_WEIGHT_ARRAY_STRIDE_ARB = $86AA;
  643. GL_WEIGHT_ARRAY_SIZE_ARB = $86AB;
  644. GL_WEIGHT_ARRAY_POINTER_ARB = $86AC;
  645. GL_WEIGHT_ARRAY_ARB = $86AD;
  646. var
  647. glWeightbvARB: procedure(size: GLint; weights: PGLbyte); extdecl;
  648. glWeightsvARB: procedure(size: GLint; weights: PGLshort); extdecl;
  649. glWeightivARB: procedure(size: GLint; weights: PGLint); extdecl;
  650. glWeightfvARB: procedure(size: GLint; weights: PGLfloat); extdecl;
  651. glWeightdvARB: procedure(size: GLint; weights: PGLdouble); extdecl;
  652. glWeightvARB: procedure(size: GLint; weights: PGLdouble); extdecl;
  653. glWeightubvARB: procedure(size: GLint; weights: PGLubyte); extdecl;
  654. glWeightusvARB: procedure(size: GLint; weights: PGLushort); extdecl;
  655. glWeightuivARB: procedure(size: GLint; weights: PGLuint); extdecl;
  656. glWeightPointerARB: procedure(size: GLint; _type: GLenum; stride: GLsizei; pointer: PGLvoid); extdecl;
  657. glVertexBlendARB: procedure(count: GLint); extdecl;
  658. function Load_GL_ARB_vertex_blend: Boolean;
  659. //***** GL_ARB_vertex_program *****//
  660. const
  661. GL_VERTEX_PROGRAM_ARB = $8620;
  662. GL_VERTEX_PROGRAM_POINT_SIZE_ARB = $8642;
  663. GL_VERTEX_PROGRAM_TWO_SIDE_ARB = $8643;
  664. GL_COLOR_SUM_ARB = $8458;
  665. GL_PROGRAM_FORMAT_ASCII_ARB = $8875;
  666. GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB = $8622;
  667. GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB = $8623;
  668. GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB = $8624;
  669. GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB = $8625;
  670. GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB = $886A;
  671. GL_CURRENT_VERTEX_ATTRIB_ARB = $8626;
  672. GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB = $8645;
  673. GL_PROGRAM_LENGTH_ARB = $8627;
  674. GL_PROGRAM_FORMAT_ARB = $8876;
  675. GL_PROGRAM_BINDING_ARB = $8677;
  676. GL_PROGRAM_INSTRUCTIONS_ARB = $88A0;
  677. GL_MAX_PROGRAM_INSTRUCTIONS_ARB = $88A1;
  678. GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB = $88A2;
  679. GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB = $88A3;
  680. GL_PROGRAM_TEMPORARIES_ARB = $88A4;
  681. GL_MAX_PROGRAM_TEMPORARIES_ARB = $88A5;
  682. GL_PROGRAM_NATIVE_TEMPORARIES_ARB = $88A6;
  683. GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB = $88A7;
  684. GL_PROGRAM_PARAMETERS_ARB = $88A8;
  685. GL_MAX_PROGRAM_PARAMETERS_ARB = $88A9;
  686. GL_PROGRAM_NATIVE_PARAMETERS_ARB = $88AA;
  687. GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB = $88AB;
  688. GL_PROGRAM_ATTRIBS_ARB = $88AC;
  689. GL_MAX_PROGRAM_ATTRIBS_ARB = $88AD;
  690. GL_PROGRAM_NATIVE_ATTRIBS_ARB = $88AE;
  691. GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB = $88AF;
  692. GL_PROGRAM_ADDRESS_REGISTERS_ARB = $88B0;
  693. GL_MAX_PROGRAM_ADDRESS_REGISTERS_ARB = $88B1;
  694. GL_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB = $88B2;
  695. GL_MAX_PROGRAM_NATIVE_ADDRESS_REGISTERS_ARB = $88B3;
  696. GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB = $88B4;
  697. GL_MAX_PROGRAM_ENV_PARAMETERS_ARB = $88B5;
  698. GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB = $88B6;
  699. GL_PROGRAM_STRING_ARB = $8628;
  700. GL_PROGRAM_ERROR_POSITION_ARB = $864B;
  701. GL_CURRENT_MATRIX_ARB = $8641;
  702. GL_TRANSPOSE_CURRENT_MATRIX_ARB = $88B7;
  703. GL_CURRENT_MATRIX_STACK_DEPTH_ARB = $8640;
  704. GL_MAX_VERTEX_ATTRIBS_ARB = $8869;
  705. GL_MAX_PROGRAM_MATRICES_ARB = $862F;
  706. GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB = $862E;
  707. GL_PROGRAM_ERROR_STRING_ARB = $8874;
  708. GL_MATRIX0_ARB = $88C0;
  709. GL_MATRIX1_ARB = $88C1;
  710. GL_MATRIX2_ARB = $88C2;
  711. GL_MATRIX3_ARB = $88C3;
  712. GL_MATRIX4_ARB = $88C4;
  713. GL_MATRIX5_ARB = $88C5;
  714. GL_MATRIX6_ARB = $88C6;
  715. GL_MATRIX7_ARB = $88C7;
  716. GL_MATRIX8_ARB = $88C8;
  717. GL_MATRIX9_ARB = $88C9;
  718. GL_MATRIX10_ARB = $88CA;
  719. GL_MATRIX11_ARB = $88CB;
  720. GL_MATRIX12_ARB = $88CC;
  721. GL_MATRIX13_ARB = $88CD;
  722. GL_MATRIX14_ARB = $88CE;
  723. GL_MATRIX15_ARB = $88CF;
  724. GL_MATRIX16_ARB = $88D0;
  725. GL_MATRIX17_ARB = $88D1;
  726. GL_MATRIX18_ARB = $88D2;
  727. GL_MATRIX19_ARB = $88D3;
  728. GL_MATRIX20_ARB = $88D4;
  729. GL_MATRIX21_ARB = $88D5;
  730. GL_MATRIX22_ARB = $88D6;
  731. GL_MATRIX23_ARB = $88D7;
  732. GL_MATRIX24_ARB = $88D8;
  733. GL_MATRIX25_ARB = $88D9;
  734. GL_MATRIX26_ARB = $88DA;
  735. GL_MATRIX27_ARB = $88DB;
  736. GL_MATRIX28_ARB = $88DC;
  737. GL_MATRIX29_ARB = $88DD;
  738. GL_MATRIX30_ARB = $88DE;
  739. GL_MATRIX31_ARB = $88DF;
  740. var
  741. glVertexAttrib1sARB: procedure(index: GLuint; x: GLshort); extdecl;
  742. glVertexAttrib1fARB: procedure(index: GLuint; x: GLfloat); extdecl;
  743. glVertexAttrib1dARB: procedure(index: GLuint; x: GLdouble); extdecl;
  744. glVertexAttrib2sARB: procedure(index: GLuint; x: GLshort; y: GLshort); extdecl;
  745. glVertexAttrib2fARB: procedure(index: GLuint; x: GLfloat; y: GLfloat); extdecl;
  746. glVertexAttrib2dARB: procedure(index: GLuint; x: GLdouble; y: GLdouble); extdecl;
  747. glVertexAttrib3sARB: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort); extdecl;
  748. glVertexAttrib3fARB: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  749. glVertexAttrib3dARB: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  750. glVertexAttrib4sARB: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort; w: GLshort); extdecl;
  751. glVertexAttrib4fARB: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  752. glVertexAttrib4dARB: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  753. glVertexAttrib4NubARB: procedure(index: GLuint; x: GLubyte; y: GLubyte; z: GLubyte; w: GLubyte); extdecl;
  754. glVertexAttrib1svARB: procedure(index: GLuint; const v: PGLshort); extdecl;
  755. glVertexAttrib1fvARB: procedure(index: GLuint; const v: PGLfloat); extdecl;
  756. glVertexAttrib1dvARB: procedure(index: GLuint; const v: PGLdouble); extdecl;
  757. glVertexAttrib2svARB: procedure(index: GLuint; const v: PGLshort); extdecl;
  758. glVertexAttrib2fvARB: procedure(index: GLuint; const v: PGLfloat); extdecl;
  759. glVertexAttrib2dvARB: procedure(index: GLuint; const v: PGLdouble); extdecl;
  760. glVertexAttrib3svARB: procedure(index: GLuint; const v: PGLshort); extdecl;
  761. glVertexAttrib3fvARB: procedure(index: GLuint; const v: PGLfloat); extdecl;
  762. glVertexAttrib3dvARB: procedure(index: GLuint; const v: PGLdouble); extdecl;
  763. glVertexAttrib4bvARB: procedure(index: GLuint; const v: PGLbyte); extdecl;
  764. glVertexAttrib4svARB: procedure(index: GLuint; const v: PGLshort); extdecl;
  765. glVertexAttrib4ivARB: procedure(index: GLuint; const v: PGLint); extdecl;
  766. glVertexAttrib4ubvARB: procedure(index: GLuint; const v: PGLubyte); extdecl;
  767. glVertexAttrib4usvARB: procedure(index: GLuint; const v: PGLushort); extdecl;
  768. glVertexAttrib4uivARB: procedure(index: GLuint; const v: PGLuint); extdecl;
  769. glVertexAttrib4fvARB: procedure(index: GLuint; const v: PGLfloat); extdecl;
  770. glVertexAttrib4dvARB: procedure(index: GLuint; const v: PGLdouble); extdecl;
  771. glVertexAttrib4NbvARB: procedure(index: GLuint; const v: PGLbyte); extdecl;
  772. glVertexAttrib4NsvARB: procedure(index: GLuint; const v: PGLshort); extdecl;
  773. glVertexAttrib4NivARB: procedure(index: GLuint; const v: PGLint); extdecl;
  774. glVertexAttrib4NubvARB: procedure(index: GLuint; const v: PGLubyte); extdecl;
  775. glVertexAttrib4NusvARB: procedure(index: GLuint; const v: PGLushort); extdecl;
  776. glVertexAttrib4NuivARB: procedure(index: GLuint; const v: PGLuint); extdecl;
  777. glVertexAttribPointerARB: procedure(index: GLuint; size: GLint; _type: GLenum; normalized: GLboolean; stride: GLsizei; const pointer: PGLvoid); extdecl;
  778. glEnableVertexAttribArrayARB: procedure(index: GLuint); extdecl;
  779. glDisableVertexAttribArrayARB: procedure(index: GLuint); extdecl;
  780. glProgramStringARB: procedure(target: GLenum; format: GLenum; len: GLsizei; const _string: PGLvoid); extdecl;
  781. glBindProgramARB: procedure(target: GLenum; _program: GLuint); extdecl;
  782. glDeleteProgramsARB: procedure(n: GLsizei; const programs: PGLuint); extdecl;
  783. glGenProgramsARB: procedure(n: GLsizei; programs: PGLuint); extdecl;
  784. glProgramEnvParameter4dARB: procedure(target: GLenum; index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  785. glProgramEnvParameter4dvARB: procedure(target: GLenum; index: GLuint; const params: PGLdouble); extdecl;
  786. glProgramEnvParameter4fARB: procedure(target: GLenum; index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  787. glProgramEnvParameter4fvARB: procedure(target: GLenum; index: GLuint; const params: PGLfloat); extdecl;
  788. glProgramLocalParameter4dARB: procedure(target: GLenum; index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  789. glProgramLocalParameter4dvARB: procedure(target: GLenum; index: GLuint; const params: PGLdouble); extdecl;
  790. glProgramLocalParameter4fARB: procedure(target: GLenum; index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  791. glProgramLocalParameter4fvARB: procedure(target: GLenum; index: GLuint; const params: PGLfloat); extdecl;
  792. glGetProgramEnvParameterdvARB: procedure(target: GLenum; index: GLuint; params: PGLdouble); extdecl;
  793. glGetProgramEnvParameterfvARB: procedure(target: GLenum; index: GLuint; params: PGLfloat); extdecl;
  794. glGetProgramLocalParameterdvARB: procedure(target: GLenum; index: GLuint; params: PGLdouble); extdecl;
  795. glGetProgramLocalParameterfvARB: procedure(target: GLenum; index: GLuint; params: PGLfloat); extdecl;
  796. glGetProgramivARB: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  797. glGetProgramStringARB: procedure(target: GLenum; pname: GLenum; _string: PGLvoid); extdecl;
  798. glGetVertexAttribdvARB: procedure(index: GLuint; pname: GLenum; params: PGLdouble); extdecl;
  799. glGetVertexAttribfvARB: procedure(index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  800. glGetVertexAttribivARB: procedure(index: GLuint; pname: GLenum; params: PGLint); extdecl;
  801. glGetVertexAttribPointervARB: procedure(index: GLuint; pname: GLenum; pointer: PGLvoid); extdecl;
  802. glIsProgramARB: function(_program: GLuint): GLboolean; extdecl;
  803. function Load_GL_ARB_vertex_program: Boolean;
  804. //***** GL_ARB_window_pos *****//
  805. var
  806. glWindowPos2dARB: procedure(x: GLdouble; y: GLdouble); extdecl;
  807. glWindowPos2fARB: procedure(x: GLfloat; y: GLfloat); extdecl;
  808. glWindowPos2iARB: procedure(x: GLint; y: GLint); extdecl;
  809. glWindowPos2sARB: procedure(x: GLshort; y: GLshort); extdecl;
  810. glWindowPos2dvARB: procedure(const p: PGLdouble); extdecl;
  811. glWindowPos2fvARB: procedure(const p: PGLfloat); extdecl;
  812. glWindowPos2ivARB: procedure(const p: PGLint); extdecl;
  813. glWindowPos2svARB: procedure(const p: PGLshort); extdecl;
  814. glWindowPos3dARB: procedure(x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  815. glWindowPos3fARB: procedure(x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  816. glWindowPos3iARB: procedure(x: GLint; y: GLint; z: GLint); extdecl;
  817. glWindowPos3sARB: procedure(x: GLshort; y: GLshort; z: GLshort); extdecl;
  818. glWindowPos3dvARB: procedure(const p: PGLdouble); extdecl;
  819. glWindowPos3fvARB: procedure(const p: PGLfloat); extdecl;
  820. glWindowPos3ivARB: procedure(const p: PGLint); extdecl;
  821. glWindowPos3svARB: procedure(const p: PGLshort); extdecl;
  822. function Load_GL_ARB_window_pos: Boolean;
  823. //***** GL_EXT_422_pixels *****//
  824. const
  825. GL_422_EXT = $80CC;
  826. GL_422_REV_EXT = $80CD;
  827. GL_422_AVERAGE_EXT = $80CE;
  828. GL_422_REV_AVERAGE_EXT = $80CF;
  829. function Load_GL_EXT_422_pixels: Boolean;
  830. //***** GL_EXT_abgr *****//
  831. const
  832. GL_ABGR_EXT = $8000;
  833. function Load_GL_EXT_abgr: Boolean;
  834. //***** GL_EXT_bgra *****//
  835. const
  836. GL_BGR_EXT = $80E0;
  837. GL_BGRA_EXT = $80E1;
  838. function Load_GL_EXT_bgra: Boolean;
  839. //***** GL_EXT_blend_color *****//
  840. const
  841. GL_CONSTANT_COLOR_EXT = $8001;
  842. GL_ONE_MINUS_CONSTANT_COLOR_EXT = $8002;
  843. GL_CONSTANT_ALPHA_EXT = $8003;
  844. GL_ONE_MINUS_CONSTANT_ALPHA_EXT = $8004;
  845. GL_BLEND_COLOR_EXT = $8005;
  846. var
  847. glBlendColorEXT: procedure(red: GLclampf; green: GLclampf; blue: GLclampf; alpha: GLclampf); extdecl;
  848. function Load_GL_EXT_blend_color: Boolean;
  849. //***** GL_EXT_blend_func_separate *****//
  850. const
  851. GL_BLEND_DST_RGB_EXT = $80C8;
  852. GL_BLEND_SRC_RGB_EXT = $80C9;
  853. GL_BLEND_DST_ALPHA_EXT = $80CA;
  854. GL_BLEND_SRC_ALPHA_EXT = $80CB;
  855. var
  856. glBlendFuncSeparateEXT: procedure(sfactorRGB: GLenum; dfactorRGB: GLenum; sfactorAlpha: GLenum; dfactorAlpha: GLenum); extdecl;
  857. function Load_GL_EXT_blend_func_separate: Boolean;
  858. //***** GL_EXT_blend_logic_op *****//
  859. function Load_GL_EXT_blend_logic_op: Boolean;
  860. //***** GL_EXT_blend_minmax *****//
  861. const
  862. GL_FUNC_ADD_EXT = $8006;
  863. GL_MIN_EXT = $8007;
  864. GL_MAX_EXT = $8008;
  865. GL_BLEND_EQUATION_EXT = $8009;
  866. var
  867. glBlendEquationEXT: procedure(mode: GLenum); extdecl;
  868. function Load_GL_EXT_blend_minmax: Boolean;
  869. //***** GL_EXT_blend_subtract *****//
  870. const
  871. GL_FUNC_SUBTRACT_EXT = $800A;
  872. GL_FUNC_REVERSE_SUBTRACT_EXT = $800B;
  873. function Load_GL_EXT_blend_subtract: Boolean;
  874. //***** GL_EXT_clip_volume_hint *****//
  875. const
  876. GL_CLIP_VOLUME_CLIPPING_HINT_EXT = $80F0;
  877. function Load_GL_EXT_clip_volume_hint: Boolean;
  878. //***** GL_EXT_color_subtable *****//
  879. var
  880. glColorSubTableEXT: procedure(target: GLenum; start: GLsizei; count: GLsizei; format: GLenum; _type: GLenum; const data: PGLvoid); extdecl;
  881. glCopyColorSubTableEXT: procedure(target: GLenum; start: GLsizei; x: GLint; y: GLint; width: GLsizei); extdecl;
  882. function Load_GL_EXT_color_subtable: Boolean;
  883. //***** GL_EXT_compiled_vertex_array *****//
  884. const
  885. GL_ARRAY_ELEMENT_LOCK_FIRST_EXT = $81A8;
  886. GL_ARRAY_ELEMENT_LOCK_COUNT_EXT = $81A9;
  887. var
  888. glLockArraysEXT: procedure(first: GLint; count: GLsizei); extdecl;
  889. glUnlockArraysEXT: procedure(); extdecl;
  890. function Load_GL_EXT_compiled_vertex_array: Boolean;
  891. //***** GL_EXT_convolution *****//
  892. const
  893. GL_CONVOLUTION_1D_EXT = $8010;
  894. GL_CONVOLUTION_2D_EXT = $8011;
  895. GL_SEPARABLE_2D_EXT = $8012;
  896. GL_CONVOLUTION_BORDER_MODE_EXT = $8013;
  897. GL_CONVOLUTION_FILTER_SCALE_EXT = $8014;
  898. GL_CONVOLUTION_FILTER_BIAS_EXT = $8015;
  899. GL_REDUCE_EXT = $8016;
  900. GL_CONVOLUTION_FORMAT_EXT = $8017;
  901. GL_CONVOLUTION_WIDTH_EXT = $8018;
  902. GL_CONVOLUTION_HEIGHT_EXT = $8019;
  903. GL_MAX_CONVOLUTION_WIDTH_EXT = $801A;
  904. GL_MAX_CONVOLUTION_HEIGHT_EXT = $801B;
  905. GL_POST_CONVOLUTION_RED_SCALE_EXT = $801C;
  906. GL_POST_CONVOLUTION_GREEN_SCALE_EXT = $801D;
  907. GL_POST_CONVOLUTION_BLUE_SCALE_EXT = $801E;
  908. GL_POST_CONVOLUTION_ALPHA_SCALE_EXT = $801F;
  909. GL_POST_CONVOLUTION_RED_BIAS_EXT = $8020;
  910. GL_POST_CONVOLUTION_GREEN_BIAS_EXT = $8021;
  911. GL_POST_CONVOLUTION_BLUE_BIAS_EXT = $8022;
  912. GL_POST_CONVOLUTION_ALPHA_BIAS_EXT = $8023;
  913. var
  914. glConvolutionFilter1DEXT: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; format: GLenum; _type: GLenum; const image: PGLvoid); extdecl;
  915. glConvolutionFilter2DEXT: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei; format: GLenum; _type: GLenum; const image: PGLvoid); extdecl;
  916. glCopyConvolutionFilter1DEXT: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei); extdecl;
  917. glCopyConvolutionFilter2DEXT: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei; height: GLsizei); extdecl;
  918. glGetConvolutionFilterEXT: procedure(target: GLenum; format: GLenum; _type: GLenum; image: PGLvoid); extdecl;
  919. glSeparableFilter2DEXT: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei; format: GLenum; _type: GLenum; const row: PGLvoid; const column: PGLvoid); extdecl;
  920. glGetSeparableFilterEXT: procedure(target: GLenum; format: GLenum; _type: GLenum; row: PGLvoid; column: PGLvoid; span: PGLvoid); extdecl;
  921. glConvolutionParameteriEXT: procedure(target: GLenum; pname: GLenum; param: GLint); extdecl;
  922. glConvolutionParameterivEXT: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  923. glConvolutionParameterfEXT: procedure(target: GLenum; pname: GLenum; param: GLfloat); extdecl;
  924. glConvolutionParameterfvEXT: procedure(target: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  925. glGetConvolutionParameterivEXT: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  926. glGetConvolutionParameterfvEXT: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  927. function Load_GL_EXT_convolution: Boolean;
  928. //***** GL_EXT_fog_coord *****//
  929. const
  930. GL_FOG_COORDINATE_SOURCE_EXT = $8450;
  931. GL_FOG_COORDINATE_EXT = $8451;
  932. GL_FRAGMENT_DEPTH_EXT = $8452;
  933. GL_CURRENT_FOG_COORDINATE_EXT = $8453;
  934. GL_FOG_COORDINATE_ARRAY_TYPE_EXT = $8454;
  935. GL_FOG_COORDINATE_ARRAY_STRIDE_EXT = $8455;
  936. GL_FOG_COORDINATE_ARRAY_POINTER_EXT = $8456;
  937. GL_FOG_COORDINATE_ARRAY_EXT = $8457;
  938. var
  939. glFogCoordfEXT: procedure(coord: GLfloat); extdecl;
  940. glFogCoorddEXT: procedure(coord: GLdouble); extdecl;
  941. glFogCoordfvEXT: procedure(coord: PGLfloat); extdecl;
  942. glFogCoorddvEXT: procedure(coord: PGLdouble); extdecl;
  943. glFogCoordPointerEXT: procedure(_type: GLenum; stride: GLsizei; pointer: PGLvoid); extdecl;
  944. function Load_GL_EXT_fog_coord: Boolean;
  945. //***** GL_EXT_histogram *****//
  946. const
  947. GL_HISTOGRAM_EXT = $8024;
  948. GL_PROXY_HISTOGRAM_EXT = $8025;
  949. GL_HISTOGRAM_WIDTH_EXT = $8026;
  950. GL_HISTOGRAM_FORMAT_EXT = $8027;
  951. GL_HISTOGRAM_RED_SIZE_EXT = $8028;
  952. GL_HISTOGRAM_GREEN_SIZE_EXT = $8029;
  953. GL_HISTOGRAM_BLUE_SIZE_EXT = $802A;
  954. GL_HISTOGRAM_ALPHA_SIZE_EXT = $802B;
  955. GL_HISTOGRAM_LUMINANCE_SIZE_EXT = $802C;
  956. GL_HISTOGRAM_SINK_EXT = $802D;
  957. GL_MINMAX_EXT = $802E;
  958. GL_MINMAX_FORMAT_EXT = $802F;
  959. GL_MINMAX_SINK_EXT = $8030;
  960. var
  961. glHistogramEXT: procedure(target: GLenum; width: GLsizei; internalformat: GLenum; sink: GLboolean); extdecl;
  962. glResetHistogramEXT: procedure(target: GLenum); extdecl;
  963. glGetHistogramEXT: procedure(target: GLenum; reset: GLboolean; format: GLenum; _type: GLenum; values: PGLvoid); extdecl;
  964. glGetHistogramParameterivEXT: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  965. glGetHistogramParameterfvEXT: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  966. glMinmaxEXT: procedure(target: GLenum; internalformat: GLenum; sink: GLboolean); extdecl;
  967. glResetMinmaxEXT: procedure(target: GLenum); extdecl;
  968. glGetMinmaxEXT: procedure(target: GLenum; reset: GLboolean; format: GLenum; _type: GLenum; values: PGLvoid); extdecl;
  969. glGetMinmaxParameterivEXT: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  970. glGetMinmaxParameterfvEXT: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  971. function Load_GL_EXT_histogram: Boolean;
  972. //***** GL_EXT_multi_draw_arrays *****//
  973. var
  974. glMultiDrawArraysEXT: procedure(mode: GLenum; first: PGLint; count: PGLsizei; primcount: GLsizei); extdecl;
  975. glMultiDrawElementsEXT: procedure(mode: GLenum; count: PGLsizei; _type: GLenum; const indices: PGLvoid; primcount: GLsizei); extdecl;
  976. function Load_GL_EXT_multi_draw_arrays: Boolean;
  977. //***** GL_EXT_packed_depth_stencil *****//
  978. const
  979. GL_DEPTH_STENCIL_EXT = $84F9;
  980. GL_UNSIGNED_INT_24_8_EXT = $84FA;
  981. GL_DEPTH24_STENCIL8_EXT = $88F0;
  982. GL_TEXTURE_STENCIL_SIZE_EXT = $88F1;
  983. function Load_GL_EXT_packed_depth_stencil: Boolean;
  984. //***** GL_EXT_packed_pixels *****//
  985. const
  986. GL_UNSIGNED_BYTE_3_3_2_EXT = $8032;
  987. GL_UNSIGNED_SHORT_4_4_4_4_EXT = $8033;
  988. GL_UNSIGNED_SHORT_5_5_5_1_EXT = $8034;
  989. GL_UNSIGNED_INT_8_8_8_8_EXT = $8035;
  990. GL_UNSIGNED_INT_10_10_10_2_EXT = $8036;
  991. function Load_GL_EXT_packed_pixels: Boolean;
  992. //***** GL_EXT_paletted_texture *****//
  993. const
  994. GL_COLOR_INDEX1_EXT = $80E2;
  995. GL_COLOR_INDEX2_EXT = $80E3;
  996. GL_COLOR_INDEX4_EXT = $80E4;
  997. GL_COLOR_INDEX8_EXT = $80E5;
  998. GL_COLOR_INDEX12_EXT = $80E6;
  999. GL_COLOR_INDEX16_EXT = $80E7;
  1000. GL_COLOR_TABLE_FORMAT_EXT = $80D8;
  1001. GL_COLOR_TABLE_WIDTH_EXT = $80D9;
  1002. GL_COLOR_TABLE_RED_SIZE_EXT = $80DA;
  1003. GL_COLOR_TABLE_GREEN_SIZE_EXT = $80DB;
  1004. GL_COLOR_TABLE_BLUE_SIZE_EXT = $80DC;
  1005. GL_COLOR_TABLE_ALPHA_SIZE_EXT = $80DD;
  1006. GL_COLOR_TABLE_LUMINANCE_SIZE_EXT = $80DE;
  1007. GL_COLOR_TABLE_INTENSITY_SIZE_EXT = $80DF;
  1008. GL_TEXTURE_INDEX_SIZE_EXT = $80ED;
  1009. GL_TEXTURE_1D = $0DE0;
  1010. GL_TEXTURE_2D = $0DE1;
  1011. GL_TEXTURE_3D_EXT = $806F;
  1012. // GL_TEXTURE_CUBE_MAP_ARB { already defined }
  1013. GL_PROXY_TEXTURE_1D = $8063;
  1014. GL_PROXY_TEXTURE_2D = $8064;
  1015. GL_PROXY_TEXTURE_3D_EXT = $8070;
  1016. // GL_PROXY_TEXTURE_CUBE_MAP_ARB { already defined }
  1017. // GL_TEXTURE_1D { already defined }
  1018. // GL_TEXTURE_2D { already defined }
  1019. // GL_TEXTURE_3D_EXT { already defined }
  1020. // GL_TEXTURE_CUBE_MAP_ARB { already defined }
  1021. var
  1022. glColorTableEXT: procedure(target: GLenum; internalFormat: GLenum; width: GLsizei; format: GLenum; _type: GLenum; const data: PGLvoid); extdecl;
  1023. // glColorSubTableEXT { already defined }
  1024. glGetColorTableEXT: procedure(target: GLenum; format: GLenum; _type: GLenum; data: PGLvoid); extdecl;
  1025. glGetColorTableParameterivEXT: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  1026. glGetColorTableParameterfvEXT: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1027. function Load_GL_EXT_paletted_texture: Boolean;
  1028. //***** GL_EXT_point_parameters *****//
  1029. const
  1030. GL_POINT_SIZE_MIN_EXT = $8126;
  1031. GL_POINT_SIZE_MAX_EXT = $8127;
  1032. GL_POINT_FADE_THRESHOLD_SIZE_EXT = $8128;
  1033. GL_DISTANCE_ATTENUATION_EXT = $8129;
  1034. var
  1035. glPointParameterfEXT: procedure(pname: GLenum; param: GLfloat); extdecl;
  1036. glPointParameterfvEXT: procedure(pname: GLenum; params: PGLfloat); extdecl;
  1037. function Load_GL_EXT_point_parameters: Boolean;
  1038. //***** GL_EXT_polygon_offset *****//
  1039. const
  1040. GL_POLYGON_OFFSET_EXT = $8037;
  1041. GL_POLYGON_OFFSET_FACTOR_EXT = $8038;
  1042. GL_POLYGON_OFFSET_BIAS_EXT = $8039;
  1043. var
  1044. glPolygonOffsetEXT: procedure(factor: GLfloat; bias: GLfloat); extdecl;
  1045. function Load_GL_EXT_polygon_offset: Boolean;
  1046. //***** GL_EXT_secondary_color *****//
  1047. const
  1048. GL_COLOR_SUM_EXT = $8458;
  1049. GL_CURRENT_SECONDARY_COLOR_EXT = $8459;
  1050. GL_SECONDARY_COLOR_ARRAY_SIZE_EXT = $845A;
  1051. GL_SECONDARY_COLOR_ARRAY_TYPE_EXT = $845B;
  1052. GL_SECONDARY_COLOR_ARRAY_STRIDE_EXT = $845C;
  1053. GL_SECONDARY_COLOR_ARRAY_POINTER_EXT = $845D;
  1054. GL_SECONDARY_COLOR_ARRAY_EXT = $845E;
  1055. var
  1056. glSecondaryColor3bEXT: procedure(components: GLbyte); extdecl;
  1057. glSecondaryColor3sEXT: procedure(components: GLshort); extdecl;
  1058. glSecondaryColor3iEXT: procedure(components: GLint); extdecl;
  1059. glSecondaryColor3fEXT: procedure(components: GLfloat); extdecl;
  1060. glSecondaryColor3dEXT: procedure(components: GLdouble); extdecl;
  1061. glSecondaryColor3ubEXT: procedure(components: GLubyte); extdecl;
  1062. glSecondaryColor3usEXT: procedure(components: GLushort); extdecl;
  1063. glSecondaryColor3uiEXT: procedure(components: GLuint); extdecl;
  1064. glSecondaryColor3bvEXT: procedure(components: GLbyte); extdecl;
  1065. glSecondaryColor3svEXT: procedure(components: GLshort); extdecl;
  1066. glSecondaryColor3ivEXT: procedure(components: GLint); extdecl;
  1067. glSecondaryColor3fvEXT: procedure(components: GLfloat); extdecl;
  1068. glSecondaryColor3dvEXT: procedure(components: GLdouble); extdecl;
  1069. glSecondaryColor3ubvEXT: procedure(components: GLubyte); extdecl;
  1070. glSecondaryColor3usvEXT: procedure(components: GLushort); extdecl;
  1071. glSecondaryColor3uivEXT: procedure(components: GLuint); extdecl;
  1072. glSecondaryColorPointerEXT: procedure(size: GLint; _type: GLenum; stride: GLsizei; pointer: PGLvoid); extdecl;
  1073. function Load_GL_EXT_secondary_color: Boolean;
  1074. //***** GL_EXT_separate_specular_color *****//
  1075. const
  1076. GL_LIGHT_MODEL_COLOR_CONTROL_EXT = $81F8;
  1077. GL_SINGLE_COLOR_EXT = $81F9;
  1078. GL_SEPARATE_SPECULAR_COLOR_EXT = $81FA;
  1079. function Load_GL_EXT_separate_specular_color: Boolean;
  1080. //***** GL_EXT_shadow_funcs *****//
  1081. function Load_GL_EXT_shadow_funcs: Boolean;
  1082. //***** GL_EXT_shared_texture_palette *****//
  1083. const
  1084. GL_SHARED_TEXTURE_PALETTE_EXT = $81FB;
  1085. function Load_GL_EXT_shared_texture_palette: Boolean;
  1086. //***** GL_EXT_stencil_two_side *****//
  1087. const
  1088. GL_STENCIL_TEST_TWO_SIDE_EXT = $8910;
  1089. GL_ACTIVE_STENCIL_FACE_EXT = $8911;
  1090. var
  1091. glActiveStencilFaceEXT: procedure(face: GLenum); extdecl;
  1092. function Load_GL_EXT_stencil_two_side: Boolean;
  1093. //***** GL_EXT_stencil_wrap *****//
  1094. const
  1095. GL_INCR_WRAP_EXT = $8507;
  1096. GL_DECR_WRAP_EXT = $8508;
  1097. function Load_GL_EXT_stencil_wrap: Boolean;
  1098. //***** GL_EXT_subtexture *****//
  1099. var
  1100. glTexSubImage1DEXT: procedure(target: GLenum; level: GLint; xoffset: GLint; width: GLsizei; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  1101. glTexSubImage2DEXT: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; width: GLsizei; height: GLsizei; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  1102. glTexSubImage3DEXT: procedure(target: GLenum; level: GLint; xoffset: GLint; yoffset: GLint; zoffset: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  1103. function Load_GL_EXT_subtexture: Boolean;
  1104. //***** GL_EXT_texture3D *****//
  1105. const
  1106. GL_PACK_SKIP_IMAGES_EXT = $806B;
  1107. GL_PACK_IMAGE_HEIGHT_EXT = $806C;
  1108. GL_UNPACK_SKIP_IMAGES_EXT = $806D;
  1109. GL_UNPACK_IMAGE_HEIGHT_EXT = $806E;
  1110. // GL_TEXTURE_3D_EXT { already defined }
  1111. // GL_PROXY_TEXTURE_3D_EXT { already defined }
  1112. GL_TEXTURE_DEPTH_EXT = $8071;
  1113. GL_TEXTURE_WRAP_R_EXT = $8072;
  1114. GL_MAX_3D_TEXTURE_SIZE_EXT = $8073;
  1115. var
  1116. glTexImage3DEXT: procedure(target: GLenum; level: GLint; internalformat: GLenum; width: GLsizei; height: GLsizei; depth: GLsizei; border: GLint; format: GLenum; _type: GLenum; const pixels: PGLvoid); extdecl;
  1117. function Load_GL_EXT_texture3D: Boolean;
  1118. //***** GL_EXT_texture_compression_s3tc *****//
  1119. const
  1120. GL_COMPRESSED_RGB_S3TC_DXT1_EXT = $83F0;
  1121. GL_COMPRESSED_RGBA_S3TC_DXT1_EXT = $83F1;
  1122. GL_COMPRESSED_RGBA_S3TC_DXT3_EXT = $83F2;
  1123. GL_COMPRESSED_RGBA_S3TC_DXT5_EXT = $83F3;
  1124. function Load_GL_EXT_texture_compression_s3tc: Boolean;
  1125. //***** GL_EXT_texture_env_add *****//
  1126. function Load_GL_EXT_texture_env_add: Boolean;
  1127. //***** GL_EXT_texture_env_combine *****//
  1128. const
  1129. GL_COMBINE_EXT = $8570;
  1130. GL_COMBINE_RGB_EXT = $8571;
  1131. GL_COMBINE_ALPHA_EXT = $8572;
  1132. GL_SOURCE0_RGB_EXT = $8580;
  1133. GL_SOURCE1_RGB_EXT = $8581;
  1134. GL_SOURCE2_RGB_EXT = $8582;
  1135. GL_SOURCE0_ALPHA_EXT = $8588;
  1136. GL_SOURCE1_ALPHA_EXT = $8589;
  1137. GL_SOURCE2_ALPHA_EXT = $858A;
  1138. GL_OPERAND0_RGB_EXT = $8590;
  1139. GL_OPERAND1_RGB_EXT = $8591;
  1140. GL_OPERAND2_RGB_EXT = $8592;
  1141. GL_OPERAND0_ALPHA_EXT = $8598;
  1142. GL_OPERAND1_ALPHA_EXT = $8599;
  1143. GL_OPERAND2_ALPHA_EXT = $859A;
  1144. GL_RGB_SCALE_EXT = $8573;
  1145. GL_ADD_SIGNED_EXT = $8574;
  1146. GL_INTERPOLATE_EXT = $8575;
  1147. GL_CONSTANT_EXT = $8576;
  1148. GL_PRIMARY_COLOR_EXT = $8577;
  1149. GL_PREVIOUS_EXT = $8578;
  1150. function Load_GL_EXT_texture_env_combine: Boolean;
  1151. //***** GL_EXT_texture_env_dot3 *****//
  1152. const
  1153. GL_DOT3_RGB_EXT = $8740;
  1154. GL_DOT3_RGBA_EXT = $8741;
  1155. function Load_GL_EXT_texture_env_dot3: Boolean;
  1156. //***** GL_EXT_texture_filter_anisotropic *****//
  1157. const
  1158. GL_TEXTURE_MAX_ANISOTROPY_EXT = $84FE;
  1159. GL_MAX_TEXTURE_MAX_ANISOTROPY_EXT = $84FF;
  1160. function Load_GL_EXT_texture_filter_anisotropic: Boolean;
  1161. //***** GL_EXT_texture_lod_bias *****//
  1162. const
  1163. GL_TEXTURE_FILTER_CONTROL_EXT = $8500;
  1164. GL_TEXTURE_LOD_BIAS_EXT = $8501;
  1165. GL_MAX_TEXTURE_LOD_BIAS_EXT = $84FD;
  1166. function Load_GL_EXT_texture_lod_bias: Boolean;
  1167. //***** GL_EXT_texture_object *****//
  1168. const
  1169. GL_TEXTURE_PRIORITY_EXT = $8066;
  1170. GL_TEXTURE_RESIDENT_EXT = $8067;
  1171. GL_TEXTURE_1D_BINDING_EXT = $8068;
  1172. GL_TEXTURE_2D_BINDING_EXT = $8069;
  1173. GL_TEXTURE_3D_BINDING_EXT = $806A;
  1174. var
  1175. glGenTexturesEXT: procedure(n: GLsizei; textures: PGLuint); extdecl;
  1176. glDeleteTexturesEXT: procedure(n: GLsizei; const textures: PGLuint); extdecl;
  1177. glBindTextureEXT: procedure(target: GLenum; texture: GLuint); extdecl;
  1178. glPrioritizeTexturesEXT: procedure(n: GLsizei; const textures: PGLuint; const priorities: PGLclampf); extdecl;
  1179. glAreTexturesResidentEXT: function(n: GLsizei; const textures: PGLuint; residences: PGLboolean): GLboolean; extdecl;
  1180. glIsTextureEXT: function(texture: GLuint): GLboolean; extdecl;
  1181. function Load_GL_EXT_texture_object: Boolean;
  1182. //***** GL_EXT_vertex_array *****//
  1183. const
  1184. GL_VERTEX_ARRAY_EXT = $8074;
  1185. GL_NORMAL_ARRAY_EXT = $8075;
  1186. GL_COLOR_ARRAY_EXT = $8076;
  1187. GL_INDEX_ARRAY_EXT = $8077;
  1188. GL_TEXTURE_COORD_ARRAY_EXT = $8078;
  1189. GL_EDGE_FLAG_ARRAY_EXT = $8079;
  1190. GL_DOUBLE_EXT = $140A;
  1191. GL_VERTEX_ARRAY_SIZE_EXT = $807A;
  1192. GL_VERTEX_ARRAY_TYPE_EXT = $807B;
  1193. GL_VERTEX_ARRAY_STRIDE_EXT = $807C;
  1194. GL_VERTEX_ARRAY_COUNT_EXT = $807D;
  1195. GL_NORMAL_ARRAY_TYPE_EXT = $807E;
  1196. GL_NORMAL_ARRAY_STRIDE_EXT = $807F;
  1197. GL_NORMAL_ARRAY_COUNT_EXT = $8080;
  1198. GL_COLOR_ARRAY_SIZE_EXT = $8081;
  1199. GL_COLOR_ARRAY_TYPE_EXT = $8082;
  1200. GL_COLOR_ARRAY_STRIDE_EXT = $8083;
  1201. GL_COLOR_ARRAY_COUNT_EXT = $8084;
  1202. GL_INDEX_ARRAY_TYPE_EXT = $8085;
  1203. GL_INDEX_ARRAY_STRIDE_EXT = $8086;
  1204. GL_INDEX_ARRAY_COUNT_EXT = $8087;
  1205. GL_TEXTURE_COORD_ARRAY_SIZE_EXT = $8088;
  1206. GL_TEXTURE_COORD_ARRAY_TYPE_EXT = $8089;
  1207. GL_TEXTURE_COORD_ARRAY_STRIDE_EXT = $808A;
  1208. GL_TEXTURE_COORD_ARRAY_COUNT_EXT = $808B;
  1209. GL_EDGE_FLAG_ARRAY_STRIDE_EXT = $808C;
  1210. GL_EDGE_FLAG_ARRAY_COUNT_EXT = $808D;
  1211. GL_VERTEX_ARRAY_POINTER_EXT = $808E;
  1212. GL_NORMAL_ARRAY_POINTER_EXT = $808F;
  1213. GL_COLOR_ARRAY_POINTER_EXT = $8090;
  1214. GL_INDEX_ARRAY_POINTER_EXT = $8091;
  1215. GL_TEXTURE_COORD_ARRAY_POINTER_EXT = $8092;
  1216. GL_EDGE_FLAG_ARRAY_POINTER_EXT = $8093;
  1217. var
  1218. glArrayElementEXT: procedure(i: GLint); extdecl;
  1219. glDrawArraysEXT: procedure(mode: GLenum; first: GLint; count: GLsizei); extdecl;
  1220. glVertexPointerEXT: procedure(size: GLint; _type: GLenum; stride: GLsizei; count: GLsizei; const pointer: PGLvoid); extdecl;
  1221. glNormalPointerEXT: procedure(_type: GLenum; stride: GLsizei; count: GLsizei; const pointer: PGLvoid); extdecl;
  1222. glColorPointerEXT: procedure(size: GLint; _type: GLenum; stride: GLsizei; count: GLsizei; const pointer: PGLvoid); extdecl;
  1223. glIndexPointerEXT: procedure(_type: GLenum; stride: GLsizei; count: GLsizei; const pointer: PGLvoid); extdecl;
  1224. glTexCoordPointerEXT: procedure(size: GLint; _type: GLenum; stride: GLsizei; count: GLsizei; const pointer: PGLvoid); extdecl;
  1225. glEdgeFlagPointerEXT: procedure(stride: GLsizei; count: GLsizei; const pointer: PGLboolean); extdecl;
  1226. glGetPointervEXT: procedure(pname: GLenum; params: PGLvoid); extdecl;
  1227. function Load_GL_EXT_vertex_array: Boolean;
  1228. //***** GL_EXT_vertex_shader *****//
  1229. const
  1230. GL_VERTEX_SHADER_EXT = $8780;
  1231. GL_VARIANT_VALUE_EXT = $87E4;
  1232. GL_VARIANT_DATATYPE_EXT = $87E5;
  1233. GL_VARIANT_ARRAY_STRIDE_EXT = $87E6;
  1234. GL_VARIANT_ARRAY_TYPE_EXT = $87E7;
  1235. GL_VARIANT_ARRAY_EXT = $87E8;
  1236. GL_VARIANT_ARRAY_POINTER_EXT = $87E9;
  1237. GL_INVARIANT_VALUE_EXT = $87EA;
  1238. GL_INVARIANT_DATATYPE_EXT = $87EB;
  1239. GL_LOCAL_CONSTANT_VALUE_EXT = $87EC;
  1240. GL_LOCAL_CONSTANT_DATATYPE_EXT = $87ED;
  1241. GL_OP_INDEX_EXT = $8782;
  1242. GL_OP_NEGATE_EXT = $8783;
  1243. GL_OP_DOT3_EXT = $8784;
  1244. GL_OP_DOT4_EXT = $8785;
  1245. GL_OP_MUL_EXT = $8786;
  1246. GL_OP_ADD_EXT = $8787;
  1247. GL_OP_MADD_EXT = $8788;
  1248. GL_OP_FRAC_EXT = $8789;
  1249. GL_OP_MAX_EXT = $878A;
  1250. GL_OP_MIN_EXT = $878B;
  1251. GL_OP_SET_GE_EXT = $878C;
  1252. GL_OP_SET_LT_EXT = $878D;
  1253. GL_OP_CLAMP_EXT = $878E;
  1254. GL_OP_FLOOR_EXT = $878F;
  1255. GL_OP_ROUND_EXT = $8790;
  1256. GL_OP_EXP_BASE_2_EXT = $8791;
  1257. GL_OP_LOG_BASE_2_EXT = $8792;
  1258. GL_OP_POWER_EXT = $8793;
  1259. GL_OP_RECIP_EXT = $8794;
  1260. GL_OP_RECIP_SQRT_EXT = $8795;
  1261. GL_OP_SUB_EXT = $8796;
  1262. GL_OP_CROSS_PRODUCT_EXT = $8797;
  1263. GL_OP_MULTIPLY_MATRIX_EXT = $8798;
  1264. GL_OP_MOV_EXT = $8799;
  1265. GL_OUTPUT_VERTEX_EXT = $879A;
  1266. GL_OUTPUT_COLOR0_EXT = $879B;
  1267. GL_OUTPUT_COLOR1_EXT = $879C;
  1268. GL_OUTPUT_TEXTURE_COORD0_EXT = $879D;
  1269. GL_OUTPUT_TEXTURE_COORD1_EXT = $879E;
  1270. GL_OUTPUT_TEXTURE_COORD2_EXT = $879F;
  1271. GL_OUTPUT_TEXTURE_COORD3_EXT = $87A0;
  1272. GL_OUTPUT_TEXTURE_COORD4_EXT = $87A1;
  1273. GL_OUTPUT_TEXTURE_COORD5_EXT = $87A2;
  1274. GL_OUTPUT_TEXTURE_COORD6_EXT = $87A3;
  1275. GL_OUTPUT_TEXTURE_COORD7_EXT = $87A4;
  1276. GL_OUTPUT_TEXTURE_COORD8_EXT = $87A5;
  1277. GL_OUTPUT_TEXTURE_COORD9_EXT = $87A6;
  1278. GL_OUTPUT_TEXTURE_COORD10_EXT = $87A7;
  1279. GL_OUTPUT_TEXTURE_COORD11_EXT = $87A8;
  1280. GL_OUTPUT_TEXTURE_COORD12_EXT = $87A9;
  1281. GL_OUTPUT_TEXTURE_COORD13_EXT = $87AA;
  1282. GL_OUTPUT_TEXTURE_COORD14_EXT = $87AB;
  1283. GL_OUTPUT_TEXTURE_COORD15_EXT = $87AC;
  1284. GL_OUTPUT_TEXTURE_COORD16_EXT = $87AD;
  1285. GL_OUTPUT_TEXTURE_COORD17_EXT = $87AE;
  1286. GL_OUTPUT_TEXTURE_COORD18_EXT = $87AF;
  1287. GL_OUTPUT_TEXTURE_COORD19_EXT = $87B0;
  1288. GL_OUTPUT_TEXTURE_COORD20_EXT = $87B1;
  1289. GL_OUTPUT_TEXTURE_COORD21_EXT = $87B2;
  1290. GL_OUTPUT_TEXTURE_COORD22_EXT = $87B3;
  1291. GL_OUTPUT_TEXTURE_COORD23_EXT = $87B4;
  1292. GL_OUTPUT_TEXTURE_COORD24_EXT = $87B5;
  1293. GL_OUTPUT_TEXTURE_COORD25_EXT = $87B6;
  1294. GL_OUTPUT_TEXTURE_COORD26_EXT = $87B7;
  1295. GL_OUTPUT_TEXTURE_COORD27_EXT = $87B8;
  1296. GL_OUTPUT_TEXTURE_COORD28_EXT = $87B9;
  1297. GL_OUTPUT_TEXTURE_COORD29_EXT = $87BA;
  1298. GL_OUTPUT_TEXTURE_COORD30_EXT = $87BB;
  1299. GL_OUTPUT_TEXTURE_COORD31_EXT = $87BC;
  1300. GL_OUTPUT_FOG_EXT = $87BD;
  1301. GL_SCALAR_EXT = $87BE;
  1302. GL_VECTOR_EXT = $87BF;
  1303. GL_MATRIX_EXT = $87C0;
  1304. GL_VARIANT_EXT = $87C1;
  1305. GL_INVARIANT_EXT = $87C2;
  1306. GL_LOCAL_CONSTANT_EXT = $87C3;
  1307. GL_LOCAL_EXT = $87C4;
  1308. GL_MAX_VERTEX_SHADER_INSTRUCTIONS_EXT = $87C5;
  1309. GL_MAX_VERTEX_SHADER_VARIANTS_EXT = $87C6;
  1310. GL_MAX_VERTEX_SHADER_INVARIANTS_EXT = $87C7;
  1311. GL_MAX_VERTEX_SHADER_LOCAL_CONSTANTS_EXT = $87C8;
  1312. GL_MAX_VERTEX_SHADER_LOCALS_EXT = $87C9;
  1313. GL_MAX_OPTIMIZED_VERTEX_SHADER_INSTRUCTIONS_EXT = $87CA;
  1314. GL_MAX_OPTIMIZED_VERTEX_SHADER_VARIANTS_EXT = $87CB;
  1315. GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCAL_CONSTANTS_EXT = $87CC;
  1316. GL_MAX_OPTIMIZED_VERTEX_SHADER_INVARIANTS_EXT = $87CD;
  1317. GL_MAX_OPTIMIZED_VERTEX_SHADER_LOCALS_EXT = $87CE;
  1318. GL_VERTEX_SHADER_INSTRUCTIONS_EXT = $87CF;
  1319. GL_VERTEX_SHADER_VARIANTS_EXT = $87D0;
  1320. GL_VERTEX_SHADER_INVARIANTS_EXT = $87D1;
  1321. GL_VERTEX_SHADER_LOCAL_CONSTANTS_EXT = $87D2;
  1322. GL_VERTEX_SHADER_LOCALS_EXT = $87D3;
  1323. GL_VERTEX_SHADER_BINDING_EXT = $8781;
  1324. GL_VERTEX_SHADER_OPTIMIZED_EXT = $87D4;
  1325. GL_X_EXT = $87D5;
  1326. GL_Y_EXT = $87D6;
  1327. GL_Z_EXT = $87D7;
  1328. GL_W_EXT = $87D8;
  1329. GL_NEGATIVE_X_EXT = $87D9;
  1330. GL_NEGATIVE_Y_EXT = $87DA;
  1331. GL_NEGATIVE_Z_EXT = $87DB;
  1332. GL_NEGATIVE_W_EXT = $87DC;
  1333. GL_ZERO_EXT = $87DD;
  1334. GL_ONE_EXT = $87DE;
  1335. GL_NEGATIVE_ONE_EXT = $87DF;
  1336. GL_NORMALIZED_RANGE_EXT = $87E0;
  1337. GL_FULL_RANGE_EXT = $87E1;
  1338. GL_CURRENT_VERTEX_EXT = $87E2;
  1339. GL_MVP_MATRIX_EXT = $87E3;
  1340. var
  1341. glBeginVertexShaderEXT: procedure(); extdecl;
  1342. glEndVertexShaderEXT: procedure(); extdecl;
  1343. glBindVertexShaderEXT: procedure(id: GLuint); extdecl;
  1344. glGenVertexShadersEXT: function(range: GLuint): GLuint; extdecl;
  1345. glDeleteVertexShaderEXT: procedure(id: GLuint); extdecl;
  1346. glShaderOp1EXT: procedure(op: GLenum; res: GLuint; arg1: GLuint); extdecl;
  1347. glShaderOp2EXT: procedure(op: GLenum; res: GLuint; arg1: GLuint; arg2: GLuint); extdecl;
  1348. glShaderOp3EXT: procedure(op: GLenum; res: GLuint; arg1: GLuint; arg2: GLuint; arg3: GLuint); extdecl;
  1349. glSwizzleEXT: procedure(res: GLuint; _in: GLuint; outX: GLenum; outY: GLenum; outZ: GLenum; outW: GLenum); extdecl;
  1350. glWriteMaskEXT: procedure(res: GLuint; _in: GLuint; outX: GLenum; outY: GLenum; outZ: GLenum; outW: GLenum); extdecl;
  1351. glInsertComponentEXT: procedure(res: GLuint; src: GLuint; num: GLuint); extdecl;
  1352. glExtractComponentEXT: procedure(res: GLuint; src: GLuint; num: GLuint); extdecl;
  1353. glGenSymbolsEXT: function(datatype: GLenum; storagetype: GLenum; range: GLenum; components: GLuint): GLuint; extdecl;
  1354. glSetInvariantEXT: procedure(id: GLuint; _type: GLenum; addr: PGLvoid); extdecl;
  1355. glSetLocalConstantEXT: procedure(id: GLuint; _type: GLenum; addr: PGLvoid); extdecl;
  1356. glVariantbvEXT: procedure(id: GLuint; addr: PGLbyte); extdecl;
  1357. glVariantsvEXT: procedure(id: GLuint; addr: PGLshort); extdecl;
  1358. glVariantivEXT: procedure(id: GLuint; addr: PGLint); extdecl;
  1359. glVariantfvEXT: procedure(id: GLuint; addr: PGLfloat); extdecl;
  1360. glVariantdvEXT: procedure(id: GLuint; addr: PGLdouble); extdecl;
  1361. glVariantubvEXT: procedure(id: GLuint; addr: PGLubyte); extdecl;
  1362. glVariantusvEXT: procedure(id: GLuint; addr: PGLushort); extdecl;
  1363. glVariantuivEXT: procedure(id: GLuint; addr: PGLuint); extdecl;
  1364. glVariantPointerEXT: procedure(id: GLuint; _type: GLenum; stride: GLuint; addr: PGLvoid); extdecl;
  1365. glEnableVariantClientStateEXT: procedure(id: GLuint); extdecl;
  1366. glDisableVariantClientStateEXT: procedure(id: GLuint); extdecl;
  1367. glBindLightParameterEXT: function(light: GLenum; value: GLenum): GLuint; extdecl;
  1368. glBindMaterialParameterEXT: function(face: GLenum; value: GLenum): GLuint; extdecl;
  1369. glBindTexGenParameterEXT: function(_unit: GLenum; coord: GLenum; value: GLenum): GLuint; extdecl;
  1370. glBindTextureUnitParameterEXT: function(_unit: GLenum; value: GLenum): GLuint; extdecl;
  1371. glBindParameterEXT: function(value: GLenum): GLuint; extdecl;
  1372. glIsVariantEnabledEXT: function(id: GLuint; cap: GLenum): GLboolean; extdecl;
  1373. glGetVariantBooleanvEXT: procedure(id: GLuint; value: GLenum; data: PGLboolean); extdecl;
  1374. glGetVariantIntegervEXT: procedure(id: GLuint; value: GLenum; data: PGLint); extdecl;
  1375. glGetVariantFloatvEXT: procedure(id: GLuint; value: GLenum; data: PGLfloat); extdecl;
  1376. glGetVariantPointervEXT: procedure(id: GLuint; value: GLenum; data: PGLvoid); extdecl;
  1377. glGetInvariantBooleanvEXT: procedure(id: GLuint; value: GLenum; data: PGLboolean); extdecl;
  1378. glGetInvariantIntegervEXT: procedure(id: GLuint; value: GLenum; data: PGLint); extdecl;
  1379. glGetInvariantFloatvEXT: procedure(id: GLuint; value: GLenum; data: PGLfloat); extdecl;
  1380. glGetLocalConstantBooleanvEXT: procedure(id: GLuint; value: GLenum; data: PGLboolean); extdecl;
  1381. glGetLocalConstantIntegervEXT: procedure(id: GLuint; value: GLenum; data: PGLint); extdecl;
  1382. glGetLocalConstantFloatvEXT: procedure(id: GLuint; value: GLenum; data: PGLfloat); extdecl;
  1383. function Load_GL_EXT_vertex_shader: Boolean;
  1384. //***** GL_EXT_vertex_weighting *****//
  1385. const
  1386. GL_VERTEX_WEIGHTING_EXT = $8509;
  1387. GL_MODELVIEW0_EXT = $1700;
  1388. GL_MODELVIEW1_EXT = $850A;
  1389. GL_MODELVIEW0_MATRIX_EXT = $0BA6;
  1390. GL_MODELVIEW1_MATRIX_EXT = $8506;
  1391. GL_CURRENT_VERTEX_WEIGHT_EXT = $850B;
  1392. GL_VERTEX_WEIGHT_ARRAY_EXT = $850C;
  1393. GL_VERTEX_WEIGHT_ARRAY_SIZE_EXT = $850D;
  1394. GL_VERTEX_WEIGHT_ARRAY_TYPE_EXT = $850E;
  1395. GL_VERTEX_WEIGHT_ARRAY_STRIDE_EXT = $850F;
  1396. GL_MODELVIEW0_STACK_DEPTH_EXT = $0BA3;
  1397. GL_MODELVIEW1_STACK_DEPTH_EXT = $8502;
  1398. GL_VERTEX_WEIGHT_ARRAY_POINTER_EXT = $8510;
  1399. var
  1400. glVertexWeightfEXT: procedure(weight: GLfloat); extdecl;
  1401. glVertexWeightfvEXT: procedure(weight: PGLfloat); extdecl;
  1402. glVertexWeightPointerEXT: procedure(size: GLint; _type: GLenum; stride: GLsizei; pointer: PGLvoid); extdecl;
  1403. function Load_GL_EXT_vertex_weighting: Boolean;
  1404. //***** GL_HP_occlusion_test *****//
  1405. const
  1406. GL_OCCLUSION_TEST_HP = $8165;
  1407. GL_OCCLUSION_TEST_RESULT_HP = $8166;
  1408. function Load_GL_HP_occlusion_test: Boolean;
  1409. //***** GL_NV_blend_square *****//
  1410. function Load_GL_NV_blend_square: Boolean;
  1411. //***** GL_NV_copy_depth_to_color *****//
  1412. const
  1413. GL_DEPTH_STENCIL_TO_RGBA_NV = $886E;
  1414. GL_DEPTH_STENCIL_TO_BGRA_NV = $886F;
  1415. function Load_GL_NV_copy_depth_to_color: Boolean;
  1416. //***** GL_NV_depth_clamp *****//
  1417. const
  1418. GL_DEPTH_CLAMP_NV = $864F;
  1419. function Load_GL_NV_depth_clamp: Boolean;
  1420. //***** GL_NV_evaluators *****//
  1421. const
  1422. GL_EVAL_2D_NV = $86C0;
  1423. GL_EVAL_TRIANGULAR_2D_NV = $86C1;
  1424. GL_MAP_TESSELLATION_NV = $86C2;
  1425. GL_MAP_ATTRIB_U_ORDER_NV = $86C3;
  1426. GL_MAP_ATTRIB_V_ORDER_NV = $86C4;
  1427. GL_EVAL_FRACTIONAL_TESSELLATION_NV = $86C5;
  1428. GL_EVAL_VERTEX_ATTRIB0_NV = $86C6;
  1429. GL_EVAL_VERTEX_ATTRIB1_NV = $86C7;
  1430. GL_EVAL_VERTEX_ATTRIB2_NV = $86C8;
  1431. GL_EVAL_VERTEX_ATTRIB3_NV = $86C9;
  1432. GL_EVAL_VERTEX_ATTRIB4_NV = $86CA;
  1433. GL_EVAL_VERTEX_ATTRIB5_NV = $86CB;
  1434. GL_EVAL_VERTEX_ATTRIB6_NV = $86CC;
  1435. GL_EVAL_VERTEX_ATTRIB7_NV = $86CD;
  1436. GL_EVAL_VERTEX_ATTRIB8_NV = $86CE;
  1437. GL_EVAL_VERTEX_ATTRIB9_NV = $86CF;
  1438. GL_EVAL_VERTEX_ATTRIB10_NV = $86D0;
  1439. GL_EVAL_VERTEX_ATTRIB11_NV = $86D1;
  1440. GL_EVAL_VERTEX_ATTRIB12_NV = $86D2;
  1441. GL_EVAL_VERTEX_ATTRIB13_NV = $86D3;
  1442. GL_EVAL_VERTEX_ATTRIB14_NV = $86D4;
  1443. GL_EVAL_VERTEX_ATTRIB15_NV = $86D5;
  1444. GL_MAX_MAP_TESSELLATION_NV = $86D6;
  1445. GL_MAX_RATIONAL_EVAL_ORDER_NV = $86D7;
  1446. var
  1447. glMapControlPointsNV: procedure(target: GLenum; index: GLuint; _type: GLenum; ustride: GLsizei; vstride: GLsizei; uorder: GLint; vorder: GLint; _packed: GLboolean; const points: PGLvoid); extdecl;
  1448. glMapParameterivNV: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  1449. glMapParameterfvNV: procedure(target: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  1450. glGetMapControlPointsNV: procedure(target: GLenum; index: GLuint; _type: GLenum; ustride: GLsizei; vstride: GLsizei; _packed: GLboolean; points: PGLvoid); extdecl;
  1451. glGetMapParameterivNV: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  1452. glGetMapParameterfvNV: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1453. glGetMapAttribParameterivNV: procedure(target: GLenum; index: GLuint; pname: GLenum; params: PGLint); extdecl;
  1454. glGetMapAttribParameterfvNV: procedure(target: GLenum; index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  1455. glEvalMapsNV: procedure(target: GLenum; mode: GLenum); extdecl;
  1456. function Load_GL_NV_evaluators: Boolean;
  1457. //***** GL_NV_fence *****//
  1458. const
  1459. GL_ALL_COMPLETED_NV = $84F2;
  1460. GL_FENCE_STATUS_NV = $84F3;
  1461. GL_FENCE_CONDITION_NV = $84F4;
  1462. var
  1463. glGenFencesNV: procedure(n: GLsizei; fences: PGLuint); extdecl;
  1464. glDeleteFencesNV: procedure(n: GLsizei; const fences: PGLuint); extdecl;
  1465. glSetFenceNV: procedure(fence: GLuint; condition: GLenum); extdecl;
  1466. glTestFenceNV: function(fence: GLuint): GLboolean; extdecl;
  1467. glFinishFenceNV: procedure(fence: GLuint); extdecl;
  1468. glIsFenceNV: function(fence: GLuint): GLboolean; extdecl;
  1469. glGetFenceivNV: procedure(fence: GLuint; pname: GLenum; params: PGLint); extdecl;
  1470. function Load_GL_NV_fence: Boolean;
  1471. //***** GL_NV_fog_distance *****//
  1472. const
  1473. GL_FOG_DISTANCE_MODE_NV = $855A;
  1474. GL_EYE_RADIAL_NV = $855B;
  1475. GL_EYE_PLANE_ABSOLUTE_NV = $855C;
  1476. function Load_GL_NV_fog_distance: Boolean;
  1477. //***** GL_NV_light_max_exponent *****//
  1478. const
  1479. GL_MAX_SHININESS_NV = $8504;
  1480. GL_MAX_SPOT_EXPONENT_NV = $8505;
  1481. function Load_GL_NV_light_max_exponent: Boolean;
  1482. //***** GL_NV_multisample_filter_hint *****//
  1483. const
  1484. GL_MULTISAMPLE_FILTER_HINT_NV = $8534;
  1485. function Load_GL_NV_multisample_filter_hint: Boolean;
  1486. //***** GL_NV_occlusion_query *****//
  1487. // GL_OCCLUSION_TEST_HP { already defined }
  1488. // GL_OCCLUSION_TEST_RESULT_HP { already defined }
  1489. const
  1490. GL_PIXEL_COUNTER_BITS_NV = $8864;
  1491. GL_CURRENT_OCCLUSION_QUERY_ID_NV = $8865;
  1492. GL_PIXEL_COUNT_NV = $8866;
  1493. GL_PIXEL_COUNT_AVAILABLE_NV = $8867;
  1494. var
  1495. glGenOcclusionQueriesNV: procedure(n: GLsizei; ids: PGLuint); extdecl;
  1496. glDeleteOcclusionQueriesNV: procedure(n: GLsizei; const ids: PGLuint); extdecl;
  1497. glIsOcclusionQueryNV: function(id: GLuint): GLboolean; extdecl;
  1498. glBeginOcclusionQueryNV: procedure(id: GLuint); extdecl;
  1499. glEndOcclusionQueryNV: procedure(); extdecl;
  1500. glGetOcclusionQueryivNV: procedure(id: GLuint; pname: GLenum; params: PGLint); extdecl;
  1501. glGetOcclusionQueryuivNV: procedure(id: GLuint; pname: GLenum; params: PGLuint); extdecl;
  1502. function Load_GL_NV_occlusion_query: Boolean;
  1503. //***** GL_NV_packed_depth_stencil *****//
  1504. const
  1505. GL_DEPTH_STENCIL_NV = $84F9;
  1506. GL_UNSIGNED_INT_24_8_NV = $84FA;
  1507. function Load_GL_NV_packed_depth_stencil: Boolean;
  1508. //***** GL_NV_point_sprite *****//
  1509. const
  1510. GL_POINT_SPRITE_NV = $8861;
  1511. GL_COORD_REPLACE_NV = $8862;
  1512. GL_POINT_SPRITE_R_MODE_NV = $8863;
  1513. var
  1514. glPointParameteriNV: procedure(pname: GLenum; param: GLint); extdecl;
  1515. glPointParameterivNV: procedure(pname: GLenum; const params: PGLint); extdecl;
  1516. function Load_GL_NV_point_sprite: Boolean;
  1517. //***** GL_NV_register_combiners *****//
  1518. const
  1519. GL_REGISTER_COMBINERS_NV = $8522;
  1520. GL_COMBINER0_NV = $8550;
  1521. GL_COMBINER1_NV = $8551;
  1522. GL_COMBINER2_NV = $8552;
  1523. GL_COMBINER3_NV = $8553;
  1524. GL_COMBINER4_NV = $8554;
  1525. GL_COMBINER5_NV = $8555;
  1526. GL_COMBINER6_NV = $8556;
  1527. GL_COMBINER7_NV = $8557;
  1528. GL_VARIABLE_A_NV = $8523;
  1529. GL_VARIABLE_B_NV = $8524;
  1530. GL_VARIABLE_C_NV = $8525;
  1531. GL_VARIABLE_D_NV = $8526;
  1532. GL_VARIABLE_E_NV = $8527;
  1533. GL_VARIABLE_F_NV = $8528;
  1534. GL_VARIABLE_G_NV = $8529;
  1535. GL_CONSTANT_COLOR0_NV = $852A;
  1536. GL_CONSTANT_COLOR1_NV = $852B;
  1537. GL_PRIMARY_COLOR_NV = $852C;
  1538. GL_SECONDARY_COLOR_NV = $852D;
  1539. GL_SPARE0_NV = $852E;
  1540. GL_SPARE1_NV = $852F;
  1541. GL_UNSIGNED_IDENTITY_NV = $8536;
  1542. GL_UNSIGNED_INVERT_NV = $8537;
  1543. GL_EXPAND_NORMAL_NV = $8538;
  1544. GL_EXPAND_NEGATE_NV = $8539;
  1545. GL_HALF_BIAS_NORMAL_NV = $853A;
  1546. GL_HALF_BIAS_NEGATE_NV = $853B;
  1547. GL_SIGNED_IDENTITY_NV = $853C;
  1548. GL_SIGNED_NEGATE_NV = $853D;
  1549. GL_E_TIMES_F_NV = $8531;
  1550. GL_SPARE0_PLUS_SECONDARY_COLOR_NV = $8532;
  1551. GL_SCALE_BY_TWO_NV = $853E;
  1552. GL_SCALE_BY_FOUR_NV = $853F;
  1553. GL_SCALE_BY_ONE_HALF_NV = $8540;
  1554. GL_BIAS_BY_NEGATIVE_ONE_HALF_NV = $8541;
  1555. GL_DISCARD_NV = $8530;
  1556. GL_COMBINER_INPUT_NV = $8542;
  1557. GL_COMBINER_MAPPING_NV = $8543;
  1558. GL_COMBINER_COMPONENT_USAGE_NV = $8544;
  1559. GL_COMBINER_AB_DOT_PRODUCT_NV = $8545;
  1560. GL_COMBINER_CD_DOT_PRODUCT_NV = $8546;
  1561. GL_COMBINER_MUX_SUM_NV = $8547;
  1562. GL_COMBINER_SCALE_NV = $8548;
  1563. GL_COMBINER_BIAS_NV = $8549;
  1564. GL_COMBINER_AB_OUTPUT_NV = $854A;
  1565. GL_COMBINER_CD_OUTPUT_NV = $854B;
  1566. GL_COMBINER_SUM_OUTPUT_NV = $854C;
  1567. GL_NUM_GENERAL_COMBINERS_NV = $854E;
  1568. GL_COLOR_SUM_CLAMP_NV = $854F;
  1569. GL_MAX_GENERAL_COMBINERS_NV = $854D;
  1570. var
  1571. glCombinerParameterfvNV: procedure(pname: GLenum; const params: PGLfloat); extdecl;
  1572. glCombinerParameterivNV: procedure(pname: GLenum; const params: PGLint); extdecl;
  1573. glCombinerParameterfNV: procedure(pname: GLenum; param: GLfloat); extdecl;
  1574. glCombinerParameteriNV: procedure(pname: GLenum; param: GLint); extdecl;
  1575. glCombinerInputNV: procedure(stage: GLenum; portion: GLenum; variable: GLenum; input: GLenum; mapping: GLenum; componentUsage: GLenum); extdecl;
  1576. glCombinerOutputNV: procedure(stage: GLenum; portion: GLenum; abOutput: GLenum; cdOutput: GLenum; sumOutput: GLenum; scale: GLenum; bias: GLenum; abDotProduct: GLboolean; cdDotProduct: GLboolean; muxSum: GLboolean); extdecl;
  1577. glFinalCombinerInputNV: procedure(variable: GLenum; input: GLenum; mapping: GLenum; componentUsage: GLenum); extdecl;
  1578. glGetCombinerInputParameterfvNV: procedure(stage: GLenum; portion: GLenum; variable: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1579. glGetCombinerInputParameterivNV: procedure(stage: GLenum; portion: GLenum; variable: GLenum; pname: GLenum; params: PGLint); extdecl;
  1580. glGetCombinerOutputParameterfvNV: procedure(stage: GLenum; portion: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1581. glGetCombinerOutputParameterivNV: procedure(stage: GLenum; portion: GLenum; pname: GLenum; params: PGLint); extdecl;
  1582. glGetFinalCombinerInputParameterfvNV: procedure(variable: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1583. glGetFinalCombinerInputParameterivNV: procedure(variable: GLenum; pname: GLenum; params: PGLint); extdecl;
  1584. function Load_GL_NV_register_combiners: Boolean;
  1585. //***** GL_NV_register_combiners2 *****//
  1586. const
  1587. GL_PER_STAGE_CONSTANTS_NV = $8535;
  1588. var
  1589. glCombinerStageParameterfvNV: procedure(stage: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  1590. glGetCombinerStageParameterfvNV: procedure(stage: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  1591. function Load_GL_NV_register_combiners2: Boolean;
  1592. //***** GL_NV_texgen_emboss *****//
  1593. const
  1594. GL_EMBOSS_MAP_NV = $855F;
  1595. GL_EMBOSS_LIGHT_NV = $855D;
  1596. GL_EMBOSS_CONSTANT_NV = $855E;
  1597. function Load_GL_NV_texgen_emboss: Boolean;
  1598. //***** GL_NV_texgen_reflection *****//
  1599. const
  1600. GL_NORMAL_MAP_NV = $8511;
  1601. GL_REFLECTION_MAP_NV = $8512;
  1602. function Load_GL_NV_texgen_reflection: Boolean;
  1603. //***** GL_NV_texture_compression_vtc *****//
  1604. // GL_COMPRESSED_RGB_S3TC_DXT1_EXT { already defined }
  1605. // GL_COMPRESSED_RGBA_S3TC_DXT1_EXT { already defined }
  1606. // GL_COMPRESSED_RGBA_S3TC_DXT3_EXT { already defined }
  1607. // GL_COMPRESSED_RGBA_S3TC_DXT5_EXT { already defined }
  1608. function Load_GL_NV_texture_compression_vtc: Boolean;
  1609. //***** GL_NV_texture_env_combine4 *****//
  1610. const
  1611. GL_COMBINE4_NV = $8503;
  1612. GL_SOURCE3_RGB_NV = $8583;
  1613. GL_SOURCE3_ALPHA_NV = $858B;
  1614. GL_OPERAND3_RGB_NV = $8593;
  1615. GL_OPERAND3_ALPHA_NV = $859B;
  1616. function Load_GL_NV_texture_env_combine4: Boolean;
  1617. //***** GL_NV_texture_rectangle *****//
  1618. const
  1619. GL_TEXTURE_RECTANGLE_NV = $84F5;
  1620. GL_TEXTURE_BINDING_RECTANGLE_NV = $84F6;
  1621. GL_PROXY_TEXTURE_RECTANGLE_NV = $84F7;
  1622. GL_MAX_RECTANGLE_TEXTURE_SIZE_NV = $84F8;
  1623. function Load_GL_NV_texture_rectangle: Boolean;
  1624. //***** GL_NV_texture_shader *****//
  1625. const
  1626. GL_TEXTURE_SHADER_NV = $86DE;
  1627. GL_RGBA_UNSIGNED_DOT_PRODUCT_MAPPING_NV = $86D9;
  1628. GL_SHADER_OPERATION_NV = $86DF;
  1629. GL_CULL_MODES_NV = $86E0;
  1630. GL_OFFSET_TEXTURE_MATRIX_NV = $86E1;
  1631. GL_OFFSET_TEXTURE_SCALE_NV = $86E2;
  1632. GL_OFFSET_TEXTURE_BIAS_NV = $86E3;
  1633. GL_PREVIOUS_TEXTURE_INPUT_NV = $86E4;
  1634. GL_CONST_EYE_NV = $86E5;
  1635. GL_SHADER_CONSISTENT_NV = $86DD;
  1636. GL_PASS_THROUGH_NV = $86E6;
  1637. GL_CULL_FRAGMENT_NV = $86E7;
  1638. GL_OFFSET_TEXTURE_2D_NV = $86E8;
  1639. GL_OFFSET_TEXTURE_RECTANGLE_NV = $864C;
  1640. GL_OFFSET_TEXTURE_RECTANGLE_SCALE_NV = $864D;
  1641. GL_DEPENDENT_AR_TEXTURE_2D_NV = $86E9;
  1642. GL_DEPENDENT_GB_TEXTURE_2D_NV = $86EA;
  1643. GL_DOT_PRODUCT_NV = $86EC;
  1644. GL_DOT_PRODUCT_DEPTH_REPLACE_NV = $86ED;
  1645. GL_DOT_PRODUCT_TEXTURE_2D_NV = $86EE;
  1646. GL_DOT_PRODUCT_TEXTURE_RECTANGLE_NV = $864E;
  1647. GL_DOT_PRODUCT_TEXTURE_CUBE_MAP_NV = $86F0;
  1648. GL_DOT_PRODUCT_DIFFUSE_CUBE_MAP_NV = $86F1;
  1649. GL_DOT_PRODUCT_REFLECT_CUBE_MAP_NV = $86F2;
  1650. GL_DOT_PRODUCT_CONST_EYE_REFLECT_CUBE_MAP_NV = $86F3;
  1651. GL_HILO_NV = $86F4;
  1652. GL_DSDT_NV = $86F5;
  1653. GL_DSDT_MAG_NV = $86F6;
  1654. GL_DSDT_MAG_VIB_NV = $86F7;
  1655. GL_UNSIGNED_INT_S8_S8_8_8_NV = $86DA;
  1656. GL_UNSIGNED_INT_8_8_S8_S8_REV_NV = $86DB;
  1657. GL_SIGNED_RGBA_NV = $86FB;
  1658. GL_SIGNED_RGBA8_NV = $86FC;
  1659. GL_SIGNED_RGB_NV = $86FE;
  1660. GL_SIGNED_RGB8_NV = $86FF;
  1661. GL_SIGNED_LUMINANCE_NV = $8701;
  1662. GL_SIGNED_LUMINANCE8_NV = $8702;
  1663. GL_SIGNED_LUMINANCE_ALPHA_NV = $8703;
  1664. GL_SIGNED_LUMINANCE8_ALPHA8_NV = $8704;
  1665. GL_SIGNED_ALPHA_NV = $8705;
  1666. GL_SIGNED_ALPHA8_NV = $8706;
  1667. GL_SIGNED_INTENSITY_NV = $8707;
  1668. GL_SIGNED_INTENSITY8_NV = $8708;
  1669. GL_SIGNED_RGB_UNSIGNED_ALPHA_NV = $870C;
  1670. GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV = $870D;
  1671. GL_HILO16_NV = $86F8;
  1672. GL_SIGNED_HILO_NV = $86F9;
  1673. GL_SIGNED_HILO16_NV = $86FA;
  1674. GL_DSDT8_NV = $8709;
  1675. GL_DSDT8_MAG8_NV = $870A;
  1676. GL_DSDT_MAG_INTENSITY_NV = $86DC;
  1677. GL_DSDT8_MAG8_INTENSITY8_NV = $870B;
  1678. GL_HI_SCALE_NV = $870E;
  1679. GL_LO_SCALE_NV = $870F;
  1680. GL_DS_SCALE_NV = $8710;
  1681. GL_DT_SCALE_NV = $8711;
  1682. GL_MAGNITUDE_SCALE_NV = $8712;
  1683. GL_VIBRANCE_SCALE_NV = $8713;
  1684. GL_HI_BIAS_NV = $8714;
  1685. GL_LO_BIAS_NV = $8715;
  1686. GL_DS_BIAS_NV = $8716;
  1687. GL_DT_BIAS_NV = $8717;
  1688. GL_MAGNITUDE_BIAS_NV = $8718;
  1689. GL_VIBRANCE_BIAS_NV = $8719;
  1690. GL_TEXTURE_BORDER_VALUES_NV = $871A;
  1691. GL_TEXTURE_HI_SIZE_NV = $871B;
  1692. GL_TEXTURE_LO_SIZE_NV = $871C;
  1693. GL_TEXTURE_DS_SIZE_NV = $871D;
  1694. GL_TEXTURE_DT_SIZE_NV = $871E;
  1695. GL_TEXTURE_MAG_SIZE_NV = $871F;
  1696. function Load_GL_NV_texture_shader: Boolean;
  1697. //***** GL_NV_texture_shader2 *****//
  1698. const
  1699. GL_DOT_PRODUCT_TEXTURE_3D_NV = $86EF;
  1700. // GL_HILO_NV { already defined }
  1701. // GL_DSDT_NV { already defined }
  1702. // GL_DSDT_MAG_NV { already defined }
  1703. // GL_DSDT_MAG_VIB_NV { already defined }
  1704. // GL_UNSIGNED_INT_S8_S8_8_8_NV { already defined }
  1705. // GL_UNSIGNED_INT_8_8_S8_S8_REV_NV { already defined }
  1706. // GL_SIGNED_RGBA_NV { already defined }
  1707. // GL_SIGNED_RGBA8_NV { already defined }
  1708. // GL_SIGNED_RGB_NV { already defined }
  1709. // GL_SIGNED_RGB8_NV { already defined }
  1710. // GL_SIGNED_LUMINANCE_NV { already defined }
  1711. // GL_SIGNED_LUMINANCE8_NV { already defined }
  1712. // GL_SIGNED_LUMINANCE_ALPHA_NV { already defined }
  1713. // GL_SIGNED_LUMINANCE8_ALPHA8_NV { already defined }
  1714. // GL_SIGNED_ALPHA_NV { already defined }
  1715. // GL_SIGNED_ALPHA8_NV { already defined }
  1716. // GL_SIGNED_INTENSITY_NV { already defined }
  1717. // GL_SIGNED_INTENSITY8_NV { already defined }
  1718. // GL_SIGNED_RGB_UNSIGNED_ALPHA_NV { already defined }
  1719. // GL_SIGNED_RGB8_UNSIGNED_ALPHA8_NV { already defined }
  1720. // GL_HILO16_NV { already defined }
  1721. // GL_SIGNED_HILO_NV { already defined }
  1722. // GL_SIGNED_HILO16_NV { already defined }
  1723. // GL_DSDT8_NV { already defined }
  1724. // GL_DSDT8_MAG8_NV { already defined }
  1725. // GL_DSDT_MAG_INTENSITY_NV { already defined }
  1726. // GL_DSDT8_MAG8_INTENSITY8_NV { already defined }
  1727. function Load_GL_NV_texture_shader2: Boolean;
  1728. //***** GL_NV_texture_shader3 *****//
  1729. const
  1730. GL_OFFSET_PROJECTIVE_TEXTURE_2D_NV = $8850;
  1731. GL_OFFSET_PROJECTIVE_TEXTURE_2D_SCALE_NV = $8851;
  1732. GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_NV = $8852;
  1733. GL_OFFSET_PROJECTIVE_TEXTURE_RECTANGLE_SCALE_NV = $8853;
  1734. GL_OFFSET_HILO_TEXTURE_2D_NV = $8854;
  1735. GL_OFFSET_HILO_TEXTURE_RECTANGLE_NV = $8855;
  1736. GL_OFFSET_HILO_PROJECTIVE_TEXTURE_2D_NV = $8856;
  1737. GL_OFFSET_HILO_PROJECTIVE_TEXTURE_RECTANGLE_NV = $8857;
  1738. GL_DEPENDENT_HILO_TEXTURE_2D_NV = $8858;
  1739. GL_DEPENDENT_RGB_TEXTURE_3D_NV = $8859;
  1740. GL_DEPENDENT_RGB_TEXTURE_CUBE_MAP_NV = $885A;
  1741. GL_DOT_PRODUCT_PASS_THROUGH_NV = $885B;
  1742. GL_DOT_PRODUCT_TEXTURE_1D_NV = $885C;
  1743. GL_DOT_PRODUCT_AFFINE_DEPTH_REPLACE_NV = $885D;
  1744. GL_HILO8_NV = $885E;
  1745. GL_SIGNED_HILO8_NV = $885F;
  1746. GL_FORCE_BLUE_TO_ONE_NV = $8860;
  1747. function Load_GL_NV_texture_shader3: Boolean;
  1748. //***** GL_NV_vertex_array_range *****//
  1749. const
  1750. GL_VERTEX_ARRAY_RANGE_NV = $851D;
  1751. GL_VERTEX_ARRAY_RANGE_LENGTH_NV = $851E;
  1752. GL_VERTEX_ARRAY_RANGE_VALID_NV = $851F;
  1753. GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_NV = $8520;
  1754. GL_VERTEX_ARRAY_RANGE_POINTER_NV = $8521;
  1755. var
  1756. glVertexArrayRangeNV: procedure(length: GLsizei; pointer: PGLvoid); extdecl;
  1757. glFlushVertexArrayRangeNV: procedure(); extdecl;
  1758. {$IFDEF Windows}
  1759. wglAllocateMemoryNV: function(size: GLsizei; readFrequency: GLfloat; writeFrequency: GLfloat; priority: GLfloat): PGLvoid; extdecl;
  1760. wglFreeMemoryNV: procedure(pointer: PGLvoid); extdecl;
  1761. {$ENDIF}
  1762. function Load_GL_NV_vertex_array_range: Boolean;
  1763. //***** GL_NV_vertex_array_range2 *****//
  1764. const
  1765. GL_VERTEX_ARRAY_RANGE_WITHOUT_FLUSH_NV = $8533;
  1766. function Load_GL_NV_vertex_array_range2: Boolean;
  1767. //***** GL_NV_vertex_program *****//
  1768. const
  1769. GL_VERTEX_PROGRAM_NV = $8620;
  1770. GL_VERTEX_PROGRAM_POINT_SIZE_NV = $8642;
  1771. GL_VERTEX_PROGRAM_TWO_SIDE_NV = $8643;
  1772. GL_VERTEX_STATE_PROGRAM_NV = $8621;
  1773. GL_ATTRIB_ARRAY_SIZE_NV = $8623;
  1774. GL_ATTRIB_ARRAY_STRIDE_NV = $8624;
  1775. GL_ATTRIB_ARRAY_TYPE_NV = $8625;
  1776. GL_CURRENT_ATTRIB_NV = $8626;
  1777. GL_PROGRAM_PARAMETER_NV = $8644;
  1778. GL_ATTRIB_ARRAY_POINTER_NV = $8645;
  1779. GL_PROGRAM_TARGET_NV = $8646;
  1780. GL_PROGRAM_LENGTH_NV = $8627;
  1781. GL_PROGRAM_RESIDENT_NV = $8647;
  1782. GL_PROGRAM_STRING_NV = $8628;
  1783. GL_TRACK_MATRIX_NV = $8648;
  1784. GL_TRACK_MATRIX_TRANSFORM_NV = $8649;
  1785. GL_MAX_TRACK_MATRIX_STACK_DEPTH_NV = $862E;
  1786. GL_MAX_TRACK_MATRICES_NV = $862F;
  1787. GL_CURRENT_MATRIX_STACK_DEPTH_NV = $8640;
  1788. GL_CURRENT_MATRIX_NV = $8641;
  1789. GL_VERTEX_PROGRAM_BINDING_NV = $864A;
  1790. GL_PROGRAM_ERROR_POSITION_NV = $864B;
  1791. GL_MODELVIEW_PROJECTION_NV = $8629;
  1792. GL_MATRIX0_NV = $8630;
  1793. GL_MATRIX1_NV = $8631;
  1794. GL_MATRIX2_NV = $8632;
  1795. GL_MATRIX3_NV = $8633;
  1796. GL_MATRIX4_NV = $8634;
  1797. GL_MATRIX5_NV = $8635;
  1798. GL_MATRIX6_NV = $8636;
  1799. GL_MATRIX7_NV = $8637;
  1800. GL_IDENTITY_NV = $862A;
  1801. GL_INVERSE_NV = $862B;
  1802. GL_TRANSPOSE_NV = $862C;
  1803. GL_INVERSE_TRANSPOSE_NV = $862D;
  1804. GL_VERTEX_ATTRIB_ARRAY0_NV = $8650;
  1805. GL_VERTEX_ATTRIB_ARRAY1_NV = $8651;
  1806. GL_VERTEX_ATTRIB_ARRAY2_NV = $8652;
  1807. GL_VERTEX_ATTRIB_ARRAY3_NV = $8653;
  1808. GL_VERTEX_ATTRIB_ARRAY4_NV = $8654;
  1809. GL_VERTEX_ATTRIB_ARRAY5_NV = $8655;
  1810. GL_VERTEX_ATTRIB_ARRAY6_NV = $8656;
  1811. GL_VERTEX_ATTRIB_ARRAY7_NV = $8657;
  1812. GL_VERTEX_ATTRIB_ARRAY8_NV = $8658;
  1813. GL_VERTEX_ATTRIB_ARRAY9_NV = $8659;
  1814. GL_VERTEX_ATTRIB_ARRAY10_NV = $865A;
  1815. GL_VERTEX_ATTRIB_ARRAY11_NV = $865B;
  1816. GL_VERTEX_ATTRIB_ARRAY12_NV = $865C;
  1817. GL_VERTEX_ATTRIB_ARRAY13_NV = $865D;
  1818. GL_VERTEX_ATTRIB_ARRAY14_NV = $865E;
  1819. GL_VERTEX_ATTRIB_ARRAY15_NV = $865F;
  1820. GL_MAP1_VERTEX_ATTRIB0_4_NV = $8660;
  1821. GL_MAP1_VERTEX_ATTRIB1_4_NV = $8661;
  1822. GL_MAP1_VERTEX_ATTRIB2_4_NV = $8662;
  1823. GL_MAP1_VERTEX_ATTRIB3_4_NV = $8663;
  1824. GL_MAP1_VERTEX_ATTRIB4_4_NV = $8664;
  1825. GL_MAP1_VERTEX_ATTRIB5_4_NV = $8665;
  1826. GL_MAP1_VERTEX_ATTRIB6_4_NV = $8666;
  1827. GL_MAP1_VERTEX_ATTRIB7_4_NV = $8667;
  1828. GL_MAP1_VERTEX_ATTRIB8_4_NV = $8668;
  1829. GL_MAP1_VERTEX_ATTRIB9_4_NV = $8669;
  1830. GL_MAP1_VERTEX_ATTRIB10_4_NV = $866A;
  1831. GL_MAP1_VERTEX_ATTRIB11_4_NV = $866B;
  1832. GL_MAP1_VERTEX_ATTRIB12_4_NV = $866C;
  1833. GL_MAP1_VERTEX_ATTRIB13_4_NV = $866D;
  1834. GL_MAP1_VERTEX_ATTRIB14_4_NV = $866E;
  1835. GL_MAP1_VERTEX_ATTRIB15_4_NV = $866F;
  1836. GL_MAP2_VERTEX_ATTRIB0_4_NV = $8670;
  1837. GL_MAP2_VERTEX_ATTRIB1_4_NV = $8671;
  1838. GL_MAP2_VERTEX_ATTRIB2_4_NV = $8672;
  1839. GL_MAP2_VERTEX_ATTRIB3_4_NV = $8673;
  1840. GL_MAP2_VERTEX_ATTRIB4_4_NV = $8674;
  1841. GL_MAP2_VERTEX_ATTRIB5_4_NV = $8675;
  1842. GL_MAP2_VERTEX_ATTRIB6_4_NV = $8676;
  1843. GL_MAP2_VERTEX_ATTRIB7_4_NV = $8677;
  1844. GL_MAP2_VERTEX_ATTRIB8_4_NV = $8678;
  1845. GL_MAP2_VERTEX_ATTRIB9_4_NV = $8679;
  1846. GL_MAP2_VERTEX_ATTRIB10_4_NV = $867A;
  1847. GL_MAP2_VERTEX_ATTRIB11_4_NV = $867B;
  1848. GL_MAP2_VERTEX_ATTRIB12_4_NV = $867C;
  1849. GL_MAP2_VERTEX_ATTRIB13_4_NV = $867D;
  1850. GL_MAP2_VERTEX_ATTRIB14_4_NV = $867E;
  1851. GL_MAP2_VERTEX_ATTRIB15_4_NV = $867F;
  1852. var
  1853. glBindProgramNV: procedure(target: GLenum; id: GLuint); extdecl;
  1854. glDeleteProgramsNV: procedure(n: GLsizei; const ids: PGLuint); extdecl;
  1855. glExecuteProgramNV: procedure(target: GLenum; id: GLuint; const params: PGLfloat); extdecl;
  1856. glGenProgramsNV: procedure(n: GLsizei; ids: PGLuint); extdecl;
  1857. glAreProgramsResidentNV: function(n: GLsizei; const ids: PGLuint; residences: PGLboolean): GLboolean; extdecl;
  1858. glRequestResidentProgramsNV: procedure(n: GLsizei; ids: PGLuint); extdecl;
  1859. glGetProgramParameterfvNV: procedure(target: GLenum; index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  1860. glGetProgramParameterdvNV: procedure(target: GLenum; index: GLuint; pname: GLenum; params: PGLdouble); extdecl;
  1861. glGetProgramivNV: procedure(id: GLuint; pname: GLenum; params: PGLint); extdecl;
  1862. glGetProgramStringNV: procedure(id: GLuint; pname: GLenum; _program: PGLubyte); extdecl;
  1863. glGetTrackMatrixivNV: procedure(target: GLenum; address: GLuint; pname: GLenum; params: PGLint); extdecl;
  1864. glGetVertexAttribdvNV: procedure(index: GLuint; pname: GLenum; params: PGLdouble); extdecl;
  1865. glGetVertexAttribfvNV: procedure(index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  1866. glGetVertexAttribivNV: procedure(index: GLuint; pname: GLenum; params: PGLint); extdecl;
  1867. glGetVertexAttribPointervNV: procedure(index: GLuint; pname: GLenum; pointer: PGLvoid); extdecl;
  1868. glIsProgramNV: function(id: GLuint): GLboolean; extdecl;
  1869. glLoadProgramNV: procedure(target: GLenum; id: GLuint; len: GLsizei; const _program: PGLubyte); extdecl;
  1870. glProgramParameter4fNV: procedure(target: GLenum; index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  1871. glProgramParameter4fvNV: procedure(target: GLenum; index: GLuint; const params: PGLfloat); extdecl;
  1872. glProgramParameters4dvNV: procedure(target: GLenum; index: GLuint; num: GLuint; const params: PGLdouble); extdecl;
  1873. glProgramParameters4fvNV: procedure(target: GLenum; index: GLuint; num: GLuint; const params: PGLfloat); extdecl;
  1874. glTrackMatrixNV: procedure(target: GLenum; address: GLuint; matrix: GLenum; transform: GLenum); extdecl;
  1875. glVertexAttribPointerNV: procedure(index: GLuint; size: GLint; _type: GLenum; stride: GLsizei; const pointer: PGLvoid); extdecl;
  1876. glVertexAttrib1sNV: procedure(index: GLuint; x: GLshort); extdecl;
  1877. glVertexAttrib1fNV: procedure(index: GLuint; x: GLfloat); extdecl;
  1878. glVertexAttrib1dNV: procedure(index: GLuint; x: GLdouble); extdecl;
  1879. glVertexAttrib2sNV: procedure(index: GLuint; x: GLshort; y: GLshort); extdecl;
  1880. glVertexAttrib2fNV: procedure(index: GLuint; x: GLfloat; y: GLfloat); extdecl;
  1881. glVertexAttrib2dNV: procedure(index: GLuint; x: GLdouble; y: GLdouble); extdecl;
  1882. glVertexAttrib3sNV: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort); extdecl;
  1883. glVertexAttrib3fNV: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  1884. glVertexAttrib3dNV: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  1885. glVertexAttrib4sNV: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort; w: GLshort); extdecl;
  1886. glVertexAttrib4fNV: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  1887. glVertexAttrib4dNV: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  1888. glVertexAttrib4ubNV: procedure(index: GLuint; x: GLubyte; y: GLubyte; z: GLubyte; w: GLubyte); extdecl;
  1889. glVertexAttrib1svNV: procedure(index: GLuint; const v: PGLshort); extdecl;
  1890. glVertexAttrib1fvNV: procedure(index: GLuint; const v: PGLfloat); extdecl;
  1891. glVertexAttrib1dvNV: procedure(index: GLuint; const v: PGLdouble); extdecl;
  1892. glVertexAttrib2svNV: procedure(index: GLuint; const v: PGLshort); extdecl;
  1893. glVertexAttrib2fvNV: procedure(index: GLuint; const v: PGLfloat); extdecl;
  1894. glVertexAttrib2dvNV: procedure(index: GLuint; const v: PGLdouble); extdecl;
  1895. glVertexAttrib3svNV: procedure(index: GLuint; const v: PGLshort); extdecl;
  1896. glVertexAttrib3fvNV: procedure(index: GLuint; const v: PGLfloat); extdecl;
  1897. glVertexAttrib3dvNV: procedure(index: GLuint; const v: PGLdouble); extdecl;
  1898. glVertexAttrib4svNV: procedure(index: GLuint; const v: PGLshort); extdecl;
  1899. glVertexAttrib4fvNV: procedure(index: GLuint; const v: PGLfloat); extdecl;
  1900. glVertexAttrib4dvNV: procedure(index: GLuint; const v: PGLdouble); extdecl;
  1901. glVertexAttrib4ubvNV: procedure(index: GLuint; const v: PGLubyte); extdecl;
  1902. glVertexAttribs1svNV: procedure(index: GLuint; n: GLsizei; const v: PGLshort); extdecl;
  1903. glVertexAttribs1fvNV: procedure(index: GLuint; n: GLsizei; const v: PGLfloat); extdecl;
  1904. glVertexAttribs1dvNV: procedure(index: GLuint; n: GLsizei; const v: PGLdouble); extdecl;
  1905. glVertexAttribs2svNV: procedure(index: GLuint; n: GLsizei; const v: PGLshort); extdecl;
  1906. glVertexAttribs2fvNV: procedure(index: GLuint; n: GLsizei; const v: PGLfloat); extdecl;
  1907. glVertexAttribs2dvNV: procedure(index: GLuint; n: GLsizei; const v: PGLdouble); extdecl;
  1908. glVertexAttribs3svNV: procedure(index: GLuint; n: GLsizei; const v: PGLshort); extdecl;
  1909. glVertexAttribs3fvNV: procedure(index: GLuint; n: GLsizei; const v: PGLfloat); extdecl;
  1910. glVertexAttribs3dvNV: procedure(index: GLuint; n: GLsizei; const v: PGLdouble); extdecl;
  1911. glVertexAttribs4svNV: procedure(index: GLuint; n: GLsizei; const v: PGLshort); extdecl;
  1912. glVertexAttribs4fvNV: procedure(index: GLuint; n: GLsizei; const v: PGLfloat); extdecl;
  1913. glVertexAttribs4dvNV: procedure(index: GLuint; n: GLsizei; const v: PGLdouble); extdecl;
  1914. glVertexAttribs4ubvNV: procedure(index: GLuint; n: GLsizei; const v: PGLubyte); extdecl;
  1915. function Load_GL_NV_vertex_program: Boolean;
  1916. //***** GL_NV_vertex_program1_1 *****//
  1917. function Load_GL_NV_vertex_program1_1: Boolean;
  1918. //***** GL_ATI_element_array *****//
  1919. const
  1920. GL_ELEMENT_ARRAY_ATI = $8768;
  1921. GL_ELEMENT_ARRAY_TYPE_ATI = $8769;
  1922. GL_ELEMENT_ARRAY_POINTER_ATI = $876A;
  1923. var
  1924. glElementPointerATI: procedure(_type: GLenum; const pointer: PGLvoid); extdecl;
  1925. glDrawElementArrayATI: procedure(mode: GLenum; count: GLsizei); extdecl;
  1926. glDrawRangeElementArrayATI: procedure(mode: GLenum; start: GLuint; _end: GLuint; count: GLsizei); extdecl;
  1927. function Load_GL_ATI_element_array: Boolean;
  1928. //***** GL_ATI_envmap_bumpmap *****//
  1929. const
  1930. GL_BUMP_ROT_MATRIX_ATI = $8775;
  1931. GL_BUMP_ROT_MATRIX_SIZE_ATI = $8776;
  1932. GL_BUMP_NUM_TEX_UNITS_ATI = $8777;
  1933. GL_BUMP_TEX_UNITS_ATI = $8778;
  1934. GL_DUDV_ATI = $8779;
  1935. GL_DU8DV8_ATI = $877A;
  1936. GL_BUMP_ENVMAP_ATI = $877B;
  1937. GL_BUMP_TARGET_ATI = $877C;
  1938. var
  1939. glTexBumpParameterivATI: procedure(pname: GLenum; param: PGLint); extdecl;
  1940. glTexBumpParameterfvATI: procedure(pname: GLenum; param: PGLfloat); extdecl;
  1941. glGetTexBumpParameterivATI: procedure(pname: GLenum; param: PGLint); extdecl;
  1942. glGetTexBumpParameterfvATI: procedure(pname: GLenum; param: PGLfloat); extdecl;
  1943. function Load_GL_ATI_envmap_bumpmap: Boolean;
  1944. //***** GL_ATI_fragment_shader *****//
  1945. const
  1946. GL_FRAGMENT_SHADER_ATI = $8920;
  1947. GL_REG_0_ATI = $8921;
  1948. GL_REG_1_ATI = $8922;
  1949. GL_REG_2_ATI = $8923;
  1950. GL_REG_3_ATI = $8924;
  1951. GL_REG_4_ATI = $8925;
  1952. GL_REG_5_ATI = $8926;
  1953. GL_CON_0_ATI = $8941;
  1954. GL_CON_1_ATI = $8942;
  1955. GL_CON_2_ATI = $8943;
  1956. GL_CON_3_ATI = $8944;
  1957. GL_CON_4_ATI = $8945;
  1958. GL_CON_5_ATI = $8946;
  1959. GL_CON_6_ATI = $8947;
  1960. GL_CON_7_ATI = $8948;
  1961. GL_MOV_ATI = $8961;
  1962. GL_ADD_ATI = $8963;
  1963. GL_MUL_ATI = $8964;
  1964. GL_SUB_ATI = $8965;
  1965. GL_DOT3_ATI = $8966;
  1966. GL_DOT4_ATI = $8967;
  1967. GL_MAD_ATI = $8968;
  1968. GL_LERP_ATI = $8969;
  1969. GL_CND_ATI = $896A;
  1970. GL_CND0_ATI = $896B;
  1971. GL_DOT2_ADD_ATI = $896C;
  1972. GL_SECONDARY_INTERPOLATOR_ATI = $896D;
  1973. GL_SWIZZLE_STR_ATI = $8976;
  1974. GL_SWIZZLE_STQ_ATI = $8977;
  1975. GL_SWIZZLE_STR_DR_ATI = $8978;
  1976. GL_SWIZZLE_STQ_DQ_ATI = $8979;
  1977. GL_RED_BIT_ATI = $0001;
  1978. GL_GREEN_BIT_ATI = $0002;
  1979. GL_BLUE_BIT_ATI = $0004;
  1980. GL_2X_BIT_ATI = $0001;
  1981. GL_4X_BIT_ATI = $0002;
  1982. GL_8X_BIT_ATI = $0004;
  1983. GL_HALF_BIT_ATI = $0008;
  1984. GL_QUARTER_BIT_ATI = $0010;
  1985. GL_EIGHTH_BIT_ATI = $0020;
  1986. GL_SATURATE_BIT_ATI = $0040;
  1987. // GL_2X_BIT_ATI { already defined }
  1988. GL_COMP_BIT_ATI = $0002;
  1989. GL_NEGATE_BIT_ATI = $0004;
  1990. GL_BIAS_BIT_ATI = $0008;
  1991. var
  1992. glGenFragmentShadersATI: function(range: GLuint): GLuint; extdecl;
  1993. glBindFragmentShaderATI: procedure(id: GLuint); extdecl;
  1994. glDeleteFragmentShaderATI: procedure(id: GLuint); extdecl;
  1995. glBeginFragmentShaderATI: procedure(); extdecl;
  1996. glEndFragmentShaderATI: procedure(); extdecl;
  1997. glPassTexCoordATI: procedure(dst: GLuint; coord: GLuint; swizzle: GLenum); extdecl;
  1998. glSampleMapATI: procedure(dst: GLuint; interp: GLuint; swizzle: GLenum); extdecl;
  1999. glColorFragmentOp1ATI: procedure(op: GLenum; dst: GLuint; dstMask: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint); extdecl;
  2000. glColorFragmentOp2ATI: procedure(op: GLenum; dst: GLuint; dstMask: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint; arg2: GLuint; arg2Rep: GLuint; arg2Mod: GLuint); extdecl;
  2001. glColorFragmentOp3ATI: procedure(op: GLenum; dst: GLuint; dstMask: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint; arg2: GLuint; arg2Rep: GLuint; arg2Mod: GLuint; arg3: GLuint; arg3Rep: GLuint; arg3Mod: GLuint); extdecl;
  2002. glAlphaFragmentOp1ATI: procedure(op: GLenum; dst: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint); extdecl;
  2003. glAlphaFragmentOp2ATI: procedure(op: GLenum; dst: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint; arg2: GLuint; arg2Rep: GLuint; arg2Mod: GLuint); extdecl;
  2004. glAlphaFragmentOp3ATI: procedure(op: GLenum; dst: GLuint; dstMod: GLuint; arg1: GLuint; arg1Rep: GLuint; arg1Mod: GLuint; arg2: GLuint; arg2Rep: GLuint; arg2Mod: GLuint; arg3: GLuint; arg3Rep: GLuint; arg3Mod: GLuint); extdecl;
  2005. glSetFragmentShaderConstantATI: procedure(dst: GLuint; const value: PGLfloat); extdecl;
  2006. function Load_GL_ATI_fragment_shader: Boolean;
  2007. //***** GL_ATI_pn_triangles *****//
  2008. const
  2009. GL_PN_TRIANGLES_ATI = $87F0;
  2010. GL_MAX_PN_TRIANGLES_TESSELATION_LEVEL_ATI = $87F1;
  2011. GL_PN_TRIANGLES_POINT_MODE_ATI = $87F2;
  2012. GL_PN_TRIANGLES_NORMAL_MODE_ATI = $87F3;
  2013. GL_PN_TRIANGLES_TESSELATION_LEVEL_ATI = $87F4;
  2014. GL_PN_TRIANGLES_POINT_MODE_LINEAR_ATI = $87F5;
  2015. GL_PN_TRIANGLES_POINT_MODE_CUBIC_ATI = $87F6;
  2016. GL_PN_TRIANGLES_NORMAL_MODE_LINEAR_ATI = $87F7;
  2017. GL_PN_TRIANGLES_NORMAL_MODE_QUADRATIC_ATI = $87F8;
  2018. var
  2019. glPNTrianglesiATI: procedure(pname: GLenum; param: GLint); extdecl;
  2020. glPNTrianglesfATI: procedure(pname: GLenum; param: GLfloat); extdecl;
  2021. function Load_GL_ATI_pn_triangles: Boolean;
  2022. //***** GL_ATI_texture_mirror_once *****//
  2023. const
  2024. GL_MIRROR_CLAMP_ATI = $8742;
  2025. GL_MIRROR_CLAMP_TO_EDGE_ATI = $8743;
  2026. function Load_GL_ATI_texture_mirror_once: Boolean;
  2027. //***** GL_ATI_vertex_array_object *****//
  2028. const
  2029. GL_STATIC_ATI = $8760;
  2030. GL_DYNAMIC_ATI = $8761;
  2031. GL_PRESERVE_ATI = $8762;
  2032. GL_DISCARD_ATI = $8763;
  2033. GL_OBJECT_BUFFER_SIZE_ATI = $8764;
  2034. GL_OBJECT_BUFFER_USAGE_ATI = $8765;
  2035. GL_ARRAY_OBJECT_BUFFER_ATI = $8766;
  2036. GL_ARRAY_OBJECT_OFFSET_ATI = $8767;
  2037. var
  2038. glNewObjectBufferATI: function(size: GLsizei; const pointer: PGLvoid; usage: GLenum): GLuint; extdecl;
  2039. glIsObjectBufferATI: function(buffer: GLuint): GLboolean; extdecl;
  2040. glUpdateObjectBufferATI: procedure(buffer: GLuint; offset: GLuint; size: GLsizei; const pointer: PGLvoid; preserve: GLenum); extdecl;
  2041. glGetObjectBufferfvATI: procedure(buffer: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  2042. glGetObjectBufferivATI: procedure(buffer: GLuint; pname: GLenum; params: PGLint); extdecl;
  2043. glDeleteObjectBufferATI: procedure(buffer: GLuint); extdecl;
  2044. glArrayObjectATI: procedure(_array: GLenum; size: GLint; _type: GLenum; stride: GLsizei; buffer: GLuint; offset: GLuint); extdecl;
  2045. glGetArrayObjectfvATI: procedure(_array: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  2046. glGetArrayObjectivATI: procedure(_array: GLenum; pname: GLenum; params: PGLint); extdecl;
  2047. glVariantArrayObjectATI: procedure(id: GLuint; _type: GLenum; stride: GLsizei; buffer: GLuint; offset: GLuint); extdecl;
  2048. glGetVariantArrayObjectfvATI: procedure(id: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  2049. glGetVariantArrayObjectivATI: procedure(id: GLuint; pname: GLenum; params: PGLint); extdecl;
  2050. function Load_GL_ATI_vertex_array_object: Boolean;
  2051. //***** GL_ATI_vertex_streams *****//
  2052. const
  2053. GL_MAX_VERTEX_STREAMS_ATI = $876B;
  2054. GL_VERTEX_STREAM0_ATI = $876C;
  2055. GL_VERTEX_STREAM1_ATI = $876D;
  2056. GL_VERTEX_STREAM2_ATI = $876E;
  2057. GL_VERTEX_STREAM3_ATI = $876F;
  2058. GL_VERTEX_STREAM4_ATI = $8770;
  2059. GL_VERTEX_STREAM5_ATI = $8771;
  2060. GL_VERTEX_STREAM6_ATI = $8772;
  2061. GL_VERTEX_STREAM7_ATI = $8773;
  2062. GL_VERTEX_SOURCE_ATI = $8774;
  2063. var
  2064. glVertexStream1s: procedure(stream: GLenum; coords: GLshort); extdecl;
  2065. glVertexStream1i: procedure(stream: GLenum; coords: GLint); extdecl;
  2066. glVertexStream1f: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2067. glVertexStream1d: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2068. glVertexStream1sv: procedure(stream: GLenum; coords: GLshort); extdecl;
  2069. glVertexStream1iv: procedure(stream: GLenum; coords: GLint); extdecl;
  2070. glVertexStream1fv: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2071. glVertexStream1dv: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2072. glVertexStream2s: procedure(stream: GLenum; coords: GLshort); extdecl;
  2073. glVertexStream2i: procedure(stream: GLenum; coords: GLint); extdecl;
  2074. glVertexStream2f: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2075. glVertexStream2d: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2076. glVertexStream2sv: procedure(stream: GLenum; coords: GLshort); extdecl;
  2077. glVertexStream2iv: procedure(stream: GLenum; coords: GLint); extdecl;
  2078. glVertexStream2fv: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2079. glVertexStream2dv: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2080. glVertexStream3s: procedure(stream: GLenum; coords: GLshort); extdecl;
  2081. glVertexStream3i: procedure(stream: GLenum; coords: GLint); extdecl;
  2082. glVertexStream3f: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2083. glVertexStream3d: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2084. glVertexStream3sv: procedure(stream: GLenum; coords: GLshort); extdecl;
  2085. glVertexStream3iv: procedure(stream: GLenum; coords: GLint); extdecl;
  2086. glVertexStream3fv: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2087. glVertexStream3dv: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2088. glVertexStream4s: procedure(stream: GLenum; coords: GLshort); extdecl;
  2089. glVertexStream4i: procedure(stream: GLenum; coords: GLint); extdecl;
  2090. glVertexStream4f: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2091. glVertexStream4d: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2092. glVertexStream4sv: procedure(stream: GLenum; coords: GLshort); extdecl;
  2093. glVertexStream4iv: procedure(stream: GLenum; coords: GLint); extdecl;
  2094. glVertexStream4fv: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2095. glVertexStream4dv: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2096. glNormalStream3b: procedure(stream: GLenum; coords: GLbyte); extdecl;
  2097. glNormalStream3s: procedure(stream: GLenum; coords: GLshort); extdecl;
  2098. glNormalStream3i: procedure(stream: GLenum; coords: GLint); extdecl;
  2099. glNormalStream3f: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2100. glNormalStream3d: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2101. glNormalStream3bv: procedure(stream: GLenum; coords: GLbyte); extdecl;
  2102. glNormalStream3sv: procedure(stream: GLenum; coords: GLshort); extdecl;
  2103. glNormalStream3iv: procedure(stream: GLenum; coords: GLint); extdecl;
  2104. glNormalStream3fv: procedure(stream: GLenum; coords: GLfloat); extdecl;
  2105. glNormalStream3dv: procedure(stream: GLenum; coords: GLdouble); extdecl;
  2106. glClientActiveVertexStream: procedure(stream: GLenum); extdecl;
  2107. glVertexBlendEnvi: procedure(pname: GLenum; param: GLint); extdecl;
  2108. glVertexBlendEnvf: procedure(pname: GLenum; param: GLfloat); extdecl;
  2109. function Load_GL_ATI_vertex_streams: Boolean;
  2110. {$IFDEF Windows}
  2111. //***** WGL_I3D_image_buffer *****//
  2112. const
  2113. WGL_IMAGE_BUFFER_MIN_ACCESS_I3D = $0001;
  2114. WGL_IMAGE_BUFFER_LOCK_I3D = $0002;
  2115. var
  2116. wglCreateImageBufferI3D: function(hDC: HDC; dwSize: DWORD; uFlags: UINT): PGLvoid; extdecl;
  2117. wglDestroyImageBufferI3D: function(hDC: HDC; pAddress: PGLvoid): BOOL; extdecl;
  2118. wglAssociateImageBufferEventsI3D: function(hdc: HDC; pEvent: PHandle; pAddress: PGLvoid; pSize: PDWORD; count: UINT): BOOL; extdecl;
  2119. wglReleaseImageBufferEventsI3D: function(hdc: HDC; pAddress: PGLvoid; count: UINT): BOOL; extdecl;
  2120. function Load_WGL_I3D_image_buffer: Boolean;
  2121. //***** WGL_I3D_swap_frame_lock *****//
  2122. var
  2123. wglEnableFrameLockI3D: function(): BOOL; extdecl;
  2124. wglDisableFrameLockI3D: function(): BOOL; extdecl;
  2125. wglIsEnabledFrameLockI3D: function(pFlag: PBOOL): BOOL; extdecl;
  2126. wglQueryFrameLockMasterI3D: function(pFlag: PBOOL): BOOL; extdecl;
  2127. function Load_WGL_I3D_swap_frame_lock: Boolean;
  2128. //***** WGL_I3D_swap_frame_usage *****//
  2129. var
  2130. wglGetFrameUsageI3D: function(pUsage: PGLfloat): BOOL; extdecl;
  2131. wglBeginFrameTrackingI3D: function(): BOOL; extdecl;
  2132. wglEndFrameTrackingI3D: function(): BOOL; extdecl;
  2133. wglQueryFrameTrackingI3D: function(pFrameCount: PDWORD; pMissedFrames: PDWORD; pLastMissedUsage: PGLfloat): BOOL; extdecl;
  2134. function Load_WGL_I3D_swap_frame_usage: Boolean;
  2135. {$ENDIF}
  2136. //***** GL_3DFX_texture_compression_FXT1 *****//
  2137. const
  2138. GL_COMPRESSED_RGB_FXT1_3DFX = $86B0;
  2139. GL_COMPRESSED_RGBA_FXT1_3DFX = $86B1;
  2140. function Load_GL_3DFX_texture_compression_FXT1: Boolean;
  2141. //***** GL_IBM_cull_vertex *****//
  2142. const
  2143. GL_CULL_VERTEX_IBM = $1928A;
  2144. function Load_GL_IBM_cull_vertex: Boolean;
  2145. //***** GL_IBM_multimode_draw_arrays *****//
  2146. var
  2147. glMultiModeDrawArraysIBM: procedure(mode: PGLenum; first: PGLint; count: PGLsizei; primcount: GLsizei; modestride: GLint); extdecl;
  2148. glMultiModeDrawElementsIBM: procedure(mode: PGLenum; count: PGLsizei; _type: GLenum; const indices: PGLvoid; primcount: GLsizei; modestride: GLint); extdecl;
  2149. function Load_GL_IBM_multimode_draw_arrays: Boolean;
  2150. //***** GL_IBM_raster_pos_clip *****//
  2151. const
  2152. GL_RASTER_POSITION_UNCLIPPED_IBM = $19262;
  2153. function Load_GL_IBM_raster_pos_clip: Boolean;
  2154. //***** GL_IBM_texture_mirrored_repeat *****//
  2155. const
  2156. GL_MIRRORED_REPEAT_IBM = $8370;
  2157. function Load_GL_IBM_texture_mirrored_repeat: Boolean;
  2158. //***** GL_IBM_vertex_array_lists *****//
  2159. const
  2160. GL_VERTEX_ARRAY_LIST_IBM = $1929E;
  2161. GL_NORMAL_ARRAY_LIST_IBM = $1929F;
  2162. GL_COLOR_ARRAY_LIST_IBM = $192A0;
  2163. GL_INDEX_ARRAY_LIST_IBM = $192A1;
  2164. GL_TEXTURE_COORD_ARRAY_LIST_IBM = $192A2;
  2165. GL_EDGE_FLAG_ARRAY_LIST_IBM = $192A3;
  2166. GL_FOG_COORDINATE_ARRAY_LIST_IBM = $192A4;
  2167. GL_SECONDARY_COLOR_ARRAY_LIST_IBM = $192A5;
  2168. GL_VERTEX_ARRAY_LIST_STRIDE_IBM = $192A8;
  2169. GL_NORMAL_ARRAY_LIST_STRIDE_IBM = $192A9;
  2170. GL_COLOR_ARRAY_LIST_STRIDE_IBM = $192AA;
  2171. GL_INDEX_ARRAY_LIST_STRIDE_IBM = $192AB;
  2172. GL_TEXTURE_COORD_ARRAY_LIST_STRIDE_IBM = $192AC;
  2173. GL_EDGE_FLAG_ARRAY_LIST_STRIDE_IBM = $192AD;
  2174. GL_FOG_COORDINATE_ARRAY_LIST_STRIDE_IBM = $192AE;
  2175. GL_SECONDARY_COLOR_ARRAY_LIST_STRIDE_IBM = $192AF;
  2176. var
  2177. glColorPointerListIBM: procedure(size: GLint; _type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2178. glSecondaryColorPointerListIBM: procedure(size: GLint; _type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2179. glEdgeFlagPointerListIBM: procedure(stride: GLint; const pointer: PGLboolean; ptrstride: GLint); extdecl;
  2180. glFogCoordPointerListIBM: procedure(_type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2181. glNormalPointerListIBM: procedure(_type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2182. glTexCoordPointerListIBM: procedure(size: GLint; _type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2183. glVertexPointerListIBM: procedure(size: GLint; _type: GLenum; stride: GLint; const pointer: PGLvoid; ptrstride: GLint); extdecl;
  2184. function Load_GL_IBM_vertex_array_lists: Boolean;
  2185. //***** GL_MESA_resize_buffers *****//
  2186. var
  2187. glResizeBuffersMESA: procedure(); extdecl;
  2188. function Load_GL_MESA_resize_buffers: Boolean;
  2189. //***** GL_MESA_window_pos *****//
  2190. var
  2191. glWindowPos2dMESA: procedure(x: GLdouble; y: GLdouble); extdecl;
  2192. glWindowPos2fMESA: procedure(x: GLfloat; y: GLfloat); extdecl;
  2193. glWindowPos2iMESA: procedure(x: GLint; y: GLint); extdecl;
  2194. glWindowPos2sMESA: procedure(x: GLshort; y: GLshort); extdecl;
  2195. glWindowPos2ivMESA: procedure(const p: PGLint); extdecl;
  2196. glWindowPos2svMESA: procedure(const p: PGLshort); extdecl;
  2197. glWindowPos2fvMESA: procedure(const p: PGLfloat); extdecl;
  2198. glWindowPos2dvMESA: procedure(const p: PGLdouble); extdecl;
  2199. glWindowPos3iMESA: procedure(x: GLint; y: GLint; z: GLint); extdecl;
  2200. glWindowPos3sMESA: procedure(x: GLshort; y: GLshort; z: GLshort); extdecl;
  2201. glWindowPos3fMESA: procedure(x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2202. glWindowPos3dMESA: procedure(x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  2203. glWindowPos3ivMESA: procedure(const p: PGLint); extdecl;
  2204. glWindowPos3svMESA: procedure(const p: PGLshort); extdecl;
  2205. glWindowPos3fvMESA: procedure(const p: PGLfloat); extdecl;
  2206. glWindowPos3dvMESA: procedure(const p: PGLdouble); extdecl;
  2207. glWindowPos4iMESA: procedure(x: GLint; y: GLint; z: GLint; w: GLint); extdecl;
  2208. glWindowPos4sMESA: procedure(x: GLshort; y: GLshort; z: GLshort; w: GLshort); extdecl;
  2209. glWindowPos4fMESA: procedure(x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  2210. glWindowPos4dMESA: procedure(x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  2211. glWindowPos4ivMESA: procedure(const p: PGLint); extdecl;
  2212. glWindowPos4svMESA: procedure(const p: PGLshort); extdecl;
  2213. glWindowPos4fvMESA: procedure(const p: PGLfloat); extdecl;
  2214. glWindowPos4dvMESA: procedure(const p: PGLdouble); extdecl;
  2215. function Load_GL_MESA_window_pos: Boolean;
  2216. //***** GL_OML_interlace *****//
  2217. const
  2218. GL_INTERLACE_OML = $8980;
  2219. GL_INTERLACE_READ_OML = $8981;
  2220. function Load_GL_OML_interlace: Boolean;
  2221. //***** GL_OML_resample *****//
  2222. const
  2223. GL_PACK_RESAMPLE_OML = $8984;
  2224. GL_UNPACK_RESAMPLE_OML = $8985;
  2225. GL_RESAMPLE_REPLICATE_OML = $8986;
  2226. GL_RESAMPLE_ZERO_FILL_OML = $8987;
  2227. GL_RESAMPLE_AVERAGE_OML = $8988;
  2228. GL_RESAMPLE_DECIMATE_OML = $8989;
  2229. // GL_RESAMPLE_AVERAGE_OML { already defined }
  2230. function Load_GL_OML_resample: Boolean;
  2231. //***** GL_OML_subsample *****//
  2232. const
  2233. GL_FORMAT_SUBSAMPLE_24_24_OML = $8982;
  2234. GL_FORMAT_SUBSAMPLE_244_244_OML = $8983;
  2235. function Load_GL_OML_subsample: Boolean;
  2236. //***** GL_SGIS_generate_mipmap *****//
  2237. const
  2238. GL_GENERATE_MIPMAP_SGIS = $8191;
  2239. GL_GENERATE_MIPMAP_HINT_SGIS = $8192;
  2240. function Load_GL_SGIS_generate_mipmap: Boolean;
  2241. //***** GL_SGIS_multisample *****//
  2242. const
  2243. GLX_SAMPLE_BUFFERS_SGIS = $186A0;
  2244. GLX_SAMPLES_SGIS = $186A1;
  2245. GL_MULTISAMPLE_SGIS = $809D;
  2246. GL_SAMPLE_ALPHA_TO_MASK_SGIS = $809E;
  2247. GL_SAMPLE_ALPHA_TO_ONE_SGIS = $809F;
  2248. GL_SAMPLE_MASK_SGIS = $80A0;
  2249. GL_MULTISAMPLE_BIT_EXT = $20000000;
  2250. GL_1PASS_SGIS = $80A1;
  2251. GL_2PASS_0_SGIS = $80A2;
  2252. GL_2PASS_1_SGIS = $80A3;
  2253. GL_4PASS_0_SGIS = $80A4;
  2254. GL_4PASS_1_SGIS = $80A5;
  2255. GL_4PASS_2_SGIS = $80A6;
  2256. GL_4PASS_3_SGIS = $80A7;
  2257. GL_SAMPLE_BUFFERS_SGIS = $80A8;
  2258. GL_SAMPLES_SGIS = $80A9;
  2259. GL_SAMPLE_MASK_VALUE_SGIS = $80AA;
  2260. GL_SAMPLE_MASK_INVERT_SGIS = $80AB;
  2261. GL_SAMPLE_PATTERN_SGIS = $80AC;
  2262. var
  2263. glSampleMaskSGIS: procedure(value: GLclampf; invert: GLboolean); extdecl;
  2264. glSamplePatternSGIS: procedure(pattern: GLenum); extdecl;
  2265. function Load_GL_SGIS_multisample: Boolean;
  2266. //***** GL_SGIS_pixel_texture *****//
  2267. const
  2268. GL_PIXEL_TEXTURE_SGIS = $8353;
  2269. GL_PIXEL_FRAGMENT_RGB_SOURCE_SGIS = $8354;
  2270. GL_PIXEL_FRAGMENT_ALPHA_SOURCE_SGIS = $8355;
  2271. GL_PIXEL_GROUP_COLOR_SGIS = $8356;
  2272. var
  2273. glPixelTexGenParameteriSGIS: procedure(pname: GLenum; param: GLint); extdecl;
  2274. glPixelTexGenParameterfSGIS: procedure(pname: GLenum; param: GLfloat); extdecl;
  2275. glGetPixelTexGenParameterivSGIS: procedure(pname: GLenum; params: GLint); extdecl;
  2276. glGetPixelTexGenParameterfvSGIS: procedure(pname: GLenum; params: GLfloat); extdecl;
  2277. function Load_GL_SGIS_pixel_texture: Boolean;
  2278. //***** GL_SGIS_texture_border_clamp *****//
  2279. // GL_CLAMP_TO_BORDER_SGIS { already defined }
  2280. function Load_GL_SGIS_texture_border_clamp: Boolean;
  2281. //***** GL_SGIS_texture_color_mask *****//
  2282. const
  2283. GL_TEXTURE_COLOR_WRITEMASK_SGIS = $81EF;
  2284. var
  2285. glTextureColorMaskSGIS: procedure(r: GLboolean; g: GLboolean; b: GLboolean; a: GLboolean); extdecl;
  2286. function Load_GL_SGIS_texture_color_mask: Boolean;
  2287. //***** GL_SGIS_texture_edge_clamp *****//
  2288. const
  2289. GL_CLAMP_TO_EDGE_SGIS = $812F;
  2290. function Load_GL_SGIS_texture_edge_clamp: Boolean;
  2291. //***** GL_SGIS_texture_lod *****//
  2292. const
  2293. GL_TEXTURE_MIN_LOD_SGIS = $813A;
  2294. GL_TEXTURE_MAX_LOD_SGIS = $813B;
  2295. GL_TEXTURE_BASE_LEVEL_SGIS = $813C;
  2296. GL_TEXTURE_MAX_LEVEL_SGIS = $813D;
  2297. function Load_GL_SGIS_texture_lod: Boolean;
  2298. //***** GL_SGIS_depth_texture *****//
  2299. const
  2300. GL_DEPTH_COMPONENT16_SGIX = $81A5;
  2301. GL_DEPTH_COMPONENT24_SGIX = $81A6;
  2302. GL_DEPTH_COMPONENT32_SGIX = $81A7;
  2303. function Load_GL_SGIS_depth_texture: Boolean;
  2304. //***** GL_SGIX_fog_offset *****//
  2305. const
  2306. GL_FOG_OFFSET_SGIX = $8198;
  2307. GL_FOG_OFFSET_VALUE_SGIX = $8199;
  2308. function Load_GL_SGIX_fog_offset: Boolean;
  2309. //***** GL_SGIX_interlace *****//
  2310. const
  2311. GL_INTERLACE_SGIX = $8094;
  2312. function Load_GL_SGIX_interlace: Boolean;
  2313. //***** GL_SGIX_shadow_ambient *****//
  2314. const
  2315. GL_SHADOW_AMBIENT_SGIX = $80BF;
  2316. function Load_GL_SGIX_shadow_ambient: Boolean;
  2317. //***** GL_SGI_color_matrix *****//
  2318. const
  2319. GL_COLOR_MATRIX_SGI = $80B1;
  2320. GL_COLOR_MATRIX_STACK_DEPTH_SGI = $80B2;
  2321. GL_MAX_COLOR_MATRIX_STACK_DEPTH_SGI = $80B3;
  2322. GL_POST_COLOR_MATRIX_RED_SCALE_SGI = $80B4;
  2323. GL_POST_COLOR_MATRIX_GREEN_SCALE_SGI = $80B5;
  2324. GL_POST_COLOR_MATRIX_BLUE_SCALE_SGI = $80B6;
  2325. GL_POST_COLOR_MATRIX_ALPHA_SCALE_SGI = $80B7;
  2326. GL_POST_COLOR_MATRIX_RED_BIAS_SGI = $80B8;
  2327. GL_POST_COLOR_MATRIX_GREEN_BIAS_SGI = $80B9;
  2328. GL_POST_COLOR_MATRIX_BLUE_BIAS_SGI = $80BA;
  2329. GL_POST_COLOR_MATRIX_ALPHA_BIAS_SGI = $80BB;
  2330. function Load_GL_SGI_color_matrix: Boolean;
  2331. //***** GL_SGI_color_table *****//
  2332. const
  2333. GL_COLOR_TABLE_SGI = $80D0;
  2334. GL_POST_CONVOLUTION_COLOR_TABLE_SGI = $80D1;
  2335. GL_POST_COLOR_MATRIX_COLOR_TABLE_SGI = $80D2;
  2336. GL_PROXY_COLOR_TABLE_SGI = $80D3;
  2337. GL_PROXY_POST_CONVOLUTION_COLOR_TABLE_SGI = $80D4;
  2338. GL_PROXY_POST_COLOR_MATRIX_COLOR_TABLE_SGI = $80D5;
  2339. GL_COLOR_TABLE_SCALE_SGI = $80D6;
  2340. GL_COLOR_TABLE_BIAS_SGI = $80D7;
  2341. GL_COLOR_TABLE_FORMAT_SGI = $80D8;
  2342. GL_COLOR_TABLE_WIDTH_SGI = $80D9;
  2343. GL_COLOR_TABLE_RED_SIZE_SGI = $80DA;
  2344. GL_COLOR_TABLE_GREEN_SIZE_SGI = $80DB;
  2345. GL_COLOR_TABLE_BLUE_SIZE_SGI = $80DC;
  2346. GL_COLOR_TABLE_ALPHA_SIZE_SGI = $80DD;
  2347. GL_COLOR_TABLE_LUMINANCE_SIZE_SGI = $80DE;
  2348. GL_COLOR_TABLE_INTENSITY_SIZE_SGI = $80DF;
  2349. var
  2350. glColorTableSGI: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; format: GLenum; _type: GLenum; const table: PGLvoid); extdecl;
  2351. glCopyColorTableSGI: procedure(target: GLenum; internalformat: GLenum; x: GLint; y: GLint; width: GLsizei); extdecl;
  2352. glColorTableParameterivSGI: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  2353. glColorTableParameterfvSGI: procedure(target: GLenum; pname: GLenum; const params: PGLfloat); extdecl;
  2354. glGetColorTableSGI: procedure(target: GLenum; format: GLenum; _type: GLenum; table: PGLvoid); extdecl;
  2355. glGetColorTableParameterivSGI: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  2356. glGetColorTableParameterfvSGI: procedure(target: GLenum; pname: GLenum; params: PGLfloat); extdecl;
  2357. function Load_GL_SGI_color_table: Boolean;
  2358. //***** GL_SGI_texture_color_table *****//
  2359. const
  2360. GL_TEXTURE_COLOR_TABLE_SGI = $80BC;
  2361. GL_PROXY_TEXTURE_COLOR_TABLE_SGI = $80BD;
  2362. function Load_GL_SGI_texture_color_table: Boolean;
  2363. //***** GL_SUN_vertex *****//
  2364. var
  2365. glColor4ubVertex2fSUN: procedure(r: GLubyte; g: GLubyte; b: GLubyte; a: GLubyte; x: GLfloat; y: GLfloat); extdecl;
  2366. glColor4ubVertex2fvSUN: procedure(const c: PGLubyte; const v: PGLfloat); extdecl;
  2367. glColor4ubVertex3fSUN: procedure(r: GLubyte; g: GLubyte; b: GLubyte; a: GLubyte; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2368. glColor4ubVertex3fvSUN: procedure(const c: PGLubyte; const v: PGLfloat); extdecl;
  2369. glColor3fVertex3fSUN: procedure(r: GLfloat; g: GLfloat; b: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2370. glColor3fVertex3fvSUN: procedure(const c: PGLfloat; const v: PGLfloat); extdecl;
  2371. glNormal3fVertex3fSUN: procedure(nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2372. glNormal3fVertex3fvSUN: procedure(const n: PGLfloat; const v: PGLfloat); extdecl;
  2373. glColor4fNormal3fVertex3fSUN: procedure(r: GLfloat; g: GLfloat; b: GLfloat; a: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2374. glColor4fNormal3fVertex3fvSUN: procedure(const c: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2375. glTexCoord2fVertex3fSUN: procedure(s: GLfloat; t: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2376. glTexCoord2fVertex3fvSUN: procedure(const tc: PGLfloat; const v: PGLfloat); extdecl;
  2377. glTexCoord4fVertex4fSUN: procedure(s: GLfloat; t: GLfloat; p: GLfloat; q: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  2378. glTexCoord4fVertex4fvSUN: procedure(const tc: PGLfloat; const v: PGLfloat); extdecl;
  2379. glTexCoord2fColor4ubVertex3fSUN: procedure(s: GLfloat; t: GLfloat; r: GLubyte; g: GLubyte; b: GLubyte; a: GLubyte; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2380. glTexCoord2fColor4ubVertex3fvSUN: procedure(const tc: PGLfloat; const c: PGLubyte; const v: PGLfloat); extdecl;
  2381. glTexCoord2fColor3fVertex3fSUN: procedure(s: GLfloat; t: GLfloat; r: GLfloat; g: GLfloat; b: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2382. glTexCoord2fColor3fVertex3fvSUN: procedure(const tc: PGLfloat; const c: PGLfloat; const v: PGLfloat); extdecl;
  2383. glTexCoord2fNormal3fVertex3fSUN: procedure(s: GLfloat; t: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2384. glTexCoord2fNormal3fVertex3fvSUN: procedure(const tc: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2385. glTexCoord2fColor4fNormal3fVertex3fSUN: procedure(s: GLfloat; t: GLfloat; r: GLfloat; g: GLfloat; b: GLfloat; a: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2386. glTexCoord2fColor4fNormal3fVertex3fvSUN: procedure(const tc: PGLfloat; const c: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2387. glTexCoord4fColor4fNormal3fVertex4fSUN: procedure(s: GLfloat; t: GLfloat; p: GLfloat; q: GLfloat; r: GLfloat; g: GLfloat; b: GLfloat; a: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  2388. glTexCoord4fColor4fNormal3fVertex4fvSUN: procedure(const tc: PGLfloat; const c: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2389. glReplacementCodeuiVertex3fSUN: procedure(rc: GLuint; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2390. glReplacementCodeuiVertex3fvSUN: procedure(const rc: PGLuint; const v: PGLfloat); extdecl;
  2391. glReplacementCodeuiColor4ubVertex3fSUN: procedure(rc: GLuint; r: GLubyte; g: GLubyte; b: GLubyte; a: GLubyte; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2392. glReplacementCodeuiColor4ubVertex3fvSUN: procedure(const rc: PGLuint; const c: PGLubyte; const v: PGLfloat); extdecl;
  2393. glReplacementCodeuiColor3fVertex3fSUN: procedure(rc: GLuint; r: GLfloat; g: GLfloat; b: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2394. glReplacementCodeuiColor3fVertex3fvSUN: procedure(const rc: PGLuint; const c: PGLfloat; const v: PGLfloat); extdecl;
  2395. glReplacementCodeuiNormal3fVertex3fSUN: procedure(rc: GLuint; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2396. glReplacementCodeuiNormal3fVertex3fvSUN: procedure(const rc: PGLuint; const n: PGLfloat; const v: PGLfloat); extdecl;
  2397. glReplacementCodeuiColor4fNormal3fVertex3fSUN: procedure(rc: GLuint; r: GLfloat; g: GLfloat; b: GLfloat; a: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2398. glReplacementCodeuiColor4fNormal3fVertex3fvSUN: procedure(const rc: PGLuint; const c: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2399. glReplacementCodeuiTexCoord2fVertex3fSUN: procedure(rc: GLuint; s: GLfloat; t: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2400. glReplacementCodeuiTexCoord2fVertex3fvSUN: procedure(const rc: PGLuint; const tc: PGLfloat; const v: PGLfloat); extdecl;
  2401. glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN: procedure(rc: GLuint; s: GLfloat; t: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2402. glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN: procedure(const rc: PGLuint; const tc: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2403. glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN: procedure(rc: GLuint; s: GLfloat; t: GLfloat; r: GLfloat; g: GLfloat; b: GLfloat; a: GLfloat; nx: GLfloat; ny: GLfloat; nz: GLfloat; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  2404. glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN: procedure(const rc: PGLuint; const tc: PGLfloat; const c: PGLfloat; const n: PGLfloat; const v: PGLfloat); extdecl;
  2405. function Load_GL_SUN_vertex: Boolean;
  2406. //***** GL_ARB_fragment_program *****//
  2407. const
  2408. GL_FRAGMENT_PROGRAM_ARB = $8804;
  2409. // GL_PROGRAM_FORMAT_ASCII_ARB { already defined }
  2410. // GL_PROGRAM_LENGTH_ARB { already defined }
  2411. // GL_PROGRAM_FORMAT_ARB { already defined }
  2412. // GL_PROGRAM_BINDING_ARB { already defined }
  2413. // GL_PROGRAM_INSTRUCTIONS_ARB { already defined }
  2414. // GL_MAX_PROGRAM_INSTRUCTIONS_ARB { already defined }
  2415. // GL_PROGRAM_NATIVE_INSTRUCTIONS_ARB { already defined }
  2416. // GL_MAX_PROGRAM_NATIVE_INSTRUCTIONS_ARB { already defined }
  2417. // GL_PROGRAM_TEMPORARIES_ARB { already defined }
  2418. // GL_MAX_PROGRAM_TEMPORARIES_ARB { already defined }
  2419. // GL_PROGRAM_NATIVE_TEMPORARIES_ARB { already defined }
  2420. // GL_MAX_PROGRAM_NATIVE_TEMPORARIES_ARB { already defined }
  2421. // GL_PROGRAM_PARAMETERS_ARB { already defined }
  2422. // GL_MAX_PROGRAM_PARAMETERS_ARB { already defined }
  2423. // GL_PROGRAM_NATIVE_PARAMETERS_ARB { already defined }
  2424. // GL_MAX_PROGRAM_NATIVE_PARAMETERS_ARB { already defined }
  2425. // GL_PROGRAM_ATTRIBS_ARB { already defined }
  2426. // GL_MAX_PROGRAM_ATTRIBS_ARB { already defined }
  2427. // GL_PROGRAM_NATIVE_ATTRIBS_ARB { already defined }
  2428. // GL_MAX_PROGRAM_NATIVE_ATTRIBS_ARB { already defined }
  2429. // GL_MAX_PROGRAM_LOCAL_PARAMETERS_ARB { already defined }
  2430. // GL_MAX_PROGRAM_ENV_PARAMETERS_ARB { already defined }
  2431. // GL_PROGRAM_UNDER_NATIVE_LIMITS_ARB { already defined }
  2432. GL_PROGRAM_ALU_INSTRUCTIONS_ARB = $8805;
  2433. GL_PROGRAM_TEX_INSTRUCTIONS_ARB = $8806;
  2434. GL_PROGRAM_TEX_INDIRECTIONS_ARB = $8807;
  2435. GL_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB = $8808;
  2436. GL_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB = $8809;
  2437. GL_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB = $880A;
  2438. GL_MAX_PROGRAM_ALU_INSTRUCTIONS_ARB = $880B;
  2439. GL_MAX_PROGRAM_TEX_INSTRUCTIONS_ARB = $880C;
  2440. GL_MAX_PROGRAM_TEX_INDIRECTIONS_ARB = $880D;
  2441. GL_MAX_PROGRAM_NATIVE_ALU_INSTRUCTIONS_ARB = $880E;
  2442. GL_MAX_PROGRAM_NATIVE_TEX_INSTRUCTIONS_ARB = $880F;
  2443. GL_MAX_PROGRAM_NATIVE_TEX_INDIRECTIONS_ARB = $8810;
  2444. // GL_PROGRAM_STRING_ARB { already defined }
  2445. // GL_PROGRAM_ERROR_POSITION_ARB { already defined }
  2446. // GL_CURRENT_MATRIX_ARB { already defined }
  2447. // GL_TRANSPOSE_CURRENT_MATRIX_ARB { already defined }
  2448. // GL_CURRENT_MATRIX_STACK_DEPTH_ARB { already defined }
  2449. // GL_MAX_PROGRAM_MATRICES_ARB { already defined }
  2450. // GL_MAX_PROGRAM_MATRIX_STACK_DEPTH_ARB { already defined }
  2451. GL_MAX_TEXTURE_COORDS_ARB = $8871;
  2452. GL_MAX_TEXTURE_IMAGE_UNITS_ARB = $8872;
  2453. // GL_PROGRAM_ERROR_STRING_ARB { already defined }
  2454. // GL_MATRIX0_ARB { already defined }
  2455. // GL_MATRIX1_ARB { already defined }
  2456. // GL_MATRIX2_ARB { already defined }
  2457. // GL_MATRIX3_ARB { already defined }
  2458. // GL_MATRIX4_ARB { already defined }
  2459. // GL_MATRIX5_ARB { already defined }
  2460. // GL_MATRIX6_ARB { already defined }
  2461. // GL_MATRIX7_ARB { already defined }
  2462. // GL_MATRIX8_ARB { already defined }
  2463. // GL_MATRIX9_ARB { already defined }
  2464. // GL_MATRIX10_ARB { already defined }
  2465. // GL_MATRIX11_ARB { already defined }
  2466. // GL_MATRIX12_ARB { already defined }
  2467. // GL_MATRIX13_ARB { already defined }
  2468. // GL_MATRIX14_ARB { already defined }
  2469. // GL_MATRIX15_ARB { already defined }
  2470. // GL_MATRIX16_ARB { already defined }
  2471. // GL_MATRIX17_ARB { already defined }
  2472. // GL_MATRIX18_ARB { already defined }
  2473. // GL_MATRIX19_ARB { already defined }
  2474. // GL_MATRIX20_ARB { already defined }
  2475. // GL_MATRIX21_ARB { already defined }
  2476. // GL_MATRIX22_ARB { already defined }
  2477. // GL_MATRIX23_ARB { already defined }
  2478. // GL_MATRIX24_ARB { already defined }
  2479. // GL_MATRIX25_ARB { already defined }
  2480. // GL_MATRIX26_ARB { already defined }
  2481. // GL_MATRIX27_ARB { already defined }
  2482. // GL_MATRIX28_ARB { already defined }
  2483. // GL_MATRIX29_ARB { already defined }
  2484. // GL_MATRIX30_ARB { already defined }
  2485. // GL_MATRIX31_ARB { already defined }
  2486. // glProgramStringARB { already defined }
  2487. // glBindProgramARB { already defined }
  2488. // glDeleteProgramsARB { already defined }
  2489. // glGenProgramsARB { already defined }
  2490. // glProgramEnvParameter4dARB { already defined }
  2491. // glProgramEnvParameter4dvARB { already defined }
  2492. // glProgramEnvParameter4fARB { already defined }
  2493. // glProgramEnvParameter4fvARB { already defined }
  2494. // glProgramLocalParameter4dARB { already defined }
  2495. // glProgramLocalParameter4dvARB { already defined }
  2496. // glProgramLocalParameter4fARB { already defined }
  2497. // glProgramLocalParameter4fvARB { already defined }
  2498. // glGetProgramEnvParameterdvARB { already defined }
  2499. // glGetProgramEnvParameterfvARB { already defined }
  2500. // glGetProgramLocalParameterdvARB { already defined }
  2501. // glGetProgramLocalParameterfvARB { already defined }
  2502. // glGetProgramivARB { already defined }
  2503. // glGetProgramStringARB { already defined }
  2504. // glIsProgramARB { already defined }
  2505. function Load_GL_ARB_fragment_program: Boolean;
  2506. {***** GL_ATI_text_fragment_shader *****}
  2507. const
  2508. GL_TEXT_FRAGMENT_SHADER_ATI = $8200;
  2509. function Load_GL_ATI_text_fragment_shader: Boolean;
  2510. {***** GL_ARB_vertex_buffer_object *****}
  2511. const
  2512. GL_BUFFER_SIZE_ARB = $8764;
  2513. GL_BUFFER_USAGE_ARB = $8765;
  2514. GL_ARRAY_BUFFER_ARB = $8892;
  2515. GL_ELEMENT_ARRAY_BUFFER_ARB = $8893;
  2516. GL_ARRAY_BUFFER_BINDING_ARB = $8894;
  2517. GL_ELEMENT_ARRAY_BUFFER_BINDING_ARB = $8895;
  2518. GL_VERTEX_ARRAY_BUFFER_BINDING_ARB = $8896;
  2519. GL_NORMAL_ARRAY_BUFFER_BINDING_ARB = $8897;
  2520. GL_COLOR_ARRAY_BUFFER_BINDING_ARB = $8898;
  2521. GL_INDEX_ARRAY_BUFFER_BINDING_ARB = $8899;
  2522. GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING_ARB = $889A;
  2523. GL_EDGE_FLAG_ARRAY_BUFFER_BINDING_ARB = $889B;
  2524. GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING_ARB = $889C;
  2525. GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING_ARB = $889D;
  2526. GL_WEIGHT_ARRAY_BUFFER_BINDING_ARB = $889E;
  2527. GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB = $889F;
  2528. GL_READ_ONLY_ARB = $88B8;
  2529. GL_WRITE_ONLY_ARB = $88B9;
  2530. GL_READ_WRITE_ARB = $88BA;
  2531. GL_BUFFER_ACCESS_ARB = $88BB;
  2532. GL_BUFFER_MAPPED_ARB = $88BC;
  2533. GL_BUFFER_MAP_POINTER_ARB = $88BD;
  2534. GL_STREAM_DRAW_ARB = $88E0;
  2535. GL_STREAM_READ_ARB = $88E1;
  2536. GL_STREAM_COPY_ARB = $88E2;
  2537. GL_STATIC_DRAW_ARB = $88E4;
  2538. GL_STATIC_READ_ARB = $88E5;
  2539. GL_STATIC_COPY_ARB = $88E6;
  2540. GL_DYNAMIC_DRAW_ARB = $88E8;
  2541. GL_DYNAMIC_READ_ARB = $88E9;
  2542. GL_DYNAMIC_COPY_ARB = $88EA;
  2543. var
  2544. glBindBufferARB : procedure(target : GLenum; buffer: GLuint); extdecl;
  2545. glDeleteBuffersARB : procedure(n : GLsizei; buffers : PGLuint); extdecl;
  2546. glGenBuffersARB : procedure(n : GLsizei; buffers : PGLuint); extdecl;
  2547. glIsBufferARB : function (buffer : GLuint) :GLboolean; extdecl;
  2548. glBufferDataARB : procedure(target : GLenum; size:GLsizei; data:PGLvoid;usage: GLenum); extdecl;
  2549. glBufferSubDataARB : procedure(target : GLenum; offset :GLint; size : GLsizei; data: PGLvoid); extdecl;
  2550. glGetBufferSubDataARB : procedure(target : GLenum; offset :GLint; size : GLsizei; data: PGLvoid); extdecl;
  2551. glMapBufferARB : function (target :GLenum; access: GLenum) : PGLvoid; extdecl;
  2552. glUnmapBufferARB : function (target :GLenum) :GLboolean; extdecl;
  2553. glGetBufferParameterivARB:procedure(target:GLenum; pname:GLenum; params:PGLint); extdecl;
  2554. glGetBufferPointervARB : procedure(target: GLenum; pname:GLenum; params: PPGLvoid); extdecl;
  2555. function Load_GL_ARB_vertex_buffer_object : boolean;
  2556. //***** GL_APPLE_client_storage *****//
  2557. const
  2558. GL_UNPACK_CLIENT_STORAGE_APPLE = $85B2;
  2559. function Load_GL_APPLE_client_storage: Boolean;
  2560. //***** GL_APPLE_element_array *****//
  2561. const
  2562. GL_ELEMENT_ARRAY_APPLE = $8768;
  2563. GL_ELEMENT_ARRAY_TYPE_APPLE = $8769;
  2564. GL_ELEMENT_ARRAY_POINTER_APPLE = $876A;
  2565. var
  2566. glElementPointerAPPLE: procedure(_type: GLenum; const pointer: PGLvoid); extdecl;
  2567. glDrawElementArrayAPPLE: procedure(mode: GLenum; first: GLint; count: GLsizei); extdecl;
  2568. glDrawRangeElementArrayAPPLE: procedure(mode: GLenum; start: GLuint; _end: GLuint; first: GLint; count: GLsizei); extdecl;
  2569. glMultiDrawElementArrayAPPLE: procedure(mode: GLenum; const first: PGLint; const count: PGLsizei; primcount: GLsizei); extdecl;
  2570. glMultiDrawRangeElementArrayAPPLE: procedure(mode: GLenum; start: GLuint; _end: GLuint; const first: PGLint; const count: PGLsizei; primcount: GLsizei); extdecl;
  2571. function Load_GL_APPLE_element_array: Boolean;
  2572. //***** GL_APPLE_fence *****//
  2573. const
  2574. GL_DRAW_PIXELS_APPLE = $8A0A;
  2575. GL_FENCE_APPLE = $8A0B;
  2576. var
  2577. glGenFencesAPPLE: procedure(n: GLsizei; fences: PGLuint); extdecl;
  2578. glDeleteFencesAPPLE: procedure(n: GLsizei; const fences: PGLuint); extdecl;
  2579. glSetFenceAPPLE: procedure(fence: GLuint); extdecl;
  2580. glIsFenceAPPLE: function(fence: GLuint): GLboolean; extdecl;
  2581. glTestFenceAPPLE: function(fence: GLuint): GLboolean; extdecl;
  2582. glFinishFenceAPPLE: procedure(fence: GLuint); extdecl;
  2583. glTestObjectAPPLE: function(_object: GLenum; name: GLuint): GLboolean; extdecl;
  2584. glFinishObjectAPPLE: procedure(_object: GLenum; name: GLint); extdecl;
  2585. function Load_GL_APPLE_fence: Boolean;
  2586. //***** GL_APPLE_vertex_array_object *****//
  2587. const
  2588. GL_VERTEX_ARRAY_BINDING_APPLE = $85B5;
  2589. var
  2590. glBindVertexArrayAPPLE: procedure(_array: GLuint); extdecl;
  2591. glDeleteVertexArraysAPPLE: procedure(n: GLsizei; const arrays: PGLuint); extdecl;
  2592. glGenVertexArraysAPPLE: procedure(n: GLsizei; const arrays: PGLuint); extdecl;
  2593. glIsVertexArrayAPPLE: function(_array: GLuint): GLboolean; extdecl;
  2594. function Load_GL_APPLE_vertex_array_object: Boolean;
  2595. //***** GL_APPLE_vertex_array_range *****//
  2596. const
  2597. GL_VERTEX_ARRAY_RANGE_APPLE = $851D;
  2598. GL_VERTEX_ARRAY_RANGE_LENGTH_APPLE = $851E;
  2599. GL_MAX_VERTEX_ARRAY_RANGE_ELEMENT_APPLE = $8520;
  2600. GL_VERTEX_ARRAY_RANGE_POINTER_APPLE = $8521;
  2601. GL_VERTEX_ARRAY_STORAGE_HINT_APPLE = $851F;
  2602. GL_STORAGE_CACHED_APPLE = $85BE;
  2603. GL_STORAGE_SHARED_APPLE = $85BF;
  2604. var
  2605. glVertexArrayRangeAPPLE: procedure(length: GLsizei; pointer: PGLvoid); extdecl;
  2606. glFlushVertexArrayRangeAPPLE: procedure(length: GLsizei; pointer: PGLvoid); extdecl;
  2607. glVertexArrayParameteriAPPLE: procedure(pname: GLenum; param: GLint); extdecl;
  2608. function Load_GL_APPLE_vertex_array_range: Boolean;
  2609. {$IFDEF Windows}
  2610. //***** WGL_ARB_pixel_format *****//
  2611. const
  2612. WGL_NUMBER_PIXEL_FORMATS_ARB = $2000;
  2613. WGL_DRAW_TO_WINDOW_ARB = $2001;
  2614. WGL_DRAW_TO_BITMAP_ARB = $2002;
  2615. WGL_ACCELERATION_ARB = $2003;
  2616. WGL_NEED_PALETTE_ARB = $2004;
  2617. WGL_NEED_SYSTEM_PALETTE_ARB = $2005;
  2618. WGL_SWAP_LAYER_BUFFERS_ARB = $2006;
  2619. WGL_SWAP_METHOD_ARB = $2007;
  2620. WGL_NUMBER_OVERLAYS_ARB = $2008;
  2621. WGL_NUMBER_UNDERLAYS_ARB = $2009;
  2622. WGL_TRANSPARENT_ARB = $200A;
  2623. WGL_TRANSPARENT_RED_VALUE_ARB = $2037;
  2624. WGL_TRANSPARENT_GREEN_VALUE_ARB = $2038;
  2625. WGL_TRANSPARENT_BLUE_VALUE_ARB = $2039;
  2626. WGL_TRANSPARENT_ALPHA_VALUE_ARB = $203A;
  2627. WGL_TRANSPARENT_INDEX_VALUE_ARB = $203B;
  2628. WGL_SHARE_DEPTH_ARB = $200C;
  2629. WGL_SHARE_STENCIL_ARB = $200D;
  2630. WGL_SHARE_ACCUM_ARB = $200E;
  2631. WGL_SUPPORT_GDI_ARB = $200F;
  2632. WGL_SUPPORT_OPENGL_ARB = $2010;
  2633. WGL_DOUBLE_BUFFER_ARB = $2011;
  2634. WGL_STEREO_ARB = $2012;
  2635. WGL_PIXEL_TYPE_ARB = $2013;
  2636. WGL_COLOR_BITS_ARB = $2014;
  2637. WGL_RED_BITS_ARB = $2015;
  2638. WGL_RED_SHIFT_ARB = $2016;
  2639. WGL_GREEN_BITS_ARB = $2017;
  2640. WGL_GREEN_SHIFT_ARB = $2018;
  2641. WGL_BLUE_BITS_ARB = $2019;
  2642. WGL_BLUE_SHIFT_ARB = $201A;
  2643. WGL_ALPHA_BITS_ARB = $201B;
  2644. WGL_ALPHA_SHIFT_ARB = $201C;
  2645. WGL_ACCUM_BITS_ARB = $201D;
  2646. WGL_ACCUM_RED_BITS_ARB = $201E;
  2647. WGL_ACCUM_GREEN_BITS_ARB = $201F;
  2648. WGL_ACCUM_BLUE_BITS_ARB = $2020;
  2649. WGL_ACCUM_ALPHA_BITS_ARB = $2021;
  2650. WGL_DEPTH_BITS_ARB = $2022;
  2651. WGL_STENCIL_BITS_ARB = $2023;
  2652. WGL_AUX_BUFFERS_ARB = $2024;
  2653. WGL_NO_ACCELERATION_ARB = $2025;
  2654. WGL_GENERIC_ACCELERATION_ARB = $2026;
  2655. WGL_FULL_ACCELERATION_ARB = $2027;
  2656. WGL_SWAP_EXCHANGE_ARB = $2028;
  2657. WGL_SWAP_COPY_ARB = $2029;
  2658. WGL_SWAP_UNDEFINED_ARB = $202A;
  2659. WGL_TYPE_RGBA_ARB = $202B;
  2660. WGL_TYPE_COLORINDEX_ARB = $202C;
  2661. var
  2662. wglGetPixelFormatAttribivARB: function(hdc: HDC; iPixelFormat: GLint; iLayerPlane: GLint; nAttributes: GLuint; const piAttributes: PGLint; piValues: PGLint): BOOL; extdecl;
  2663. wglGetPixelFormatAttribfvARB: function(hdc: HDC; iPixelFormat: GLint; iLayerPlane: GLint; nAttributes: GLuint; const piAttributes: PGLint; pfValues: PGLfloat): BOOL; extdecl;
  2664. wglChoosePixelFormatARB: function(hdc: HDC; const piAttribIList: PGLint; const pfAttribFList: PGLfloat; nMaxFormats: GLuint; piFormats: PGLint; nNumFormats: PGLuint): BOOL; extdecl;
  2665. function Load_WGL_ARB_pixel_format: Boolean;
  2666. //***** WGL_ARB_make_current_read *****//
  2667. const
  2668. WGL_ERROR_INVALID_PIXEL_TYPE_ARB = $2043;
  2669. WGL_ERROR_INCOMPATIBLE_DEVICE_CONTEXTS_ARB = $2054;
  2670. var
  2671. wglMakeContextCurrentARB: function(hDrawDC: HDC; hReadDC: HDC; hglrc: HGLRC): BOOL; extdecl;
  2672. wglGetCurrentReadDCARB: function(): HDC; extdecl;
  2673. function Load_WGL_ARB_make_current_read: Boolean;
  2674. //***** WGL_ARB_pbuffer *****//
  2675. const
  2676. WGL_DRAW_TO_PBUFFER_ARB = $202D;
  2677. // WGL_DRAW_TO_PBUFFER_ARB { already defined }
  2678. WGL_MAX_PBUFFER_PIXELS_ARB = $202E;
  2679. WGL_MAX_PBUFFER_WIDTH_ARB = $202F;
  2680. WGL_MAX_PBUFFER_HEIGHT_ARB = $2030;
  2681. WGL_PBUFFER_LARGEST_ARB = $2033;
  2682. WGL_PBUFFER_WIDTH_ARB = $2034;
  2683. WGL_PBUFFER_HEIGHT_ARB = $2035;
  2684. WGL_PBUFFER_LOST_ARB = $2036;
  2685. var
  2686. wglCreatePbufferARB: function(hDC: HDC; iPixelFormat: GLint; iWidth: GLint; iHeight: GLint; const piAttribList: PGLint): THandle; extdecl;
  2687. wglGetPbufferDCARB: function(hPbuffer: THandle): HDC; extdecl;
  2688. wglReleasePbufferDCARB: function(hPbuffer: THandle; hDC: HDC): GLint; extdecl;
  2689. wglDestroyPbufferARB: function(hPbuffer: THandle): BOOL; extdecl;
  2690. wglQueryPbufferARB: function(hPbuffer: THandle; iAttribute: GLint; piValue: PGLint): BOOL; extdecl;
  2691. function Load_WGL_ARB_pbuffer: Boolean;
  2692. //***** WGL_EXT_swap_control *****//
  2693. var
  2694. wglSwapIntervalEXT: function(interval: GLint): BOOL; extdecl;
  2695. wglGetSwapIntervalEXT: function(): GLint; extdecl;
  2696. function Load_WGL_EXT_swap_control: Boolean;
  2697. //***** WGL_ARB_render_texture *****//
  2698. const
  2699. WGL_BIND_TO_TEXTURE_RGB_ARB = $2070;
  2700. WGL_BIND_TO_TEXTURE_RGBA_ARB = $2071;
  2701. WGL_TEXTURE_FORMAT_ARB = $2072;
  2702. WGL_TEXTURE_TARGET_ARB = $2073;
  2703. WGL_MIPMAP_TEXTURE_ARB = $2074;
  2704. WGL_TEXTURE_RGB_ARB = $2075;
  2705. WGL_TEXTURE_RGBA_ARB = $2076;
  2706. WGL_NO_TEXTURE_ARB = $2077;
  2707. WGL_TEXTURE_CUBE_MAP_ARB = $2078;
  2708. WGL_TEXTURE_1D_ARB = $2079;
  2709. WGL_TEXTURE_2D_ARB = $207A;
  2710. // WGL_NO_TEXTURE_ARB { already defined }
  2711. WGL_MIPMAP_LEVEL_ARB = $207B;
  2712. WGL_CUBE_MAP_FACE_ARB = $207C;
  2713. WGL_TEXTURE_CUBE_MAP_POSITIVE_X_ARB = $207D;
  2714. WGL_TEXTURE_CUBE_MAP_NEGATIVE_X_ARB = $207E;
  2715. WGL_TEXTURE_CUBE_MAP_POSITIVE_Y_ARB = $207F;
  2716. WGL_TEXTURE_CUBE_MAP_NEGATIVE_Y_ARB = $2080;
  2717. WGL_TEXTURE_CUBE_MAP_POSITIVE_Z_ARB = $2081;
  2718. WGL_TEXTURE_CUBE_MAP_NEGATIVE_Z_ARB = $2082;
  2719. WGL_FRONT_LEFT_ARB = $2083;
  2720. WGL_FRONT_RIGHT_ARB = $2084;
  2721. WGL_BACK_LEFT_ARB = $2085;
  2722. WGL_BACK_RIGHT_ARB = $2086;
  2723. WGL_AUX0_ARB = $2087;
  2724. WGL_AUX1_ARB = $2088;
  2725. WGL_AUX2_ARB = $2089;
  2726. WGL_AUX3_ARB = $208A;
  2727. WGL_AUX4_ARB = $208B;
  2728. WGL_AUX5_ARB = $208C;
  2729. WGL_AUX6_ARB = $208D;
  2730. WGL_AUX7_ARB = $208E;
  2731. WGL_AUX8_ARB = $208F;
  2732. WGL_AUX9_ARB = $2090;
  2733. var
  2734. wglBindTexImageARB: function(hPbuffer: THandle; iBuffer: GLint): BOOL; extdecl;
  2735. wglReleaseTexImageARB: function(hPbuffer: THandle; iBuffer: GLint): BOOL; extdecl;
  2736. wglSetPbufferAttribARB: function(hPbuffer: THandle; const piAttribList: PGLint): BOOL; extdecl;
  2737. function Load_WGL_ARB_render_texture: Boolean;
  2738. //***** WGL_EXT_extensions_string *****//
  2739. var
  2740. wglGetExtensionsStringEXT: function(): Pchar; extdecl;
  2741. function Load_WGL_EXT_extensions_string: Boolean;
  2742. //***** WGL_EXT_make_current_read *****//
  2743. var
  2744. wglMakeContextCurrentEXT: function(hDrawDC: HDC; hReadDC: HDC; hglrc: HGLRC): BOOL; extdecl;
  2745. wglGetCurrentReadDCEXT: function(): HDC; extdecl;
  2746. function Load_WGL_EXT_make_current_read: Boolean;
  2747. //***** WGL_EXT_pbuffer *****//
  2748. const
  2749. WGL_DRAW_TO_PBUFFER_EXT = $202D;
  2750. WGL_MAX_PBUFFER_PIXELS_EXT = $202E;
  2751. WGL_MAX_PBUFFER_WIDTH_EXT = $202F;
  2752. WGL_MAX_PBUFFER_HEIGHT_EXT = $2030;
  2753. WGL_OPTIMAL_PBUFFER_WIDTH_EXT = $2031;
  2754. WGL_OPTIMAL_PBUFFER_HEIGHT_EXT = $2032;
  2755. WGL_PBUFFER_LARGEST_EXT = $2033;
  2756. WGL_PBUFFER_WIDTH_EXT = $2034;
  2757. WGL_PBUFFER_HEIGHT_EXT = $2035;
  2758. var
  2759. wglCreatePbufferEXT: function(hDC: HDC; iPixelFormat: GLint; iWidth: GLint; iHeight: GLint; const piAttribList: PGLint): THandle; extdecl;
  2760. wglGetPbufferDCEXT: function(hPbuffer: THandle): HDC; extdecl;
  2761. wglReleasePbufferDCEXT: function(hPbuffer: THandle; hDC: HDC): GLint; extdecl;
  2762. wglDestroyPbufferEXT: function(hPbuffer: THandle): BOOL; extdecl;
  2763. wglQueryPbufferEXT: function(hPbuffer: THandle; iAttribute: GLint; piValue: PGLint): BOOL; extdecl;
  2764. function Load_WGL_EXT_pbuffer: Boolean;
  2765. //***** WGL_EXT_pixel_format *****//
  2766. const
  2767. WGL_NUMBER_PIXEL_FORMATS_EXT = $2000;
  2768. WGL_DRAW_TO_WINDOW_EXT = $2001;
  2769. WGL_DRAW_TO_BITMAP_EXT = $2002;
  2770. WGL_ACCELERATION_EXT = $2003;
  2771. WGL_NEED_PALETTE_EXT = $2004;
  2772. WGL_NEED_SYSTEM_PALETTE_EXT = $2005;
  2773. WGL_SWAP_LAYER_BUFFERS_EXT = $2006;
  2774. WGL_SWAP_METHOD_EXT = $2007;
  2775. WGL_NUMBER_OVERLAYS_EXT = $2008;
  2776. WGL_NUMBER_UNDERLAYS_EXT = $2009;
  2777. WGL_TRANSPARENT_EXT = $200A;
  2778. WGL_TRANSPARENT_VALUE_EXT = $200B;
  2779. WGL_SHARE_DEPTH_EXT = $200C;
  2780. WGL_SHARE_STENCIL_EXT = $200D;
  2781. WGL_SHARE_ACCUM_EXT = $200E;
  2782. WGL_SUPPORT_GDI_EXT = $200F;
  2783. WGL_SUPPORT_OPENGL_EXT = $2010;
  2784. WGL_DOUBLE_BUFFER_EXT = $2011;
  2785. WGL_STEREO_EXT = $2012;
  2786. WGL_PIXEL_TYPE_EXT = $2013;
  2787. WGL_COLOR_BITS_EXT = $2014;
  2788. WGL_RED_BITS_EXT = $2015;
  2789. WGL_RED_SHIFT_EXT = $2016;
  2790. WGL_GREEN_BITS_EXT = $2017;
  2791. WGL_GREEN_SHIFT_EXT = $2018;
  2792. WGL_BLUE_BITS_EXT = $2019;
  2793. WGL_BLUE_SHIFT_EXT = $201A;
  2794. WGL_ALPHA_BITS_EXT = $201B;
  2795. WGL_ALPHA_SHIFT_EXT = $201C;
  2796. WGL_ACCUM_BITS_EXT = $201D;
  2797. WGL_ACCUM_RED_BITS_EXT = $201E;
  2798. WGL_ACCUM_GREEN_BITS_EXT = $201F;
  2799. WGL_ACCUM_BLUE_BITS_EXT = $2020;
  2800. WGL_ACCUM_ALPHA_BITS_EXT = $2021;
  2801. WGL_DEPTH_BITS_EXT = $2022;
  2802. WGL_STENCIL_BITS_EXT = $2023;
  2803. WGL_AUX_BUFFERS_EXT = $2024;
  2804. WGL_NO_ACCELERATION_EXT = $2025;
  2805. WGL_GENERIC_ACCELERATION_EXT = $2026;
  2806. WGL_FULL_ACCELERATION_EXT = $2027;
  2807. WGL_SWAP_EXCHANGE_EXT = $2028;
  2808. WGL_SWAP_COPY_EXT = $2029;
  2809. WGL_SWAP_UNDEFINED_EXT = $202A;
  2810. WGL_TYPE_RGBA_EXT = $202B;
  2811. WGL_TYPE_COLORINDEX_EXT = $202C;
  2812. var
  2813. wglGetPixelFormatAttribivEXT: function(hdc: HDC; iPixelFormat: GLint; iLayerPlane: GLint; nAttributes: GLuint; piAttributes: PGLint; piValues: PGLint): BOOL; extdecl;
  2814. wglGetPixelFormatAttribfvEXT: function(hdc: HDC; iPixelFormat: GLint; iLayerPlane: GLint; nAttributes: GLuint; piAttributes: PGLint; pfValues: PGLfloat): BOOL; extdecl;
  2815. wglChoosePixelFormatEXT: function(hdc: HDC; const piAttribIList: PGLint; const pfAttribFList: PGLfloat; nMaxFormats: GLuint; piFormats: PGLint; nNumFormats: PGLuint): BOOL; extdecl;
  2816. function Load_WGL_EXT_pixel_format: Boolean;
  2817. //***** WGL_I3D_digital_video_control *****//
  2818. const
  2819. WGL_DIGITAL_VIDEO_CURSOR_ALPHA_FRAMEBUFFER_I3D = $2050;
  2820. WGL_DIGITAL_VIDEO_CURSOR_ALPHA_VALUE_I3D = $2051;
  2821. WGL_DIGITAL_VIDEO_CURSOR_INCLUDED_I3D = $2052;
  2822. WGL_DIGITAL_VIDEO_GAMMA_CORRECTED_I3D = $2053;
  2823. var
  2824. wglGetDigitalVideoParametersI3D: function(hDC: HDC; iAttribute: GLint; piValue: PGLint): BOOL; extdecl;
  2825. wglSetDigitalVideoParametersI3D: function(hDC: HDC; iAttribute: GLint; const piValue: PGLint): BOOL; extdecl;
  2826. function Load_WGL_I3D_digital_video_control: Boolean;
  2827. //***** WGL_I3D_gamma *****//
  2828. const
  2829. WGL_GAMMA_TABLE_SIZE_I3D = $204E;
  2830. WGL_GAMMA_EXCLUDE_DESKTOP_I3D = $204F;
  2831. // WGL_GAMMA_EXCLUDE_DESKTOP_I3D { already defined }
  2832. var
  2833. wglGetGammaTableParametersI3D: function(hDC: HDC; iAttribute: GLint; piValue: PGLint): BOOL; extdecl;
  2834. wglSetGammaTableParametersI3D: function(hDC: HDC; iAttribute: GLint; const piValue: PGLint): BOOL; extdecl;
  2835. wglGetGammaTableI3D: function(hDC: HDC; iEntries: GLint; puRed: PGLUSHORT; puGreen: PGLUSHORT; puBlue: PGLUSHORT): BOOL; extdecl;
  2836. wglSetGammaTableI3D: function(hDC: HDC; iEntries: GLint; const puRed: PGLUSHORT; const puGreen: PGLUSHORT; const puBlue: PGLUSHORT): BOOL; extdecl;
  2837. function Load_WGL_I3D_gamma: Boolean;
  2838. //***** WGL_I3D_genlock *****//
  2839. const
  2840. WGL_GENLOCK_SOURCE_MULTIVIEW_I3D = $2044;
  2841. WGL_GENLOCK_SOURCE_EXTERNAL_SYNC_I3D = $2045;
  2842. WGL_GENLOCK_SOURCE_EXTERNAL_FIELD_I3D = $2046;
  2843. WGL_GENLOCK_SOURCE_EXTERNAL_TTL_I3D = $2047;
  2844. WGL_GENLOCK_SOURCE_DIGITAL_SYNC_I3D = $2048;
  2845. WGL_GENLOCK_SOURCE_DIGITAL_FIELD_I3D = $2049;
  2846. WGL_GENLOCK_SOURCE_EDGE_FALLING_I3D = $204A;
  2847. WGL_GENLOCK_SOURCE_EDGE_RISING_I3D = $204B;
  2848. WGL_GENLOCK_SOURCE_EDGE_BOTH_I3D = $204C;
  2849. var
  2850. wglEnableGenlockI3D: function(hDC: HDC): BOOL; extdecl;
  2851. wglDisableGenlockI3D: function(hDC: HDC): BOOL; extdecl;
  2852. wglIsEnabledGenlockI3D: function(hDC: HDC; pFlag: PBOOL): BOOL; extdecl;
  2853. wglGenlockSourceI3D: function(hDC: HDC; uSource: GLUINT): BOOL; extdecl;
  2854. wglGetGenlockSourceI3D: function(hDC: HDC; uSource: PGLUINT): BOOL; extdecl;
  2855. wglGenlockSourceEdgeI3D: function(hDC: HDC; uEdge: GLUINT): BOOL; extdecl;
  2856. wglGetGenlockSourceEdgeI3D: function(hDC: HDC; uEdge: PGLUINT): BOOL; extdecl;
  2857. wglGenlockSampleRateI3D: function(hDC: HDC; uRate: GLUINT): BOOL; extdecl;
  2858. wglGetGenlockSampleRateI3D: function(hDC: HDC; uRate: PGLUINT): BOOL; extdecl;
  2859. wglGenlockSourceDelayI3D: function(hDC: HDC; uDelay: GLUINT): BOOL; extdecl;
  2860. wglGetGenlockSourceDelayI3D: function(hDC: HDC; uDelay: PGLUINT): BOOL; extdecl;
  2861. wglQueryGenlockMaxSourceDelayI3D: function(hDC: HDC; uMaxLineDelay: PGLUINT; uMaxPixelDelay: PGLUINT): BOOL; extdecl;
  2862. function Load_WGL_I3D_genlock: Boolean;
  2863. {$ENDIF}
  2864. //***** GL_ARB_matrix_palette *****//
  2865. const
  2866. GL_MATRIX_PALETTE_ARB = $8840;
  2867. GL_MAX_MATRIX_PALETTE_STACK_DEPTH_ARB = $8841;
  2868. GL_MAX_PALETTE_MATRICES_ARB = $8842;
  2869. GL_CURRENT_PALETTE_MATRIX_ARB = $8843;
  2870. GL_MATRIX_INDEX_ARRAY_ARB = $8844;
  2871. GL_CURRENT_MATRIX_INDEX_ARB = $8845;
  2872. GL_MATRIX_INDEX_ARRAY_SIZE_ARB = $8846;
  2873. GL_MATRIX_INDEX_ARRAY_TYPE_ARB = $8847;
  2874. GL_MATRIX_INDEX_ARRAY_STRIDE_ARB = $8848;
  2875. GL_MATRIX_INDEX_ARRAY_POINTER_ARB = $8849;
  2876. var
  2877. glCurrentPaletteMatrixARB: procedure(index: GLint); extdecl;
  2878. glMatrixIndexubvARB: procedure(size: GLint; indices: PGLubyte); extdecl;
  2879. glMatrixIndexusvARB: procedure(size: GLint; indices: PGLushort); extdecl;
  2880. glMatrixIndexuivARB: procedure(size: GLint; indices: PGLuint); extdecl;
  2881. glMatrixIndexPointerARB: procedure(size: GLint; _type: GLenum; stride: GLsizei; pointer: PGLvoid); extdecl;
  2882. function Load_GL_ARB_matrix_palette: Boolean;
  2883. //***** GL_NV_element_array *****//
  2884. const
  2885. GL_ELEMENT_ARRAY_TYPE_NV = $8769;
  2886. GL_ELEMENT_ARRAY_POINTER_NV = $876A;
  2887. var
  2888. glElementPointerNV: procedure(_type: GLenum; const pointer: PGLvoid); extdecl;
  2889. glDrawElementArrayNV: procedure(mode: GLenum; first: GLint; count: GLsizei); extdecl;
  2890. glDrawRangeElementArrayNV: procedure(mode: GLenum; start: GLuint; _end: GLuint; first: GLint; count: GLsizei); extdecl;
  2891. glMultiDrawElementArrayNV: procedure(mode: GLenum; const first: PGLint; const count: PGLsizei; primcount: GLsizei); extdecl;
  2892. glMultiDrawRangeElementArrayNV: procedure(mode: GLenum; start: GLuint; _end: GLuint; const first: PGLint; const count: PGLsizei; primcount: GLsizei); extdecl;
  2893. function Load_GL_NV_element_array: Boolean;
  2894. //***** GL_NV_float_buffer *****//
  2895. const
  2896. GL_FLOAT_R_NV = $8880;
  2897. GL_FLOAT_RG_NV = $8881;
  2898. GL_FLOAT_RGB_NV = $8882;
  2899. GL_FLOAT_RGBA_NV = $8883;
  2900. GL_FLOAT_R16_NV = $8884;
  2901. GL_FLOAT_R32_NV = $8885;
  2902. GL_FLOAT_RG16_NV = $8886;
  2903. GL_FLOAT_RG32_NV = $8887;
  2904. GL_FLOAT_RGB16_NV = $8888;
  2905. GL_FLOAT_RGB32_NV = $8889;
  2906. GL_FLOAT_RGBA16_NV = $888A;
  2907. GL_FLOAT_RGBA32_NV = $888B;
  2908. GL_TEXTURE_FLOAT_COMPONENTS_NV = $888C;
  2909. GL_FLOAT_CLEAR_COLOR_VALUE_NV = $888D;
  2910. GL_FLOAT_RGBA_MODE_NV = $888E;
  2911. {$IFDEF Windows}
  2912. WGL_FLOAT_COMPONENTS_NV = $20B0;
  2913. WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_R_NV = $20B1;
  2914. WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RG_NV = $20B2;
  2915. WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGB_NV = $20B3;
  2916. WGL_BIND_TO_TEXTURE_RECTANGLE_FLOAT_RGBA_NV = $20B4;
  2917. WGL_TEXTURE_FLOAT_R_NV = $20B5;
  2918. WGL_TEXTURE_FLOAT_RG_NV = $20B6;
  2919. WGL_TEXTURE_FLOAT_RGB_NV = $20B7;
  2920. WGL_TEXTURE_FLOAT_RGBA_NV = $20B8;
  2921. {$ENDIF}
  2922. function Load_GL_NV_float_buffer: Boolean;
  2923. //***** GL_NV_fragment_program *****//
  2924. const
  2925. GL_FRAGMENT_PROGRAM_NV = $8870;
  2926. GL_MAX_TEXTURE_COORDS_NV = $8871;
  2927. GL_MAX_TEXTURE_IMAGE_UNITS_NV = $8872;
  2928. GL_FRAGMENT_PROGRAM_BINDING_NV = $8873;
  2929. GL_MAX_FRAGMENT_PROGRAM_LOCAL_PARAMETERS_NV = $8868;
  2930. GL_PROGRAM_ERROR_STRING_NV = $8874;
  2931. var
  2932. glProgramNamedParameter4fNV: procedure(id: GLuint; len: GLsizei; const name: PGLubyte; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  2933. glProgramNamedParameter4dNV: procedure(id: GLuint; len: GLsizei; const name: PGLubyte; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  2934. glGetProgramNamedParameterfvNV: procedure(id: GLuint; len: GLsizei; const name: PGLubyte; params: PGLfloat); extdecl;
  2935. glGetProgramNamedParameterdvNV: procedure(id: GLuint; len: GLsizei; const name: PGLubyte; params: PGLdouble); extdecl;
  2936. // glProgramLocalParameter4dARB { already defined }
  2937. // glProgramLocalParameter4dvARB { already defined }
  2938. // glProgramLocalParameter4fARB { already defined }
  2939. // glProgramLocalParameter4fvARB { already defined }
  2940. // glGetProgramLocalParameterdvARB { already defined }
  2941. // glGetProgramLocalParameterfvARB { already defined }
  2942. function Load_GL_NV_fragment_program: Boolean;
  2943. //***** GL_NV_primitive_restart *****//
  2944. const
  2945. GL_PRIMITIVE_RESTART_NV = $8558;
  2946. GL_PRIMITIVE_RESTART_INDEX_NV = $8559;
  2947. var
  2948. glPrimitiveRestartNV: procedure(); extdecl;
  2949. glPrimitiveRestartIndexNV: procedure(index: GLuint); extdecl;
  2950. function Load_GL_NV_primitive_restart: Boolean;
  2951. //***** GL_NV_vertex_program2 *****//
  2952. function Load_GL_NV_vertex_program2: Boolean;
  2953. {$IFDEF Windows}
  2954. //***** WGL_NV_render_texture_rectangle *****//
  2955. const
  2956. WGL_BIND_TO_TEXTURE_RECTANGLE_RGB_NV = $20A0;
  2957. WGL_BIND_TO_TEXTURE_RECTANGLE_RGBA_NV = $20A1;
  2958. WGL_TEXTURE_RECTANGLE_NV = $20A2;
  2959. function Load_WGL_NV_render_texture_rectangle: Boolean;
  2960. {$ENDIF}
  2961. //***** GL_NV_pixel_data_range *****//
  2962. const
  2963. GL_WRITE_PIXEL_DATA_RANGE_NV = $8878;
  2964. GL_READ_PIXEL_DATA_RANGE_NV = $8879;
  2965. GL_WRITE_PIXEL_DATA_RANGE_LENGTH_NV = $887A;
  2966. GL_READ_PIXEL_DATA_RANGE_LENGTH_NV = $887B;
  2967. GL_WRITE_PIXEL_DATA_RANGE_POINTER_NV = $887C;
  2968. GL_READ_PIXEL_DATA_RANGE_POINTER_NV = $887D;
  2969. var
  2970. glPixelDataRangeNV: procedure(target: GLenum; length: GLsizei; pointer: PGLvoid); extdecl;
  2971. glFlushPixelDataRangeNV: procedure(target: GLenum); extdecl;
  2972. // wglAllocateMemoryNV { already defined }
  2973. // wglFreeMemoryNV { already defined }
  2974. function Load_GL_NV_pixel_data_range: Boolean;
  2975. //***** GL_EXT_texture_rectangle *****//
  2976. const
  2977. GL_TEXTURE_RECTANGLE_EXT = $84F5;
  2978. GL_TEXTURE_BINDING_RECTANGLE_EXT = $84F6;
  2979. GL_PROXY_TEXTURE_RECTANGLE_EXT = $84F7;
  2980. GL_MAX_RECTANGLE_TEXTURE_SIZE_EXT = $84F8;
  2981. function Load_GL_EXT_texture_rectangle: Boolean;
  2982. //***** GL_S3_s3tc *****//
  2983. const
  2984. GL_RGB_S3TC = $83A0;
  2985. GL_RGB4_S3TC = $83A1;
  2986. GL_RGBA_S3TC = $83A2;
  2987. GL_RGBA4_S3TC = $83A3;
  2988. function Load_GL_S3_s3tc: Boolean;
  2989. //***** GL_ATI_draw_buffers *****//
  2990. const
  2991. GL_MAX_DRAW_BUFFERS_ATI = $8824;
  2992. GL_DRAW_BUFFER0_ATI = $8825;
  2993. GL_DRAW_BUFFER1_ATI = $8826;
  2994. GL_DRAW_BUFFER2_ATI = $8827;
  2995. GL_DRAW_BUFFER3_ATI = $8828;
  2996. GL_DRAW_BUFFER4_ATI = $8829;
  2997. GL_DRAW_BUFFER5_ATI = $882A;
  2998. GL_DRAW_BUFFER6_ATI = $882B;
  2999. GL_DRAW_BUFFER7_ATI = $882C;
  3000. GL_DRAW_BUFFER8_ATI = $882D;
  3001. GL_DRAW_BUFFER9_ATI = $882E;
  3002. GL_DRAW_BUFFER10_ATI = $882F;
  3003. GL_DRAW_BUFFER11_ATI = $8830;
  3004. GL_DRAW_BUFFER12_ATI = $8831;
  3005. GL_DRAW_BUFFER13_ATI = $8832;
  3006. GL_DRAW_BUFFER14_ATI = $8833;
  3007. GL_DRAW_BUFFER15_ATI = $8834;
  3008. var
  3009. glDrawBuffersATI: procedure(n: GLsizei; const bufs: PGLenum); extdecl;
  3010. function Load_GL_ATI_draw_buffers: Boolean;
  3011. {$IFDEF Windows}
  3012. //***** WGL_ATI_pixel_format_float *****//
  3013. const
  3014. WGL_RGBA_FLOAT_MODE_ATI = $8820;
  3015. WGL_COLOR_CLEAR_UNCLAMPED_VALUE_ATI = $8835;
  3016. WGL_TYPE_RGBA_FLOAT_ATI = $21A0;
  3017. function Load_WGL_ATI_pixel_format_float: Boolean;
  3018. {$ENDIF}
  3019. //***** GL_ATI_texture_env_combine3 *****//
  3020. const
  3021. GL_MODULATE_ADD_ATI = $8744;
  3022. GL_MODULATE_SIGNED_ADD_ATI = $8745;
  3023. GL_MODULATE_SUBTRACT_ATI = $8746;
  3024. function Load_GL_ATI_texture_env_combine3: Boolean;
  3025. //***** GL_ATI_texture_float *****//
  3026. const
  3027. GL_RGBA_FLOAT32_ATI = $8814;
  3028. GL_RGB_FLOAT32_ATI = $8815;
  3029. GL_ALPHA_FLOAT32_ATI = $8816;
  3030. GL_INTENSITY_FLOAT32_ATI = $8817;
  3031. GL_LUMINANCE_FLOAT32_ATI = $8818;
  3032. GL_LUMINANCE_ALPHA_FLOAT32_ATI = $8819;
  3033. GL_RGBA_FLOAT16_ATI = $881A;
  3034. GL_RGB_FLOAT16_ATI = $881B;
  3035. GL_ALPHA_FLOAT16_ATI = $881C;
  3036. GL_INTENSITY_FLOAT16_ATI = $881D;
  3037. GL_LUMINANCE_FLOAT16_ATI = $881E;
  3038. GL_LUMINANCE_ALPHA_FLOAT16_ATI = $881F;
  3039. function Load_GL_ATI_texture_float: Boolean;
  3040. //***** GL_NV_texture_expand_normal *****//
  3041. const
  3042. GL_TEXTURE_UNSIGNED_REMAP_MODE_NV = $888F;
  3043. function Load_GL_NV_texture_expand_normal: Boolean;
  3044. //***** GL_NV_half_float *****//
  3045. const
  3046. GL_HALF_FLOAT_NV = $140B;
  3047. var
  3048. glVertex2hNV: procedure(x: GLushort; y: GLushort); extdecl;
  3049. glVertex2hvNV: procedure(const v: PGLushort); extdecl;
  3050. glVertex3hNV: procedure(x: GLushort; y: GLushort; z: GLushort); extdecl;
  3051. glVertex3hvNV: procedure(const v: PGLushort); extdecl;
  3052. glVertex4hNV: procedure(x: GLushort; y: GLushort; z: GLushort; w: GLushort); extdecl;
  3053. glVertex4hvNV: procedure(const v: PGLushort); extdecl;
  3054. glNormal3hNV: procedure(nx: GLushort; ny: GLushort; nz: GLushort); extdecl;
  3055. glNormal3hvNV: procedure(const v: PGLushort); extdecl;
  3056. glColor3hNV: procedure(red: GLushort; green: GLushort; blue: GLushort); extdecl;
  3057. glColor3hvNV: procedure(const v: PGLushort); extdecl;
  3058. glColor4hNV: procedure(red: GLushort; green: GLushort; blue: GLushort; alpha: GLushort); extdecl;
  3059. glColor4hvNV: procedure(const v: PGLushort); extdecl;
  3060. glTexCoord1hNV: procedure(s: GLushort); extdecl;
  3061. glTexCoord1hvNV: procedure(const v: PGLushort); extdecl;
  3062. glTexCoord2hNV: procedure(s: GLushort; t: GLushort); extdecl;
  3063. glTexCoord2hvNV: procedure(const v: PGLushort); extdecl;
  3064. glTexCoord3hNV: procedure(s: GLushort; t: GLushort; r: GLushort); extdecl;
  3065. glTexCoord3hvNV: procedure(const v: PGLushort); extdecl;
  3066. glTexCoord4hNV: procedure(s: GLushort; t: GLushort; r: GLushort; q: GLushort); extdecl;
  3067. glTexCoord4hvNV: procedure(const v: PGLushort); extdecl;
  3068. glMultiTexCoord1hNV: procedure(target: GLenum; s: GLushort); extdecl;
  3069. glMultiTexCoord1hvNV: procedure(target: GLenum; const v: PGLushort); extdecl;
  3070. glMultiTexCoord2hNV: procedure(target: GLenum; s: GLushort; t: GLushort); extdecl;
  3071. glMultiTexCoord2hvNV: procedure(target: GLenum; const v: PGLushort); extdecl;
  3072. glMultiTexCoord3hNV: procedure(target: GLenum; s: GLushort; t: GLushort; r: GLushort); extdecl;
  3073. glMultiTexCoord3hvNV: procedure(target: GLenum; const v: PGLushort); extdecl;
  3074. glMultiTexCoord4hNV: procedure(target: GLenum; s: GLushort; t: GLushort; r: GLushort; q: GLushort); extdecl;
  3075. glMultiTexCoord4hvNV: procedure(target: GLenum; const v: PGLushort); extdecl;
  3076. glFogCoordhNV: procedure(fog: GLushort); extdecl;
  3077. glFogCoordhvNV: procedure(const fog: PGLushort); extdecl;
  3078. glSecondaryColor3hNV: procedure(red: GLushort; green: GLushort; blue: GLushort); extdecl;
  3079. glSecondaryColor3hvNV: procedure(const v: PGLushort); extdecl;
  3080. glVertexWeighthNV: procedure(weight: GLushort); extdecl;
  3081. glVertexWeighthvNV: procedure(const weight: PGLushort); extdecl;
  3082. glVertexAttrib1hNV: procedure(index: GLuint; x: GLushort); extdecl;
  3083. glVertexAttrib1hvNV: procedure(index: GLuint; const v: PGLushort); extdecl;
  3084. glVertexAttrib2hNV: procedure(index: GLuint; x: GLushort; y: GLushort); extdecl;
  3085. glVertexAttrib2hvNV: procedure(index: GLuint; const v: PGLushort); extdecl;
  3086. glVertexAttrib3hNV: procedure(index: GLuint; x: GLushort; y: GLushort; z: GLushort); extdecl;
  3087. glVertexAttrib3hvNV: procedure(index: GLuint; const v: PGLushort); extdecl;
  3088. glVertexAttrib4hNV: procedure(index: GLuint; x: GLushort; y: GLushort; z: GLushort; w: GLushort); extdecl;
  3089. glVertexAttrib4hvNV: procedure(index: GLuint; const v: PGLushort); extdecl;
  3090. glVertexAttribs1hvNV: procedure(index: GLuint; n: GLsizei; const v: PGLushort); extdecl;
  3091. glVertexAttribs2hvNV: procedure(index: GLuint; n: GLsizei; const v: PGLushort); extdecl;
  3092. glVertexAttribs3hvNV: procedure(index: GLuint; n: GLsizei; const v: PGLushort); extdecl;
  3093. glVertexAttribs4hvNV: procedure(index: GLuint; n: GLsizei; const v: PGLushort); extdecl;
  3094. function Load_GL_NV_half_float: Boolean;
  3095. //***** GL_ATI_map_object_buffer *****//
  3096. var
  3097. glMapObjectBufferATI: function(buffer: GLuint): PGLvoid; extdecl;
  3098. glUnmapObjectBufferATI: procedure(buffer: GLuint); extdecl;
  3099. function Load_GL_ATI_map_object_buffer: Boolean;
  3100. //***** GL_ATI_separate_stencil *****//
  3101. const
  3102. GL_KEEP = $1E00;
  3103. GL_ZERO = $0000;
  3104. GL_REPLACE = $1E01;
  3105. GL_INCR = $1E02;
  3106. GL_DECR = $1E03;
  3107. GL_INVERT = $150A;
  3108. GL_NEVER = $0200;
  3109. GL_LESS = $0201;
  3110. GL_LEQUAL = $0203;
  3111. GL_GREATER = $0204;
  3112. GL_GEQUAL = $0206;
  3113. GL_EQUAL = $0202;
  3114. GL_NOTEQUAL = $0205;
  3115. GL_ALWAYS = $0207;
  3116. GL_FRONT = $0404;
  3117. GL_BACK = $0405;
  3118. GL_FRONT_AND_BACK = $0408;
  3119. GL_STENCIL_BACK_FUNC_ATI = $8800;
  3120. GL_STENCIL_BACK_FAIL_ATI = $8801;
  3121. GL_STENCIL_BACK_PASS_DEPTH_FAIL_ATI = $8802;
  3122. GL_STENCIL_BACK_PASS_DEPTH_PASS_ATI = $8803;
  3123. var
  3124. glStencilOpSeparateATI: procedure(face: GLenum; sfail: GLenum; dpfail: GLenum; dppass: GLenum); extdecl;
  3125. glStencilFuncSeparateATI: procedure(frontfunc: GLenum; backfunc: GLenum; ref: GLint; mask: GLuint); extdecl;
  3126. function Load_GL_ATI_separate_stencil: Boolean;
  3127. //***** GL_ATI_vertex_attrib_array_object *****//
  3128. var
  3129. glVertexAttribArrayObjectATI: procedure(index: GLuint; size: GLint; _type: GLenum; normalized: GLboolean; stride: GLsizei; buffer: GLuint; offset: GLuint); extdecl;
  3130. glGetVertexAttribArrayObjectfvATI: procedure(index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  3131. glGetVertexAttribArrayObjectivATI: procedure(index: GLuint; pname: GLenum; params: PGLint); extdecl;
  3132. function Load_GL_ATI_vertex_attrib_array_object: Boolean;
  3133. //***** GL_ARB_occlusion_query *****//
  3134. const
  3135. GL_SAMPLES_PASSED_ARB = $8914;
  3136. GL_QUERY_COUNTER_BITS_ARB = $8864;
  3137. GL_CURRENT_QUERY_ARB = $8865;
  3138. GL_QUERY_RESULT_ARB = $8866;
  3139. GL_QUERY_RESULT_AVAILABLE_ARB = $8867;
  3140. var
  3141. glGenQueriesARB: procedure(n: GLsizei; ids: PGLuint); extdecl;
  3142. glDeleteQueriesARB: procedure(n: GLsizei; const ids: PGLuint); extdecl;
  3143. glIsQueryARB: function(id: GLuint): GLboolean; extdecl;
  3144. glBeginQueryARB: procedure(target: GLenum; id: GLuint); extdecl;
  3145. glEndQueryARB: procedure(target: GLenum); extdecl;
  3146. glGetQueryivARB: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  3147. glGetQueryObjectivARB: procedure(id: GLuint; pname: GLenum; params: PGLint); extdecl;
  3148. glGetQueryObjectuivARB: procedure(id: GLuint; pname: GLenum; params: PGLuint); extdecl;
  3149. function Load_GL_ARB_occlusion_query: Boolean;
  3150. //***** GL_ARB_shader_objects *****//
  3151. const
  3152. GL_PROGRAM_OBJECT_ARB = $8B40;
  3153. GL_OBJECT_TYPE_ARB = $8B4E;
  3154. GL_OBJECT_SUBTYPE_ARB = $8B4F;
  3155. GL_OBJECT_DELETE_STATUS_ARB = $8B80;
  3156. GL_OBJECT_COMPILE_STATUS_ARB = $8B81;
  3157. GL_OBJECT_LINK_STATUS_ARB = $8B82;
  3158. GL_OBJECT_VALIDATE_STATUS_ARB = $8B83;
  3159. GL_OBJECT_INFO_LOG_LENGTH_ARB = $8B84;
  3160. GL_OBJECT_ATTACHED_OBJECTS_ARB = $8B85;
  3161. GL_OBJECT_ACTIVE_UNIFORMS_ARB = $8B86;
  3162. GL_OBJECT_ACTIVE_UNIFORM_MAX_LENGTH_ARB = $8B87;
  3163. GL_OBJECT_SHADER_SOURCE_LENGTH_ARB = $8B88;
  3164. GL_SHADER_OBJECT_ARB = $8B48;
  3165. GL_FLOAT = $1406;
  3166. GL_FLOAT_VEC2_ARB = $8B50;
  3167. GL_FLOAT_VEC3_ARB = $8B51;
  3168. GL_FLOAT_VEC4_ARB = $8B52;
  3169. GL_INT = $1404;
  3170. GL_INT_VEC2_ARB = $8B53;
  3171. GL_INT_VEC3_ARB = $8B54;
  3172. GL_INT_VEC4_ARB = $8B55;
  3173. GL_BOOL_ARB = $8B56;
  3174. GL_BOOL_VEC2_ARB = $8B57;
  3175. GL_BOOL_VEC3_ARB = $8B58;
  3176. GL_BOOL_VEC4_ARB = $8B59;
  3177. GL_FLOAT_MAT2_ARB = $8B5A;
  3178. GL_FLOAT_MAT3_ARB = $8B5B;
  3179. GL_FLOAT_MAT4_ARB = $8B5C;
  3180. var
  3181. glDeleteObjectARB: procedure(obj: GLhandleARB); extdecl;
  3182. glGetHandleARB: function(pname: GLenum): GLhandleARB; extdecl;
  3183. glDetachObjectARB: procedure(containerObj: GLhandleARB; attachedObj: GLhandleARB); extdecl;
  3184. glCreateShaderObjectARB: function(shaderType: GLenum): GLhandleARB; extdecl;
  3185. glShaderSourceARB: procedure(shaderObj: GLhandleARB; count: GLsizei; const _string: PGLvoid; const length: PGLint); extdecl;
  3186. glCompileShaderARB: procedure(shaderObj: GLhandleARB); extdecl;
  3187. glCreateProgramObjectARB: function(): GLhandleARB; extdecl;
  3188. glAttachObjectARB: procedure(containerObj: GLhandleARB; obj: GLhandleARB); extdecl;
  3189. glLinkProgramARB: procedure(programObj: GLhandleARB); extdecl;
  3190. glUseProgramObjectARB: procedure(programObj: GLhandleARB); extdecl;
  3191. glValidateProgramARB: procedure(programObj: GLhandleARB); extdecl;
  3192. glUniform1fARB: procedure(location: GLint; v0: GLfloat); extdecl;
  3193. glUniform2fARB: procedure(location: GLint; v0: GLfloat; v1: GLfloat); extdecl;
  3194. glUniform3fARB: procedure(location: GLint; v0: GLfloat; v1: GLfloat; v2: GLfloat); extdecl;
  3195. glUniform4fARB: procedure(location: GLint; v0: GLfloat; v1: GLfloat; v2: GLfloat; v3: GLfloat); extdecl;
  3196. glUniform1iARB: procedure(location: GLint; v0: GLint); extdecl;
  3197. glUniform2iARB: procedure(location: GLint; v0: GLint; v1: GLint); extdecl;
  3198. glUniform3iARB: procedure(location: GLint; v0: GLint; v1: GLint; v2: GLint); extdecl;
  3199. glUniform4iARB: procedure(location: GLint; v0: GLint; v1: GLint; v2: GLint; v3: GLint); extdecl;
  3200. glUniform1fvARB: procedure(location: GLint; count: GLsizei; value: PGLfloat); extdecl;
  3201. glUniform2fvARB: procedure(location: GLint; count: GLsizei; value: PGLfloat); extdecl;
  3202. glUniform3fvARB: procedure(location: GLint; count: GLsizei; value: PGLfloat); extdecl;
  3203. glUniform4fvARB: procedure(location: GLint; count: GLsizei; value: PGLfloat); extdecl;
  3204. glUniform1ivARB: procedure(location: GLint; count: GLsizei; value: PGLint); extdecl;
  3205. glUniform2ivARB: procedure(location: GLint; count: GLsizei; value: PGLint); extdecl;
  3206. glUniform3ivARB: procedure(location: GLint; count: GLsizei; value: PGLint); extdecl;
  3207. glUniform4ivARB: procedure(location: GLint; count: GLsizei; value: PGLint); extdecl;
  3208. glUniformMatrix2fvARB: procedure(location: GLint; count: GLsizei; transpose: GLboolean; value: PGLfloat); extdecl;
  3209. glUniformMatrix3fvARB: procedure(location: GLint; count: GLsizei; transpose: GLboolean; value: PGLfloat); extdecl;
  3210. glUniformMatrix4fvARB: procedure(location: GLint; count: GLsizei; transpose: GLboolean; value: PGLfloat); extdecl;
  3211. glGetObjectParameterfvARB: procedure(obj: GLhandleARB; pname: GLenum; params: PGLfloat); extdecl;
  3212. glGetObjectParameterivARB: procedure(obj: GLhandleARB; pname: GLenum; params: PGLint); extdecl;
  3213. glGetInfoLogARB: procedure(obj: GLhandleARB; maxLength: GLsizei; length: PGLsizei; infoLog: PGLcharARB); extdecl;
  3214. glGetAttachedObjectsARB: procedure(containerObj: GLhandleARB; maxCount: GLsizei; count: PGLsizei; obj: PGLhandleARB); extdecl;
  3215. glGetUniformLocationARB: function(programObj: GLhandleARB; const name: PGLcharARB): GLint; extdecl;
  3216. glGetActiveUniformARB: procedure(programObj: GLhandleARB; index: GLuint; maxLength: GLsizei; length: PGLsizei; size: PGLint; _type: PGLenum; name: PGLcharARB); extdecl;
  3217. glGetUniformfvARB: procedure(programObj: GLhandleARB; location: GLint; params: PGLfloat); extdecl;
  3218. glGetUniformivARB: procedure(programObj: GLhandleARB; location: GLint; params: PGLint); extdecl;
  3219. glGetShaderSourceARB: procedure(obj: GLhandleARB; maxLength: GLsizei; length: PGLsizei; source: PGLcharARB); extdecl;
  3220. function Load_GL_ARB_shader_objects: Boolean;
  3221. //***** GL_ARB_vertex_shader *****//
  3222. const
  3223. GL_VERTEX_SHADER_ARB = $8B31;
  3224. GL_MAX_VERTEX_UNIFORM_COMPONENTS_ARB = $8B4A;
  3225. GL_MAX_VARYING_FLOATS_ARB = $8B4B;
  3226. // GL_MAX_VERTEX_ATTRIBS_ARB { already defined }
  3227. // GL_MAX_TEXTURE_IMAGE_UNITS_ARB { already defined }
  3228. GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB = $8B4C;
  3229. GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS_ARB = $8B4D;
  3230. // GL_MAX_TEXTURE_COORDS_ARB { already defined }
  3231. // GL_VERTEX_PROGRAM_POINT_SIZE_ARB { already defined }
  3232. // GL_VERTEX_PROGRAM_TWO_SIDE_ARB { already defined }
  3233. // GL_OBJECT_TYPE_ARB { already defined }
  3234. // GL_OBJECT_SUBTYPE_ARB { already defined }
  3235. GL_OBJECT_ACTIVE_ATTRIBUTES_ARB = $8B89;
  3236. GL_OBJECT_ACTIVE_ATTRIBUTE_MAX_LENGTH_ARB = $8B8A;
  3237. // GL_SHADER_OBJECT_ARB { already defined }
  3238. // GL_VERTEX_ATTRIB_ARRAY_ENABLED_ARB { already defined }
  3239. // GL_VERTEX_ATTRIB_ARRAY_SIZE_ARB { already defined }
  3240. // GL_VERTEX_ATTRIB_ARRAY_STRIDE_ARB { already defined }
  3241. // GL_VERTEX_ATTRIB_ARRAY_TYPE_ARB { already defined }
  3242. // GL_VERTEX_ATTRIB_ARRAY_NORMALIZED_ARB { already defined }
  3243. // GL_CURRENT_VERTEX_ATTRIB_ARB { already defined }
  3244. // GL_VERTEX_ATTRIB_ARRAY_POINTER_ARB { already defined }
  3245. // GL_FLOAT { already defined }
  3246. // GL_FLOAT_VEC2_ARB { already defined }
  3247. // GL_FLOAT_VEC3_ARB { already defined }
  3248. // GL_FLOAT_VEC4_ARB { already defined }
  3249. // GL_FLOAT_MAT2_ARB { already defined }
  3250. // GL_FLOAT_MAT3_ARB { already defined }
  3251. // GL_FLOAT_MAT4_ARB { already defined }
  3252. // glVertexAttrib1fARB { already defined }
  3253. // glVertexAttrib1sARB { already defined }
  3254. // glVertexAttrib1dARB { already defined }
  3255. // glVertexAttrib2fARB { already defined }
  3256. // glVertexAttrib2sARB { already defined }
  3257. // glVertexAttrib2dARB { already defined }
  3258. // glVertexAttrib3fARB { already defined }
  3259. // glVertexAttrib3sARB { already defined }
  3260. // glVertexAttrib3dARB { already defined }
  3261. // glVertexAttrib4fARB { already defined }
  3262. // glVertexAttrib4sARB { already defined }
  3263. // glVertexAttrib4dARB { already defined }
  3264. // glVertexAttrib4NubARB { already defined }
  3265. // glVertexAttrib1fvARB { already defined }
  3266. // glVertexAttrib1svARB { already defined }
  3267. // glVertexAttrib1dvARB { already defined }
  3268. // glVertexAttrib2fvARB { already defined }
  3269. // glVertexAttrib2svARB { already defined }
  3270. // glVertexAttrib2dvARB { already defined }
  3271. // glVertexAttrib3fvARB { already defined }
  3272. // glVertexAttrib3svARB { already defined }
  3273. // glVertexAttrib3dvARB { already defined }
  3274. // glVertexAttrib4fvARB { already defined }
  3275. // glVertexAttrib4svARB { already defined }
  3276. // glVertexAttrib4dvARB { already defined }
  3277. // glVertexAttrib4ivARB { already defined }
  3278. // glVertexAttrib4bvARB { already defined }
  3279. // glVertexAttrib4ubvARB { already defined }
  3280. // glVertexAttrib4usvARB { already defined }
  3281. // glVertexAttrib4uivARB { already defined }
  3282. // glVertexAttrib4NbvARB { already defined }
  3283. // glVertexAttrib4NsvARB { already defined }
  3284. // glVertexAttrib4NivARB { already defined }
  3285. // glVertexAttrib4NubvARB { already defined }
  3286. // glVertexAttrib4NusvARB { already defined }
  3287. // glVertexAttrib4NuivARB { already defined }
  3288. // glVertexAttribPointerARB { already defined }
  3289. // glEnableVertexAttribArrayARB { already defined }
  3290. // glDisableVertexAttribArrayARB { already defined }
  3291. var
  3292. glBindAttribLocationARB: procedure(programObj: GLhandleARB; index: GLuint; const name: PGLcharARB); extdecl;
  3293. glGetActiveAttribARB: procedure(programObj: GLhandleARB; index: GLuint; maxLength: GLsizei; length: PGLsizei; size: PGLint; _type: PGLenum; name: PGLcharARB); extdecl;
  3294. glGetAttribLocationARB: function(programObj: GLhandleARB; const name: PGLcharARB): GLint; extdecl;
  3295. // glGetVertexAttribdvARB { already defined }
  3296. // glGetVertexAttribfvARB { already defined }
  3297. // glGetVertexAttribivARB { already defined }
  3298. // glGetVertexAttribPointervARB { already defined }
  3299. function Load_GL_ARB_vertex_shader: Boolean;
  3300. //***** GL_ARB_fragment_shader *****//
  3301. const
  3302. GL_FRAGMENT_SHADER_ARB = $8B30;
  3303. GL_MAX_FRAGMENT_UNIFORM_COMPONENTS_ARB = $8B49;
  3304. // GL_MAX_TEXTURE_COORDS_ARB { already defined }
  3305. // GL_MAX_TEXTURE_IMAGE_UNITS_ARB { already defined }
  3306. // GL_OBJECT_TYPE_ARB { already defined }
  3307. // GL_OBJECT_SUBTYPE_ARB { already defined }
  3308. // GL_SHADER_OBJECT_ARB { already defined }
  3309. function Load_GL_ARB_fragment_shader: Boolean;
  3310. //***** GL_ARB_shading_language_100 *****//
  3311. function Load_GL_ARB_shading_language_100: Boolean;
  3312. //***** GL_ARB_texture_non_power_of_two *****//
  3313. function Load_GL_ARB_texture_non_power_of_two: Boolean;
  3314. //***** GL_ARB_point_sprite *****//
  3315. const
  3316. GL_POINT_SPRITE_ARB = $8861;
  3317. GL_COORD_REPLACE_ARB = $8862;
  3318. function Load_GL_ARB_point_sprite: Boolean;
  3319. //***** GL_EXT_depth_bounds_test *****//
  3320. const
  3321. GL_DEPTH_BOUNDS_TEST_EXT = $8890;
  3322. GL_DEPTH_BOUNDS_EXT = $8891;
  3323. var
  3324. glDepthBoundsEXT: procedure(zmin: GLclampd; zmax: GLclampd); extdecl;
  3325. function Load_GL_EXT_depth_bounds_test: Boolean;
  3326. //***** GL_EXT_texture_mirror_clamp *****//
  3327. const
  3328. GL_MIRROR_CLAMP_EXT = $8742;
  3329. GL_MIRROR_CLAMP_TO_EDGE_EXT = $8743;
  3330. GL_MIRROR_CLAMP_TO_BORDER_EXT = $8912;
  3331. function Load_GL_EXT_texture_mirror_clamp: Boolean;
  3332. //***** GL_EXT_blend_equation_separate *****//
  3333. const
  3334. GL_BLEND_EQUATION_RGB_EXT = $8009;
  3335. GL_BLEND_EQUATION_ALPHA_EXT = $883D;
  3336. var
  3337. glBlendEquationSeparateEXT: procedure(modeRGB: GLenum; modeAlpha: GLenum); extdecl;
  3338. function Load_GL_EXT_blend_equation_separate: Boolean;
  3339. //***** GL_MESA_pack_invert *****//
  3340. const
  3341. GL_PACK_INVERT_MESA = $8758;
  3342. function Load_GL_MESA_pack_invert: Boolean;
  3343. //***** GL_MESA_ycbcr_texture *****//
  3344. const
  3345. GL_YCBCR_MESA = $8757;
  3346. GL_UNSIGNED_SHORT_8_8_MESA = $85BA;
  3347. GL_UNSIGNED_SHORT_8_8_REV_MESA = $85BB;
  3348. function Load_GL_MESA_ycbcr_texture: Boolean;
  3349. //***** GL_ARB_fragment_program_shadow *****//
  3350. function Load_GL_ARB_fragment_program_shadow: Boolean;
  3351. //***** GL_NV_fragment_program_option *****//
  3352. function Load_GL_NV_fragment_program_option: Boolean;
  3353. //***** GL_EXT_pixel_buffer_object *****//
  3354. const
  3355. GL_PIXEL_PACK_BUFFER_EXT = $88EB;
  3356. GL_PIXEL_UNPACK_BUFFER_EXT = $88EC;
  3357. GL_PIXEL_PACK_BUFFER_BINDING_EXT = $88ED;
  3358. GL_PIXEL_UNPACK_BUFFER_BINDING_EXT = $88EF;
  3359. function Load_GL_EXT_pixel_buffer_object: Boolean;
  3360. //***** GL_NV_fragment_program2 *****//
  3361. const
  3362. GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV = $88F4;
  3363. GL_MAX_PROGRAM_CALL_DEPTH_NV = $88F5;
  3364. GL_MAX_PROGRAM_IF_DEPTH_NV = $88F6;
  3365. GL_MAX_PROGRAM_LOOP_DEPTH_NV = $88F7;
  3366. GL_MAX_PROGRAM_LOOP_COUNT_NV = $88F8;
  3367. function Load_GL_NV_fragment_program2: Boolean;
  3368. //***** GL_NV_vertex_program2_option *****//
  3369. // GL_MAX_PROGRAM_EXEC_INSTRUCTIONS_NV { already defined }
  3370. // GL_MAX_PROGRAM_CALL_DEPTH_NV { already defined }
  3371. function Load_GL_NV_vertex_program2_option: Boolean;
  3372. //***** GL_NV_vertex_program3 *****//
  3373. // GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS_ARB { already defined }
  3374. function Load_GL_NV_vertex_program3: Boolean;
  3375. //***** GL_ARB_draw_buffers *****//
  3376. const
  3377. GL_MAX_DRAW_BUFFERS_ARB = $8824;
  3378. GL_DRAW_BUFFER0_ARB = $8825;
  3379. GL_DRAW_BUFFER1_ARB = $8826;
  3380. GL_DRAW_BUFFER2_ARB = $8827;
  3381. GL_DRAW_BUFFER3_ARB = $8828;
  3382. GL_DRAW_BUFFER4_ARB = $8829;
  3383. GL_DRAW_BUFFER5_ARB = $882A;
  3384. GL_DRAW_BUFFER6_ARB = $882B;
  3385. GL_DRAW_BUFFER7_ARB = $882C;
  3386. GL_DRAW_BUFFER8_ARB = $882D;
  3387. GL_DRAW_BUFFER9_ARB = $882E;
  3388. GL_DRAW_BUFFER10_ARB = $882F;
  3389. GL_DRAW_BUFFER11_ARB = $8830;
  3390. GL_DRAW_BUFFER12_ARB = $8831;
  3391. GL_DRAW_BUFFER13_ARB = $8832;
  3392. GL_DRAW_BUFFER14_ARB = $8833;
  3393. GL_DRAW_BUFFER15_ARB = $8834;
  3394. var
  3395. glDrawBuffersARB: procedure(n: GLsizei; const bufs: PGLenum); extdecl;
  3396. function Load_GL_ARB_draw_buffers: Boolean;
  3397. //***** GL_ARB_texture_rectangle *****//
  3398. const
  3399. GL_TEXTURE_RECTANGLE_ARB = $84F5;
  3400. GL_TEXTURE_BINDING_RECTANGLE_ARB = $84F6;
  3401. GL_PROXY_TEXTURE_RECTANGLE_ARB = $84F7;
  3402. GL_MAX_RECTANGLE_TEXTURE_SIZE_ARB = $84F8;
  3403. function Load_GL_ARB_texture_rectangle: Boolean;
  3404. //***** GL_ARB_color_buffer_float *****//
  3405. const
  3406. GL_RGBA_FLOAT_MODE_ARB = $8820;
  3407. GL_CLAMP_VERTEX_COLOR_ARB = $891A;
  3408. GL_CLAMP_FRAGMENT_COLOR_ARB = $891B;
  3409. GL_CLAMP_READ_COLOR_ARB = $891C;
  3410. GL_FIXED_ONLY_ARB = $891D;
  3411. WGL_TYPE_RGBA_FLOAT_ARB = $21A0;
  3412. var
  3413. glClampColorARB: procedure(target: GLenum; clamp: GLenum); extdecl;
  3414. function Load_GL_ARB_color_buffer_float: Boolean;
  3415. //***** GL_ARB_half_float_pixel *****//
  3416. const
  3417. GL_HALF_FLOAT_ARB = $140B;
  3418. function Load_GL_ARB_half_float_pixel: Boolean;
  3419. //***** GL_ARB_texture_float *****//
  3420. const
  3421. GL_TEXTURE_RED_TYPE_ARB = $8C10;
  3422. GL_TEXTURE_GREEN_TYPE_ARB = $8C11;
  3423. GL_TEXTURE_BLUE_TYPE_ARB = $8C12;
  3424. GL_TEXTURE_ALPHA_TYPE_ARB = $8C13;
  3425. GL_TEXTURE_LUMINANCE_TYPE_ARB = $8C14;
  3426. GL_TEXTURE_INTENSITY_TYPE_ARB = $8C15;
  3427. GL_TEXTURE_DEPTH_TYPE_ARB = $8C16;
  3428. GL_UNSIGNED_NORMALIZED_ARB = $8C17;
  3429. GL_RGBA32F_ARB = $8814;
  3430. GL_RGB32F_ARB = $8815;
  3431. GL_ALPHA32F_ARB = $8816;
  3432. GL_INTENSITY32F_ARB = $8817;
  3433. GL_LUMINANCE32F_ARB = $8818;
  3434. GL_LUMINANCE_ALPHA32F_ARB = $8819;
  3435. GL_RGBA16F_ARB = $881A;
  3436. GL_RGB16F_ARB = $881B;
  3437. GL_ALPHA16F_ARB = $881C;
  3438. GL_INTENSITY16F_ARB = $881D;
  3439. GL_LUMINANCE16F_ARB = $881E;
  3440. GL_LUMINANCE_ALPHA16F_ARB = $881F;
  3441. function Load_GL_ARB_texture_float: Boolean;
  3442. //***** GL_EXT_texture_compression_dxt1 *****//
  3443. // GL_COMPRESSED_RGB_S3TC_DXT1_EXT { already defined }
  3444. // GL_COMPRESSED_RGBA_S3TC_DXT1_EXT { already defined }
  3445. function Load_GL_EXT_texture_compression_dxt1: Boolean;
  3446. //***** GL_ARB_pixel_buffer_object *****//
  3447. const
  3448. GL_PIXEL_PACK_BUFFER_ARB = $88EB;
  3449. GL_PIXEL_UNPACK_BUFFER_ARB = $88EC;
  3450. GL_PIXEL_PACK_BUFFER_BINDING_ARB = $88ED;
  3451. GL_PIXEL_UNPACK_BUFFER_BINDING_ARB = $88EF;
  3452. function Load_GL_ARB_pixel_buffer_object: Boolean;
  3453. //***** GL_EXT_framebuffer_object *****//
  3454. const
  3455. GL_FRAMEBUFFER_EXT = $8D40;
  3456. GL_RENDERBUFFER_EXT = $8D41;
  3457. GL_STENCIL_INDEX_EXT = $8D45;
  3458. GL_STENCIL_INDEX1_EXT = $8D46;
  3459. GL_STENCIL_INDEX4_EXT = $8D47;
  3460. GL_STENCIL_INDEX8_EXT = $8D48;
  3461. GL_STENCIL_INDEX16_EXT = $8D49;
  3462. GL_RENDERBUFFER_WIDTH_EXT = $8D42;
  3463. GL_RENDERBUFFER_HEIGHT_EXT = $8D43;
  3464. GL_RENDERBUFFER_INTERNAL_FORMAT_EXT = $8D44;
  3465. GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE_EXT = $8CD0;
  3466. GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME_EXT = $8CD1;
  3467. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL_EXT = $8CD2;
  3468. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE_EXT = $8CD3;
  3469. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_3D_ZOFFSET_EXT = $8CD4;
  3470. GL_COLOR_ATTACHMENT0_EXT = $8CE0;
  3471. GL_COLOR_ATTACHMENT1_EXT = $8CE1;
  3472. GL_COLOR_ATTACHMENT2_EXT = $8CE2;
  3473. GL_COLOR_ATTACHMENT3_EXT = $8CE3;
  3474. GL_COLOR_ATTACHMENT4_EXT = $8CE4;
  3475. GL_COLOR_ATTACHMENT5_EXT = $8CE5;
  3476. GL_COLOR_ATTACHMENT6_EXT = $8CE6;
  3477. GL_COLOR_ATTACHMENT7_EXT = $8CE7;
  3478. GL_COLOR_ATTACHMENT8_EXT = $8CE8;
  3479. GL_COLOR_ATTACHMENT9_EXT = $8CE9;
  3480. GL_COLOR_ATTACHMENT10_EXT = $8CEA;
  3481. GL_COLOR_ATTACHMENT11_EXT = $8CEB;
  3482. GL_COLOR_ATTACHMENT12_EXT = $8CEC;
  3483. GL_COLOR_ATTACHMENT13_EXT = $8CED;
  3484. GL_COLOR_ATTACHMENT14_EXT = $8CEE;
  3485. GL_COLOR_ATTACHMENT15_EXT = $8CEF;
  3486. GL_DEPTH_ATTACHMENT_EXT = $8D00;
  3487. GL_STENCIL_ATTACHMENT_EXT = $8D20;
  3488. GL_FRAMEBUFFER_COMPLETE_EXT = $8CD5;
  3489. GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT_EXT = $8CD6;
  3490. GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT_EXT = $8CD7;
  3491. GL_FRAMEBUFFER_INCOMPLETE_DUPLICATE_ATTACHMENT_EXT = $8CD8;
  3492. GL_FRAMEBUFFER_INCOMPLETE_DIMENSIONS_EXT = $8CD9;
  3493. GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT = $8CDA;
  3494. GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER_EXT = $8CDB;
  3495. GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER_EXT = $8CDC;
  3496. GL_FRAMEBUFFER_UNSUPPORTED_EXT = $8CDD;
  3497. GL_FRAMEBUFFER_STATUS_ERROR_EXT = $8CDE;
  3498. GL_FRAMEBUFFER_BINDING_EXT = $8CA6;
  3499. GL_RENDERBUFFER_BINDING_EXT = $8CA7;
  3500. GL_MAX_COLOR_ATTACHMENTS_EXT = $8CDF;
  3501. GL_MAX_RENDERBUFFER_SIZE_EXT = $84E8;
  3502. GL_INVALID_FRAMEBUFFER_OPERATION_EXT = $0506;
  3503. var
  3504. glIsRenderbufferEXT: function(renderbuffer: GLuint): GLboolean; extdecl;
  3505. glBindRenderbufferEXT: procedure(target: GLenum; renderbuffer: GLuint); extdecl;
  3506. glDeleteRenderbuffersEXT: procedure(n: GLsizei; const renderbuffers: PGLuint); extdecl;
  3507. glGenRenderbuffersEXT: procedure(n: GLsizei; renderbuffers: PGLuint); extdecl;
  3508. glRenderbufferStorageEXT: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei); extdecl;
  3509. glGetRenderbufferParameterivEXT: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  3510. glIsFramebufferEXT: function(framebuffer: GLuint): GLboolean; extdecl;
  3511. glBindFramebufferEXT: procedure(target: GLenum; framebuffer: GLuint); extdecl;
  3512. glDeleteFramebuffersEXT: procedure(n: GLsizei; const framebuffers: PGLuint); extdecl;
  3513. glGenFramebuffersEXT: procedure(n: GLsizei; framebuffers: PGLuint); extdecl;
  3514. glCheckFramebufferStatusEXT: function(target: GLenum): GLenum; extdecl;
  3515. glFramebufferTexture1DEXT: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint); extdecl;
  3516. glFramebufferTexture2DEXT: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint); extdecl;
  3517. glFramebufferTexture3DEXT: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint; zoffset: GLint); extdecl;
  3518. glFramebufferRenderbufferEXT: procedure(target: GLenum; attachment: GLenum; renderbuffertarget: GLenum; renderbuffer: GLuint); extdecl;
  3519. glGetFramebufferAttachmentParameterivEXT: procedure(target: GLenum; attachment: GLenum; pname: GLenum; params: PGLint); extdecl;
  3520. glGenerateMipmapEXT: procedure(target: GLenum); extdecl;
  3521. function Load_GL_EXT_framebuffer_object: Boolean;
  3522. //**** GL_ARB_framebuffer_object *****//
  3523. const
  3524. GL_INVALID_FRAMEBUFFER_OPERATION = $0506;
  3525. GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING = $8210;
  3526. GL_FRAMEBUFFER_ATTACHMENT_COMPONENT_TYPE = $8211;
  3527. GL_FRAMEBUFFER_ATTACHMENT_RED_SIZE = $8212;
  3528. GL_FRAMEBUFFER_ATTACHMENT_GREEN_SIZE = $8213;
  3529. GL_FRAMEBUFFER_ATTACHMENT_BLUE_SIZE = $8214;
  3530. GL_FRAMEBUFFER_ATTACHMENT_ALPHA_SIZE = $8215;
  3531. GL_FRAMEBUFFER_ATTACHMENT_DEPTH_SIZE = $8216;
  3532. GL_FRAMEBUFFER_ATTACHMENT_STENCIL_SIZE = $8217;
  3533. GL_FRAMEBUFFER_DEFAULT = $8218;
  3534. GL_FRAMEBUFFER_UNDEFINED = $8219;
  3535. GL_DEPTH_STENCIL_ATTACHMENT = $821A;
  3536. GL_MAX_RENDERBUFFER_SIZE = $84E8;
  3537. GL_DEPTH_STENCIL = $84F9;
  3538. GL_UNSIGNED_INT_24_8 = $84FA;
  3539. GL_DEPTH24_STENCIL8 = $88F0;
  3540. GL_TEXTURE_STENCIL_SIZE = $88F1;
  3541. GL_TEXTURE_RED_TYPE = $8C10;
  3542. GL_TEXTURE_GREEN_TYPE = $8C11;
  3543. GL_TEXTURE_BLUE_TYPE = $8C12;
  3544. GL_TEXTURE_ALPHA_TYPE = $8C13;
  3545. GL_TEXTURE_DEPTH_TYPE = $8C16;
  3546. GL_UNSIGNED_NORMALIZED = $8C17;
  3547. GL_FRAMEBUFFER_BINDING = $8CA6;
  3548. GL_DRAW_FRAMEBUFFER_BINDING = GL_FRAMEBUFFER_BINDING;
  3549. GL_RENDERBUFFER_BINDING = $8CA7;
  3550. GL_READ_FRAMEBUFFER = $8CA8;
  3551. GL_DRAW_FRAMEBUFFER = $8CA9;
  3552. GL_READ_FRAMEBUFFER_BINDING = $8CAA;
  3553. GL_RENDERBUFFER_SAMPLES = $8CAB;
  3554. GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE = $8CD0;
  3555. GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME = $8CD1;
  3556. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LEVEL = $8CD2;
  3557. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_CUBE_MAP_FACE = $8CD3;
  3558. GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER = $8CD4;
  3559. GL_FRAMEBUFFER_COMPLETE = $8CD5;
  3560. GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT = $8CD6;
  3561. GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT = $8CD7;
  3562. GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER = $8CDB;
  3563. GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER = $8CDC;
  3564. GL_FRAMEBUFFER_UNSUPPORTED = $8CDD;
  3565. GL_MAX_COLOR_ATTACHMENTS = $8CDF;
  3566. GL_COLOR_ATTACHMENT0 = $8CE0;
  3567. GL_COLOR_ATTACHMENT1 = $8CE1;
  3568. GL_COLOR_ATTACHMENT2 = $8CE2;
  3569. GL_COLOR_ATTACHMENT3 = $8CE3;
  3570. GL_COLOR_ATTACHMENT4 = $8CE4;
  3571. GL_COLOR_ATTACHMENT5 = $8CE5;
  3572. GL_COLOR_ATTACHMENT6 = $8CE6;
  3573. GL_COLOR_ATTACHMENT7 = $8CE7;
  3574. GL_COLOR_ATTACHMENT8 = $8CE8;
  3575. GL_COLOR_ATTACHMENT9 = $8CE9;
  3576. GL_COLOR_ATTACHMENT10 = $8CEA;
  3577. GL_COLOR_ATTACHMENT11 = $8CEB;
  3578. GL_COLOR_ATTACHMENT12 = $8CEC;
  3579. GL_COLOR_ATTACHMENT13 = $8CED;
  3580. GL_COLOR_ATTACHMENT14 = $8CEE;
  3581. GL_COLOR_ATTACHMENT15 = $8CEF;
  3582. GL_DEPTH_ATTACHMENT = $8D00;
  3583. GL_STENCIL_ATTACHMENT = $8D20;
  3584. GL_FRAMEBUFFER = $8D40;
  3585. GL_RENDERBUFFER = $8D41;
  3586. GL_RENDERBUFFER_WIDTH = $8D42;
  3587. GL_RENDERBUFFER_HEIGHT = $8D43;
  3588. GL_RENDERBUFFER_INTERNAL_FORMAT = $8D44;
  3589. GL_STENCIL_INDEX1 = $8D46;
  3590. GL_STENCIL_INDEX4 = $8D47;
  3591. GL_STENCIL_INDEX8 = $8D48;
  3592. GL_STENCIL_INDEX16 = $8D49;
  3593. GL_RENDERBUFFER_RED_SIZE = $8D50;
  3594. GL_RENDERBUFFER_GREEN_SIZE = $8D51;
  3595. GL_RENDERBUFFER_BLUE_SIZE = $8D52;
  3596. GL_RENDERBUFFER_ALPHA_SIZE = $8D53;
  3597. GL_RENDERBUFFER_DEPTH_SIZE = $8D54;
  3598. GL_RENDERBUFFER_STENCIL_SIZE = $8D55;
  3599. GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE = $8D56;
  3600. GL_MAX_SAMPLES = $8D57;
  3601. var
  3602. glIsRenderbuffer: function(renderbuffer: GLuint): GLboolean; extdecl;
  3603. glBindRenderbuffer: procedure(target: GLenum; renderbuffer: GLuint); extdecl;
  3604. glDeleteRenderbuffers: procedure(n: GLsizei; const renderbuffers: PGLuint); extdecl;
  3605. glGenRenderbuffers: procedure(n: GLsizei; renderbuffers: PGLuint); extdecl;
  3606. glRenderbufferStorage: procedure(target: GLenum; internalformat: GLenum; width: GLsizei; height: GLsizei); extdecl;
  3607. glGetRenderbufferParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  3608. glIsFramebuffer: function(framebuffer: GLuint): GLboolean; extdecl;
  3609. glBindFramebuffer: procedure(target: GLenum; framebuffer: GLuint); extdecl;
  3610. glDeleteFramebuffers: procedure(n: GLsizei; const framebuffers: PGLuint); extdecl;
  3611. glGenFramebuffers: procedure(n: GLsizei; framebuffers: PGLuint); extdecl;
  3612. glCheckFramebufferStatus: function(target: GLenum): GLenum; extdecl;
  3613. glFramebufferTexture1D: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint); extdecl;
  3614. glFramebufferTexture2D: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint); extdecl;
  3615. glFramebufferTexture3D: procedure(target: GLenum; attachment: GLenum; textarget: GLenum; texture: GLuint; level: GLint; zoffset: GLint); extdecl;
  3616. glFramebufferRenderbuffer: procedure(target: GLenum; attachment: GLenum; renderbuffertarget: GLenum; renderbuffer: GLuint); extdecl;
  3617. glGetFramebufferAttachmentParameteriv: procedure(target: GLenum; attachment: GLenum; pname: GLenum; params: PGLint); extdecl;
  3618. glGenerateMipmap: procedure(target: GLenum); extdecl;
  3619. glBlitFramebuffer: procedure(srcX0: GLint; srcY0: GLint; srcX1: GLint; srcY1: GLint; dstX0: GLint; dstY0: GLint; dstX1: GLint; dstY1: GLint; mask: GLbitfield; filter: GLenum); extdecl;
  3620. glRenderbufferStorageMultisample: procedure(target: GLenum; samples: GLsizei; internalformat: GLenum; width: GLsizei; height: GLsizei); extdecl;
  3621. glFramebufferTextureLayer: procedure(target: GLenum; attachment: GLenum; texture: GLuint; level: GLint; layer: GLint); extdecl;
  3622. { Using LoadAsCore = true means that we will *not* check
  3623. if the extension is advertised in glGetString(GL_EXTENSIONS) string.
  3624. This allows to successfully Load_GL_version_3_0 in an OpenGL 3.0
  3625. forward-compatible context, where the "core extensions" do not have
  3626. to be mentioned inside glGetString(GL_EXTENSIONS). }
  3627. function Load_GL_ARB_framebuffer_object(LoadAsCore: boolean = false): Boolean;
  3628. //**** GL_ARB_framebuffer_object DEPRECATED *****//
  3629. const
  3630. GL_INDEX = $8222;
  3631. GL_TEXTURE_LUMINANCE_TYPE = $8C14;
  3632. GL_TEXTURE_INTENSITY_TYPE = $8C15;
  3633. //**** GL_ARB_map_buffer_range *****//
  3634. const
  3635. GL_MAP_READ_BIT = $0001;
  3636. GL_MAP_WRITE_BIT = $0002;
  3637. GL_MAP_INVALIDATE_RANGE_BIT = $0004;
  3638. GL_MAP_INVALIDATE_BUFFER_BIT = $0008;
  3639. GL_MAP_FLUSH_EXPLICIT_BIT = $0010;
  3640. GL_MAP_UNSYNCHRONIZED_BIT = $0020;
  3641. var
  3642. glMapBufferRange: function(target: GLenum; offset: GLintptr; length: GLsizeiptr; access: GLbitfield): PGLvoid; extdecl;
  3643. glFlushMappedBufferRange: procedure(target: GLenum; offset: GLintptr; length: GLsizeiptr); extdecl;
  3644. function Load_GL_ARB_map_buffer_range(LoadAsCore: boolean = false): Boolean;
  3645. //**** GL_ARB_vertex_array_object *****//
  3646. const
  3647. GL_VERTEX_ARRAY_BINDING = $85B5;
  3648. var
  3649. glBindVertexArray: procedure(_array: GLuint); extdecl;
  3650. glDeleteVertexArrays: procedure(n: GLsizei; const arrays: PGLuint); extdecl;
  3651. glGenVertexArrays: procedure(n: GLsizei; arrays: PGLuint); extdecl;
  3652. glIsVertexArray: function(_array: GLuint): GLboolean; extdecl;
  3653. function Load_GL_ARB_vertex_array_object(LoadAsCore: boolean = false): Boolean;
  3654. //**** GL_ARB_copy_buffer *****//
  3655. const
  3656. GL_COPY_READ_BUFFER = $8F36;
  3657. GL_COPY_WRITE_BUFFER = $8F37;
  3658. var
  3659. glCopyBufferSubData: procedure(readTarget: GLenum; writeTarget: GLenum; readOffset: GLintptr; writeOffset: GLintptr; size: GLsizeiptr); extdecl;
  3660. function Load_GL_ARB_copy_buffer(LoadAsCore: boolean = false): Boolean;
  3661. //**** GL_ARB_uniform_buffer_object *****//
  3662. const
  3663. GL_UNIFORM_BUFFER = $8A11;
  3664. GL_UNIFORM_BUFFER_BINDING = $8A28;
  3665. GL_UNIFORM_BUFFER_START = $8A29;
  3666. GL_UNIFORM_BUFFER_SIZE = $8A2A;
  3667. GL_MAX_VERTEX_UNIFORM_BLOCKS = $8A2B;
  3668. GL_MAX_GEOMETRY_UNIFORM_BLOCKS = $8A2C;
  3669. GL_MAX_FRAGMENT_UNIFORM_BLOCKS = $8A2D;
  3670. GL_MAX_COMBINED_UNIFORM_BLOCKS = $8A2E;
  3671. GL_MAX_UNIFORM_BUFFER_BINDINGS = $8A2F;
  3672. GL_MAX_UNIFORM_BLOCK_SIZE = $8A30;
  3673. GL_MAX_COMBINED_VERTEX_UNIFORM_COMPONENTS = $8A31;
  3674. GL_MAX_COMBINED_GEOMETRY_UNIFORM_COMPONENTS = $8A32;
  3675. GL_MAX_COMBINED_FRAGMENT_UNIFORM_COMPONENTS = $8A33;
  3676. GL_UNIFORM_BUFFER_OFFSET_ALIGNMENT = $8A34;
  3677. GL_ACTIVE_UNIFORM_BLOCK_MAX_NAME_LENGTH = $8A35;
  3678. GL_ACTIVE_UNIFORM_BLOCKS = $8A36;
  3679. GL_UNIFORM_TYPE = $8A37;
  3680. GL_UNIFORM_SIZE = $8A38;
  3681. GL_UNIFORM_NAME_LENGTH = $8A39;
  3682. GL_UNIFORM_BLOCK_INDEX = $8A3A;
  3683. GL_UNIFORM_OFFSET = $8A3B;
  3684. GL_UNIFORM_ARRAY_STRIDE = $8A3C;
  3685. GL_UNIFORM_MATRIX_STRIDE = $8A3D;
  3686. GL_UNIFORM_IS_ROW_MAJOR = $8A3E;
  3687. GL_UNIFORM_BLOCK_BINDING = $8A3F;
  3688. GL_UNIFORM_BLOCK_DATA_SIZE = $8A40;
  3689. GL_UNIFORM_BLOCK_NAME_LENGTH = $8A41;
  3690. GL_UNIFORM_BLOCK_ACTIVE_UNIFORMS = $8A42;
  3691. GL_UNIFORM_BLOCK_ACTIVE_UNIFORM_INDICES = $8A43;
  3692. GL_UNIFORM_BLOCK_REFERENCED_BY_VERTEX_SHADER = $8A44;
  3693. GL_UNIFORM_BLOCK_REFERENCED_BY_GEOMETRY_SHADER = $8A45;
  3694. GL_UNIFORM_BLOCK_REFERENCED_BY_FRAGMENT_SHADER = $8A46;
  3695. GL_INVALID_INDEX = DWord($FFFFFFFF);
  3696. var
  3697. glGetUniformIndices: procedure(_program: GLuint; uniformCount: GLsizei; const uniformNames: PPGLchar; uniformIndices: PGLuint); extdecl;
  3698. glGetActiveUniformsiv: procedure(_program: GLuint; uniformCount: GLsizei; const uniformIndices: PGLuint; pname: GLenum; params: PGLint); extdecl;
  3699. glGetActiveUniformName: procedure(_program: GLuint; uniformIndex: GLuint; bufSize: GLsizei; length: PGLsizei; uniformName: PGLchar); extdecl;
  3700. glGetUniformBlockIndex: function(_program: GLuint; const uniformBlockName: PGLchar): GLuint; extdecl;
  3701. glGetActiveUniformBlockiv: procedure(_program: GLuint; uniformBlockIndex: GLuint; pname: GLenum; params: PGLint); extdecl;
  3702. glGetActiveUniformBlockName: procedure(_program: GLuint; uniformBlockIndex: GLuint; bufSize: GLsizei; length: PGLsizei; uniformBlockName: PGLchar); extdecl;
  3703. glUniformBlockBinding: procedure(_program: GLuint; uniformBlockIndex: GLuint; uniformBlockBinding: GLuint); extdecl;
  3704. function Load_GL_ARB_uniform_buffer_object(LoadAsCore: boolean = false): Boolean;
  3705. //**** GL_ARB_draw_elements_base_vertex *****//
  3706. var
  3707. glDrawElementsBaseVertex: procedure(mode: GLenum; count: GLsizei; _type: GLenum; const indices: PGLvoid; basevertex: GLint); extdecl;
  3708. glDrawRangeElementsBaseVertex: procedure(mode: GLenum; start: GLuint; _end: GLuint; count: GLsizei; _type: GLenum; const indices: PGLvoid; basevertex: GLint); extdecl;
  3709. glDrawElementsInstancedBaseVertex: procedure(mode: GLenum; count: GLsizei; _type: GLenum; const indices: PGLvoid; primcount: GLsizei; basevertex: GLint); extdecl;
  3710. glMultiDrawElementsBaseVertex: procedure(mode: GLenum; const count: PGLsizei; _type: GLenum; const indices: PPGLvoid; primcount: GLsizei; const basevertex: PGLint); extdecl;
  3711. function Load_GL_ARB_draw_elements_base_vertex(LoadAsCore: boolean = false): Boolean;
  3712. //**** GL_ARB_provoking_vertex *****//
  3713. const
  3714. GL_QUADS_FOLLOW_PROVOKING_VERTEX_CONVENTION = $8E4C;
  3715. GL_FIRST_VERTEX_CONVENTION = $8E4D;
  3716. GL_LAST_VERTEX_CONVENTION = $8E4E;
  3717. GL_PROVOKING_VERTEX = $8E4F;
  3718. var
  3719. glProvokingVertex: procedure(mode: GLenum); extdecl;
  3720. function Load_GL_ARB_provoking_vertex(LoadAsCore: boolean = false): Boolean;
  3721. //**** GL_ARB_sync *****//
  3722. type
  3723. GLsync = Pointer;
  3724. TGLsync = GLSync;
  3725. PGLsync = ^GLSync;
  3726. const
  3727. GL_MAX_SERVER_WAIT_TIMEOUT = $9111;
  3728. GL_OBJECT_TYPE = $9112;
  3729. GL_SYNC_CONDITION = $9113;
  3730. GL_SYNC_STATUS = $9114;
  3731. GL_SYNC_FLAGS = $9115;
  3732. GL_SYNC_FENCE = $9116;
  3733. GL_SYNC_GPU_COMMANDS_COMPLETE = $9117;
  3734. GL_UNSIGNALED = $9118;
  3735. GL_SIGNALED = $9119;
  3736. GL_ALREADY_SIGNALED = $911A;
  3737. GL_TIMEOUT_EXPIRED = $911B;
  3738. GL_CONDITION_SATISFIED = $911C;
  3739. GL_WAIT_FAILED = $911D;
  3740. GL_SYNC_FLUSH_COMMANDS_BIT = $00000001;
  3741. GL_TIMEOUT_IGNORED = QWord($FFFFFFFFFFFFFFFF);
  3742. var
  3743. glFenceSync: function(condition: GLenum; flags: GLbitfield): GLsync; extdecl;
  3744. glIsSync: function(sync: GLsync): GLboolean; extdecl;
  3745. glDeleteSync: procedure(sync: GLsync); extdecl;
  3746. glClientWaitSync: function(sync: GLsync; flags: GLbitfield; timeout: GLuint64): GLenum; extdecl;
  3747. glWaitSync: procedure(sync: GLsync; flags: GLbitfield; timeout: GLuint64); extdecl;
  3748. glGetInteger64v: procedure(pname: GLenum; params: PGLint64); extdecl;
  3749. glGetSynciv: procedure(sync: GLsync; pname: GLenum; bufSize: GLsizei; length: PGLsizei; values: PGLint); extdecl;
  3750. function Load_GL_ARB_sync(LoadAsCore: boolean = false): Boolean;
  3751. //**** GL_ARB_texture_multisample *****//
  3752. const
  3753. GL_SAMPLE_POSITION = $8E50;
  3754. GL_SAMPLE_MASK = $8E51;
  3755. GL_SAMPLE_MASK_VALUE = $8E52;
  3756. GL_MAX_SAMPLE_MASK_WORDS = $8E59;
  3757. GL_TEXTURE_2D_MULTISAMPLE = $9100;
  3758. GL_PROXY_TEXTURE_2D_MULTISAMPLE = $9101;
  3759. GL_TEXTURE_2D_MULTISAMPLE_ARRAY = $9102;
  3760. GL_PROXY_TEXTURE_2D_MULTISAMPLE_ARRAY = $9103;
  3761. GL_TEXTURE_BINDING_2D_MULTISAMPLE = $9104;
  3762. GL_TEXTURE_BINDING_2D_MULTISAMPLE_ARRAY = $9105;
  3763. GL_TEXTURE_SAMPLES = $9106;
  3764. GL_TEXTURE_FIXED_SAMPLE_LOCATIONS = $9107;
  3765. GL_SAMPLER_2D_MULTISAMPLE = $9108;
  3766. GL_INT_SAMPLER_2D_MULTISAMPLE = $9109;
  3767. GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE = $910A;
  3768. GL_SAMPLER_2D_MULTISAMPLE_ARRAY = $910B;
  3769. GL_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = $910C;
  3770. GL_UNSIGNED_INT_SAMPLER_2D_MULTISAMPLE_ARRAY = $910D;
  3771. GL_MAX_COLOR_TEXTURE_SAMPLES = $910E;
  3772. GL_MAX_DEPTH_TEXTURE_SAMPLES = $910F;
  3773. GL_MAX_INTEGER_SAMPLES = $9110;
  3774. var
  3775. glTexImage2DMultisample: procedure(target: GLenum; samples: GLsizei; internalformat: GLint; width: GLsizei; height: GLsizei; fixedsamplelocations: GLboolean); extdecl;
  3776. glTexImage3DMultisample: procedure(target: GLenum; samples: GLsizei; internalformat: GLint; width: GLsizei; height: GLsizei; depth: GLsizei; fixedsamplelocations: GLboolean); extdecl;
  3777. glGetMultisamplefv: procedure(pname: GLenum; index: GLuint; val: PGLfloat); extdecl;
  3778. glSampleMaski: procedure(index: GLuint; mask: GLbitfield); extdecl;
  3779. function Load_GL_ARB_texture_multisample(LoadAsCore: boolean = false): Boolean;
  3780. //**** GL_ARB_blend_func_extended *****//
  3781. const
  3782. GL_SRC1_COLOR = $88F9;
  3783. // reuse GL_SRC1_ALPHA
  3784. const
  3785. GL_ONE_MINUS_SRC1_COLOR = $88FA;
  3786. GL_ONE_MINUS_SRC1_ALPHA = $88FB;
  3787. GL_MAX_DUAL_SOURCE_DRAW_BUFFERS = $88FC;
  3788. var
  3789. glBindFragDataLocationIndexed: procedure(_program: GLuint; colorNumber: GLuint; index: GLuint; const name: PGLchar); extdecl;
  3790. glGetFragDataIndex: function(_program: GLuint; const name: PGLchar): GLint; extdecl;
  3791. function Load_GL_ARB_blend_func_extended(LoadAsCore: boolean = false): Boolean;
  3792. //**** GL_ARB_sampler_objects *****//
  3793. const
  3794. GL_SAMPLER_BINDING = $8919;
  3795. var
  3796. glGenSamplers: procedure(count: GLsizei; samplers: PGLuint); extdecl;
  3797. glDeleteSamplers: procedure(count: GLsizei; const samplers: PGLuint); extdecl;
  3798. glIsSampler: function(sampler: GLuint): GLboolean; extdecl;
  3799. glBindSampler: procedure(_unit: GLenum; sampler: GLuint); extdecl;
  3800. glSamplerParameteri: procedure(sampler: GLuint; pname: GLenum; param: GLint); extdecl;
  3801. glSamplerParameteriv: procedure(sampler: GLuint; pname: GLenum; const param: PGLint); extdecl;
  3802. glSamplerParameterf: procedure(sampler: GLuint; pname: GLenum; param: GLfloat); extdecl;
  3803. glSamplerParameterfv: procedure(sampler: GLuint; pname: GLenum; const param: PGLfloat); extdecl;
  3804. glSamplerParameterIiv: procedure(sampler: GLuint; pname: GLenum; const param: PGLint); extdecl;
  3805. glSamplerParameterIuiv: procedure(sampler: GLuint; pname: GLenum; const param: PGLuint); extdecl;
  3806. glGetSamplerParameteriv: procedure(sampler: GLuint; pname: GLenum; params: PGLint); extdecl;
  3807. glGetSamplerParameterIiv: procedure(sampler: GLuint; pname: GLenum; params: PGLint); extdecl;
  3808. glGetSamplerParameterfv: procedure(sampler: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  3809. glGetSamplerParameterIuiv: procedure(sampler: GLuint; pname: GLenum; params: PGLuint); extdecl;
  3810. function Load_GL_ARB_sampler_objects(LoadAsCore: boolean = false): Boolean;
  3811. //**** GL_ARB_timer_query *****//
  3812. const
  3813. GL_TIME_ELAPSED = $88BF;
  3814. GL_TIMESTAMP = $8E28;
  3815. var
  3816. glQueryCounter: procedure(id: GLuint; target: GLenum); extdecl;
  3817. glGetQueryObjecti64v: procedure(id: GLuint; pname: GLenum; params: PGLint64); extdecl;
  3818. glGetQueryObjectui64v: procedure(id: GLuint; pname: GLenum; params: PGLuint64); extdecl;
  3819. function Load_GL_ARB_timer_query(LoadAsCore: boolean = false): Boolean;
  3820. //**** GL_ARB_vertex_type_2_10_10_10_rev *****//
  3821. const
  3822. GL_INT_2_10_10_10_REV = $8D9F;
  3823. var
  3824. glVertexP2ui: procedure(_type: GLenum; value: GLuint); extdecl;
  3825. glVertexP2uiv: procedure(_type: GLenum; const value: PGLuint); extdecl;
  3826. glVertexP3ui: procedure(_type: GLenum; value: GLuint); extdecl;
  3827. glVertexP3uiv: procedure(_type: GLenum; const value: PGLuint); extdecl;
  3828. glVertexP4ui: procedure(_type: GLenum; value: GLuint); extdecl;
  3829. glVertexP4uiv: procedure(_type: GLenum; const value: PGLuint); extdecl;
  3830. glTexCoordP1ui: procedure(_type: GLenum; coords: GLuint); extdecl;
  3831. glTexCoordP1uiv: procedure(_type: GLenum; const coords: PGLuint); extdecl;
  3832. glTexCoordP2ui: procedure(_type: GLenum; coords: GLuint); extdecl;
  3833. glTexCoordP2uiv: procedure(_type: GLenum; const coords: PGLuint); extdecl;
  3834. glTexCoordP3ui: procedure(_type: GLenum; coords: GLuint); extdecl;
  3835. glTexCoordP3uiv: procedure(_type: GLenum; const coords: PGLuint); extdecl;
  3836. glTexCoordP4ui: procedure(_type: GLenum; coords: GLuint); extdecl;
  3837. glTexCoordP4uiv: procedure(_type: GLenum; const coords: PGLuint); extdecl;
  3838. glMultiTexCoordP1ui: procedure(texture: GLenum; _type: GLenum; coords: GLuint); extdecl;
  3839. glMultiTexCoordP1uiv: procedure(texture: GLenum; _type: GLenum; const coords: PGLuint); extdecl;
  3840. glMultiTexCoordP2ui: procedure(texture: GLenum; _type: GLenum; coords: GLuint); extdecl;
  3841. glMultiTexCoordP2uiv: procedure(texture: GLenum; _type: GLenum; const coords: PGLuint); extdecl;
  3842. glMultiTexCoordP3ui: procedure(texture: GLenum; _type: GLenum; coords: GLuint); extdecl;
  3843. glMultiTexCoordP3uiv: procedure(texture: GLenum; _type: GLenum; const coords: PGLuint); extdecl;
  3844. glMultiTexCoordP4ui: procedure(texture: GLenum; _type: GLenum; coords: GLuint); extdecl;
  3845. glMultiTexCoordP4uiv: procedure(texture: GLenum; _type: GLenum; const coords: PGLuint); extdecl;
  3846. glNormalP3ui: procedure(_type: GLenum; coords: GLuint); extdecl;
  3847. glNormalP3uiv: procedure(_type: GLenum; const coords: PGLuint); extdecl;
  3848. glColorP3ui: procedure(_type: GLenum; color: GLuint); extdecl;
  3849. glColorP3uiv: procedure(_type: GLenum; const color: PGLuint); extdecl;
  3850. glColorP4ui: procedure(_type: GLenum; color: GLuint); extdecl;
  3851. glColorP4uiv: procedure(_type: GLenum; const color: PGLuint); extdecl;
  3852. glSecondaryColorP3ui: procedure(_type: GLenum; color: GLuint); extdecl;
  3853. glSecondaryColorP3uiv: procedure(_type: GLenum; const color: PGLuint); extdecl;
  3854. glVertexAttribP1ui: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; value: GLuint); extdecl;
  3855. glVertexAttribP1uiv: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; const value: PGLuint); extdecl;
  3856. glVertexAttribP2ui: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; value: GLuint); extdecl;
  3857. glVertexAttribP2uiv: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; const value: PGLuint); extdecl;
  3858. glVertexAttribP3ui: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; value: GLuint); extdecl;
  3859. glVertexAttribP3uiv: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; const value: PGLuint); extdecl;
  3860. glVertexAttribP4ui: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; value: GLuint); extdecl;
  3861. glVertexAttribP4uiv: procedure(index: GLuint; _type: GLenum; normalized: GLboolean; const value: PGLuint); extdecl;
  3862. function Load_GL_ARB_vertex_type_2_10_10_10_rev(LoadAsCore: boolean = false): Boolean;
  3863. //**** GL_ARB_gpu_shader_fp64 *****//
  3864. // reuse GL_DOUBLE
  3865. const
  3866. GL_DOUBLE_VEC2 = $8FFC;
  3867. GL_DOUBLE_VEC3 = $8FFD;
  3868. GL_DOUBLE_VEC4 = $8FFE;
  3869. GL_DOUBLE_MAT2 = $8F46;
  3870. GL_DOUBLE_MAT3 = $8F47;
  3871. GL_DOUBLE_MAT4 = $8F48;
  3872. GL_DOUBLE_MAT2x3 = $8F49;
  3873. GL_DOUBLE_MAT2x4 = $8F4A;
  3874. GL_DOUBLE_MAT3x2 = $8F4B;
  3875. GL_DOUBLE_MAT3x4 = $8F4C;
  3876. GL_DOUBLE_MAT4x2 = $8F4D;
  3877. GL_DOUBLE_MAT4x3 = $8F4E;
  3878. var
  3879. glUniform1d: procedure(location: GLint; x: GLdouble); extdecl;
  3880. glUniform2d: procedure(location: GLint; x: GLdouble; y: GLdouble); extdecl;
  3881. glUniform3d: procedure(location: GLint; x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  3882. glUniform4d: procedure(location: GLint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  3883. glUniform1dv: procedure(location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3884. glUniform2dv: procedure(location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3885. glUniform3dv: procedure(location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3886. glUniform4dv: procedure(location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3887. glUniformMatrix2dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3888. glUniformMatrix3dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3889. glUniformMatrix4dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3890. glUniformMatrix2x3dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3891. glUniformMatrix2x4dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3892. glUniformMatrix3x2dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3893. glUniformMatrix3x4dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3894. glUniformMatrix4x2dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3895. glUniformMatrix4x3dv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3896. glGetUniformdv: procedure(_program: GLuint; location: GLint; params: PGLdouble); extdecl;
  3897. { All of the following ProgramUniform* functions are supported if and only
  3898. if EXT_direct_state_access is supported.
  3899. (See http://www.opengl.org/registry/specs/ARB/gpu_shader_fp64.txt)
  3900. Load_GL_ARB_gpu_shader_fp64 will try to load them, but their presence/absence
  3901. will have no effect on the result of Load_GL_ARB_gpu_shader_fp64 and
  3902. Load_GL_VERSION_4_0 functions. (Because they are not mandatory parts of
  3903. the extension or OpenGL 4.0 core spec.) }
  3904. glProgramUniform1dEXT: procedure(_program: GLuint; location: GLint; x: GLdouble); extdecl;
  3905. glProgramUniform2dEXT: procedure(_program: GLuint; location: GLint; x: GLdouble; y: GLdouble); extdecl;
  3906. glProgramUniform3dEXT: procedure(_program: GLuint; location: GLint; x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  3907. glProgramUniform4dEXT: procedure(_program: GLuint; location: GLint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  3908. glProgramUniform1dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3909. glProgramUniform2dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3910. glProgramUniform3dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3911. glProgramUniform4dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; const value: PGLdouble); extdecl;
  3912. glProgramUniformMatrix2dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3913. glProgramUniformMatrix3dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3914. glProgramUniformMatrix4dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3915. glProgramUniformMatrix2x3dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3916. glProgramUniformMatrix2x4dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3917. glProgramUniformMatrix3x2dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3918. glProgramUniformMatrix3x4dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3919. glProgramUniformMatrix4x2dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3920. glProgramUniformMatrix4x3dvEXT: procedure(_program: GLuint; location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLdouble); extdecl;
  3921. function Load_GL_ARB_gpu_shader_fp64(LoadAsCore: boolean = false): Boolean;
  3922. //**** GL_ARB_shader_subroutine *****//
  3923. const
  3924. GL_ACTIVE_SUBROUTINES = $8DE5;
  3925. GL_ACTIVE_SUBROUTINE_UNIFORMS = $8DE6;
  3926. GL_ACTIVE_SUBROUTINE_UNIFORM_LOCATIONS = $8E47;
  3927. GL_ACTIVE_SUBROUTINE_MAX_LENGTH = $8E48;
  3928. GL_ACTIVE_SUBROUTINE_UNIFORM_MAX_LENGTH = $8E49;
  3929. GL_MAX_SUBROUTINES = $8DE7;
  3930. GL_MAX_SUBROUTINE_UNIFORM_LOCATIONS = $8DE8;
  3931. GL_NUM_COMPATIBLE_SUBROUTINES = $8E4A;
  3932. GL_COMPATIBLE_SUBROUTINES = $8E4B;
  3933. var
  3934. glGetSubroutineUniformLocation: function(_program: GLuint; shadertype: GLenum; const name: PGLchar): GLint; extdecl;
  3935. glGetSubroutineIndex: function(_program: GLuint; shadertype: GLenum; const name: PGLchar): GLuint; extdecl;
  3936. glGetActiveSubroutineUniformiv: procedure(_program: GLuint; shadertype: GLenum; index: GLuint; pname: GLenum; values: PGLint); extdecl;
  3937. glGetActiveSubroutineUniformName: procedure(_program: GLuint; shadertype: GLenum; index: GLuint; bufsize: GLsizei; length: PGLsizei; name: PGLchar); extdecl;
  3938. glGetActiveSubroutineName: procedure(_program: GLuint; shadertype: GLenum; index: GLuint; bufsize: GLsizei; length: PGLsizei; name: PGLchar); extdecl;
  3939. glUniformSubroutinesuiv: procedure(shadertype: GLenum; count: GLsizei; const indices: PGLuint); extdecl;
  3940. glGetUniformSubroutineuiv: procedure(shadertype: GLenum; location: GLint; params: PGLuint); extdecl;
  3941. glGetProgramStageiv: procedure(_program: GLuint; shadertype: GLenum; pname: GLenum; values: PGLint); extdecl;
  3942. function Load_GL_ARB_shader_subroutine(LoadAsCore: boolean = false): Boolean;
  3943. //**** GL_ARB_tessellation_shader *****//
  3944. const
  3945. GL_PATCHES = $000E;
  3946. GL_PATCH_VERTICES = $8E72;
  3947. GL_PATCH_DEFAULT_INNER_LEVEL = $8E73;
  3948. GL_PATCH_DEFAULT_OUTER_LEVEL = $8E74;
  3949. GL_TESS_CONTROL_OUTPUT_VERTICES = $8E75;
  3950. GL_TESS_GEN_MODE = $8E76;
  3951. GL_TESS_GEN_SPACING = $8E77;
  3952. GL_TESS_GEN_VERTEX_ORDER = $8E78;
  3953. GL_TESS_GEN_POINT_MODE = $8E79;
  3954. // reuse GL_TRIANGLES
  3955. // reuse GL_QUADS
  3956. const
  3957. GL_ISOLINES = $8E7A;
  3958. // reuse GL_EQUAL
  3959. const
  3960. GL_FRACTIONAL_ODD = $8E7B;
  3961. GL_FRACTIONAL_EVEN = $8E7C;
  3962. // reuse GL_CCW
  3963. // reuse GL_CW
  3964. const
  3965. GL_MAX_PATCH_VERTICES = $8E7D;
  3966. GL_MAX_TESS_GEN_LEVEL = $8E7E;
  3967. GL_MAX_TESS_CONTROL_UNIFORM_COMPONENTS = $8E7F;
  3968. GL_MAX_TESS_EVALUATION_UNIFORM_COMPONENTS = $8E80;
  3969. GL_MAX_TESS_CONTROL_TEXTURE_IMAGE_UNITS = $8E81;
  3970. GL_MAX_TESS_EVALUATION_TEXTURE_IMAGE_UNITS = $8E82;
  3971. GL_MAX_TESS_CONTROL_OUTPUT_COMPONENTS = $8E83;
  3972. GL_MAX_TESS_PATCH_COMPONENTS = $8E84;
  3973. GL_MAX_TESS_CONTROL_TOTAL_OUTPUT_COMPONENTS = $8E85;
  3974. GL_MAX_TESS_EVALUATION_OUTPUT_COMPONENTS = $8E86;
  3975. GL_MAX_TESS_CONTROL_UNIFORM_BLOCKS = $8E89;
  3976. GL_MAX_TESS_EVALUATION_UNIFORM_BLOCKS = $8E8A;
  3977. GL_MAX_TESS_CONTROL_INPUT_COMPONENTS = $886C;
  3978. GL_MAX_TESS_EVALUATION_INPUT_COMPONENTS = $886D;
  3979. GL_MAX_COMBINED_TESS_CONTROL_UNIFORM_COMPONENTS = $8E1E;
  3980. GL_MAX_COMBINED_TESS_EVALUATION_UNIFORM_COMPONENTS = $8E1F;
  3981. GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_CONTROL_SHADER = $84F0;
  3982. GL_UNIFORM_BLOCK_REFERENCED_BY_TESS_EVALUATION_SHADER = $84F1;
  3983. GL_TESS_EVALUATION_SHADER = $8E87;
  3984. GL_TESS_CONTROL_SHADER = $8E88;
  3985. var
  3986. glPatchParameteri: procedure(pname: GLenum; value: GLint); extdecl;
  3987. glPatchParameterfv: procedure(pname: GLenum; const values: PGLfloat); extdecl;
  3988. function Load_GL_ARB_tessellation_shader(LoadAsCore: boolean = false): Boolean;
  3989. //**** GL_ARB_transform_feedback2 *****//
  3990. const
  3991. GL_TRANSFORM_FEEDBACK = $8E22;
  3992. GL_TRANSFORM_FEEDBACK_BUFFER_PAUSED = $8E23;
  3993. GL_TRANSFORM_FEEDBACK_BUFFER_ACTIVE = $8E24;
  3994. GL_TRANSFORM_FEEDBACK_BINDING = $8E25;
  3995. var
  3996. glBindTransformFeedback: procedure(target: GLenum; id: GLuint); extdecl;
  3997. glDeleteTransformFeedbacks: procedure(n: GLsizei; const ids: PGLuint); extdecl;
  3998. glGenTransformFeedbacks: procedure(n: GLsizei; ids: PGLuint); extdecl;
  3999. glIsTransformFeedback: function(id: GLuint): GLboolean; extdecl;
  4000. glPauseTransformFeedback: procedure(); extdecl;
  4001. glResumeTransformFeedback: procedure(); extdecl;
  4002. glDrawTransformFeedback: procedure(mode: GLenum; id: GLuint); extdecl;
  4003. function Load_GL_ARB_transform_feedback2(LoadAsCore: boolean = false): Boolean;
  4004. //**** GL_ARB_transform_feedback3 *****//
  4005. const
  4006. GL_MAX_TRANSFORM_FEEDBACK_BUFFERS = $8E70;
  4007. var
  4008. glDrawTransformFeedbackStream: procedure(mode: GLenum; id: GLuint; stream: GLuint); extdecl;
  4009. glBeginQueryIndexed: procedure(target: GLenum; index: GLuint; id: GLuint); extdecl;
  4010. glEndQueryIndexed: procedure(target: GLenum; index: GLuint); extdecl;
  4011. glGetQueryIndexediv: procedure(target: GLenum; index: GLuint; pname: GLenum; params: PGLint); extdecl;
  4012. function Load_GL_ARB_transform_feedback3(LoadAsCore: boolean = false): Boolean;
  4013. //***** GL_version_1_4 *****//
  4014. const
  4015. GL_BLEND_DST_RGB = $80C8;
  4016. GL_BLEND_SRC_RGB = $80C9;
  4017. GL_BLEND_DST_ALPHA = $80CA;
  4018. GL_BLEND_SRC_ALPHA = $80CB;
  4019. GL_POINT_SIZE_MIN = $8126;
  4020. GL_POINT_SIZE_MAX = $8127;
  4021. GL_POINT_FADE_THRESHOLD_SIZE = $8128;
  4022. GL_POINT_DISTANCE_ATTENUATION = $8129;
  4023. GL_GENERATE_MIPMAP = $8191;
  4024. GL_GENERATE_MIPMAP_HINT = $8192;
  4025. GL_DEPTH_COMPONENT16 = $81A5;
  4026. GL_DEPTH_COMPONENT24 = $81A6;
  4027. GL_DEPTH_COMPONENT32 = $81A7;
  4028. GL_MIRRORED_REPEAT = $8370;
  4029. GL_FOG_COORDINATE_SOURCE = $8450;
  4030. GL_FOG_COORDINATE = $8451;
  4031. GL_FRAGMENT_DEPTH = $8452;
  4032. GL_CURRENT_FOG_COORDINATE = $8453;
  4033. GL_FOG_COORDINATE_ARRAY_TYPE = $8454;
  4034. GL_FOG_COORDINATE_ARRAY_STRIDE = $8455;
  4035. GL_FOG_COORDINATE_ARRAY_POINTER = $8456;
  4036. GL_FOG_COORDINATE_ARRAY = $8457;
  4037. GL_COLOR_SUM = $8458;
  4038. GL_CURRENT_SECONDARY_COLOR = $8459;
  4039. GL_SECONDARY_COLOR_ARRAY_SIZE = $845A;
  4040. GL_SECONDARY_COLOR_ARRAY_TYPE = $845B;
  4041. GL_SECONDARY_COLOR_ARRAY_STRIDE = $845C;
  4042. GL_SECONDARY_COLOR_ARRAY_POINTER = $845D;
  4043. GL_SECONDARY_COLOR_ARRAY = $845E;
  4044. GL_MAX_TEXTURE_LOD_BIAS = $84FD;
  4045. GL_TEXTURE_FILTER_CONTROL = $8500;
  4046. GL_TEXTURE_LOD_BIAS = $8501;
  4047. GL_INCR_WRAP = $8507;
  4048. GL_DECR_WRAP = $8508;
  4049. GL_TEXTURE_DEPTH_SIZE = $884A;
  4050. GL_DEPTH_TEXTURE_MODE = $884B;
  4051. GL_TEXTURE_COMPARE_MODE = $884C;
  4052. GL_TEXTURE_COMPARE_FUNC = $884D;
  4053. GL_COMPARE_R_TO_TEXTURE = $884E;
  4054. var
  4055. glBlendFuncSeparate: procedure(sfactorRGB: GLenum; dfactorRGB: GLenum; sfactorAlpha: GLenum; dfactorAlpha: GLenum); extdecl;
  4056. glFogCoordf: procedure(coord: GLfloat); extdecl;
  4057. glFogCoordfv: procedure(const coord: PGLfloat); extdecl;
  4058. glFogCoordd: procedure(coord: GLdouble); extdecl;
  4059. glFogCoorddv: procedure(const coord: PGLdouble); extdecl;
  4060. glFogCoordPointer: procedure(_type: GLenum; stride: GLsizei; const pointer: PGLvoid); extdecl;
  4061. glMultiDrawArrays: procedure(mode: GLenum; first: PGLint; count: PGLsizei; primcount: GLsizei); extdecl;
  4062. glMultiDrawElements: procedure(mode: GLenum; const count: PGLsizei; _type: GLenum; const indices: PGLvoid; primcount: GLsizei); extdecl;
  4063. glPointParameterf: procedure(pname: GLenum; param: GLfloat); extdecl;
  4064. glPointParameterfv: procedure(pname: GLenum; const params: PGLfloat); extdecl;
  4065. glPointParameteri: procedure(pname: GLenum; param: GLint); extdecl;
  4066. glPointParameteriv: procedure(pname: GLenum; const params: PGLint); extdecl;
  4067. glSecondaryColor3b: procedure(red: GLbyte; green: GLbyte; blue: GLbyte); extdecl;
  4068. glSecondaryColor3bv: procedure(const v: PGLbyte); extdecl;
  4069. glSecondaryColor3d: procedure(red: GLdouble; green: GLdouble; blue: GLdouble); extdecl;
  4070. glSecondaryColor3dv: procedure(const v: PGLdouble); extdecl;
  4071. glSecondaryColor3f: procedure(red: GLfloat; green: GLfloat; blue: GLfloat); extdecl;
  4072. glSecondaryColor3fv: procedure(const v: PGLfloat); extdecl;
  4073. glSecondaryColor3i: procedure(red: GLint; green: GLint; blue: GLint); extdecl;
  4074. glSecondaryColor3iv: procedure(const v: PGLint); extdecl;
  4075. glSecondaryColor3s: procedure(red: GLshort; green: GLshort; blue: GLshort); extdecl;
  4076. glSecondaryColor3sv: procedure(const v: PGLshort); extdecl;
  4077. glSecondaryColor3ub: procedure(red: GLubyte; green: GLubyte; blue: GLubyte); extdecl;
  4078. glSecondaryColor3ubv: procedure(const v: PGLubyte); extdecl;
  4079. glSecondaryColor3ui: procedure(red: GLuint; green: GLuint; blue: GLuint); extdecl;
  4080. glSecondaryColor3uiv: procedure(const v: PGLuint); extdecl;
  4081. glSecondaryColor3us: procedure(red: GLushort; green: GLushort; blue: GLushort); extdecl;
  4082. glSecondaryColor3usv: procedure(const v: PGLushort); extdecl;
  4083. glSecondaryColorPointer: procedure(size: GLint; _type: GLenum; stride: GLsizei; const pointer: PGLvoid); extdecl;
  4084. glWindowPos2d: procedure(x: GLdouble; y: GLdouble); extdecl;
  4085. glWindowPos2dv: procedure(const v: PGLdouble); extdecl;
  4086. glWindowPos2f: procedure(x: GLfloat; y: GLfloat); extdecl;
  4087. glWindowPos2fv: procedure(const v: PGLfloat); extdecl;
  4088. glWindowPos2i: procedure(x: GLint; y: GLint); extdecl;
  4089. glWindowPos2iv: procedure(const v: PGLint); extdecl;
  4090. glWindowPos2s: procedure(x: GLshort; y: GLshort); extdecl;
  4091. glWindowPos2sv: procedure(const v: PGLshort); extdecl;
  4092. glWindowPos3d: procedure(x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  4093. glWindowPos3dv: procedure(const v: PGLdouble); extdecl;
  4094. glWindowPos3f: procedure(x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  4095. glWindowPos3fv: procedure(const v: PGLfloat); extdecl;
  4096. glWindowPos3i: procedure(x: GLint; y: GLint; z: GLint); extdecl;
  4097. glWindowPos3iv: procedure(const v: PGLint); extdecl;
  4098. glWindowPos3s: procedure(x: GLshort; y: GLshort; z: GLshort); extdecl;
  4099. glWindowPos3sv: procedure(const v: PGLshort); extdecl;
  4100. function Load_GL_version_1_4: Boolean;
  4101. //***** GL_version_1_5 *****//
  4102. const
  4103. GL_BUFFER_SIZE = $8764;
  4104. GL_BUFFER_USAGE = $8765;
  4105. GL_QUERY_COUNTER_BITS = $8864;
  4106. GL_CURRENT_QUERY = $8865;
  4107. GL_QUERY_RESULT = $8866;
  4108. GL_QUERY_RESULT_AVAILABLE = $8867;
  4109. GL_ARRAY_BUFFER = $8892;
  4110. GL_ELEMENT_ARRAY_BUFFER = $8893;
  4111. GL_ARRAY_BUFFER_BINDING = $8894;
  4112. GL_ELEMENT_ARRAY_BUFFER_BINDING = $8895;
  4113. GL_VERTEX_ARRAY_BUFFER_BINDING = $8896;
  4114. GL_NORMAL_ARRAY_BUFFER_BINDING = $8897;
  4115. GL_COLOR_ARRAY_BUFFER_BINDING = $8898;
  4116. GL_INDEX_ARRAY_BUFFER_BINDING = $8899;
  4117. GL_TEXTURE_COORD_ARRAY_BUFFER_BINDING = $889A;
  4118. GL_EDGE_FLAG_ARRAY_BUFFER_BINDING = $889B;
  4119. GL_SECONDARY_COLOR_ARRAY_BUFFER_BINDING = $889C;
  4120. GL_FOG_COORDINATE_ARRAY_BUFFER_BINDING = $889D;
  4121. GL_WEIGHT_ARRAY_BUFFER_BINDING = $889E;
  4122. GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING = $889F;
  4123. GL_READ_ONLY = $88B8;
  4124. GL_WRITE_ONLY = $88B9;
  4125. GL_READ_WRITE = $88BA;
  4126. GL_BUFFER_ACCESS = $88BB;
  4127. GL_BUFFER_MAPPED = $88BC;
  4128. GL_BUFFER_MAP_POINTER = $88BD;
  4129. GL_STREAM_DRAW = $88E0;
  4130. GL_STREAM_READ = $88E1;
  4131. GL_STREAM_COPY = $88E2;
  4132. GL_STATIC_DRAW = $88E4;
  4133. GL_STATIC_READ = $88E5;
  4134. GL_STATIC_COPY = $88E6;
  4135. GL_DYNAMIC_DRAW = $88E8;
  4136. GL_DYNAMIC_READ = $88E9;
  4137. GL_DYNAMIC_COPY = $88EA;
  4138. GL_SAMPLES_PASSED = $8914;
  4139. GL_FOG_COORD_SRC = $8450;
  4140. GL_FOG_COORD = $8451;
  4141. GL_CURRENT_FOG_COORD = $8453;
  4142. GL_FOG_COORD_ARRAY_TYPE = $8454;
  4143. GL_FOG_COORD_ARRAY_STRIDE = $8455;
  4144. GL_FOG_COORD_ARRAY_POINTER = $8456;
  4145. GL_FOG_COORD_ARRAY = $8457;
  4146. GL_FOG_COORD_ARRAY_BUFFER_BINDING = $889D;
  4147. GL_SRC0_RGB = $8580;
  4148. GL_SRC1_RGB = $8581;
  4149. GL_SRC2_RGB = $8582;
  4150. GL_SRC0_ALPHA = $8588;
  4151. GL_SRC1_ALPHA = $8589;
  4152. GL_SRC2_ALPHA = $858A;
  4153. var
  4154. glGenQueries: procedure(n: GLsizei; ids: PGLuint); extdecl;
  4155. glDeleteQueries: procedure(n: GLsizei; const ids: PGLuint); extdecl;
  4156. glIsQuery: function(id: GLuint): GLboolean; extdecl;
  4157. glBeginQuery: procedure(target: GLenum; id: GLuint); extdecl;
  4158. glEndQuery: procedure(target: GLenum); extdecl;
  4159. glGetQueryiv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  4160. glGetQueryObjectiv: procedure(id: GLuint; pname: GLenum; params: PGLint); extdecl;
  4161. glGetQueryObjectuiv: procedure(id: GLuint; pname: GLenum; params: PGLuint); extdecl;
  4162. glBindBuffer: procedure(target: GLenum; buffer: GLuint); extdecl;
  4163. glDeleteBuffers: procedure(n: GLsizei; const buffers: PGLuint); extdecl;
  4164. glGenBuffers: procedure(n: GLsizei; buffers: PGLuint); extdecl;
  4165. glIsBuffer: function(buffer: GLuint): GLboolean; extdecl;
  4166. glBufferData: procedure(target: GLenum; size: GLsizeiptr; const data: PGLvoid; usage: GLenum); extdecl;
  4167. glBufferSubData: procedure(target: GLenum; offset: GLintptr; size: GLsizeiptr; const data: PGLvoid); extdecl;
  4168. glGetBufferSubData: procedure(target: GLenum; offset: GLintptr; size: GLsizeiptr; data: PGLvoid); extdecl;
  4169. glMapBuffer: function(target: GLenum; access: GLenum): PGLvoid; extdecl;
  4170. glUnmapBuffer: function(target: GLenum): GLboolean; extdecl;
  4171. glGetBufferParameteriv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  4172. glGetBufferPointerv: procedure(target: GLenum; pname: GLenum; params: PGLvoid); extdecl;
  4173. function Load_GL_version_1_5: Boolean;
  4174. //***** GL_version_2_0 *****//
  4175. const
  4176. GL_BLEND_EQUATION_RGB = $8009;
  4177. GL_VERTEX_ATTRIB_ARRAY_ENABLED = $8622;
  4178. GL_VERTEX_ATTRIB_ARRAY_SIZE = $8623;
  4179. GL_VERTEX_ATTRIB_ARRAY_STRIDE = $8624;
  4180. GL_VERTEX_ATTRIB_ARRAY_TYPE = $8625;
  4181. GL_CURRENT_VERTEX_ATTRIB = $8626;
  4182. GL_VERTEX_PROGRAM_POINT_SIZE = $8642;
  4183. GL_VERTEX_PROGRAM_TWO_SIDE = $8643;
  4184. GL_VERTEX_ATTRIB_ARRAY_POINTER = $8645;
  4185. GL_STENCIL_BACK_FUNC = $8800;
  4186. GL_STENCIL_BACK_FAIL = $8801;
  4187. GL_STENCIL_BACK_PASS_DEPTH_FAIL = $8802;
  4188. GL_STENCIL_BACK_PASS_DEPTH_PASS = $8803;
  4189. GL_MAX_DRAW_BUFFERS = $8824;
  4190. GL_DRAW_BUFFER0 = $8825;
  4191. GL_DRAW_BUFFER1 = $8826;
  4192. GL_DRAW_BUFFER2 = $8827;
  4193. GL_DRAW_BUFFER3 = $8828;
  4194. GL_DRAW_BUFFER4 = $8829;
  4195. GL_DRAW_BUFFER5 = $882A;
  4196. GL_DRAW_BUFFER6 = $882B;
  4197. GL_DRAW_BUFFER7 = $882C;
  4198. GL_DRAW_BUFFER8 = $882D;
  4199. GL_DRAW_BUFFER9 = $882E;
  4200. GL_DRAW_BUFFER10 = $882F;
  4201. GL_DRAW_BUFFER11 = $8830;
  4202. GL_DRAW_BUFFER12 = $8831;
  4203. GL_DRAW_BUFFER13 = $8832;
  4204. GL_DRAW_BUFFER14 = $8833;
  4205. GL_DRAW_BUFFER15 = $8834;
  4206. GL_BLEND_EQUATION_ALPHA = $883D;
  4207. GL_POINT_SPRITE = $8861;
  4208. GL_COORD_REPLACE = $8862;
  4209. GL_MAX_VERTEX_ATTRIBS = $8869;
  4210. GL_VERTEX_ATTRIB_ARRAY_NORMALIZED = $886A;
  4211. GL_MAX_TEXTURE_COORDS = $8871;
  4212. GL_MAX_TEXTURE_IMAGE_UNITS = $8872;
  4213. GL_FRAGMENT_SHADER = $8B30;
  4214. GL_VERTEX_SHADER = $8B31;
  4215. GL_MAX_FRAGMENT_UNIFORM_COMPONENTS = $8B49;
  4216. GL_MAX_VERTEX_UNIFORM_COMPONENTS = $8B4A;
  4217. GL_MAX_VARYING_FLOATS = $8B4B;
  4218. GL_MAX_VERTEX_TEXTURE_IMAGE_UNITS = $8B4C;
  4219. GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS = $8B4D;
  4220. GL_SHADER_TYPE = $8B4F;
  4221. GL_FLOAT_VEC2 = $8B50;
  4222. GL_FLOAT_VEC3 = $8B51;
  4223. GL_FLOAT_VEC4 = $8B52;
  4224. GL_INT_VEC2 = $8B53;
  4225. GL_INT_VEC3 = $8B54;
  4226. GL_INT_VEC4 = $8B55;
  4227. GL_BOOL = $8B56;
  4228. GL_BOOL_VEC2 = $8B57;
  4229. GL_BOOL_VEC3 = $8B58;
  4230. GL_BOOL_VEC4 = $8B59;
  4231. GL_FLOAT_MAT2 = $8B5A;
  4232. GL_FLOAT_MAT3 = $8B5B;
  4233. GL_FLOAT_MAT4 = $8B5C;
  4234. GL_SAMPLER_1D = $8B5D;
  4235. GL_SAMPLER_2D = $8B5E;
  4236. GL_SAMPLER_3D = $8B5F;
  4237. GL_SAMPLER_CUBE = $8B60;
  4238. GL_SAMPLER_1D_SHADOW = $8B61;
  4239. GL_SAMPLER_2D_SHADOW = $8B62;
  4240. GL_DELETE_STATUS = $8B80;
  4241. GL_COMPILE_STATUS = $8B81;
  4242. GL_LINK_STATUS = $8B82;
  4243. GL_VALIDATE_STATUS = $8B83;
  4244. GL_INFO_LOG_LENGTH = $8B84;
  4245. GL_ATTACHED_SHADERS = $8B85;
  4246. GL_ACTIVE_UNIFORMS = $8B86;
  4247. GL_ACTIVE_UNIFORM_MAX_LENGTH = $8B87;
  4248. GL_SHADER_SOURCE_LENGTH = $8B88;
  4249. GL_ACTIVE_ATTRIBUTES = $8B89;
  4250. GL_ACTIVE_ATTRIBUTE_MAX_LENGTH = $8B8A;
  4251. GL_FRAGMENT_SHADER_DERIVATIVE_HINT = $8B8B;
  4252. GL_SHADING_LANGUAGE_VERSION = $8B8C;
  4253. GL_CURRENT_PROGRAM = $8B8D;
  4254. GL_POINT_SPRITE_COORD_ORIGIN = $8CA0;
  4255. GL_LOWER_LEFT = $8CA1;
  4256. GL_UPPER_LEFT = $8CA2;
  4257. GL_STENCIL_BACK_REF = $8CA3;
  4258. GL_STENCIL_BACK_VALUE_MASK = $8CA4;
  4259. GL_STENCIL_BACK_WRITEMASK = $8CA5;
  4260. var
  4261. glBlendEquationSeparate: procedure(modeRGB: GLenum; modeAlpha: GLenum); extdecl;
  4262. glDrawBuffers: procedure(n: GLsizei; const bufs: PGLenum); extdecl;
  4263. glStencilOpSeparate: procedure(face: GLenum; sfail: GLenum; dpfail: GLenum; dppass: GLenum); extdecl;
  4264. glStencilFuncSeparate: procedure(frontfunc: GLenum; backfunc: GLenum; ref: GLint; mask: GLuint); extdecl;
  4265. glStencilMaskSeparate: procedure(face: GLenum; mask: GLuint); extdecl;
  4266. glAttachShader: procedure(_program: GLuint; shader: GLuint); extdecl;
  4267. glBindAttribLocation: procedure(_program: GLuint; index: GLuint; const name: PGLchar); extdecl;
  4268. glCompileShader: procedure(shader: GLuint); extdecl;
  4269. glCreateProgram: function(): GLuint; extdecl;
  4270. glCreateShader: function(_type: GLenum): GLuint; extdecl;
  4271. glDeleteProgram: procedure(_program: GLuint); extdecl;
  4272. glDeleteShader: procedure(shader: GLuint); extdecl;
  4273. glDetachShader: procedure(_program: GLuint; shader: GLuint); extdecl;
  4274. glDisableVertexAttribArray: procedure(index: GLuint); extdecl;
  4275. glEnableVertexAttribArray: procedure(index: GLuint); extdecl;
  4276. glGetActiveAttrib: procedure(_program: GLuint; index: GLuint; bufSize: GLsizei; length: PGLsizei; size: PGLint; _type: PGLenum; name: PGLchar); extdecl;
  4277. glGetActiveUniform: procedure(_program: GLuint; index: GLuint; bufSize: GLsizei; length: PGLsizei; size: PGLint; _type: PGLenum; name: PGLchar); extdecl;
  4278. glGetAttachedShaders: procedure(_program: GLuint; maxCount: GLsizei; count: PGLsizei; obj: PGLuint); extdecl;
  4279. glGetAttribLocation: function(_program: GLuint; const name: PGLchar): GLint; extdecl;
  4280. glGetProgramiv: procedure(_program: GLuint; pname: GLenum; params: PGLint); extdecl;
  4281. glGetProgramInfoLog: procedure(_program: GLuint; bufSize: GLsizei; length: PGLsizei; infoLog: PGLchar); extdecl;
  4282. glGetShaderiv: procedure(shader: GLuint; pname: GLenum; params: PGLint); extdecl;
  4283. glGetShaderInfoLog: procedure(shader: GLuint; bufSize: GLsizei; length: PGLsizei; infoLog: PGLchar); extdecl;
  4284. glGetShaderSource: procedure(shader: GLuint; bufSize: GLsizei; length: PGLsizei; source: PGLchar); extdecl;
  4285. glGetUniformLocation: function(_program: GLuint; const name: PGLchar): GLint; extdecl;
  4286. glGetUniformfv: procedure(_program: GLuint; location: GLint; params: PGLfloat); extdecl;
  4287. glGetUniformiv: procedure(_program: GLuint; location: GLint; params: PGLint); extdecl;
  4288. glGetVertexAttribdv: procedure(index: GLuint; pname: GLenum; params: PGLdouble); extdecl;
  4289. glGetVertexAttribfv: procedure(index: GLuint; pname: GLenum; params: PGLfloat); extdecl;
  4290. glGetVertexAttribiv: procedure(index: GLuint; pname: GLenum; params: PGLint); extdecl;
  4291. glGetVertexAttribPointerv: procedure(index: GLuint; pname: GLenum; pointer: PGLvoid); extdecl;
  4292. glIsProgram: function(_program: GLuint): GLboolean; extdecl;
  4293. glIsShader: function(shader: GLuint): GLboolean; extdecl;
  4294. glLinkProgram: procedure(_program: GLuint); extdecl;
  4295. glShaderSource: procedure(shader: GLuint; count: GLsizei; const _string: PGLchar; const length: PGLint); extdecl;
  4296. glUseProgram: procedure(_program: GLuint); extdecl;
  4297. glUniform1f: procedure(location: GLint; v0: GLfloat); extdecl;
  4298. glUniform2f: procedure(location: GLint; v0: GLfloat; v1: GLfloat); extdecl;
  4299. glUniform3f: procedure(location: GLint; v0: GLfloat; v1: GLfloat; v2: GLfloat); extdecl;
  4300. glUniform4f: procedure(location: GLint; v0: GLfloat; v1: GLfloat; v2: GLfloat; v3: GLfloat); extdecl;
  4301. glUniform1i: procedure(location: GLint; v0: GLint); extdecl;
  4302. glUniform2i: procedure(location: GLint; v0: GLint; v1: GLint); extdecl;
  4303. glUniform3i: procedure(location: GLint; v0: GLint; v1: GLint; v2: GLint); extdecl;
  4304. glUniform4i: procedure(location: GLint; v0: GLint; v1: GLint; v2: GLint; v3: GLint); extdecl;
  4305. glUniform1fv: procedure(location: GLint; count: GLsizei; const value: PGLfloat); extdecl;
  4306. glUniform2fv: procedure(location: GLint; count: GLsizei; const value: PGLfloat); extdecl;
  4307. glUniform3fv: procedure(location: GLint; count: GLsizei; const value: PGLfloat); extdecl;
  4308. glUniform4fv: procedure(location: GLint; count: GLsizei; const value: PGLfloat); extdecl;
  4309. glUniform1iv: procedure(location: GLint; count: GLsizei; const value: PGLint); extdecl;
  4310. glUniform2iv: procedure(location: GLint; count: GLsizei; const value: PGLint); extdecl;
  4311. glUniform3iv: procedure(location: GLint; count: GLsizei; const value: PGLint); extdecl;
  4312. glUniform4iv: procedure(location: GLint; count: GLsizei; const value: PGLint); extdecl;
  4313. glUniformMatrix2fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4314. glUniformMatrix3fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4315. glUniformMatrix4fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4316. glValidateProgram: procedure(_program: GLuint); extdecl;
  4317. glVertexAttrib1d: procedure(index: GLuint; x: GLdouble); extdecl;
  4318. glVertexAttrib1dv: procedure(index: GLuint; const v: PGLdouble); extdecl;
  4319. glVertexAttrib1f: procedure(index: GLuint; x: GLfloat); extdecl;
  4320. glVertexAttrib1fv: procedure(index: GLuint; const v: PGLfloat); extdecl;
  4321. glVertexAttrib1s: procedure(index: GLuint; x: GLshort); extdecl;
  4322. glVertexAttrib1sv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4323. glVertexAttrib2d: procedure(index: GLuint; x: GLdouble; y: GLdouble); extdecl;
  4324. glVertexAttrib2dv: procedure(index: GLuint; const v: PGLdouble); extdecl;
  4325. glVertexAttrib2f: procedure(index: GLuint; x: GLfloat; y: GLfloat); extdecl;
  4326. glVertexAttrib2fv: procedure(index: GLuint; const v: PGLfloat); extdecl;
  4327. glVertexAttrib2s: procedure(index: GLuint; x: GLshort; y: GLshort); extdecl;
  4328. glVertexAttrib2sv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4329. glVertexAttrib3d: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble); extdecl;
  4330. glVertexAttrib3dv: procedure(index: GLuint; const v: PGLdouble); extdecl;
  4331. glVertexAttrib3f: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat); extdecl;
  4332. glVertexAttrib3fv: procedure(index: GLuint; const v: PGLfloat); extdecl;
  4333. glVertexAttrib3s: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort); extdecl;
  4334. glVertexAttrib3sv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4335. glVertexAttrib4Nbv: procedure(index: GLuint; const v: PGLbyte); extdecl;
  4336. glVertexAttrib4Niv: procedure(index: GLuint; const v: PGLint); extdecl;
  4337. glVertexAttrib4Nsv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4338. glVertexAttrib4Nub: procedure(index: GLuint; x: GLubyte; y: GLubyte; z: GLubyte; w: GLubyte); extdecl;
  4339. glVertexAttrib4Nubv: procedure(index: GLuint; const v: PGLubyte); extdecl;
  4340. glVertexAttrib4Nuiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4341. glVertexAttrib4Nusv: procedure(index: GLuint; const v: PGLushort); extdecl;
  4342. glVertexAttrib4bv: procedure(index: GLuint; const v: PGLbyte); extdecl;
  4343. glVertexAttrib4d: procedure(index: GLuint; x: GLdouble; y: GLdouble; z: GLdouble; w: GLdouble); extdecl;
  4344. glVertexAttrib4dv: procedure(index: GLuint; const v: PGLdouble); extdecl;
  4345. glVertexAttrib4f: procedure(index: GLuint; x: GLfloat; y: GLfloat; z: GLfloat; w: GLfloat); extdecl;
  4346. glVertexAttrib4fv: procedure(index: GLuint; const v: PGLfloat); extdecl;
  4347. glVertexAttrib4iv: procedure(index: GLuint; const v: PGLint); extdecl;
  4348. glVertexAttrib4s: procedure(index: GLuint; x: GLshort; y: GLshort; z: GLshort; w: GLshort); extdecl;
  4349. glVertexAttrib4sv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4350. glVertexAttrib4ubv: procedure(index: GLuint; const v: PGLubyte); extdecl;
  4351. glVertexAttrib4uiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4352. glVertexAttrib4usv: procedure(index: GLuint; const v: PGLushort); extdecl;
  4353. glVertexAttribPointer: procedure(index: GLuint; size: GLint; _type: GLenum; normalized: GLboolean; stride: GLsizei; const pointer: PGLvoid); extdecl;
  4354. function Load_GL_version_2_0: Boolean;
  4355. //**** GL_VERSION_2_1 *****//
  4356. const
  4357. GL_PIXEL_PACK_BUFFER = $88EB;
  4358. GL_PIXEL_UNPACK_BUFFER = $88EC;
  4359. GL_PIXEL_PACK_BUFFER_BINDING = $88ED;
  4360. GL_PIXEL_UNPACK_BUFFER_BINDING = $88EF;
  4361. GL_FLOAT_MAT2x3 = $8B65;
  4362. GL_FLOAT_MAT2x4 = $8B66;
  4363. GL_FLOAT_MAT3x2 = $8B67;
  4364. GL_FLOAT_MAT3x4 = $8B68;
  4365. GL_FLOAT_MAT4x2 = $8B69;
  4366. GL_FLOAT_MAT4x3 = $8B6A;
  4367. GL_SRGB = $8C40;
  4368. GL_SRGB8 = $8C41;
  4369. GL_SRGB_ALPHA = $8C42;
  4370. GL_SRGB8_ALPHA8 = $8C43;
  4371. GL_COMPRESSED_SRGB = $8C48;
  4372. GL_COMPRESSED_SRGB_ALPHA = $8C49;
  4373. var
  4374. glUniformMatrix2x3fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4375. glUniformMatrix3x2fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4376. glUniformMatrix2x4fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4377. glUniformMatrix4x2fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4378. glUniformMatrix3x4fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4379. glUniformMatrix4x3fv: procedure(location: GLint; count: GLsizei; transpose: GLboolean; const value: PGLfloat); extdecl;
  4380. function Load_GL_VERSION_2_1(): Boolean;
  4381. //**** GL_VERSION_2_1 DEPRECATED *****//
  4382. const
  4383. GL_CURRENT_RASTER_SECONDARY_COLOR = $845F;
  4384. GL_SLUMINANCE_ALPHA = $8C44;
  4385. GL_SLUMINANCE8_ALPHA8 = $8C45;
  4386. GL_SLUMINANCE = $8C46;
  4387. GL_SLUMINANCE8 = $8C47;
  4388. GL_COMPRESSED_SLUMINANCE = $8C4A;
  4389. GL_COMPRESSED_SLUMINANCE_ALPHA = $8C4B;
  4390. //**** GL_VERSION_3_0 *****//
  4391. const
  4392. GL_COMPARE_REF_TO_TEXTURE = $884E;
  4393. GL_CLIP_DISTANCE0 = $3000;
  4394. GL_CLIP_DISTANCE1 = $3001;
  4395. GL_CLIP_DISTANCE2 = $3002;
  4396. GL_CLIP_DISTANCE3 = $3003;
  4397. GL_CLIP_DISTANCE4 = $3004;
  4398. GL_CLIP_DISTANCE5 = $3005;
  4399. GL_CLIP_DISTANCE6 = $3006;
  4400. GL_CLIP_DISTANCE7 = $3007;
  4401. GL_MAX_CLIP_DISTANCES = $0D32;
  4402. GL_MAJOR_VERSION = $821B;
  4403. GL_MINOR_VERSION = $821C;
  4404. GL_NUM_EXTENSIONS = $821D;
  4405. GL_CONTEXT_FLAGS = $821E;
  4406. GL_DEPTH_BUFFER = $8223;
  4407. GL_STENCIL_BUFFER = $8224;
  4408. GL_COMPRESSED_RED = $8225;
  4409. GL_COMPRESSED_RG = $8226;
  4410. GL_CONTEXT_FLAG_FORWARD_COMPATIBLE_BIT = $0001;
  4411. GL_RGBA32F = $8814;
  4412. GL_RGB32F = $8815;
  4413. GL_RGBA16F = $881A;
  4414. GL_RGB16F = $881B;
  4415. GL_VERTEX_ATTRIB_ARRAY_INTEGER = $88FD;
  4416. GL_MAX_ARRAY_TEXTURE_LAYERS = $88FF;
  4417. GL_MIN_PROGRAM_TEXEL_OFFSET = $8904;
  4418. GL_MAX_PROGRAM_TEXEL_OFFSET = $8905;
  4419. GL_CLAMP_READ_COLOR = $891C;
  4420. GL_FIXED_ONLY = $891D;
  4421. GL_MAX_VARYING_COMPONENTS = $8B4B;
  4422. GL_TEXTURE_1D_ARRAY = $8C18;
  4423. GL_PROXY_TEXTURE_1D_ARRAY = $8C19;
  4424. GL_TEXTURE_2D_ARRAY = $8C1A;
  4425. GL_PROXY_TEXTURE_2D_ARRAY = $8C1B;
  4426. GL_TEXTURE_BINDING_1D_ARRAY = $8C1C;
  4427. GL_TEXTURE_BINDING_2D_ARRAY = $8C1D;
  4428. GL_R11F_G11F_B10F = $8C3A;
  4429. GL_UNSIGNED_INT_10F_11F_11F_REV = $8C3B;
  4430. GL_RGB9_E5 = $8C3D;
  4431. GL_UNSIGNED_INT_5_9_9_9_REV = $8C3E;
  4432. GL_TEXTURE_SHARED_SIZE = $8C3F;
  4433. GL_TRANSFORM_FEEDBACK_VARYING_MAX_LENGTH = $8C76;
  4434. GL_TRANSFORM_FEEDBACK_BUFFER_MODE = $8C7F;
  4435. GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_COMPONENTS = $8C80;
  4436. GL_TRANSFORM_FEEDBACK_VARYINGS = $8C83;
  4437. GL_TRANSFORM_FEEDBACK_BUFFER_START = $8C84;
  4438. GL_TRANSFORM_FEEDBACK_BUFFER_SIZE = $8C85;
  4439. GL_PRIMITIVES_GENERATED = $8C87;
  4440. GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN = $8C88;
  4441. GL_RASTERIZER_DISCARD = $8C89;
  4442. GL_MAX_TRANSFORM_FEEDBACK_INTERLEAVED_COMPONENTS = $8C8A;
  4443. GL_MAX_TRANSFORM_FEEDBACK_SEPARATE_ATTRIBS = $8C8B;
  4444. GL_INTERLEAVED_ATTRIBS = $8C8C;
  4445. GL_SEPARATE_ATTRIBS = $8C8D;
  4446. GL_TRANSFORM_FEEDBACK_BUFFER = $8C8E;
  4447. GL_TRANSFORM_FEEDBACK_BUFFER_BINDING = $8C8F;
  4448. GL_RGBA32UI = $8D70;
  4449. GL_RGB32UI = $8D71;
  4450. GL_RGBA16UI = $8D76;
  4451. GL_RGB16UI = $8D77;
  4452. GL_RGBA8UI = $8D7C;
  4453. GL_RGB8UI = $8D7D;
  4454. GL_RGBA32I = $8D82;
  4455. GL_RGB32I = $8D83;
  4456. GL_RGBA16I = $8D88;
  4457. GL_RGB16I = $8D89;
  4458. GL_RGBA8I = $8D8E;
  4459. GL_RGB8I = $8D8F;
  4460. GL_RED_INTEGER = $8D94;
  4461. GL_GREEN_INTEGER = $8D95;
  4462. GL_BLUE_INTEGER = $8D96;
  4463. GL_RGB_INTEGER = $8D98;
  4464. GL_RGBA_INTEGER = $8D99;
  4465. GL_BGR_INTEGER = $8D9A;
  4466. GL_BGRA_INTEGER = $8D9B;
  4467. GL_SAMPLER_1D_ARRAY = $8DC0;
  4468. GL_SAMPLER_2D_ARRAY = $8DC1;
  4469. GL_SAMPLER_1D_ARRAY_SHADOW = $8DC3;
  4470. GL_SAMPLER_2D_ARRAY_SHADOW = $8DC4;
  4471. GL_SAMPLER_CUBE_SHADOW = $8DC5;
  4472. GL_UNSIGNED_INT_VEC2 = $8DC6;
  4473. GL_UNSIGNED_INT_VEC3 = $8DC7;
  4474. GL_UNSIGNED_INT_VEC4 = $8DC8;
  4475. GL_INT_SAMPLER_1D = $8DC9;
  4476. GL_INT_SAMPLER_2D = $8DCA;
  4477. GL_INT_SAMPLER_3D = $8DCB;
  4478. GL_INT_SAMPLER_CUBE = $8DCC;
  4479. GL_INT_SAMPLER_1D_ARRAY = $8DCE;
  4480. GL_INT_SAMPLER_2D_ARRAY = $8DCF;
  4481. GL_UNSIGNED_INT_SAMPLER_1D = $8DD1;
  4482. GL_UNSIGNED_INT_SAMPLER_2D = $8DD2;
  4483. GL_UNSIGNED_INT_SAMPLER_3D = $8DD3;
  4484. GL_UNSIGNED_INT_SAMPLER_CUBE = $8DD4;
  4485. GL_UNSIGNED_INT_SAMPLER_1D_ARRAY = $8DD6;
  4486. GL_UNSIGNED_INT_SAMPLER_2D_ARRAY = $8DD7;
  4487. GL_QUERY_WAIT = $8E13;
  4488. GL_QUERY_NO_WAIT = $8E14;
  4489. GL_QUERY_BY_REGION_WAIT = $8E15;
  4490. GL_QUERY_BY_REGION_NO_WAIT = $8E16;
  4491. GL_BUFFER_ACCESS_FLAGS = $911F;
  4492. GL_BUFFER_MAP_LENGTH = $9120;
  4493. GL_BUFFER_MAP_OFFSET = $9121;
  4494. var
  4495. glColorMaski: procedure(index: GLuint; r: GLboolean; g: GLboolean; b: GLboolean; a: GLboolean); extdecl;
  4496. glGetBooleani_v: procedure(target: GLenum; index: GLuint; data: PGLboolean); extdecl;
  4497. glGetIntegeri_v: procedure(target: GLenum; index: GLuint; data: PGLint); extdecl; (* Also used in GL_ARB_uniform_buffer_object *)
  4498. glEnablei: procedure(target: GLenum; index: GLuint); extdecl;
  4499. glDisablei: procedure(target: GLenum; index: GLuint); extdecl;
  4500. glIsEnabledi: function(target: GLenum; index: GLuint): GLboolean; extdecl;
  4501. glBeginTransformFeedback: procedure(primitiveMode: GLenum); extdecl;
  4502. glEndTransformFeedback: procedure(); extdecl;
  4503. glBindBufferRange: procedure(target: GLenum; index: GLuint; buffer: GLuint; offset: GLintptr; size: GLsizeiptr); extdecl; (* Also used in GL_ARB_uniform_buffer_object *)
  4504. glBindBufferBase: procedure(target: GLenum; index: GLuint; buffer: GLuint); extdecl; (* Also used in GL_ARB_uniform_buffer_object *)
  4505. glTransformFeedbackVaryings: procedure(_program: GLuint; count: GLsizei; const varyings: PPGLchar; bufferMode: GLenum); extdecl;
  4506. glGetTransformFeedbackVarying: procedure(_program: GLuint; index: GLuint; bufSize: GLsizei; length: PGLsizei; size: PGLsizei; _type: PGLenum; name: PGLchar); extdecl;
  4507. glClampColor: procedure(target: GLenum; clamp: GLenum); extdecl;
  4508. glBeginConditionalRender: procedure(id: GLuint; mode: GLenum); extdecl;
  4509. glEndConditionalRender: procedure(); extdecl;
  4510. glVertexAttribIPointer: procedure(index: GLuint; size: GLint; _type: GLenum; stride: GLsizei; const _pointer: PGLvoid); extdecl;
  4511. glGetVertexAttribIiv: procedure(index: GLuint; pname: GLenum; params: PGLint); extdecl;
  4512. glGetVertexAttribIuiv: procedure(index: GLuint; pname: GLenum; params: PGLuint); extdecl;
  4513. glVertexAttribI1i: procedure(index: GLuint; x: GLint); extdecl;
  4514. glVertexAttribI2i: procedure(index: GLuint; x: GLint; y: GLint); extdecl;
  4515. glVertexAttribI3i: procedure(index: GLuint; x: GLint; y: GLint; z: GLint); extdecl;
  4516. glVertexAttribI4i: procedure(index: GLuint; x: GLint; y: GLint; z: GLint; w: GLint); extdecl;
  4517. glVertexAttribI1ui: procedure(index: GLuint; x: GLuint); extdecl;
  4518. glVertexAttribI2ui: procedure(index: GLuint; x: GLuint; y: GLuint); extdecl;
  4519. glVertexAttribI3ui: procedure(index: GLuint; x: GLuint; y: GLuint; z: GLuint); extdecl;
  4520. glVertexAttribI4ui: procedure(index: GLuint; x: GLuint; y: GLuint; z: GLuint; w: GLuint); extdecl;
  4521. glVertexAttribI1iv: procedure(index: GLuint; const v: PGLint); extdecl;
  4522. glVertexAttribI2iv: procedure(index: GLuint; const v: PGLint); extdecl;
  4523. glVertexAttribI3iv: procedure(index: GLuint; const v: PGLint); extdecl;
  4524. glVertexAttribI4iv: procedure(index: GLuint; const v: PGLint); extdecl;
  4525. glVertexAttribI1uiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4526. glVertexAttribI2uiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4527. glVertexAttribI3uiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4528. glVertexAttribI4uiv: procedure(index: GLuint; const v: PGLuint); extdecl;
  4529. glVertexAttribI4bv: procedure(index: GLuint; const v: PGLbyte); extdecl;
  4530. glVertexAttribI4sv: procedure(index: GLuint; const v: PGLshort); extdecl;
  4531. glVertexAttribI4ubv: procedure(index: GLuint; const v: PGLubyte); extdecl;
  4532. glVertexAttribI4usv: procedure(index: GLuint; const v: PGLushort); extdecl;
  4533. glGetUniformuiv: procedure(_program: GLuint; location: GLint; params: PGLuint); extdecl;
  4534. glBindFragDataLocation: procedure(_program: GLuint; color: GLuint; const name: PGLchar); extdecl;
  4535. glGetFragDataLocation: function(_program: GLuint; const name: PGLchar): GLint; extdecl;
  4536. glUniform1ui: procedure(location: GLint; v0: GLuint); extdecl;
  4537. glUniform2ui: procedure(location: GLint; v0: GLuint; v1: GLuint); extdecl;
  4538. glUniform3ui: procedure(location: GLint; v0: GLuint; v1: GLuint; v2: GLuint); extdecl;
  4539. glUniform4ui: procedure(location: GLint; v0: GLuint; v1: GLuint; v2: GLuint; v3: GLuint); extdecl;
  4540. glUniform1uiv: procedure(location: GLint; count: GLsizei; const value: PGLuint); extdecl;
  4541. glUniform2uiv: procedure(location: GLint; count: GLsizei; const value: PGLuint); extdecl;
  4542. glUniform3uiv: procedure(location: GLint; count: GLsizei; const value: PGLuint); extdecl;
  4543. glUniform4uiv: procedure(location: GLint; count: GLsizei; const value: PGLuint); extdecl;
  4544. glTexParameterIiv: procedure(target: GLenum; pname: GLenum; const params: PGLint); extdecl;
  4545. glTexParameterIuiv: procedure(target: GLenum; pname: GLenum; const params: PGLuint); extdecl;
  4546. glGetTexParameterIiv: procedure(target: GLenum; pname: GLenum; params: PGLint); extdecl;
  4547. glGetTexParameterIuiv: procedure(target: GLenum; pname: GLenum; params: PGLuint); extdecl;
  4548. glClearBufferiv: procedure(buffer: GLenum; drawbuffer: GLint; const value: PGLint); extdecl;
  4549. glClearBufferuiv: procedure(buffer: GLenum; drawbuffer: GLint; const value: PGLuint); extdecl;
  4550. glClearBufferfv: procedure(buffer: GLenum; drawbuffer: GLint; const value: PGLfloat); extdecl;
  4551. glClearBufferfi: procedure(buffer: GLenum; drawbuffer: GLint; depth: GLfloat; stencil: GLint); extdecl;
  4552. glGetStringi: function(name: GLenum; index: GLuint): PGLubyte; extdecl;
  4553. function Load_GL_VERSION_3_0(): Boolean; //returns false if any legacy components missing
  4554. function Load_GL_VERSION_3_0_CORE(): Boolean; //returns false only if core 3.0 functions are missing
  4555. function Load_GL_version_3_1_CORE(): boolean;
  4556. function Load_GL_version_3_2_CORE(): boolean;
  4557. function Load_GL_version_3_3_CORE(): boolean;
  4558. function Load_GL_version_4_0_CORE(): boolean;
  4559. function Load_GL_version_4_3_CORE(): boolean;
  4560. //**** GL_VERSION_3_0 DEPRECATED *****//
  4561. const
  4562. GL_CLAMP_VERTEX_COLOR = $891A;
  4563. GL_CLAMP_FRAGMENT_COLOR = $891B;
  4564. GL_ALPHA_INTEGER = $8D97;
  4565. //**** GL_VERSION_3_1 *****//
  4566. const
  4567. GL_SAMPLER_2D_RECT = $8B63;
  4568. GL_SAMPLER_2D_RECT_SHADOW = $8B64;
  4569. GL_SAMPLER_BUFFER = $8DC2;
  4570. GL_INT_SAMPLER_2D_RECT = $8DCD;
  4571. GL_INT_SAMPLER_BUFFER = $8DD0;
  4572. GL_UNSIGNED_INT_SAMPLER_2D_RECT = $8DD5;
  4573. GL_UNSIGNED_INT_SAMPLER_BUFFER = $8DD8;
  4574. GL_TEXTURE_BUFFER = $8C2A;
  4575. GL_MAX_TEXTURE_BUFFER_SIZE = $8C2B;
  4576. GL_TEXTURE_BINDING_BUFFER = $8C2C;
  4577. GL_TEXTURE_BUFFER_DATA_STORE_BINDING = $8C2D;
  4578. GL_TEXTURE_BUFFER_FORMAT = $8C2E;
  4579. GL_TEXTURE_RECTANGLE = $84F5;
  4580. GL_TEXTURE_BINDING_RECTANGLE = $84F6;
  4581. GL_PROXY_TEXTURE_RECTANGLE = $84F7;
  4582. GL_MAX_RECTANGLE_TEXTURE_SIZE = $84F8;
  4583. GL_RED_SNORM = $8F90;
  4584. GL_RG_SNORM = $8F91;
  4585. GL_RGB_SNORM = $8F92;
  4586. GL_RGBA_SNORM = $8F93;
  4587. GL_R8_SNORM = $8F94;
  4588. GL_RG8_SNORM = $8F95;
  4589. GL_RGB8_SNORM = $8F96;
  4590. GL_RGBA8_SNORM = $8F97;
  4591. GL_R16_SNORM = $8F98;
  4592. GL_RG16_SNORM = $8F99;
  4593. GL_RGB16_SNORM = $8F9A;
  4594. GL_RGBA16_SNORM = $8F9B;
  4595. GL_SIGNED_NORMALIZED = $8F9C;
  4596. GL_PRIMITIVE_RESTART = $8F9D;
  4597. GL_PRIMITIVE_RESTART_INDEX = $8F9E;
  4598. var
  4599. glDrawArraysInstanced: procedure(mode: GLenum; first: GLint; count: GLsizei; primcount: GLsizei); extdecl;
  4600. glDrawElementsInstanced: procedure(mode: GLenum; count: GLsizei; _type: GLenum; const indices: PGLvoid; primcount: GLsizei); extdecl;
  4601. glTexBuffer: procedure(target: GLenum; internalformat: GLenum; buffer: GLuint); extdecl;
  4602. glPrimitiveRestartIndex: procedure(index: GLuint); extdecl;
  4603. function Load_GL_VERSION_3_1(): Boolean;
  4604. //**** GL_VERSION_3_2 *****//
  4605. const
  4606. GL_CONTEXT_CORE_PROFILE_BIT = $00000001;
  4607. GL_CONTEXT_COMPATIBILITY_PROFILE_BIT = $00000002;
  4608. GL_LINES_ADJACENCY = $000A;
  4609. GL_LINE_STRIP_ADJACENCY = $000B;
  4610. GL_TRIANGLES_ADJACENCY = $000C;
  4611. GL_TRIANGLE_STRIP_ADJACENCY = $000D;
  4612. GL_PROGRAM_POINT_SIZE = $8642;
  4613. GL_MAX_GEOMETRY_TEXTURE_IMAGE_UNITS = $8C29;
  4614. GL_FRAMEBUFFER_ATTACHMENT_LAYERED = $8DA7;
  4615. GL_FRAMEBUFFER_INCOMPLETE_LAYER_TARGETS = $8DA8;
  4616. GL_GEOMETRY_SHADER = $8DD9;
  4617. GL_GEOMETRY_VERTICES_OUT = $8916;
  4618. GL_GEOMETRY_INPUT_TYPE = $8917;
  4619. GL_GEOMETRY_OUTPUT_TYPE = $8918;
  4620. GL_MAX_GEOMETRY_UNIFORM_COMPONENTS = $8DDF;
  4621. GL_MAX_GEOMETRY_OUTPUT_VERTICES = $8DE0;
  4622. GL_MAX_GEOMETRY_TOTAL_OUTPUT_COMPONENTS = $8DE1;
  4623. GL_MAX_VERTEX_OUTPUT_COMPONENTS = $9122;
  4624. GL_MAX_GEOMETRY_INPUT_COMPONENTS = $9123;
  4625. GL_MAX_GEOMETRY_OUTPUT_COMPONENTS = $9124;
  4626. GL_MAX_FRAGMENT_INPUT_COMPONENTS = $9125;
  4627. GL_CONTEXT_PROFILE_MASK = $9126;
  4628. var
  4629. glGetInteger64i_v: procedure(target: GLenum; index: GLuint; data: PGLint64); extdecl;
  4630. glGetBufferParameteri64v: procedure(target: GLenum; pname: GLenum; params: PGLint64); extdecl;
  4631. glProgramParameteri: procedure(_program: GLuint; pname: GLenum; value: GLint); extdecl;
  4632. glFramebufferTexture: procedure(target: GLenum; attachment: GLenum; texture: GLuint; level: GLint); extdecl;
  4633. function Load_GL_VERSION_3_2(): Boolean;
  4634. //**** GL_VERSION_3_3 *****//
  4635. function Load_GL_VERSION_3_3(): Boolean;
  4636. //**** GL_VERSION_4_0 *****//
  4637. function Load_GL_VERSION_4_0(): Boolean;
  4638. //**** GL_VERSION_4_3 *****//
  4639. const
  4640. GL_DEBUG_OUTPUT = $92E0;
  4641. GL_DONT_CARE = $1100;
  4642. GL_CONTEXT_FLAG_DEBUG_BIT = $00000002;
  4643. GL_STACK_OVERFLOW = $0503;
  4644. GL_STACK_UNDERFLOW = $0504;
  4645. GL_DEBUG_OUTPUT_SYNCHRONOUS = $8242;
  4646. GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH = $8243;
  4647. GL_DEBUG_CALLBACK_FUNCTION = $8244;
  4648. GL_DEBUG_CALLBACK_USER_PARAM = $8245;
  4649. GL_DEBUG_SOURCE_API = $8246;
  4650. GL_DEBUG_SOURCE_WINDOW_SYSTEM = $8247;
  4651. GL_DEBUG_SOURCE_SHADER_COMPILER = $8248;
  4652. GL_DEBUG_SOURCE_THIRD_PARTY = $8249;
  4653. GL_DEBUG_SOURCE_APPLICATION = $824A;
  4654. GL_DEBUG_SOURCE_OTHER = $824B;
  4655. GL_DEBUG_TYPE_ERROR = $824C;
  4656. GL_DEBUG_TYPE_DEPRECATED_BEHAVIOR = $824D;
  4657. GL_DEBUG_TYPE_UNDEFINED_BEHAVIOR = $824E;
  4658. GL_DEBUG_TYPE_PORTABILITY = $824F;
  4659. GL_DEBUG_TYPE_PERFORMANCE = $8250;
  4660. GL_DEBUG_TYPE_OTHER = $8251;
  4661. GL_DEBUG_TYPE_MARKER = $8268;
  4662. GL_DEBUG_TYPE_PUSH_GROUP = $8269;
  4663. GL_DEBUG_TYPE_POP_GROUP = $826A;
  4664. GL_DEBUG_SEVERITY_NOTIFICATION = $826B;
  4665. GL_MAX_DEBUG_GROUP_STACK_DEPTH = $826C;
  4666. GL_DEBUG_GROUP_STACK_DEPTH = $826D;
  4667. GL_BUFFER = $82E0;
  4668. GL_SHADER = $82E1;
  4669. GL_PROGRAM = $82E2;
  4670. GL_QUERY = $82E3;
  4671. GL_PROGRAM_PIPELINE = $82E4;
  4672. GL_SAMPLER = $82E6;
  4673. GL_DISPLAY_LIST = $82E7;
  4674. GL_MAX_LABEL_LENGTH = $82E8;
  4675. GL_MAX_DEBUG_MESSAGE_LENGTH = $9143;
  4676. GL_MAX_DEBUG_LOGGED_MESSAGES = $9144;
  4677. GL_DEBUG_LOGGED_MESSAGES = $9145;
  4678. GL_DEBUG_SEVERITY_HIGH = $9146;
  4679. GL_DEBUG_SEVERITY_MEDIUM = $9147;
  4680. GL_DEBUG_SEVERITY_LOW = $9148;
  4681. type
  4682. GLDEBUGPROC = procedure (source:GLenum; _type:GLenum; id:GLuint; severity:GLenum; length:GLsizei; message:PGLchar; userParam:PGLvoid );extdecl;
  4683. var
  4684. glDebugMessageCallback:procedure (callback:GLDEBUGPROC; userParam:PGLvoid);
  4685. glDebugMessageControl :procedure (source:GLenum; _type:GLenum; severity:GLenum; count:GLsizei; ids:PGLuint; enabled:GLboolean);
  4686. function Load_GL_Debug_output(): Boolean;
  4687. function Load_GL_VERSION_4_3(): Boolean;
  4688. implementation
  4689. {$IFNDEF Windows}
  4690. function wglGetProcAddress(proc: PChar): Pointer;
  4691. begin
  4692. Result := GetProcAddress(LibGL, proc);
  4693. end;
  4694. {$ENDIF}
  4695. function glext_ExtensionSupported(const extension: String; const searchIn: String): Boolean;
  4696. var
  4697. extensions: PChar;
  4698. start: PChar;
  4699. where, terminator: PChar;
  4700. begin
  4701. if (Pos(' ', extension) <> 0) or (extension = '') then
  4702. begin
  4703. Result := FALSE;
  4704. Exit;
  4705. end;
  4706. if searchIn = '' then extensions := PChar(glGetString(GL_EXTENSIONS))
  4707. else extensions := PChar(searchIn);
  4708. start := extensions;
  4709. while TRUE do
  4710. begin
  4711. where := StrPos(start, PChar(extension));
  4712. if where = nil then Break;
  4713. terminator := Pointer(PtrUInt(where) + Length(extension));
  4714. if (where = start) or (PChar(PtrUInt(where) - 1)^ = ' ') then
  4715. begin
  4716. if (terminator^ = ' ') or (terminator^ = #0) then
  4717. begin
  4718. Result := TRUE;
  4719. Exit;
  4720. end;
  4721. end;
  4722. start := terminator;
  4723. end;
  4724. Result := FALSE;
  4725. end;
  4726. procedure Load_GL_version_1_2x(var allOK: Boolean);
  4727. begin
  4728. glBlendColor := wglGetProcAddress('glBlendColor');
  4729. if not Assigned(glBlendColor) then allOK := False;
  4730. glBlendEquation := wglGetProcAddress('glBlendEquation');
  4731. if not Assigned(glBlendEquation) then allOK := False;
  4732. glDrawRangeElements := wglGetProcAddress('glDrawRangeElements');
  4733. if not Assigned(glDrawRangeElements) then allOK := False;
  4734. glTexImage3D := wglGetProcAddress('glTexImage3D');
  4735. if not Assigned(glTexImage3D) then allOK := False;
  4736. glTexSubImage3D := wglGetProcAddress('glTexSubImage3D');
  4737. if not Assigned(glTexSubImage3D) then allOK := False;
  4738. glCopyTexSubImage3D := wglGetProcAddress('glCopyTexSubImage3D');
  4739. if not Assigned(glCopyTexSubImage3D) then allOK := False;
  4740. end;
  4741. function Load_GL_version_1_2: boolean;
  4742. begin
  4743. result := true;
  4744. Load_GL_version_1_2x(result);
  4745. end;
  4746. function Load_GL_ARB_imaging: Boolean;
  4747. var
  4748. extstring: String;
  4749. begin
  4750. Result := FALSE;
  4751. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  4752. if glext_ExtensionSupported('GL_ARB_imaging', extstring) then
  4753. begin
  4754. glColorTable := wglGetProcAddress('glColorTable');
  4755. if not Assigned(glColorTable) then Exit;
  4756. glColorTableParameterfv := wglGetProcAddress('glColorTableParameterfv');
  4757. if not Assigned(glColorTableParameterfv) then Exit;
  4758. glColorTableParameteriv := wglGetProcAddress('glColorTableParameteriv');
  4759. if not Assigned(glColorTableParameteriv) then Exit;
  4760. glCopyColorTable := wglGetProcAddress('glCopyColorTable');
  4761. if not Assigned(glCopyColorTable) then Exit;
  4762. glGetColorTable := wglGetProcAddress('glGetColorTable');
  4763. if not Assigned(glGetColorTable) then Exit;
  4764. glGetColorTableParameterfv := wglGetProcAddress('glGetColorTableParameterfv');
  4765. if not Assigned(glGetColorTableParameterfv) then Exit;
  4766. glGetColorTableParameteriv := wglGetProcAddress('glGetColorTableParameteriv');
  4767. if not Assigned(glGetColorTableParameteriv) then Exit;
  4768. glColorSubTable := wglGetProcAddress('glColorSubTable');
  4769. if not Assigned(glColorSubTable) then Exit;
  4770. glCopyColorSubTable := wglGetProcAddress('glCopyColorSubTable');
  4771. if not Assigned(glCopyColorSubTable) then Exit;
  4772. glConvolutionFilter1D := wglGetProcAddress('glConvolutionFilter1D');
  4773. if not Assigned(glConvolutionFilter1D) then Exit;
  4774. glConvolutionFilter2D := wglGetProcAddress('glConvolutionFilter2D');
  4775. if not Assigned(glConvolutionFilter2D) then Exit;
  4776. glConvolutionParameterf := wglGetProcAddress('glConvolutionParameterf');
  4777. if not Assigned(glConvolutionParameterf) then Exit;
  4778. glConvolutionParameterfv := wglGetProcAddress('glConvolutionParameterfv');
  4779. if not Assigned(glConvolutionParameterfv) then Exit;
  4780. glConvolutionParameteri := wglGetProcAddress('glConvolutionParameteri');
  4781. if not Assigned(glConvolutionParameteri) then Exit;
  4782. glConvolutionParameteriv := wglGetProcAddress('glConvolutionParameteriv');
  4783. if not Assigned(glConvolutionParameteriv) then Exit;
  4784. glCopyConvolutionFilter1D := wglGetProcAddress('glCopyConvolutionFilter1D');
  4785. if not Assigned(glCopyConvolutionFilter1D) then Exit;
  4786. glCopyConvolutionFilter2D := wglGetProcAddress('glCopyConvolutionFilter2D');
  4787. if not Assigned(glCopyConvolutionFilter2D) then Exit;
  4788. glGetConvolutionFilter := wglGetProcAddress('glGetConvolutionFilter');
  4789. if not Assigned(glGetConvolutionFilter) then Exit;
  4790. glGetConvolutionParameterfv := wglGetProcAddress('glGetConvolutionParameterfv');
  4791. if not Assigned(glGetConvolutionParameterfv) then Exit;
  4792. glGetConvolutionParameteriv := wglGetProcAddress('glGetConvolutionParameteriv');
  4793. if not Assigned(glGetConvolutionParameteriv) then Exit;
  4794. glGetSeparableFilter := wglGetProcAddress('glGetSeparableFilter');
  4795. if not Assigned(glGetSeparableFilter) then Exit;
  4796. glSeparableFilter2D := wglGetProcAddress('glSeparableFilter2D');
  4797. if not Assigned(glSeparableFilter2D) then Exit;
  4798. glGetHistogram := wglGetProcAddress('glGetHistogram');
  4799. if not Assigned(glGetHistogram) then Exit;
  4800. glGetHistogramParameterfv := wglGetProcAddress('glGetHistogramParameterfv');
  4801. if not Assigned(glGetHistogramParameterfv) then Exit;
  4802. glGetHistogramParameteriv := wglGetProcAddress('glGetHistogramParameteriv');
  4803. if not Assigned(glGetHistogramParameteriv) then Exit;
  4804. glGetMinmax := wglGetProcAddress('glGetMinmax');
  4805. if not Assigned(glGetMinmax) then Exit;
  4806. glGetMinmaxParameterfv := wglGetProcAddress('glGetMinmaxParameterfv');
  4807. if not Assigned(glGetMinmaxParameterfv) then Exit;
  4808. glGetMinmaxParameteriv := wglGetProcAddress('glGetMinmaxParameteriv');
  4809. if not Assigned(glGetMinmaxParameteriv) then Exit;
  4810. glHistogram := wglGetProcAddress('glHistogram');
  4811. if not Assigned(glHistogram) then Exit;
  4812. glMinmax := wglGetProcAddress('glMinmax');
  4813. if not Assigned(glMinmax) then Exit;
  4814. glResetHistogram := wglGetProcAddress('glResetHistogram');
  4815. if not Assigned(glResetHistogram) then Exit;
  4816. glResetMinmax := wglGetProcAddress('glResetMinmax');
  4817. if not Assigned(glResetMinmax) then Exit;
  4818. Result := TRUE;
  4819. end;
  4820. end;
  4821. procedure Load_GL_version_1_3x(var allOK: Boolean);
  4822. var
  4823. extstring: String;
  4824. begin
  4825. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  4826. glActiveTexture := wglGetProcAddress('glActiveTexture');
  4827. if not Assigned(glActiveTexture) then allOK := false;
  4828. glClientActiveTexture := wglGetProcAddress('glClientActiveTexture');
  4829. if not Assigned(glClientActiveTexture) then allOK := false;
  4830. glMultiTexCoord1d := wglGetProcAddress('glMultiTexCoord1d');
  4831. if not Assigned(glMultiTexCoord1d) then allOK := false;
  4832. glMultiTexCoord1dv := wglGetProcAddress('glMultiTexCoord1dv');
  4833. if not Assigned(glMultiTexCoord1dv) then allOK := false;
  4834. glMultiTexCoord1f := wglGetProcAddress('glMultiTexCoord1f');
  4835. if not Assigned(glMultiTexCoord1f) then allOK := false;
  4836. glMultiTexCoord1fv := wglGetProcAddress('glMultiTexCoord1fv');
  4837. if not Assigned(glMultiTexCoord1fv) then allOK := false;
  4838. glMultiTexCoord1i := wglGetProcAddress('glMultiTexCoord1i');
  4839. if not Assigned(glMultiTexCoord1i) then allOK := false;
  4840. glMultiTexCoord1iv := wglGetProcAddress('glMultiTexCoord1iv');
  4841. if not Assigned(glMultiTexCoord1iv) then allOK := false;
  4842. glMultiTexCoord1s := wglGetProcAddress('glMultiTexCoord1s');
  4843. if not Assigned(glMultiTexCoord1s) then allOK := false;
  4844. glMultiTexCoord1sv := wglGetProcAddress('glMultiTexCoord1sv');
  4845. if not Assigned(glMultiTexCoord1sv) then allOK := false;
  4846. glMultiTexCoord2d := wglGetProcAddress('glMultiTexCoord2d');
  4847. if not Assigned(glMultiTexCoord2d) then allOK := false;
  4848. glMultiTexCoord2dv := wglGetProcAddress('glMultiTexCoord2dv');
  4849. if not Assigned(glMultiTexCoord2dv) then allOK := false;
  4850. glMultiTexCoord2f := wglGetProcAddress('glMultiTexCoord2f');
  4851. if not Assigned(glMultiTexCoord2f) then allOK := false;
  4852. glMultiTexCoord2fv := wglGetProcAddress('glMultiTexCoord2fv');
  4853. if not Assigned(glMultiTexCoord2fv) then allOK := false;
  4854. glMultiTexCoord2i := wglGetProcAddress('glMultiTexCoord2i');
  4855. if not Assigned(glMultiTexCoord2i) then allOK := false;
  4856. glMultiTexCoord2iv := wglGetProcAddress('glMultiTexCoord2iv');
  4857. if not Assigned(glMultiTexCoord2iv) then allOK := false;
  4858. glMultiTexCoord2s := wglGetProcAddress('glMultiTexCoord2s');
  4859. if not Assigned(glMultiTexCoord2s) then allOK := false;
  4860. glMultiTexCoord2sv := wglGetProcAddress('glMultiTexCoord2sv');
  4861. if not Assigned(glMultiTexCoord2sv) then allOK := false;
  4862. glMultiTexCoord3d := wglGetProcAddress('glMultiTexCoord3d');
  4863. if not Assigned(glMultiTexCoord3d) then allOK := false;
  4864. glMultiTexCoord3dv := wglGetProcAddress('glMultiTexCoord3dv');
  4865. if not Assigned(glMultiTexCoord3dv) then allOK := false;
  4866. glMultiTexCoord3f := wglGetProcAddress('glMultiTexCoord3f');
  4867. if not Assigned(glMultiTexCoord3f) then allOK := false;
  4868. glMultiTexCoord3fv := wglGetProcAddress('glMultiTexCoord3fv');
  4869. if not Assigned(glMultiTexCoord3fv) then allOK := false;
  4870. glMultiTexCoord3i := wglGetProcAddress('glMultiTexCoord3i');
  4871. if not Assigned(glMultiTexCoord3i) then allOK := false;
  4872. glMultiTexCoord3iv := wglGetProcAddress('glMultiTexCoord3iv');
  4873. if not Assigned(glMultiTexCoord3iv) then allOK := false;
  4874. glMultiTexCoord3s := wglGetProcAddress('glMultiTexCoord3s');
  4875. if not Assigned(glMultiTexCoord3s) then allOK := false;
  4876. glMultiTexCoord3sv := wglGetProcAddress('glMultiTexCoord3sv');
  4877. if not Assigned(glMultiTexCoord3sv) then allOK := false;
  4878. glMultiTexCoord4d := wglGetProcAddress('glMultiTexCoord4d');
  4879. if not Assigned(glMultiTexCoord4d) then allOK := false;
  4880. glMultiTexCoord4dv := wglGetProcAddress('glMultiTexCoord4dv');
  4881. if not Assigned(glMultiTexCoord4dv) then allOK := false;
  4882. glMultiTexCoord4f := wglGetProcAddress('glMultiTexCoord4f');
  4883. if not Assigned(glMultiTexCoord4f) then allOK := false;
  4884. glMultiTexCoord4fv := wglGetProcAddress('glMultiTexCoord4fv');
  4885. if not Assigned(glMultiTexCoord4fv) then allOK := false;
  4886. glMultiTexCoord4i := wglGetProcAddress('glMultiTexCoord4i');
  4887. if not Assigned(glMultiTexCoord4i) then allOK := false;
  4888. glMultiTexCoord4iv := wglGetProcAddress('glMultiTexCoord4iv');
  4889. if not Assigned(glMultiTexCoord4iv) then allOK := false;
  4890. glMultiTexCoord4s := wglGetProcAddress('glMultiTexCoord4s');
  4891. if not Assigned(glMultiTexCoord4s) then allOK := false;
  4892. glMultiTexCoord4sv := wglGetProcAddress('glMultiTexCoord4sv');
  4893. if not Assigned(glMultiTexCoord4sv) then allOK := false;
  4894. glLoadTransposeMatrixf := wglGetProcAddress('glLoadTransposeMatrixf');
  4895. if not Assigned(glLoadTransposeMatrixf) then allOK := false;
  4896. glLoadTransposeMatrixd := wglGetProcAddress('glLoadTransposeMatrixd');
  4897. if not Assigned(glLoadTransposeMatrixd) then allOK := false;
  4898. glMultTransposeMatrixf := wglGetProcAddress('glMultTransposeMatrixf');
  4899. if not Assigned(glMultTransposeMatrixf) then allOK := false;
  4900. glMultTransposeMatrixd := wglGetProcAddress('glMultTransposeMatrixd');
  4901. if not Assigned(glMultTransposeMatrixd) then allOK := false;
  4902. glSampleCoverage := wglGetProcAddress('glSampleCoverage');
  4903. if not Assigned(glSampleCoverage) then allOK := false;
  4904. glCompressedTexImage3D := wglGetProcAddress('glCompressedTexImage3D');
  4905. if not Assigned(glCompressedTexImage3D) then allOK := false;
  4906. glCompressedTexImage2D := wglGetProcAddress('glCompressedTexImage2D');
  4907. if not Assigned(glCompressedTexImage2D) then allOK := false;
  4908. glCompressedTexImage1D := wglGetProcAddress('glCompressedTexImage1D');
  4909. if not Assigned(glCompressedTexImage1D) then allOK := false;
  4910. glCompressedTexSubImage3D := wglGetProcAddress('glCompressedTexSubImage3D');
  4911. if not Assigned(glCompressedTexSubImage3D) then allOK := false;
  4912. glCompressedTexSubImage2D := wglGetProcAddress('glCompressedTexSubImage2D');
  4913. if not Assigned(glCompressedTexSubImage2D) then allOK := false;
  4914. glCompressedTexSubImage1D := wglGetProcAddress('glCompressedTexSubImage1D');
  4915. if not Assigned(glCompressedTexSubImage1D) then allOK := false;
  4916. glGetCompressedTexImage := wglGetProcAddress('glGetCompressedTexImage');
  4917. if not Assigned(glGetCompressedTexImage) then allOK := false;
  4918. end;
  4919. function Load_GL_version_1_3: boolean;
  4920. begin
  4921. result := true;
  4922. Load_GL_version_1_3x(result);
  4923. end;
  4924. function Load_GL_ARB_multitexture: Boolean;
  4925. var
  4926. extstring: String;
  4927. begin
  4928. Result := FALSE;
  4929. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  4930. if glext_ExtensionSupported('GL_ARB_multitexture', extstring) then
  4931. begin
  4932. glActiveTextureARB := wglGetProcAddress('glActiveTextureARB');
  4933. if not Assigned(glActiveTextureARB) then Exit;
  4934. glClientActiveTextureARB := wglGetProcAddress('glClientActiveTextureARB');
  4935. if not Assigned(glClientActiveTextureARB) then Exit;
  4936. glMultiTexCoord1dARB := wglGetProcAddress('glMultiTexCoord1dARB');
  4937. if not Assigned(glMultiTexCoord1dARB) then Exit;
  4938. glMultiTexCoord1dvARB := wglGetProcAddress('glMultiTexCoord1dvARB');
  4939. if not Assigned(glMultiTexCoord1dvARB) then Exit;
  4940. glMultiTexCoord1fARB := wglGetProcAddress('glMultiTexCoord1fARB');
  4941. if not Assigned(glMultiTexCoord1fARB) then Exit;
  4942. glMultiTexCoord1fvARB := wglGetProcAddress('glMultiTexCoord1fvARB');
  4943. if not Assigned(glMultiTexCoord1fvARB) then Exit;
  4944. glMultiTexCoord1iARB := wglGetProcAddress('glMultiTexCoord1iARB');
  4945. if not Assigned(glMultiTexCoord1iARB) then Exit;
  4946. glMultiTexCoord1ivARB := wglGetProcAddress('glMultiTexCoord1ivARB');
  4947. if not Assigned(glMultiTexCoord1ivARB) then Exit;
  4948. glMultiTexCoord1sARB := wglGetProcAddress('glMultiTexCoord1sARB');
  4949. if not Assigned(glMultiTexCoord1sARB) then Exit;
  4950. glMultiTexCoord1svARB := wglGetProcAddress('glMultiTexCoord1svARB');
  4951. if not Assigned(glMultiTexCoord1svARB) then Exit;
  4952. glMultiTexCoord2dARB := wglGetProcAddress('glMultiTexCoord2dARB');
  4953. if not Assigned(glMultiTexCoord2dARB) then Exit;
  4954. glMultiTexCoord2dvARB := wglGetProcAddress('glMultiTexCoord2dvARB');
  4955. if not Assigned(glMultiTexCoord2dvARB) then Exit;
  4956. glMultiTexCoord2fARB := wglGetProcAddress('glMultiTexCoord2fARB');
  4957. if not Assigned(glMultiTexCoord2fARB) then Exit;
  4958. glMultiTexCoord2fvARB := wglGetProcAddress('glMultiTexCoord2fvARB');
  4959. if not Assigned(glMultiTexCoord2fvARB) then Exit;
  4960. glMultiTexCoord2iARB := wglGetProcAddress('glMultiTexCoord2iARB');
  4961. if not Assigned(glMultiTexCoord2iARB) then Exit;
  4962. glMultiTexCoord2ivARB := wglGetProcAddress('glMultiTexCoord2ivARB');
  4963. if not Assigned(glMultiTexCoord2ivARB) then Exit;
  4964. glMultiTexCoord2sARB := wglGetProcAddress('glMultiTexCoord2sARB');
  4965. if not Assigned(glMultiTexCoord2sARB) then Exit;
  4966. glMultiTexCoord2svARB := wglGetProcAddress('glMultiTexCoord2svARB');
  4967. if not Assigned(glMultiTexCoord2svARB) then Exit;
  4968. glMultiTexCoord3dARB := wglGetProcAddress('glMultiTexCoord3dARB');
  4969. if not Assigned(glMultiTexCoord3dARB) then Exit;
  4970. glMultiTexCoord3dvARB := wglGetProcAddress('glMultiTexCoord3dvARB');
  4971. if not Assigned(glMultiTexCoord3dvARB) then Exit;
  4972. glMultiTexCoord3fARB := wglGetProcAddress('glMultiTexCoord3fARB');
  4973. if not Assigned(glMultiTexCoord3fARB) then Exit;
  4974. glMultiTexCoord3fvARB := wglGetProcAddress('glMultiTexCoord3fvARB');
  4975. if not Assigned(glMultiTexCoord3fvARB) then Exit;
  4976. glMultiTexCoord3iARB := wglGetProcAddress('glMultiTexCoord3iARB');
  4977. if not Assigned(glMultiTexCoord3iARB) then Exit;
  4978. glMultiTexCoord3ivARB := wglGetProcAddress('glMultiTexCoord3ivARB');
  4979. if not Assigned(glMultiTexCoord3ivARB) then Exit;
  4980. glMultiTexCoord3sARB := wglGetProcAddress('glMultiTexCoord3sARB');
  4981. if not Assigned(glMultiTexCoord3sARB) then Exit;
  4982. glMultiTexCoord3svARB := wglGetProcAddress('glMultiTexCoord3svARB');
  4983. if not Assigned(glMultiTexCoord3svARB) then Exit;
  4984. glMultiTexCoord4dARB := wglGetProcAddress('glMultiTexCoord4dARB');
  4985. if not Assigned(glMultiTexCoord4dARB) then Exit;
  4986. glMultiTexCoord4dvARB := wglGetProcAddress('glMultiTexCoord4dvARB');
  4987. if not Assigned(glMultiTexCoord4dvARB) then Exit;
  4988. glMultiTexCoord4fARB := wglGetProcAddress('glMultiTexCoord4fARB');
  4989. if not Assigned(glMultiTexCoord4fARB) then Exit;
  4990. glMultiTexCoord4fvARB := wglGetProcAddress('glMultiTexCoord4fvARB');
  4991. if not Assigned(glMultiTexCoord4fvARB) then Exit;
  4992. glMultiTexCoord4iARB := wglGetProcAddress('glMultiTexCoord4iARB');
  4993. if not Assigned(glMultiTexCoord4iARB) then Exit;
  4994. glMultiTexCoord4ivARB := wglGetProcAddress('glMultiTexCoord4ivARB');
  4995. if not Assigned(glMultiTexCoord4ivARB) then Exit;
  4996. glMultiTexCoord4sARB := wglGetProcAddress('glMultiTexCoord4sARB');
  4997. if not Assigned(glMultiTexCoord4sARB) then Exit;
  4998. glMultiTexCoord4svARB := wglGetProcAddress('glMultiTexCoord4svARB');
  4999. if not Assigned(glMultiTexCoord4svARB) then Exit;
  5000. Result := TRUE;
  5001. end;
  5002. end;
  5003. function Load_GL_ARB_transpose_matrix: Boolean;
  5004. var
  5005. extstring: String;
  5006. begin
  5007. Result := FALSE;
  5008. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5009. if glext_ExtensionSupported('GL_ARB_transpose_matrix', extstring) then
  5010. begin
  5011. glLoadTransposeMatrixfARB := wglGetProcAddress('glLoadTransposeMatrixfARB');
  5012. if not Assigned(glLoadTransposeMatrixfARB) then Exit;
  5013. glLoadTransposeMatrixdARB := wglGetProcAddress('glLoadTransposeMatrixdARB');
  5014. if not Assigned(glLoadTransposeMatrixdARB) then Exit;
  5015. glMultTransposeMatrixfARB := wglGetProcAddress('glMultTransposeMatrixfARB');
  5016. if not Assigned(glMultTransposeMatrixfARB) then Exit;
  5017. glMultTransposeMatrixdARB := wglGetProcAddress('glMultTransposeMatrixdARB');
  5018. if not Assigned(glMultTransposeMatrixdARB) then Exit;
  5019. Result := TRUE;
  5020. end;
  5021. end;
  5022. function Load_GL_ARB_multisample: Boolean;
  5023. var
  5024. extstring: String;
  5025. begin
  5026. Result := FALSE;
  5027. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5028. if glext_ExtensionSupported('GL_ARB_multisample', extstring) then
  5029. begin
  5030. glSampleCoverageARB := wglGetProcAddress('glSampleCoverageARB');
  5031. if not Assigned(glSampleCoverageARB) then Exit;
  5032. Result := TRUE;
  5033. end;
  5034. end;
  5035. function Load_GL_ARB_texture_env_add: Boolean;
  5036. var
  5037. extstring: String;
  5038. begin
  5039. Result := FALSE;
  5040. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5041. if glext_ExtensionSupported('GL_ARB_texture_env_add', extstring) then
  5042. begin
  5043. Result := TRUE;
  5044. end;
  5045. end;
  5046. {$IFDEF Windows}
  5047. function Load_WGL_ARB_extensions_string: Boolean;
  5048. var
  5049. extstring: String;
  5050. begin
  5051. Result := FALSE;
  5052. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  5053. if not Assigned(wglGetExtensionsStringARB) then Exit;
  5054. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  5055. if glext_ExtensionSupported('WGL_ARB_extensions_string', extstring) then
  5056. begin
  5057. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  5058. if not Assigned(wglGetExtensionsStringARB) then Exit;
  5059. Result := TRUE;
  5060. end;
  5061. end;
  5062. function Load_WGL_ARB_buffer_region: Boolean;
  5063. var
  5064. extstring: String;
  5065. begin
  5066. Result := FALSE;
  5067. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  5068. if not Assigned(wglGetExtensionsStringARB) then Exit;
  5069. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  5070. if glext_ExtensionSupported('WGL_ARB_buffer_region', extstring) then
  5071. begin
  5072. wglCreateBufferRegionARB := wglGetProcAddress('wglCreateBufferRegionARB');
  5073. if not Assigned(wglCreateBufferRegionARB) then Exit;
  5074. wglDeleteBufferRegionARB := wglGetProcAddress('wglDeleteBufferRegionARB');
  5075. if not Assigned(wglDeleteBufferRegionARB) then Exit;
  5076. wglSaveBufferRegionARB := wglGetProcAddress('wglSaveBufferRegionARB');
  5077. if not Assigned(wglSaveBufferRegionARB) then Exit;
  5078. wglRestoreBufferRegionARB := wglGetProcAddress('wglRestoreBufferRegionARB');
  5079. if not Assigned(wglRestoreBufferRegionARB) then Exit;
  5080. Result := TRUE;
  5081. end;
  5082. end;
  5083. {$ENDIF}
  5084. function Load_GL_ARB_texture_cube_map: Boolean;
  5085. var
  5086. extstring: String;
  5087. begin
  5088. Result := FALSE;
  5089. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5090. if glext_ExtensionSupported('GL_ARB_texture_cube_map', extstring) then
  5091. begin
  5092. Result := TRUE;
  5093. end;
  5094. end;
  5095. function Load_GL_ARB_depth_texture: Boolean;
  5096. var
  5097. extstring: String;
  5098. begin
  5099. Result := FALSE;
  5100. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5101. if glext_ExtensionSupported('GL_ARB_depth_texture', extstring) then
  5102. begin
  5103. Result := TRUE;
  5104. end;
  5105. end;
  5106. function Load_GL_ARB_point_parameters: Boolean;
  5107. var
  5108. extstring: String;
  5109. begin
  5110. Result := FALSE;
  5111. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5112. if glext_ExtensionSupported('GL_ARB_point_parameters', extstring) then
  5113. begin
  5114. glPointParameterfARB := wglGetProcAddress('glPointParameterfARB');
  5115. if not Assigned(glPointParameterfARB) then Exit;
  5116. glPointParameterfvARB := wglGetProcAddress('glPointParameterfvARB');
  5117. if not Assigned(glPointParameterfvARB) then Exit;
  5118. Result := TRUE;
  5119. end;
  5120. end;
  5121. function Load_GL_ARB_shadow: Boolean;
  5122. var
  5123. extstring: String;
  5124. begin
  5125. Result := FALSE;
  5126. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5127. if glext_ExtensionSupported('GL_ARB_shadow', extstring) then
  5128. begin
  5129. Result := TRUE;
  5130. end;
  5131. end;
  5132. function Load_GL_ARB_shadow_ambient: Boolean;
  5133. var
  5134. extstring: String;
  5135. begin
  5136. Result := FALSE;
  5137. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5138. if glext_ExtensionSupported('GL_ARB_shadow_ambient', extstring) then
  5139. begin
  5140. Result := TRUE;
  5141. end;
  5142. end;
  5143. function Load_GL_ARB_texture_border_clamp: Boolean;
  5144. var
  5145. extstring: String;
  5146. begin
  5147. Result := FALSE;
  5148. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5149. if glext_ExtensionSupported('GL_ARB_texture_border_clamp', extstring) then
  5150. begin
  5151. Result := TRUE;
  5152. end;
  5153. end;
  5154. function Load_GL_ARB_texture_compression: Boolean;
  5155. var
  5156. extstring: String;
  5157. begin
  5158. Result := FALSE;
  5159. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5160. if glext_ExtensionSupported('GL_ARB_texture_compression', extstring) then
  5161. begin
  5162. glCompressedTexImage3DARB := wglGetProcAddress('glCompressedTexImage3DARB');
  5163. if not Assigned(glCompressedTexImage3DARB) then Exit;
  5164. glCompressedTexImage2DARB := wglGetProcAddress('glCompressedTexImage2DARB');
  5165. if not Assigned(glCompressedTexImage2DARB) then Exit;
  5166. glCompressedTexImage1DARB := wglGetProcAddress('glCompressedTexImage1DARB');
  5167. if not Assigned(glCompressedTexImage1DARB) then Exit;
  5168. glCompressedTexSubImage3DARB := wglGetProcAddress('glCompressedTexSubImage3DARB');
  5169. if not Assigned(glCompressedTexSubImage3DARB) then Exit;
  5170. glCompressedTexSubImage2DARB := wglGetProcAddress('glCompressedTexSubImage2DARB');
  5171. if not Assigned(glCompressedTexSubImage2DARB) then Exit;
  5172. glCompressedTexSubImage1DARB := wglGetProcAddress('glCompressedTexSubImage1DARB');
  5173. if not Assigned(glCompressedTexSubImage1DARB) then Exit;
  5174. glGetCompressedTexImageARB := wglGetProcAddress('glGetCompressedTexImageARB');
  5175. if not Assigned(glGetCompressedTexImageARB) then Exit;
  5176. Result := TRUE;
  5177. end;
  5178. end;
  5179. function Load_GL_ARB_texture_env_combine: Boolean;
  5180. var
  5181. extstring: String;
  5182. begin
  5183. Result := FALSE;
  5184. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5185. if glext_ExtensionSupported('GL_ARB_texture_env_combine', extstring) then
  5186. begin
  5187. Result := TRUE;
  5188. end;
  5189. end;
  5190. function Load_GL_ARB_texture_env_crossbar: Boolean;
  5191. var
  5192. extstring: String;
  5193. begin
  5194. Result := FALSE;
  5195. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5196. if glext_ExtensionSupported('GL_ARB_texture_env_crossbar', extstring) then
  5197. begin
  5198. Result := TRUE;
  5199. end;
  5200. end;
  5201. function Load_GL_ARB_texture_env_dot3: Boolean;
  5202. var
  5203. extstring: String;
  5204. begin
  5205. Result := FALSE;
  5206. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5207. if glext_ExtensionSupported('GL_ARB_texture_env_dot3', extstring) then
  5208. begin
  5209. Result := TRUE;
  5210. end;
  5211. end;
  5212. function Load_GL_ARB_texture_mirrored_repeat: Boolean;
  5213. var
  5214. extstring: String;
  5215. begin
  5216. Result := FALSE;
  5217. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5218. if glext_ExtensionSupported('GL_ARB_texture_mirrored_repeat', extstring) then
  5219. begin
  5220. Result := TRUE;
  5221. end;
  5222. end;
  5223. function Load_GL_ARB_vertex_blend: Boolean;
  5224. var
  5225. extstring: String;
  5226. begin
  5227. Result := FALSE;
  5228. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5229. if glext_ExtensionSupported('GL_ARB_vertex_blend', extstring) then
  5230. begin
  5231. glWeightbvARB := wglGetProcAddress('glWeightbvARB');
  5232. if not Assigned(glWeightbvARB) then Exit;
  5233. glWeightsvARB := wglGetProcAddress('glWeightsvARB');
  5234. if not Assigned(glWeightsvARB) then Exit;
  5235. glWeightivARB := wglGetProcAddress('glWeightivARB');
  5236. if not Assigned(glWeightivARB) then Exit;
  5237. glWeightfvARB := wglGetProcAddress('glWeightfvARB');
  5238. if not Assigned(glWeightfvARB) then Exit;
  5239. glWeightdvARB := wglGetProcAddress('glWeightdvARB');
  5240. if not Assigned(glWeightdvARB) then Exit;
  5241. glWeightvARB := wglGetProcAddress('glWeightvARB');
  5242. if not Assigned(glWeightvARB) then Exit;
  5243. glWeightubvARB := wglGetProcAddress('glWeightubvARB');
  5244. if not Assigned(glWeightubvARB) then Exit;
  5245. glWeightusvARB := wglGetProcAddress('glWeightusvARB');
  5246. if not Assigned(glWeightusvARB) then Exit;
  5247. glWeightuivARB := wglGetProcAddress('glWeightuivARB');
  5248. if not Assigned(glWeightuivARB) then Exit;
  5249. glWeightPointerARB := wglGetProcAddress('glWeightPointerARB');
  5250. if not Assigned(glWeightPointerARB) then Exit;
  5251. glVertexBlendARB := wglGetProcAddress('glVertexBlendARB');
  5252. if not Assigned(glVertexBlendARB) then Exit;
  5253. Result := TRUE;
  5254. end;
  5255. end;
  5256. function Load_GL_ARB_vertex_program: Boolean;
  5257. var
  5258. extstring: String;
  5259. begin
  5260. Result := FALSE;
  5261. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5262. if glext_ExtensionSupported('GL_ARB_vertex_program', extstring) then
  5263. begin
  5264. glVertexAttrib1sARB := wglGetProcAddress('glVertexAttrib1sARB');
  5265. if not Assigned(glVertexAttrib1sARB) then Exit;
  5266. glVertexAttrib1fARB := wglGetProcAddress('glVertexAttrib1fARB');
  5267. if not Assigned(glVertexAttrib1fARB) then Exit;
  5268. glVertexAttrib1dARB := wglGetProcAddress('glVertexAttrib1dARB');
  5269. if not Assigned(glVertexAttrib1dARB) then Exit;
  5270. glVertexAttrib2sARB := wglGetProcAddress('glVertexAttrib2sARB');
  5271. if not Assigned(glVertexAttrib2sARB) then Exit;
  5272. glVertexAttrib2fARB := wglGetProcAddress('glVertexAttrib2fARB');
  5273. if not Assigned(glVertexAttrib2fARB) then Exit;
  5274. glVertexAttrib2dARB := wglGetProcAddress('glVertexAttrib2dARB');
  5275. if not Assigned(glVertexAttrib2dARB) then Exit;
  5276. glVertexAttrib3sARB := wglGetProcAddress('glVertexAttrib3sARB');
  5277. if not Assigned(glVertexAttrib3sARB) then Exit;
  5278. glVertexAttrib3fARB := wglGetProcAddress('glVertexAttrib3fARB');
  5279. if not Assigned(glVertexAttrib3fARB) then Exit;
  5280. glVertexAttrib3dARB := wglGetProcAddress('glVertexAttrib3dARB');
  5281. if not Assigned(glVertexAttrib3dARB) then Exit;
  5282. glVertexAttrib4sARB := wglGetProcAddress('glVertexAttrib4sARB');
  5283. if not Assigned(glVertexAttrib4sARB) then Exit;
  5284. glVertexAttrib4fARB := wglGetProcAddress('glVertexAttrib4fARB');
  5285. if not Assigned(glVertexAttrib4fARB) then Exit;
  5286. glVertexAttrib4dARB := wglGetProcAddress('glVertexAttrib4dARB');
  5287. if not Assigned(glVertexAttrib4dARB) then Exit;
  5288. glVertexAttrib4NubARB := wglGetProcAddress('glVertexAttrib4NubARB');
  5289. if not Assigned(glVertexAttrib4NubARB) then Exit;
  5290. glVertexAttrib1svARB := wglGetProcAddress('glVertexAttrib1svARB');
  5291. if not Assigned(glVertexAttrib1svARB) then Exit;
  5292. glVertexAttrib1fvARB := wglGetProcAddress('glVertexAttrib1fvARB');
  5293. if not Assigned(glVertexAttrib1fvARB) then Exit;
  5294. glVertexAttrib1dvARB := wglGetProcAddress('glVertexAttrib1dvARB');
  5295. if not Assigned(glVertexAttrib1dvARB) then Exit;
  5296. glVertexAttrib2svARB := wglGetProcAddress('glVertexAttrib2svARB');
  5297. if not Assigned(glVertexAttrib2svARB) then Exit;
  5298. glVertexAttrib2fvARB := wglGetProcAddress('glVertexAttrib2fvARB');
  5299. if not Assigned(glVertexAttrib2fvARB) then Exit;
  5300. glVertexAttrib2dvARB := wglGetProcAddress('glVertexAttrib2dvARB');
  5301. if not Assigned(glVertexAttrib2dvARB) then Exit;
  5302. glVertexAttrib3svARB := wglGetProcAddress('glVertexAttrib3svARB');
  5303. if not Assigned(glVertexAttrib3svARB) then Exit;
  5304. glVertexAttrib3fvARB := wglGetProcAddress('glVertexAttrib3fvARB');
  5305. if not Assigned(glVertexAttrib3fvARB) then Exit;
  5306. glVertexAttrib3dvARB := wglGetProcAddress('glVertexAttrib3dvARB');
  5307. if not Assigned(glVertexAttrib3dvARB) then Exit;
  5308. glVertexAttrib4bvARB := wglGetProcAddress('glVertexAttrib4bvARB');
  5309. if not Assigned(glVertexAttrib4bvARB) then Exit;
  5310. glVertexAttrib4svARB := wglGetProcAddress('glVertexAttrib4svARB');
  5311. if not Assigned(glVertexAttrib4svARB) then Exit;
  5312. glVertexAttrib4ivARB := wglGetProcAddress('glVertexAttrib4ivARB');
  5313. if not Assigned(glVertexAttrib4ivARB) then Exit;
  5314. glVertexAttrib4ubvARB := wglGetProcAddress('glVertexAttrib4ubvARB');
  5315. if not Assigned(glVertexAttrib4ubvARB) then Exit;
  5316. glVertexAttrib4usvARB := wglGetProcAddress('glVertexAttrib4usvARB');
  5317. if not Assigned(glVertexAttrib4usvARB) then Exit;
  5318. glVertexAttrib4uivARB := wglGetProcAddress('glVertexAttrib4uivARB');
  5319. if not Assigned(glVertexAttrib4uivARB) then Exit;
  5320. glVertexAttrib4fvARB := wglGetProcAddress('glVertexAttrib4fvARB');
  5321. if not Assigned(glVertexAttrib4fvARB) then Exit;
  5322. glVertexAttrib4dvARB := wglGetProcAddress('glVertexAttrib4dvARB');
  5323. if not Assigned(glVertexAttrib4dvARB) then Exit;
  5324. glVertexAttrib4NbvARB := wglGetProcAddress('glVertexAttrib4NbvARB');
  5325. if not Assigned(glVertexAttrib4NbvARB) then Exit;
  5326. glVertexAttrib4NsvARB := wglGetProcAddress('glVertexAttrib4NsvARB');
  5327. if not Assigned(glVertexAttrib4NsvARB) then Exit;
  5328. glVertexAttrib4NivARB := wglGetProcAddress('glVertexAttrib4NivARB');
  5329. if not Assigned(glVertexAttrib4NivARB) then Exit;
  5330. glVertexAttrib4NubvARB := wglGetProcAddress('glVertexAttrib4NubvARB');
  5331. if not Assigned(glVertexAttrib4NubvARB) then Exit;
  5332. glVertexAttrib4NusvARB := wglGetProcAddress('glVertexAttrib4NusvARB');
  5333. if not Assigned(glVertexAttrib4NusvARB) then Exit;
  5334. glVertexAttrib4NuivARB := wglGetProcAddress('glVertexAttrib4NuivARB');
  5335. if not Assigned(glVertexAttrib4NuivARB) then Exit;
  5336. glVertexAttribPointerARB := wglGetProcAddress('glVertexAttribPointerARB');
  5337. if not Assigned(glVertexAttribPointerARB) then Exit;
  5338. glEnableVertexAttribArrayARB := wglGetProcAddress('glEnableVertexAttribArrayARB');
  5339. if not Assigned(glEnableVertexAttribArrayARB) then Exit;
  5340. glDisableVertexAttribArrayARB := wglGetProcAddress('glDisableVertexAttribArrayARB');
  5341. if not Assigned(glDisableVertexAttribArrayARB) then Exit;
  5342. glProgramStringARB := wglGetProcAddress('glProgramStringARB');
  5343. if not Assigned(glProgramStringARB) then Exit;
  5344. glBindProgramARB := wglGetProcAddress('glBindProgramARB');
  5345. if not Assigned(glBindProgramARB) then Exit;
  5346. glDeleteProgramsARB := wglGetProcAddress('glDeleteProgramsARB');
  5347. if not Assigned(glDeleteProgramsARB) then Exit;
  5348. glGenProgramsARB := wglGetProcAddress('glGenProgramsARB');
  5349. if not Assigned(glGenProgramsARB) then Exit;
  5350. glProgramEnvParameter4dARB := wglGetProcAddress('glProgramEnvParameter4dARB');
  5351. if not Assigned(glProgramEnvParameter4dARB) then Exit;
  5352. glProgramEnvParameter4dvARB := wglGetProcAddress('glProgramEnvParameter4dvARB');
  5353. if not Assigned(glProgramEnvParameter4dvARB) then Exit;
  5354. glProgramEnvParameter4fARB := wglGetProcAddress('glProgramEnvParameter4fARB');
  5355. if not Assigned(glProgramEnvParameter4fARB) then Exit;
  5356. glProgramEnvParameter4fvARB := wglGetProcAddress('glProgramEnvParameter4fvARB');
  5357. if not Assigned(glProgramEnvParameter4fvARB) then Exit;
  5358. glProgramLocalParameter4dARB := wglGetProcAddress('glProgramLocalParameter4dARB');
  5359. if not Assigned(glProgramLocalParameter4dARB) then Exit;
  5360. glProgramLocalParameter4dvARB := wglGetProcAddress('glProgramLocalParameter4dvARB');
  5361. if not Assigned(glProgramLocalParameter4dvARB) then Exit;
  5362. glProgramLocalParameter4fARB := wglGetProcAddress('glProgramLocalParameter4fARB');
  5363. if not Assigned(glProgramLocalParameter4fARB) then Exit;
  5364. glProgramLocalParameter4fvARB := wglGetProcAddress('glProgramLocalParameter4fvARB');
  5365. if not Assigned(glProgramLocalParameter4fvARB) then Exit;
  5366. glGetProgramEnvParameterdvARB := wglGetProcAddress('glGetProgramEnvParameterdvARB');
  5367. if not Assigned(glGetProgramEnvParameterdvARB) then Exit;
  5368. glGetProgramEnvParameterfvARB := wglGetProcAddress('glGetProgramEnvParameterfvARB');
  5369. if not Assigned(glGetProgramEnvParameterfvARB) then Exit;
  5370. glGetProgramLocalParameterdvARB := wglGetProcAddress('glGetProgramLocalParameterdvARB');
  5371. if not Assigned(glGetProgramLocalParameterdvARB) then Exit;
  5372. glGetProgramLocalParameterfvARB := wglGetProcAddress('glGetProgramLocalParameterfvARB');
  5373. if not Assigned(glGetProgramLocalParameterfvARB) then Exit;
  5374. glGetProgramivARB := wglGetProcAddress('glGetProgramivARB');
  5375. if not Assigned(glGetProgramivARB) then Exit;
  5376. glGetProgramStringARB := wglGetProcAddress('glGetProgramStringARB');
  5377. if not Assigned(glGetProgramStringARB) then Exit;
  5378. glGetVertexAttribdvARB := wglGetProcAddress('glGetVertexAttribdvARB');
  5379. if not Assigned(glGetVertexAttribdvARB) then Exit;
  5380. glGetVertexAttribfvARB := wglGetProcAddress('glGetVertexAttribfvARB');
  5381. if not Assigned(glGetVertexAttribfvARB) then Exit;
  5382. glGetVertexAttribivARB := wglGetProcAddress('glGetVertexAttribivARB');
  5383. if not Assigned(glGetVertexAttribivARB) then Exit;
  5384. glGetVertexAttribPointervARB := wglGetProcAddress('glGetVertexAttribPointervARB');
  5385. if not Assigned(glGetVertexAttribPointervARB) then Exit;
  5386. glIsProgramARB := wglGetProcAddress('glIsProgramARB');
  5387. if not Assigned(glIsProgramARB) then Exit;
  5388. Result := TRUE;
  5389. end;
  5390. end;
  5391. function Load_GL_ARB_window_pos: Boolean;
  5392. var
  5393. extstring: String;
  5394. begin
  5395. Result := FALSE;
  5396. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5397. if glext_ExtensionSupported('GL_ARB_window_pos', extstring) then
  5398. begin
  5399. glWindowPos2dARB := wglGetProcAddress('glWindowPos2dARB');
  5400. if not Assigned(glWindowPos2dARB) then Exit;
  5401. glWindowPos2fARB := wglGetProcAddress('glWindowPos2fARB');
  5402. if not Assigned(glWindowPos2fARB) then Exit;
  5403. glWindowPos2iARB := wglGetProcAddress('glWindowPos2iARB');
  5404. if not Assigned(glWindowPos2iARB) then Exit;
  5405. glWindowPos2sARB := wglGetProcAddress('glWindowPos2sARB');
  5406. if not Assigned(glWindowPos2sARB) then Exit;
  5407. glWindowPos2dvARB := wglGetProcAddress('glWindowPos2dvARB');
  5408. if not Assigned(glWindowPos2dvARB) then Exit;
  5409. glWindowPos2fvARB := wglGetProcAddress('glWindowPos2fvARB');
  5410. if not Assigned(glWindowPos2fvARB) then Exit;
  5411. glWindowPos2ivARB := wglGetProcAddress('glWindowPos2ivARB');
  5412. if not Assigned(glWindowPos2ivARB) then Exit;
  5413. glWindowPos2svARB := wglGetProcAddress('glWindowPos2svARB');
  5414. if not Assigned(glWindowPos2svARB) then Exit;
  5415. glWindowPos3dARB := wglGetProcAddress('glWindowPos3dARB');
  5416. if not Assigned(glWindowPos3dARB) then Exit;
  5417. glWindowPos3fARB := wglGetProcAddress('glWindowPos3fARB');
  5418. if not Assigned(glWindowPos3fARB) then Exit;
  5419. glWindowPos3iARB := wglGetProcAddress('glWindowPos3iARB');
  5420. if not Assigned(glWindowPos3iARB) then Exit;
  5421. glWindowPos3sARB := wglGetProcAddress('glWindowPos3sARB');
  5422. if not Assigned(glWindowPos3sARB) then Exit;
  5423. glWindowPos3dvARB := wglGetProcAddress('glWindowPos3dvARB');
  5424. if not Assigned(glWindowPos3dvARB) then Exit;
  5425. glWindowPos3fvARB := wglGetProcAddress('glWindowPos3fvARB');
  5426. if not Assigned(glWindowPos3fvARB) then Exit;
  5427. glWindowPos3ivARB := wglGetProcAddress('glWindowPos3ivARB');
  5428. if not Assigned(glWindowPos3ivARB) then Exit;
  5429. glWindowPos3svARB := wglGetProcAddress('glWindowPos3svARB');
  5430. if not Assigned(glWindowPos3svARB) then Exit;
  5431. Result := TRUE;
  5432. end;
  5433. end;
  5434. function Load_GL_EXT_422_pixels: Boolean;
  5435. var
  5436. extstring: String;
  5437. begin
  5438. Result := FALSE;
  5439. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5440. if glext_ExtensionSupported('GL_EXT_422_pixels', extstring) then
  5441. begin
  5442. Result := TRUE;
  5443. end;
  5444. end;
  5445. function Load_GL_EXT_abgr: Boolean;
  5446. var
  5447. extstring: String;
  5448. begin
  5449. Result := FALSE;
  5450. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5451. if glext_ExtensionSupported('GL_EXT_abgr', extstring) then
  5452. begin
  5453. Result := TRUE;
  5454. end;
  5455. end;
  5456. function Load_GL_EXT_bgra: Boolean;
  5457. var
  5458. extstring: String;
  5459. begin
  5460. Result := FALSE;
  5461. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5462. if glext_ExtensionSupported('GL_EXT_bgra', extstring) then
  5463. begin
  5464. Result := TRUE;
  5465. end;
  5466. end;
  5467. function Load_GL_EXT_blend_color: Boolean;
  5468. var
  5469. extstring: String;
  5470. begin
  5471. Result := FALSE;
  5472. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5473. if glext_ExtensionSupported('GL_EXT_blend_color', extstring) then
  5474. begin
  5475. glBlendColorEXT := wglGetProcAddress('glBlendColorEXT');
  5476. if not Assigned(glBlendColorEXT) then Exit;
  5477. Result := TRUE;
  5478. end;
  5479. end;
  5480. function Load_GL_EXT_blend_func_separate: Boolean;
  5481. var
  5482. extstring: String;
  5483. begin
  5484. Result := FALSE;
  5485. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5486. if glext_ExtensionSupported('GL_EXT_blend_func_separate', extstring) then
  5487. begin
  5488. glBlendFuncSeparateEXT := wglGetProcAddress('glBlendFuncSeparateEXT');
  5489. if not Assigned(glBlendFuncSeparateEXT) then Exit;
  5490. Result := TRUE;
  5491. end;
  5492. end;
  5493. function Load_GL_EXT_blend_logic_op: Boolean;
  5494. var
  5495. extstring: String;
  5496. begin
  5497. Result := FALSE;
  5498. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5499. if glext_ExtensionSupported('GL_EXT_blend_logic_op', extstring) then
  5500. begin
  5501. Result := TRUE;
  5502. end;
  5503. end;
  5504. function Load_GL_EXT_blend_minmax: Boolean;
  5505. var
  5506. extstring: String;
  5507. begin
  5508. Result := FALSE;
  5509. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5510. if glext_ExtensionSupported('GL_EXT_blend_minmax', extstring) then
  5511. begin
  5512. glBlendEquationEXT := wglGetProcAddress('glBlendEquationEXT');
  5513. if not Assigned(glBlendEquationEXT) then Exit;
  5514. Result := TRUE;
  5515. end;
  5516. end;
  5517. function Load_GL_EXT_blend_subtract: Boolean;
  5518. var
  5519. extstring: String;
  5520. begin
  5521. Result := FALSE;
  5522. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5523. if glext_ExtensionSupported('GL_EXT_blend_subtract', extstring) then
  5524. begin
  5525. Result := TRUE;
  5526. end;
  5527. end;
  5528. function Load_GL_EXT_clip_volume_hint: Boolean;
  5529. var
  5530. extstring: String;
  5531. begin
  5532. Result := FALSE;
  5533. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5534. if glext_ExtensionSupported('GL_EXT_clip_volume_hint', extstring) then
  5535. begin
  5536. Result := TRUE;
  5537. end;
  5538. end;
  5539. function Load_GL_EXT_color_subtable: Boolean;
  5540. var
  5541. extstring: String;
  5542. begin
  5543. Result := FALSE;
  5544. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5545. if glext_ExtensionSupported('GL_EXT_color_subtable', extstring) then
  5546. begin
  5547. glColorSubTableEXT := wglGetProcAddress('glColorSubTableEXT');
  5548. if not Assigned(glColorSubTableEXT) then Exit;
  5549. glCopyColorSubTableEXT := wglGetProcAddress('glCopyColorSubTableEXT');
  5550. if not Assigned(glCopyColorSubTableEXT) then Exit;
  5551. Result := TRUE;
  5552. end;
  5553. end;
  5554. function Load_GL_EXT_compiled_vertex_array: Boolean;
  5555. var
  5556. extstring: String;
  5557. begin
  5558. Result := FALSE;
  5559. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5560. if glext_ExtensionSupported('GL_EXT_compiled_vertex_array', extstring) then
  5561. begin
  5562. glLockArraysEXT := wglGetProcAddress('glLockArraysEXT');
  5563. if not Assigned(glLockArraysEXT) then Exit;
  5564. glUnlockArraysEXT := wglGetProcAddress('glUnlockArraysEXT');
  5565. if not Assigned(glUnlockArraysEXT) then Exit;
  5566. Result := TRUE;
  5567. end;
  5568. end;
  5569. function Load_GL_EXT_convolution: Boolean;
  5570. var
  5571. extstring: String;
  5572. begin
  5573. Result := FALSE;
  5574. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5575. if glext_ExtensionSupported('GL_EXT_convolution', extstring) then
  5576. begin
  5577. glConvolutionFilter1DEXT := wglGetProcAddress('glConvolutionFilter1DEXT');
  5578. if not Assigned(glConvolutionFilter1DEXT) then Exit;
  5579. glConvolutionFilter2DEXT := wglGetProcAddress('glConvolutionFilter2DEXT');
  5580. if not Assigned(glConvolutionFilter2DEXT) then Exit;
  5581. glCopyConvolutionFilter1DEXT := wglGetProcAddress('glCopyConvolutionFilter1DEXT');
  5582. if not Assigned(glCopyConvolutionFilter1DEXT) then Exit;
  5583. glCopyConvolutionFilter2DEXT := wglGetProcAddress('glCopyConvolutionFilter2DEXT');
  5584. if not Assigned(glCopyConvolutionFilter2DEXT) then Exit;
  5585. glGetConvolutionFilterEXT := wglGetProcAddress('glGetConvolutionFilterEXT');
  5586. if not Assigned(glGetConvolutionFilterEXT) then Exit;
  5587. glSeparableFilter2DEXT := wglGetProcAddress('glSeparableFilter2DEXT');
  5588. if not Assigned(glSeparableFilter2DEXT) then Exit;
  5589. glGetSeparableFilterEXT := wglGetProcAddress('glGetSeparableFilterEXT');
  5590. if not Assigned(glGetSeparableFilterEXT) then Exit;
  5591. glConvolutionParameteriEXT := wglGetProcAddress('glConvolutionParameteriEXT');
  5592. if not Assigned(glConvolutionParameteriEXT) then Exit;
  5593. glConvolutionParameterivEXT := wglGetProcAddress('glConvolutionParameterivEXT');
  5594. if not Assigned(glConvolutionParameterivEXT) then Exit;
  5595. glConvolutionParameterfEXT := wglGetProcAddress('glConvolutionParameterfEXT');
  5596. if not Assigned(glConvolutionParameterfEXT) then Exit;
  5597. glConvolutionParameterfvEXT := wglGetProcAddress('glConvolutionParameterfvEXT');
  5598. if not Assigned(glConvolutionParameterfvEXT) then Exit;
  5599. glGetConvolutionParameterivEXT := wglGetProcAddress('glGetConvolutionParameterivEXT');
  5600. if not Assigned(glGetConvolutionParameterivEXT) then Exit;
  5601. glGetConvolutionParameterfvEXT := wglGetProcAddress('glGetConvolutionParameterfvEXT');
  5602. if not Assigned(glGetConvolutionParameterfvEXT) then Exit;
  5603. Result := TRUE;
  5604. end;
  5605. end;
  5606. function Load_GL_EXT_fog_coord: Boolean;
  5607. var
  5608. extstring: String;
  5609. begin
  5610. Result := FALSE;
  5611. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5612. if glext_ExtensionSupported('GL_EXT_fog_coord', extstring) then
  5613. begin
  5614. glFogCoordfEXT := wglGetProcAddress('glFogCoordfEXT');
  5615. if not Assigned(glFogCoordfEXT) then Exit;
  5616. glFogCoorddEXT := wglGetProcAddress('glFogCoorddEXT');
  5617. if not Assigned(glFogCoorddEXT) then Exit;
  5618. glFogCoordfvEXT := wglGetProcAddress('glFogCoordfvEXT');
  5619. if not Assigned(glFogCoordfvEXT) then Exit;
  5620. glFogCoorddvEXT := wglGetProcAddress('glFogCoorddvEXT');
  5621. if not Assigned(glFogCoorddvEXT) then Exit;
  5622. glFogCoordPointerEXT := wglGetProcAddress('glFogCoordPointerEXT');
  5623. if not Assigned(glFogCoordPointerEXT) then Exit;
  5624. Result := TRUE;
  5625. end;
  5626. end;
  5627. function Load_GL_EXT_histogram: Boolean;
  5628. var
  5629. extstring: String;
  5630. begin
  5631. Result := FALSE;
  5632. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5633. if glext_ExtensionSupported('GL_EXT_histogram', extstring) then
  5634. begin
  5635. glHistogramEXT := wglGetProcAddress('glHistogramEXT');
  5636. if not Assigned(glHistogramEXT) then Exit;
  5637. glResetHistogramEXT := wglGetProcAddress('glResetHistogramEXT');
  5638. if not Assigned(glResetHistogramEXT) then Exit;
  5639. glGetHistogramEXT := wglGetProcAddress('glGetHistogramEXT');
  5640. if not Assigned(glGetHistogramEXT) then Exit;
  5641. glGetHistogramParameterivEXT := wglGetProcAddress('glGetHistogramParameterivEXT');
  5642. if not Assigned(glGetHistogramParameterivEXT) then Exit;
  5643. glGetHistogramParameterfvEXT := wglGetProcAddress('glGetHistogramParameterfvEXT');
  5644. if not Assigned(glGetHistogramParameterfvEXT) then Exit;
  5645. glMinmaxEXT := wglGetProcAddress('glMinmaxEXT');
  5646. if not Assigned(glMinmaxEXT) then Exit;
  5647. glResetMinmaxEXT := wglGetProcAddress('glResetMinmaxEXT');
  5648. if not Assigned(glResetMinmaxEXT) then Exit;
  5649. glGetMinmaxEXT := wglGetProcAddress('glGetMinmaxEXT');
  5650. if not Assigned(glGetMinmaxEXT) then Exit;
  5651. glGetMinmaxParameterivEXT := wglGetProcAddress('glGetMinmaxParameterivEXT');
  5652. if not Assigned(glGetMinmaxParameterivEXT) then Exit;
  5653. glGetMinmaxParameterfvEXT := wglGetProcAddress('glGetMinmaxParameterfvEXT');
  5654. if not Assigned(glGetMinmaxParameterfvEXT) then Exit;
  5655. Result := TRUE;
  5656. end;
  5657. end;
  5658. function Load_GL_EXT_multi_draw_arrays: Boolean;
  5659. var
  5660. extstring: String;
  5661. begin
  5662. Result := FALSE;
  5663. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5664. if glext_ExtensionSupported('GL_EXT_multi_draw_arrays', extstring) then
  5665. begin
  5666. glMultiDrawArraysEXT := wglGetProcAddress('glMultiDrawArraysEXT');
  5667. if not Assigned(glMultiDrawArraysEXT) then Exit;
  5668. glMultiDrawElementsEXT := wglGetProcAddress('glMultiDrawElementsEXT');
  5669. if not Assigned(glMultiDrawElementsEXT) then Exit;
  5670. Result := TRUE;
  5671. end;
  5672. end;
  5673. function Load_GL_EXT_packed_depth_stencil: Boolean;
  5674. var
  5675. extstring: String;
  5676. begin
  5677. Result := FALSE;
  5678. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5679. if glext_ExtensionSupported('GL_EXT_packed_depth_stencil', extstring) then
  5680. begin
  5681. Result := TRUE;
  5682. end;
  5683. end;
  5684. function Load_GL_EXT_packed_pixels: Boolean;
  5685. var
  5686. extstring: String;
  5687. begin
  5688. Result := FALSE;
  5689. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5690. if glext_ExtensionSupported('GL_EXT_packed_pixels', extstring) then
  5691. begin
  5692. Result := TRUE;
  5693. end;
  5694. end;
  5695. function Load_GL_EXT_paletted_texture: Boolean;
  5696. var
  5697. extstring: String;
  5698. begin
  5699. Result := FALSE;
  5700. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5701. if glext_ExtensionSupported('GL_EXT_paletted_texture', extstring) then
  5702. begin
  5703. glColorTableEXT := wglGetProcAddress('glColorTableEXT');
  5704. if not Assigned(glColorTableEXT) then Exit;
  5705. glColorSubTableEXT := wglGetProcAddress('glColorSubTableEXT');
  5706. if not Assigned(glColorSubTableEXT) then Exit;
  5707. glGetColorTableEXT := wglGetProcAddress('glGetColorTableEXT');
  5708. if not Assigned(glGetColorTableEXT) then Exit;
  5709. glGetColorTableParameterivEXT := wglGetProcAddress('glGetColorTableParameterivEXT');
  5710. if not Assigned(glGetColorTableParameterivEXT) then Exit;
  5711. glGetColorTableParameterfvEXT := wglGetProcAddress('glGetColorTableParameterfvEXT');
  5712. if not Assigned(glGetColorTableParameterfvEXT) then Exit;
  5713. Result := TRUE;
  5714. end;
  5715. end;
  5716. function Load_GL_EXT_point_parameters: Boolean;
  5717. var
  5718. extstring: String;
  5719. begin
  5720. Result := FALSE;
  5721. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5722. if glext_ExtensionSupported('GL_EXT_point_parameters', extstring) then
  5723. begin
  5724. glPointParameterfEXT := wglGetProcAddress('glPointParameterfEXT');
  5725. if not Assigned(glPointParameterfEXT) then Exit;
  5726. glPointParameterfvEXT := wglGetProcAddress('glPointParameterfvEXT');
  5727. if not Assigned(glPointParameterfvEXT) then Exit;
  5728. Result := TRUE;
  5729. end;
  5730. end;
  5731. function Load_GL_EXT_polygon_offset: Boolean;
  5732. var
  5733. extstring: String;
  5734. begin
  5735. Result := FALSE;
  5736. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5737. if glext_ExtensionSupported('GL_EXT_polygon_offset', extstring) then
  5738. begin
  5739. glPolygonOffsetEXT := wglGetProcAddress('glPolygonOffsetEXT');
  5740. if not Assigned(glPolygonOffsetEXT) then Exit;
  5741. Result := TRUE;
  5742. end;
  5743. end;
  5744. function Load_GL_EXT_secondary_color: Boolean;
  5745. var
  5746. extstring: String;
  5747. begin
  5748. Result := FALSE;
  5749. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5750. if glext_ExtensionSupported('GL_EXT_secondary_color', extstring) then
  5751. begin
  5752. glSecondaryColor3bEXT := wglGetProcAddress('glSecondaryColor3bEXT');
  5753. if not Assigned(glSecondaryColor3bEXT) then Exit;
  5754. glSecondaryColor3sEXT := wglGetProcAddress('glSecondaryColor3sEXT');
  5755. if not Assigned(glSecondaryColor3sEXT) then Exit;
  5756. glSecondaryColor3iEXT := wglGetProcAddress('glSecondaryColor3iEXT');
  5757. if not Assigned(glSecondaryColor3iEXT) then Exit;
  5758. glSecondaryColor3fEXT := wglGetProcAddress('glSecondaryColor3fEXT');
  5759. if not Assigned(glSecondaryColor3fEXT) then Exit;
  5760. glSecondaryColor3dEXT := wglGetProcAddress('glSecondaryColor3dEXT');
  5761. if not Assigned(glSecondaryColor3dEXT) then Exit;
  5762. glSecondaryColor3ubEXT := wglGetProcAddress('glSecondaryColor3ubEXT');
  5763. if not Assigned(glSecondaryColor3ubEXT) then Exit;
  5764. glSecondaryColor3usEXT := wglGetProcAddress('glSecondaryColor3usEXT');
  5765. if not Assigned(glSecondaryColor3usEXT) then Exit;
  5766. glSecondaryColor3uiEXT := wglGetProcAddress('glSecondaryColor3uiEXT');
  5767. if not Assigned(glSecondaryColor3uiEXT) then Exit;
  5768. glSecondaryColor3bvEXT := wglGetProcAddress('glSecondaryColor3bvEXT');
  5769. if not Assigned(glSecondaryColor3bvEXT) then Exit;
  5770. glSecondaryColor3svEXT := wglGetProcAddress('glSecondaryColor3svEXT');
  5771. if not Assigned(glSecondaryColor3svEXT) then Exit;
  5772. glSecondaryColor3ivEXT := wglGetProcAddress('glSecondaryColor3ivEXT');
  5773. if not Assigned(glSecondaryColor3ivEXT) then Exit;
  5774. glSecondaryColor3fvEXT := wglGetProcAddress('glSecondaryColor3fvEXT');
  5775. if not Assigned(glSecondaryColor3fvEXT) then Exit;
  5776. glSecondaryColor3dvEXT := wglGetProcAddress('glSecondaryColor3dvEXT');
  5777. if not Assigned(glSecondaryColor3dvEXT) then Exit;
  5778. glSecondaryColor3ubvEXT := wglGetProcAddress('glSecondaryColor3ubvEXT');
  5779. if not Assigned(glSecondaryColor3ubvEXT) then Exit;
  5780. glSecondaryColor3usvEXT := wglGetProcAddress('glSecondaryColor3usvEXT');
  5781. if not Assigned(glSecondaryColor3usvEXT) then Exit;
  5782. glSecondaryColor3uivEXT := wglGetProcAddress('glSecondaryColor3uivEXT');
  5783. if not Assigned(glSecondaryColor3uivEXT) then Exit;
  5784. glSecondaryColorPointerEXT := wglGetProcAddress('glSecondaryColorPointerEXT');
  5785. if not Assigned(glSecondaryColorPointerEXT) then Exit;
  5786. Result := TRUE;
  5787. end;
  5788. end;
  5789. function Load_GL_EXT_separate_specular_color: Boolean;
  5790. var
  5791. extstring: String;
  5792. begin
  5793. Result := FALSE;
  5794. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5795. if glext_ExtensionSupported('GL_EXT_separate_specular_color', extstring) then
  5796. begin
  5797. Result := TRUE;
  5798. end;
  5799. end;
  5800. function Load_GL_EXT_shadow_funcs: Boolean;
  5801. var
  5802. extstring: String;
  5803. begin
  5804. Result := FALSE;
  5805. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5806. if glext_ExtensionSupported('GL_EXT_shadow_funcs', extstring) then
  5807. begin
  5808. Result := TRUE;
  5809. end;
  5810. end;
  5811. function Load_GL_EXT_shared_texture_palette: Boolean;
  5812. var
  5813. extstring: String;
  5814. begin
  5815. Result := FALSE;
  5816. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5817. if glext_ExtensionSupported('GL_EXT_shared_texture_palette', extstring) then
  5818. begin
  5819. Result := TRUE;
  5820. end;
  5821. end;
  5822. function Load_GL_EXT_stencil_two_side: Boolean;
  5823. var
  5824. extstring: String;
  5825. begin
  5826. Result := FALSE;
  5827. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5828. if glext_ExtensionSupported('GL_EXT_stencil_two_side', extstring) then
  5829. begin
  5830. glActiveStencilFaceEXT := wglGetProcAddress('glActiveStencilFaceEXT');
  5831. if not Assigned(glActiveStencilFaceEXT) then Exit;
  5832. Result := TRUE;
  5833. end;
  5834. end;
  5835. function Load_GL_EXT_stencil_wrap: Boolean;
  5836. var
  5837. extstring: String;
  5838. begin
  5839. Result := FALSE;
  5840. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5841. if glext_ExtensionSupported('GL_EXT_stencil_wrap', extstring) then
  5842. begin
  5843. Result := TRUE;
  5844. end;
  5845. end;
  5846. function Load_GL_EXT_subtexture: Boolean;
  5847. var
  5848. extstring: String;
  5849. begin
  5850. Result := FALSE;
  5851. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5852. if glext_ExtensionSupported('GL_EXT_subtexture', extstring) then
  5853. begin
  5854. glTexSubImage1DEXT := wglGetProcAddress('glTexSubImage1DEXT');
  5855. if not Assigned(glTexSubImage1DEXT) then Exit;
  5856. glTexSubImage2DEXT := wglGetProcAddress('glTexSubImage2DEXT');
  5857. if not Assigned(glTexSubImage2DEXT) then Exit;
  5858. glTexSubImage3DEXT := wglGetProcAddress('glTexSubImage3DEXT');
  5859. if not Assigned(glTexSubImage3DEXT) then Exit;
  5860. Result := TRUE;
  5861. end;
  5862. end;
  5863. function Load_GL_EXT_texture3D: Boolean;
  5864. var
  5865. extstring: String;
  5866. begin
  5867. Result := FALSE;
  5868. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5869. if glext_ExtensionSupported('GL_EXT_texture3D', extstring) then
  5870. begin
  5871. glTexImage3DEXT := wglGetProcAddress('glTexImage3DEXT');
  5872. if not Assigned(glTexImage3DEXT) then Exit;
  5873. Result := TRUE;
  5874. end;
  5875. end;
  5876. function Load_GL_EXT_texture_compression_s3tc: Boolean;
  5877. var
  5878. extstring: String;
  5879. begin
  5880. Result := FALSE;
  5881. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5882. if glext_ExtensionSupported('GL_EXT_texture_compression_s3tc', extstring) then
  5883. begin
  5884. Result := TRUE;
  5885. end;
  5886. end;
  5887. function Load_GL_EXT_texture_env_add: Boolean;
  5888. var
  5889. extstring: String;
  5890. begin
  5891. Result := FALSE;
  5892. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5893. if glext_ExtensionSupported('GL_EXT_texture_env_add', extstring) then
  5894. begin
  5895. Result := TRUE;
  5896. end;
  5897. end;
  5898. function Load_GL_EXT_texture_env_combine: Boolean;
  5899. var
  5900. extstring: String;
  5901. begin
  5902. Result := FALSE;
  5903. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5904. if glext_ExtensionSupported('GL_EXT_texture_env_combine', extstring) then
  5905. begin
  5906. Result := TRUE;
  5907. end;
  5908. end;
  5909. function Load_GL_EXT_texture_env_dot3: Boolean;
  5910. var
  5911. extstring: String;
  5912. begin
  5913. Result := FALSE;
  5914. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5915. if glext_ExtensionSupported('GL_EXT_texture_env_dot3', extstring) then
  5916. begin
  5917. Result := TRUE;
  5918. end;
  5919. end;
  5920. function Load_GL_EXT_texture_filter_anisotropic: Boolean;
  5921. var
  5922. extstring: String;
  5923. begin
  5924. Result := FALSE;
  5925. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5926. if glext_ExtensionSupported('GL_EXT_texture_filter_anisotropic', extstring) then
  5927. begin
  5928. Result := TRUE;
  5929. end;
  5930. end;
  5931. function Load_GL_EXT_texture_lod_bias: Boolean;
  5932. var
  5933. extstring: String;
  5934. begin
  5935. Result := FALSE;
  5936. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5937. if glext_ExtensionSupported('GL_EXT_texture_lod_bias', extstring) then
  5938. begin
  5939. Result := TRUE;
  5940. end;
  5941. end;
  5942. function Load_GL_EXT_texture_object: Boolean;
  5943. var
  5944. extstring: String;
  5945. begin
  5946. Result := FALSE;
  5947. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5948. if glext_ExtensionSupported('GL_EXT_texture_object', extstring) then
  5949. begin
  5950. glGenTexturesEXT := wglGetProcAddress('glGenTexturesEXT');
  5951. if not Assigned(glGenTexturesEXT) then Exit;
  5952. glDeleteTexturesEXT := wglGetProcAddress('glDeleteTexturesEXT');
  5953. if not Assigned(glDeleteTexturesEXT) then Exit;
  5954. glBindTextureEXT := wglGetProcAddress('glBindTextureEXT');
  5955. if not Assigned(glBindTextureEXT) then Exit;
  5956. glPrioritizeTexturesEXT := wglGetProcAddress('glPrioritizeTexturesEXT');
  5957. if not Assigned(glPrioritizeTexturesEXT) then Exit;
  5958. glAreTexturesResidentEXT := wglGetProcAddress('glAreTexturesResidentEXT');
  5959. if not Assigned(glAreTexturesResidentEXT) then Exit;
  5960. glIsTextureEXT := wglGetProcAddress('glIsTextureEXT');
  5961. if not Assigned(glIsTextureEXT) then Exit;
  5962. Result := TRUE;
  5963. end;
  5964. end;
  5965. function Load_GL_EXT_vertex_array: Boolean;
  5966. var
  5967. extstring: String;
  5968. begin
  5969. Result := FALSE;
  5970. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  5971. if glext_ExtensionSupported('GL_EXT_vertex_array', extstring) then
  5972. begin
  5973. glArrayElementEXT := wglGetProcAddress('glArrayElementEXT');
  5974. if not Assigned(glArrayElementEXT) then Exit;
  5975. glDrawArraysEXT := wglGetProcAddress('glDrawArraysEXT');
  5976. if not Assigned(glDrawArraysEXT) then Exit;
  5977. glVertexPointerEXT := wglGetProcAddress('glVertexPointerEXT');
  5978. if not Assigned(glVertexPointerEXT) then Exit;
  5979. glNormalPointerEXT := wglGetProcAddress('glNormalPointerEXT');
  5980. if not Assigned(glNormalPointerEXT) then Exit;
  5981. glColorPointerEXT := wglGetProcAddress('glColorPointerEXT');
  5982. if not Assigned(glColorPointerEXT) then Exit;
  5983. glIndexPointerEXT := wglGetProcAddress('glIndexPointerEXT');
  5984. if not Assigned(glIndexPointerEXT) then Exit;
  5985. glTexCoordPointerEXT := wglGetProcAddress('glTexCoordPointerEXT');
  5986. if not Assigned(glTexCoordPointerEXT) then Exit;
  5987. glEdgeFlagPointerEXT := wglGetProcAddress('glEdgeFlagPointerEXT');
  5988. if not Assigned(glEdgeFlagPointerEXT) then Exit;
  5989. glGetPointervEXT := wglGetProcAddress('glGetPointervEXT');
  5990. if not Assigned(glGetPointervEXT) then Exit;
  5991. Result := TRUE;
  5992. end;
  5993. end;
  5994. function Load_GL_EXT_vertex_shader: Boolean;
  5995. var
  5996. extstring: String;
  5997. begin
  5998. Result := FALSE;
  5999. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6000. if glext_ExtensionSupported('GL_EXT_vertex_shader', extstring) then
  6001. begin
  6002. glBeginVertexShaderEXT := wglGetProcAddress('glBeginVertexShaderEXT');
  6003. if not Assigned(glBeginVertexShaderEXT) then Exit;
  6004. glEndVertexShaderEXT := wglGetProcAddress('glEndVertexShaderEXT');
  6005. if not Assigned(glEndVertexShaderEXT) then Exit;
  6006. glBindVertexShaderEXT := wglGetProcAddress('glBindVertexShaderEXT');
  6007. if not Assigned(glBindVertexShaderEXT) then Exit;
  6008. glGenVertexShadersEXT := wglGetProcAddress('glGenVertexShadersEXT');
  6009. if not Assigned(glGenVertexShadersEXT) then Exit;
  6010. glDeleteVertexShaderEXT := wglGetProcAddress('glDeleteVertexShaderEXT');
  6011. if not Assigned(glDeleteVertexShaderEXT) then Exit;
  6012. glShaderOp1EXT := wglGetProcAddress('glShaderOp1EXT');
  6013. if not Assigned(glShaderOp1EXT) then Exit;
  6014. glShaderOp2EXT := wglGetProcAddress('glShaderOp2EXT');
  6015. if not Assigned(glShaderOp2EXT) then Exit;
  6016. glShaderOp3EXT := wglGetProcAddress('glShaderOp3EXT');
  6017. if not Assigned(glShaderOp3EXT) then Exit;
  6018. glSwizzleEXT := wglGetProcAddress('glSwizzleEXT');
  6019. if not Assigned(glSwizzleEXT) then Exit;
  6020. glWriteMaskEXT := wglGetProcAddress('glWriteMaskEXT');
  6021. if not Assigned(glWriteMaskEXT) then Exit;
  6022. glInsertComponentEXT := wglGetProcAddress('glInsertComponentEXT');
  6023. if not Assigned(glInsertComponentEXT) then Exit;
  6024. glExtractComponentEXT := wglGetProcAddress('glExtractComponentEXT');
  6025. if not Assigned(glExtractComponentEXT) then Exit;
  6026. glGenSymbolsEXT := wglGetProcAddress('glGenSymbolsEXT');
  6027. if not Assigned(glGenSymbolsEXT) then Exit;
  6028. glSetInvariantEXT := wglGetProcAddress('glSetInvariantEXT');
  6029. if not Assigned(glSetInvariantEXT) then Exit;
  6030. glSetLocalConstantEXT := wglGetProcAddress('glSetLocalConstantEXT');
  6031. if not Assigned(glSetLocalConstantEXT) then Exit;
  6032. glVariantbvEXT := wglGetProcAddress('glVariantbvEXT');
  6033. if not Assigned(glVariantbvEXT) then Exit;
  6034. glVariantsvEXT := wglGetProcAddress('glVariantsvEXT');
  6035. if not Assigned(glVariantsvEXT) then Exit;
  6036. glVariantivEXT := wglGetProcAddress('glVariantivEXT');
  6037. if not Assigned(glVariantivEXT) then Exit;
  6038. glVariantfvEXT := wglGetProcAddress('glVariantfvEXT');
  6039. if not Assigned(glVariantfvEXT) then Exit;
  6040. glVariantdvEXT := wglGetProcAddress('glVariantdvEXT');
  6041. if not Assigned(glVariantdvEXT) then Exit;
  6042. glVariantubvEXT := wglGetProcAddress('glVariantubvEXT');
  6043. if not Assigned(glVariantubvEXT) then Exit;
  6044. glVariantusvEXT := wglGetProcAddress('glVariantusvEXT');
  6045. if not Assigned(glVariantusvEXT) then Exit;
  6046. glVariantuivEXT := wglGetProcAddress('glVariantuivEXT');
  6047. if not Assigned(glVariantuivEXT) then Exit;
  6048. glVariantPointerEXT := wglGetProcAddress('glVariantPointerEXT');
  6049. if not Assigned(glVariantPointerEXT) then Exit;
  6050. glEnableVariantClientStateEXT := wglGetProcAddress('glEnableVariantClientStateEXT');
  6051. if not Assigned(glEnableVariantClientStateEXT) then Exit;
  6052. glDisableVariantClientStateEXT := wglGetProcAddress('glDisableVariantClientStateEXT');
  6053. if not Assigned(glDisableVariantClientStateEXT) then Exit;
  6054. glBindLightParameterEXT := wglGetProcAddress('glBindLightParameterEXT');
  6055. if not Assigned(glBindLightParameterEXT) then Exit;
  6056. glBindMaterialParameterEXT := wglGetProcAddress('glBindMaterialParameterEXT');
  6057. if not Assigned(glBindMaterialParameterEXT) then Exit;
  6058. glBindTexGenParameterEXT := wglGetProcAddress('glBindTexGenParameterEXT');
  6059. if not Assigned(glBindTexGenParameterEXT) then Exit;
  6060. glBindTextureUnitParameterEXT := wglGetProcAddress('glBindTextureUnitParameterEXT');
  6061. if not Assigned(glBindTextureUnitParameterEXT) then Exit;
  6062. glBindParameterEXT := wglGetProcAddress('glBindParameterEXT');
  6063. if not Assigned(glBindParameterEXT) then Exit;
  6064. glIsVariantEnabledEXT := wglGetProcAddress('glIsVariantEnabledEXT');
  6065. if not Assigned(glIsVariantEnabledEXT) then Exit;
  6066. glGetVariantBooleanvEXT := wglGetProcAddress('glGetVariantBooleanvEXT');
  6067. if not Assigned(glGetVariantBooleanvEXT) then Exit;
  6068. glGetVariantIntegervEXT := wglGetProcAddress('glGetVariantIntegervEXT');
  6069. if not Assigned(glGetVariantIntegervEXT) then Exit;
  6070. glGetVariantFloatvEXT := wglGetProcAddress('glGetVariantFloatvEXT');
  6071. if not Assigned(glGetVariantFloatvEXT) then Exit;
  6072. glGetVariantPointervEXT := wglGetProcAddress('glGetVariantPointervEXT');
  6073. if not Assigned(glGetVariantPointervEXT) then Exit;
  6074. glGetInvariantBooleanvEXT := wglGetProcAddress('glGetInvariantBooleanvEXT');
  6075. if not Assigned(glGetInvariantBooleanvEXT) then Exit;
  6076. glGetInvariantIntegervEXT := wglGetProcAddress('glGetInvariantIntegervEXT');
  6077. if not Assigned(glGetInvariantIntegervEXT) then Exit;
  6078. glGetInvariantFloatvEXT := wglGetProcAddress('glGetInvariantFloatvEXT');
  6079. if not Assigned(glGetInvariantFloatvEXT) then Exit;
  6080. glGetLocalConstantBooleanvEXT := wglGetProcAddress('glGetLocalConstantBooleanvEXT');
  6081. if not Assigned(glGetLocalConstantBooleanvEXT) then Exit;
  6082. glGetLocalConstantIntegervEXT := wglGetProcAddress('glGetLocalConstantIntegervEXT');
  6083. if not Assigned(glGetLocalConstantIntegervEXT) then Exit;
  6084. glGetLocalConstantFloatvEXT := wglGetProcAddress('glGetLocalConstantFloatvEXT');
  6085. if not Assigned(glGetLocalConstantFloatvEXT) then Exit;
  6086. Result := TRUE;
  6087. end;
  6088. end;
  6089. function Load_GL_EXT_vertex_weighting: Boolean;
  6090. var
  6091. extstring: String;
  6092. begin
  6093. Result := FALSE;
  6094. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6095. if glext_ExtensionSupported('GL_EXT_vertex_weighting', extstring) then
  6096. begin
  6097. glVertexWeightfEXT := wglGetProcAddress('glVertexWeightfEXT');
  6098. if not Assigned(glVertexWeightfEXT) then Exit;
  6099. glVertexWeightfvEXT := wglGetProcAddress('glVertexWeightfvEXT');
  6100. if not Assigned(glVertexWeightfvEXT) then Exit;
  6101. glVertexWeightPointerEXT := wglGetProcAddress('glVertexWeightPointerEXT');
  6102. if not Assigned(glVertexWeightPointerEXT) then Exit;
  6103. Result := TRUE;
  6104. end;
  6105. end;
  6106. function Load_GL_HP_occlusion_test: Boolean;
  6107. var
  6108. extstring: String;
  6109. begin
  6110. Result := FALSE;
  6111. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6112. if glext_ExtensionSupported('GL_HP_occlusion_test', extstring) then
  6113. begin
  6114. Result := TRUE;
  6115. end;
  6116. end;
  6117. function Load_GL_NV_blend_square: Boolean;
  6118. var
  6119. extstring: String;
  6120. begin
  6121. Result := FALSE;
  6122. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6123. if glext_ExtensionSupported('GL_NV_blend_square', extstring) then
  6124. begin
  6125. Result := TRUE;
  6126. end;
  6127. end;
  6128. function Load_GL_NV_copy_depth_to_color: Boolean;
  6129. var
  6130. extstring: String;
  6131. begin
  6132. Result := FALSE;
  6133. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6134. if glext_ExtensionSupported('GL_NV_copy_depth_to_color', extstring) then
  6135. begin
  6136. Result := TRUE;
  6137. end;
  6138. end;
  6139. function Load_GL_NV_depth_clamp: Boolean;
  6140. var
  6141. extstring: String;
  6142. begin
  6143. Result := FALSE;
  6144. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6145. if glext_ExtensionSupported('GL_NV_depth_clamp', extstring) then
  6146. begin
  6147. Result := TRUE;
  6148. end;
  6149. end;
  6150. function Load_GL_NV_evaluators: Boolean;
  6151. var
  6152. extstring: String;
  6153. begin
  6154. Result := FALSE;
  6155. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6156. if glext_ExtensionSupported('GL_NV_evaluators', extstring) then
  6157. begin
  6158. glMapControlPointsNV := wglGetProcAddress('glMapControlPointsNV');
  6159. if not Assigned(glMapControlPointsNV) then Exit;
  6160. glMapParameterivNV := wglGetProcAddress('glMapParameterivNV');
  6161. if not Assigned(glMapParameterivNV) then Exit;
  6162. glMapParameterfvNV := wglGetProcAddress('glMapParameterfvNV');
  6163. if not Assigned(glMapParameterfvNV) then Exit;
  6164. glGetMapControlPointsNV := wglGetProcAddress('glGetMapControlPointsNV');
  6165. if not Assigned(glGetMapControlPointsNV) then Exit;
  6166. glGetMapParameterivNV := wglGetProcAddress('glGetMapParameterivNV');
  6167. if not Assigned(glGetMapParameterivNV) then Exit;
  6168. glGetMapParameterfvNV := wglGetProcAddress('glGetMapParameterfvNV');
  6169. if not Assigned(glGetMapParameterfvNV) then Exit;
  6170. glGetMapAttribParameterivNV := wglGetProcAddress('glGetMapAttribParameterivNV');
  6171. if not Assigned(glGetMapAttribParameterivNV) then Exit;
  6172. glGetMapAttribParameterfvNV := wglGetProcAddress('glGetMapAttribParameterfvNV');
  6173. if not Assigned(glGetMapAttribParameterfvNV) then Exit;
  6174. glEvalMapsNV := wglGetProcAddress('glEvalMapsNV');
  6175. if not Assigned(glEvalMapsNV) then Exit;
  6176. Result := TRUE;
  6177. end;
  6178. end;
  6179. function Load_GL_NV_fence: Boolean;
  6180. var
  6181. extstring: String;
  6182. begin
  6183. Result := FALSE;
  6184. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6185. if glext_ExtensionSupported('GL_NV_fence', extstring) then
  6186. begin
  6187. glGenFencesNV := wglGetProcAddress('glGenFencesNV');
  6188. if not Assigned(glGenFencesNV) then Exit;
  6189. glDeleteFencesNV := wglGetProcAddress('glDeleteFencesNV');
  6190. if not Assigned(glDeleteFencesNV) then Exit;
  6191. glSetFenceNV := wglGetProcAddress('glSetFenceNV');
  6192. if not Assigned(glSetFenceNV) then Exit;
  6193. glTestFenceNV := wglGetProcAddress('glTestFenceNV');
  6194. if not Assigned(glTestFenceNV) then Exit;
  6195. glFinishFenceNV := wglGetProcAddress('glFinishFenceNV');
  6196. if not Assigned(glFinishFenceNV) then Exit;
  6197. glIsFenceNV := wglGetProcAddress('glIsFenceNV');
  6198. if not Assigned(glIsFenceNV) then Exit;
  6199. glGetFenceivNV := wglGetProcAddress('glGetFenceivNV');
  6200. if not Assigned(glGetFenceivNV) then Exit;
  6201. Result := TRUE;
  6202. end;
  6203. end;
  6204. function Load_GL_NV_fog_distance: Boolean;
  6205. var
  6206. extstring: String;
  6207. begin
  6208. Result := FALSE;
  6209. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6210. if glext_ExtensionSupported('GL_NV_fog_distance', extstring) then
  6211. begin
  6212. Result := TRUE;
  6213. end;
  6214. end;
  6215. function Load_GL_NV_light_max_exponent: Boolean;
  6216. var
  6217. extstring: String;
  6218. begin
  6219. Result := FALSE;
  6220. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6221. if glext_ExtensionSupported('GL_NV_light_max_exponent', extstring) then
  6222. begin
  6223. Result := TRUE;
  6224. end;
  6225. end;
  6226. function Load_GL_NV_multisample_filter_hint: Boolean;
  6227. var
  6228. extstring: String;
  6229. begin
  6230. Result := FALSE;
  6231. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6232. if glext_ExtensionSupported('GL_NV_multisample_filter_hint', extstring) then
  6233. begin
  6234. Result := TRUE;
  6235. end;
  6236. end;
  6237. function Load_GL_NV_occlusion_query: Boolean;
  6238. var
  6239. extstring: String;
  6240. begin
  6241. Result := FALSE;
  6242. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6243. if glext_ExtensionSupported('GL_NV_occlusion_query', extstring) then
  6244. begin
  6245. glGenOcclusionQueriesNV := wglGetProcAddress('glGenOcclusionQueriesNV');
  6246. if not Assigned(glGenOcclusionQueriesNV) then Exit;
  6247. glDeleteOcclusionQueriesNV := wglGetProcAddress('glDeleteOcclusionQueriesNV');
  6248. if not Assigned(glDeleteOcclusionQueriesNV) then Exit;
  6249. glIsOcclusionQueryNV := wglGetProcAddress('glIsOcclusionQueryNV');
  6250. if not Assigned(glIsOcclusionQueryNV) then Exit;
  6251. glBeginOcclusionQueryNV := wglGetProcAddress('glBeginOcclusionQueryNV');
  6252. if not Assigned(glBeginOcclusionQueryNV) then Exit;
  6253. glEndOcclusionQueryNV := wglGetProcAddress('glEndOcclusionQueryNV');
  6254. if not Assigned(glEndOcclusionQueryNV) then Exit;
  6255. glGetOcclusionQueryivNV := wglGetProcAddress('glGetOcclusionQueryivNV');
  6256. if not Assigned(glGetOcclusionQueryivNV) then Exit;
  6257. glGetOcclusionQueryuivNV := wglGetProcAddress('glGetOcclusionQueryuivNV');
  6258. if not Assigned(glGetOcclusionQueryuivNV) then Exit;
  6259. Result := TRUE;
  6260. end;
  6261. end;
  6262. function Load_GL_NV_packed_depth_stencil: Boolean;
  6263. var
  6264. extstring: String;
  6265. begin
  6266. Result := FALSE;
  6267. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6268. if glext_ExtensionSupported('GL_NV_packed_depth_stencil', extstring) then
  6269. begin
  6270. Result := TRUE;
  6271. end;
  6272. end;
  6273. function Load_GL_NV_point_sprite: Boolean;
  6274. var
  6275. extstring: String;
  6276. begin
  6277. Result := FALSE;
  6278. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6279. if glext_ExtensionSupported('GL_NV_point_sprite', extstring) then
  6280. begin
  6281. glPointParameteriNV := wglGetProcAddress('glPointParameteriNV');
  6282. if not Assigned(glPointParameteriNV) then Exit;
  6283. glPointParameterivNV := wglGetProcAddress('glPointParameterivNV');
  6284. if not Assigned(glPointParameterivNV) then Exit;
  6285. Result := TRUE;
  6286. end;
  6287. end;
  6288. function Load_GL_NV_register_combiners: Boolean;
  6289. var
  6290. extstring: String;
  6291. begin
  6292. Result := FALSE;
  6293. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6294. if glext_ExtensionSupported('GL_NV_register_combiners', extstring) then
  6295. begin
  6296. glCombinerParameterfvNV := wglGetProcAddress('glCombinerParameterfvNV');
  6297. if not Assigned(glCombinerParameterfvNV) then Exit;
  6298. glCombinerParameterivNV := wglGetProcAddress('glCombinerParameterivNV');
  6299. if not Assigned(glCombinerParameterivNV) then Exit;
  6300. glCombinerParameterfNV := wglGetProcAddress('glCombinerParameterfNV');
  6301. if not Assigned(glCombinerParameterfNV) then Exit;
  6302. glCombinerParameteriNV := wglGetProcAddress('glCombinerParameteriNV');
  6303. if not Assigned(glCombinerParameteriNV) then Exit;
  6304. glCombinerInputNV := wglGetProcAddress('glCombinerInputNV');
  6305. if not Assigned(glCombinerInputNV) then Exit;
  6306. glCombinerOutputNV := wglGetProcAddress('glCombinerOutputNV');
  6307. if not Assigned(glCombinerOutputNV) then Exit;
  6308. glFinalCombinerInputNV := wglGetProcAddress('glFinalCombinerInputNV');
  6309. if not Assigned(glFinalCombinerInputNV) then Exit;
  6310. glGetCombinerInputParameterfvNV := wglGetProcAddress('glGetCombinerInputParameterfvNV');
  6311. if not Assigned(glGetCombinerInputParameterfvNV) then Exit;
  6312. glGetCombinerInputParameterivNV := wglGetProcAddress('glGetCombinerInputParameterivNV');
  6313. if not Assigned(glGetCombinerInputParameterivNV) then Exit;
  6314. glGetCombinerOutputParameterfvNV := wglGetProcAddress('glGetCombinerOutputParameterfvNV');
  6315. if not Assigned(glGetCombinerOutputParameterfvNV) then Exit;
  6316. glGetCombinerOutputParameterivNV := wglGetProcAddress('glGetCombinerOutputParameterivNV');
  6317. if not Assigned(glGetCombinerOutputParameterivNV) then Exit;
  6318. glGetFinalCombinerInputParameterfvNV := wglGetProcAddress('glGetFinalCombinerInputParameterfvNV');
  6319. if not Assigned(glGetFinalCombinerInputParameterfvNV) then Exit;
  6320. glGetFinalCombinerInputParameterivNV := wglGetProcAddress('glGetFinalCombinerInputParameterivNV');
  6321. if not Assigned(glGetFinalCombinerInputParameterivNV) then Exit;
  6322. Result := TRUE;
  6323. end;
  6324. end;
  6325. function Load_GL_NV_register_combiners2: Boolean;
  6326. var
  6327. extstring: String;
  6328. begin
  6329. Result := FALSE;
  6330. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6331. if glext_ExtensionSupported('GL_NV_register_combiners2', extstring) then
  6332. begin
  6333. glCombinerStageParameterfvNV := wglGetProcAddress('glCombinerStageParameterfvNV');
  6334. if not Assigned(glCombinerStageParameterfvNV) then Exit;
  6335. glGetCombinerStageParameterfvNV := wglGetProcAddress('glGetCombinerStageParameterfvNV');
  6336. if not Assigned(glGetCombinerStageParameterfvNV) then Exit;
  6337. Result := TRUE;
  6338. end;
  6339. end;
  6340. function Load_GL_NV_texgen_emboss: Boolean;
  6341. var
  6342. extstring: String;
  6343. begin
  6344. Result := FALSE;
  6345. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6346. if glext_ExtensionSupported('GL_NV_texgen_emboss', extstring) then
  6347. begin
  6348. Result := TRUE;
  6349. end;
  6350. end;
  6351. function Load_GL_NV_texgen_reflection: Boolean;
  6352. var
  6353. extstring: String;
  6354. begin
  6355. Result := FALSE;
  6356. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6357. if glext_ExtensionSupported('GL_NV_texgen_reflection', extstring) then
  6358. begin
  6359. Result := TRUE;
  6360. end;
  6361. end;
  6362. function Load_GL_NV_texture_compression_vtc: Boolean;
  6363. var
  6364. extstring: String;
  6365. begin
  6366. Result := FALSE;
  6367. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6368. if glext_ExtensionSupported('GL_NV_texture_compression_vtc', extstring) then
  6369. begin
  6370. Result := TRUE;
  6371. end;
  6372. end;
  6373. function Load_GL_NV_texture_env_combine4: Boolean;
  6374. var
  6375. extstring: String;
  6376. begin
  6377. Result := FALSE;
  6378. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6379. if glext_ExtensionSupported('GL_NV_texture_env_combine4', extstring) then
  6380. begin
  6381. Result := TRUE;
  6382. end;
  6383. end;
  6384. function Load_GL_NV_texture_rectangle: Boolean;
  6385. var
  6386. extstring: String;
  6387. begin
  6388. Result := FALSE;
  6389. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6390. if glext_ExtensionSupported('GL_NV_texture_rectangle', extstring) then
  6391. begin
  6392. Result := TRUE;
  6393. end;
  6394. end;
  6395. function Load_GL_NV_texture_shader: Boolean;
  6396. var
  6397. extstring: String;
  6398. begin
  6399. Result := FALSE;
  6400. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6401. if glext_ExtensionSupported('GL_NV_texture_shader', extstring) then
  6402. begin
  6403. Result := TRUE;
  6404. end;
  6405. end;
  6406. function Load_GL_NV_texture_shader2: Boolean;
  6407. var
  6408. extstring: String;
  6409. begin
  6410. Result := FALSE;
  6411. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6412. if glext_ExtensionSupported('GL_NV_texture_shader2', extstring) then
  6413. begin
  6414. Result := TRUE;
  6415. end;
  6416. end;
  6417. function Load_GL_NV_texture_shader3: Boolean;
  6418. var
  6419. extstring: String;
  6420. begin
  6421. Result := FALSE;
  6422. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6423. if glext_ExtensionSupported('GL_NV_texture_shader3', extstring) then
  6424. begin
  6425. Result := TRUE;
  6426. end;
  6427. end;
  6428. function Load_GL_NV_vertex_array_range: Boolean;
  6429. var
  6430. extstring: String;
  6431. begin
  6432. Result := FALSE;
  6433. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6434. if glext_ExtensionSupported('GL_NV_vertex_array_range', extstring) then
  6435. begin
  6436. glVertexArrayRangeNV := wglGetProcAddress('glVertexArrayRangeNV');
  6437. if not Assigned(glVertexArrayRangeNV) then Exit;
  6438. glFlushVertexArrayRangeNV := wglGetProcAddress('glFlushVertexArrayRangeNV');
  6439. if not Assigned(glFlushVertexArrayRangeNV) then Exit;
  6440. {$IFDEF Windows}
  6441. wglAllocateMemoryNV := wglGetProcAddress('wglAllocateMemoryNV');
  6442. if not Assigned(wglAllocateMemoryNV) then Exit;
  6443. wglFreeMemoryNV := wglGetProcAddress('wglFreeMemoryNV');
  6444. if not Assigned(wglFreeMemoryNV) then Exit;
  6445. {$ENDIF}
  6446. Result := TRUE;
  6447. end;
  6448. end;
  6449. function Load_GL_NV_vertex_array_range2: Boolean;
  6450. var
  6451. extstring: String;
  6452. begin
  6453. Result := FALSE;
  6454. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6455. if glext_ExtensionSupported('GL_NV_vertex_array_range2', extstring) then
  6456. begin
  6457. Result := TRUE;
  6458. end;
  6459. end;
  6460. function Load_GL_NV_vertex_program: Boolean;
  6461. var
  6462. extstring: String;
  6463. begin
  6464. Result := FALSE;
  6465. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6466. if glext_ExtensionSupported('GL_NV_vertex_program', extstring) then
  6467. begin
  6468. glBindProgramNV := wglGetProcAddress('glBindProgramNV');
  6469. if not Assigned(glBindProgramNV) then Exit;
  6470. glDeleteProgramsNV := wglGetProcAddress('glDeleteProgramsNV');
  6471. if not Assigned(glDeleteProgramsNV) then Exit;
  6472. glExecuteProgramNV := wglGetProcAddress('glExecuteProgramNV');
  6473. if not Assigned(glExecuteProgramNV) then Exit;
  6474. glGenProgramsNV := wglGetProcAddress('glGenProgramsNV');
  6475. if not Assigned(glGenProgramsNV) then Exit;
  6476. glAreProgramsResidentNV := wglGetProcAddress('glAreProgramsResidentNV');
  6477. if not Assigned(glAreProgramsResidentNV) then Exit;
  6478. glRequestResidentProgramsNV := wglGetProcAddress('glRequestResidentProgramsNV');
  6479. if not Assigned(glRequestResidentProgramsNV) then Exit;
  6480. glGetProgramParameterfvNV := wglGetProcAddress('glGetProgramParameterfvNV');
  6481. if not Assigned(glGetProgramParameterfvNV) then Exit;
  6482. glGetProgramParameterdvNV := wglGetProcAddress('glGetProgramParameterdvNV');
  6483. if not Assigned(glGetProgramParameterdvNV) then Exit;
  6484. glGetProgramivNV := wglGetProcAddress('glGetProgramivNV');
  6485. if not Assigned(glGetProgramivNV) then Exit;
  6486. glGetProgramStringNV := wglGetProcAddress('glGetProgramStringNV');
  6487. if not Assigned(glGetProgramStringNV) then Exit;
  6488. glGetTrackMatrixivNV := wglGetProcAddress('glGetTrackMatrixivNV');
  6489. if not Assigned(glGetTrackMatrixivNV) then Exit;
  6490. glGetVertexAttribdvNV := wglGetProcAddress('glGetVertexAttribdvNV');
  6491. if not Assigned(glGetVertexAttribdvNV) then Exit;
  6492. glGetVertexAttribfvNV := wglGetProcAddress('glGetVertexAttribfvNV');
  6493. if not Assigned(glGetVertexAttribfvNV) then Exit;
  6494. glGetVertexAttribivNV := wglGetProcAddress('glGetVertexAttribivNV');
  6495. if not Assigned(glGetVertexAttribivNV) then Exit;
  6496. glGetVertexAttribPointervNV := wglGetProcAddress('glGetVertexAttribPointervNV');
  6497. if not Assigned(glGetVertexAttribPointervNV) then Exit;
  6498. glIsProgramNV := wglGetProcAddress('glIsProgramNV');
  6499. if not Assigned(glIsProgramNV) then Exit;
  6500. glLoadProgramNV := wglGetProcAddress('glLoadProgramNV');
  6501. if not Assigned(glLoadProgramNV) then Exit;
  6502. glProgramParameter4fNV := wglGetProcAddress('glProgramParameter4fNV');
  6503. if not Assigned(glProgramParameter4fNV) then Exit;
  6504. glProgramParameter4fvNV := wglGetProcAddress('glProgramParameter4fvNV');
  6505. if not Assigned(glProgramParameter4fvNV) then Exit;
  6506. glProgramParameters4dvNV := wglGetProcAddress('glProgramParameters4dvNV');
  6507. if not Assigned(glProgramParameters4dvNV) then Exit;
  6508. glProgramParameters4fvNV := wglGetProcAddress('glProgramParameters4fvNV');
  6509. if not Assigned(glProgramParameters4fvNV) then Exit;
  6510. glTrackMatrixNV := wglGetProcAddress('glTrackMatrixNV');
  6511. if not Assigned(glTrackMatrixNV) then Exit;
  6512. glVertexAttribPointerNV := wglGetProcAddress('glVertexAttribPointerNV');
  6513. if not Assigned(glVertexAttribPointerNV) then Exit;
  6514. glVertexAttrib1sNV := wglGetProcAddress('glVertexAttrib1sNV');
  6515. if not Assigned(glVertexAttrib1sNV) then Exit;
  6516. glVertexAttrib1fNV := wglGetProcAddress('glVertexAttrib1fNV');
  6517. if not Assigned(glVertexAttrib1fNV) then Exit;
  6518. glVertexAttrib1dNV := wglGetProcAddress('glVertexAttrib1dNV');
  6519. if not Assigned(glVertexAttrib1dNV) then Exit;
  6520. glVertexAttrib2sNV := wglGetProcAddress('glVertexAttrib2sNV');
  6521. if not Assigned(glVertexAttrib2sNV) then Exit;
  6522. glVertexAttrib2fNV := wglGetProcAddress('glVertexAttrib2fNV');
  6523. if not Assigned(glVertexAttrib2fNV) then Exit;
  6524. glVertexAttrib2dNV := wglGetProcAddress('glVertexAttrib2dNV');
  6525. if not Assigned(glVertexAttrib2dNV) then Exit;
  6526. glVertexAttrib3sNV := wglGetProcAddress('glVertexAttrib3sNV');
  6527. if not Assigned(glVertexAttrib3sNV) then Exit;
  6528. glVertexAttrib3fNV := wglGetProcAddress('glVertexAttrib3fNV');
  6529. if not Assigned(glVertexAttrib3fNV) then Exit;
  6530. glVertexAttrib3dNV := wglGetProcAddress('glVertexAttrib3dNV');
  6531. if not Assigned(glVertexAttrib3dNV) then Exit;
  6532. glVertexAttrib4sNV := wglGetProcAddress('glVertexAttrib4sNV');
  6533. if not Assigned(glVertexAttrib4sNV) then Exit;
  6534. glVertexAttrib4fNV := wglGetProcAddress('glVertexAttrib4fNV');
  6535. if not Assigned(glVertexAttrib4fNV) then Exit;
  6536. glVertexAttrib4dNV := wglGetProcAddress('glVertexAttrib4dNV');
  6537. if not Assigned(glVertexAttrib4dNV) then Exit;
  6538. glVertexAttrib4ubNV := wglGetProcAddress('glVertexAttrib4ubNV');
  6539. if not Assigned(glVertexAttrib4ubNV) then Exit;
  6540. glVertexAttrib1svNV := wglGetProcAddress('glVertexAttrib1svNV');
  6541. if not Assigned(glVertexAttrib1svNV) then Exit;
  6542. glVertexAttrib1fvNV := wglGetProcAddress('glVertexAttrib1fvNV');
  6543. if not Assigned(glVertexAttrib1fvNV) then Exit;
  6544. glVertexAttrib1dvNV := wglGetProcAddress('glVertexAttrib1dvNV');
  6545. if not Assigned(glVertexAttrib1dvNV) then Exit;
  6546. glVertexAttrib2svNV := wglGetProcAddress('glVertexAttrib2svNV');
  6547. if not Assigned(glVertexAttrib2svNV) then Exit;
  6548. glVertexAttrib2fvNV := wglGetProcAddress('glVertexAttrib2fvNV');
  6549. if not Assigned(glVertexAttrib2fvNV) then Exit;
  6550. glVertexAttrib2dvNV := wglGetProcAddress('glVertexAttrib2dvNV');
  6551. if not Assigned(glVertexAttrib2dvNV) then Exit;
  6552. glVertexAttrib3svNV := wglGetProcAddress('glVertexAttrib3svNV');
  6553. if not Assigned(glVertexAttrib3svNV) then Exit;
  6554. glVertexAttrib3fvNV := wglGetProcAddress('glVertexAttrib3fvNV');
  6555. if not Assigned(glVertexAttrib3fvNV) then Exit;
  6556. glVertexAttrib3dvNV := wglGetProcAddress('glVertexAttrib3dvNV');
  6557. if not Assigned(glVertexAttrib3dvNV) then Exit;
  6558. glVertexAttrib4svNV := wglGetProcAddress('glVertexAttrib4svNV');
  6559. if not Assigned(glVertexAttrib4svNV) then Exit;
  6560. glVertexAttrib4fvNV := wglGetProcAddress('glVertexAttrib4fvNV');
  6561. if not Assigned(glVertexAttrib4fvNV) then Exit;
  6562. glVertexAttrib4dvNV := wglGetProcAddress('glVertexAttrib4dvNV');
  6563. if not Assigned(glVertexAttrib4dvNV) then Exit;
  6564. glVertexAttrib4ubvNV := wglGetProcAddress('glVertexAttrib4ubvNV');
  6565. if not Assigned(glVertexAttrib4ubvNV) then Exit;
  6566. glVertexAttribs1svNV := wglGetProcAddress('glVertexAttribs1svNV');
  6567. if not Assigned(glVertexAttribs1svNV) then Exit;
  6568. glVertexAttribs1fvNV := wglGetProcAddress('glVertexAttribs1fvNV');
  6569. if not Assigned(glVertexAttribs1fvNV) then Exit;
  6570. glVertexAttribs1dvNV := wglGetProcAddress('glVertexAttribs1dvNV');
  6571. if not Assigned(glVertexAttribs1dvNV) then Exit;
  6572. glVertexAttribs2svNV := wglGetProcAddress('glVertexAttribs2svNV');
  6573. if not Assigned(glVertexAttribs2svNV) then Exit;
  6574. glVertexAttribs2fvNV := wglGetProcAddress('glVertexAttribs2fvNV');
  6575. if not Assigned(glVertexAttribs2fvNV) then Exit;
  6576. glVertexAttribs2dvNV := wglGetProcAddress('glVertexAttribs2dvNV');
  6577. if not Assigned(glVertexAttribs2dvNV) then Exit;
  6578. glVertexAttribs3svNV := wglGetProcAddress('glVertexAttribs3svNV');
  6579. if not Assigned(glVertexAttribs3svNV) then Exit;
  6580. glVertexAttribs3fvNV := wglGetProcAddress('glVertexAttribs3fvNV');
  6581. if not Assigned(glVertexAttribs3fvNV) then Exit;
  6582. glVertexAttribs3dvNV := wglGetProcAddress('glVertexAttribs3dvNV');
  6583. if not Assigned(glVertexAttribs3dvNV) then Exit;
  6584. glVertexAttribs4svNV := wglGetProcAddress('glVertexAttribs4svNV');
  6585. if not Assigned(glVertexAttribs4svNV) then Exit;
  6586. glVertexAttribs4fvNV := wglGetProcAddress('glVertexAttribs4fvNV');
  6587. if not Assigned(glVertexAttribs4fvNV) then Exit;
  6588. glVertexAttribs4dvNV := wglGetProcAddress('glVertexAttribs4dvNV');
  6589. if not Assigned(glVertexAttribs4dvNV) then Exit;
  6590. glVertexAttribs4ubvNV := wglGetProcAddress('glVertexAttribs4ubvNV');
  6591. if not Assigned(glVertexAttribs4ubvNV) then Exit;
  6592. Result := TRUE;
  6593. end;
  6594. end;
  6595. function Load_GL_NV_vertex_program1_1: Boolean;
  6596. var
  6597. extstring: String;
  6598. begin
  6599. Result := FALSE;
  6600. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6601. if glext_ExtensionSupported('GL_NV_vertex_program1_1', extstring) then
  6602. begin
  6603. Result := TRUE;
  6604. end;
  6605. end;
  6606. function Load_GL_ATI_element_array: Boolean;
  6607. var
  6608. extstring: String;
  6609. begin
  6610. Result := FALSE;
  6611. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6612. if glext_ExtensionSupported('GL_ATI_element_array', extstring) then
  6613. begin
  6614. glElementPointerATI := wglGetProcAddress('glElementPointerATI');
  6615. if not Assigned(glElementPointerATI) then Exit;
  6616. glDrawElementArrayATI := wglGetProcAddress('glDrawElementArrayATI');
  6617. if not Assigned(glDrawElementArrayATI) then Exit;
  6618. glDrawRangeElementArrayATI := wglGetProcAddress('glDrawRangeElementArrayATI');
  6619. if not Assigned(glDrawRangeElementArrayATI) then Exit;
  6620. Result := TRUE;
  6621. end;
  6622. end;
  6623. function Load_GL_ATI_envmap_bumpmap: Boolean;
  6624. var
  6625. extstring: String;
  6626. begin
  6627. Result := FALSE;
  6628. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6629. if glext_ExtensionSupported('GL_ATI_envmap_bumpmap', extstring) then
  6630. begin
  6631. glTexBumpParameterivATI := wglGetProcAddress('glTexBumpParameterivATI');
  6632. if not Assigned(glTexBumpParameterivATI) then Exit;
  6633. glTexBumpParameterfvATI := wglGetProcAddress('glTexBumpParameterfvATI');
  6634. if not Assigned(glTexBumpParameterfvATI) then Exit;
  6635. glGetTexBumpParameterivATI := wglGetProcAddress('glGetTexBumpParameterivATI');
  6636. if not Assigned(glGetTexBumpParameterivATI) then Exit;
  6637. glGetTexBumpParameterfvATI := wglGetProcAddress('glGetTexBumpParameterfvATI');
  6638. if not Assigned(glGetTexBumpParameterfvATI) then Exit;
  6639. Result := TRUE;
  6640. end;
  6641. end;
  6642. function Load_GL_ATI_fragment_shader: Boolean;
  6643. var
  6644. extstring: String;
  6645. begin
  6646. Result := FALSE;
  6647. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6648. if glext_ExtensionSupported('GL_ATI_fragment_shader', extstring) then
  6649. begin
  6650. glGenFragmentShadersATI := wglGetProcAddress('glGenFragmentShadersATI');
  6651. if not Assigned(glGenFragmentShadersATI) then Exit;
  6652. glBindFragmentShaderATI := wglGetProcAddress('glBindFragmentShaderATI');
  6653. if not Assigned(glBindFragmentShaderATI) then Exit;
  6654. glDeleteFragmentShaderATI := wglGetProcAddress('glDeleteFragmentShaderATI');
  6655. if not Assigned(glDeleteFragmentShaderATI) then Exit;
  6656. glBeginFragmentShaderATI := wglGetProcAddress('glBeginFragmentShaderATI');
  6657. if not Assigned(glBeginFragmentShaderATI) then Exit;
  6658. glEndFragmentShaderATI := wglGetProcAddress('glEndFragmentShaderATI');
  6659. if not Assigned(glEndFragmentShaderATI) then Exit;
  6660. glPassTexCoordATI := wglGetProcAddress('glPassTexCoordATI');
  6661. if not Assigned(glPassTexCoordATI) then Exit;
  6662. glSampleMapATI := wglGetProcAddress('glSampleMapATI');
  6663. if not Assigned(glSampleMapATI) then Exit;
  6664. glColorFragmentOp1ATI := wglGetProcAddress('glColorFragmentOp1ATI');
  6665. if not Assigned(glColorFragmentOp1ATI) then Exit;
  6666. glColorFragmentOp2ATI := wglGetProcAddress('glColorFragmentOp2ATI');
  6667. if not Assigned(glColorFragmentOp2ATI) then Exit;
  6668. glColorFragmentOp3ATI := wglGetProcAddress('glColorFragmentOp3ATI');
  6669. if not Assigned(glColorFragmentOp3ATI) then Exit;
  6670. glAlphaFragmentOp1ATI := wglGetProcAddress('glAlphaFragmentOp1ATI');
  6671. if not Assigned(glAlphaFragmentOp1ATI) then Exit;
  6672. glAlphaFragmentOp2ATI := wglGetProcAddress('glAlphaFragmentOp2ATI');
  6673. if not Assigned(glAlphaFragmentOp2ATI) then Exit;
  6674. glAlphaFragmentOp3ATI := wglGetProcAddress('glAlphaFragmentOp3ATI');
  6675. if not Assigned(glAlphaFragmentOp3ATI) then Exit;
  6676. glSetFragmentShaderConstantATI := wglGetProcAddress('glSetFragmentShaderConstantATI');
  6677. if not Assigned(glSetFragmentShaderConstantATI) then Exit;
  6678. Result := TRUE;
  6679. end;
  6680. end;
  6681. function Load_GL_ATI_pn_triangles: Boolean;
  6682. var
  6683. extstring: String;
  6684. begin
  6685. Result := FALSE;
  6686. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6687. if glext_ExtensionSupported('GL_ATI_pn_triangles', extstring) then
  6688. begin
  6689. glPNTrianglesiATI := wglGetProcAddress('glPNTrianglesiATI');
  6690. if not Assigned(glPNTrianglesiATI) then Exit;
  6691. glPNTrianglesfATI := wglGetProcAddress('glPNTrianglesfATI');
  6692. if not Assigned(glPNTrianglesfATI) then Exit;
  6693. Result := TRUE;
  6694. end;
  6695. end;
  6696. function Load_GL_ATI_texture_mirror_once: Boolean;
  6697. var
  6698. extstring: String;
  6699. begin
  6700. Result := FALSE;
  6701. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6702. if glext_ExtensionSupported('GL_ATI_texture_mirror_once', extstring) then
  6703. begin
  6704. Result := TRUE;
  6705. end;
  6706. end;
  6707. function Load_GL_ATI_vertex_array_object: Boolean;
  6708. var
  6709. extstring: String;
  6710. begin
  6711. Result := FALSE;
  6712. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6713. if glext_ExtensionSupported('GL_ATI_vertex_array_object', extstring) then
  6714. begin
  6715. glNewObjectBufferATI := wglGetProcAddress('glNewObjectBufferATI');
  6716. if not Assigned(glNewObjectBufferATI) then Exit;
  6717. glIsObjectBufferATI := wglGetProcAddress('glIsObjectBufferATI');
  6718. if not Assigned(glIsObjectBufferATI) then Exit;
  6719. glUpdateObjectBufferATI := wglGetProcAddress('glUpdateObjectBufferATI');
  6720. if not Assigned(glUpdateObjectBufferATI) then Exit;
  6721. glGetObjectBufferfvATI := wglGetProcAddress('glGetObjectBufferfvATI');
  6722. if not Assigned(glGetObjectBufferfvATI) then Exit;
  6723. glGetObjectBufferivATI := wglGetProcAddress('glGetObjectBufferivATI');
  6724. if not Assigned(glGetObjectBufferivATI) then Exit;
  6725. glDeleteObjectBufferATI := wglGetProcAddress('glDeleteObjectBufferATI');
  6726. if not Assigned(glDeleteObjectBufferATI) then Exit;
  6727. glArrayObjectATI := wglGetProcAddress('glArrayObjectATI');
  6728. if not Assigned(glArrayObjectATI) then Exit;
  6729. glGetArrayObjectfvATI := wglGetProcAddress('glGetArrayObjectfvATI');
  6730. if not Assigned(glGetArrayObjectfvATI) then Exit;
  6731. glGetArrayObjectivATI := wglGetProcAddress('glGetArrayObjectivATI');
  6732. if not Assigned(glGetArrayObjectivATI) then Exit;
  6733. glVariantArrayObjectATI := wglGetProcAddress('glVariantArrayObjectATI');
  6734. if not Assigned(glVariantArrayObjectATI) then Exit;
  6735. glGetVariantArrayObjectfvATI := wglGetProcAddress('glGetVariantArrayObjectfvATI');
  6736. if not Assigned(glGetVariantArrayObjectfvATI) then Exit;
  6737. glGetVariantArrayObjectivATI := wglGetProcAddress('glGetVariantArrayObjectivATI');
  6738. if not Assigned(glGetVariantArrayObjectivATI) then Exit;
  6739. Result := TRUE;
  6740. end;
  6741. end;
  6742. function Load_GL_ATI_vertex_streams: Boolean;
  6743. var
  6744. extstring: String;
  6745. begin
  6746. Result := FALSE;
  6747. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6748. if glext_ExtensionSupported('GL_ATI_vertex_streams', extstring) then
  6749. begin
  6750. glVertexStream1s := wglGetProcAddress('glVertexStream1s');
  6751. if not Assigned(glVertexStream1s) then Exit;
  6752. glVertexStream1i := wglGetProcAddress('glVertexStream1i');
  6753. if not Assigned(glVertexStream1i) then Exit;
  6754. glVertexStream1f := wglGetProcAddress('glVertexStream1f');
  6755. if not Assigned(glVertexStream1f) then Exit;
  6756. glVertexStream1d := wglGetProcAddress('glVertexStream1d');
  6757. if not Assigned(glVertexStream1d) then Exit;
  6758. glVertexStream1sv := wglGetProcAddress('glVertexStream1sv');
  6759. if not Assigned(glVertexStream1sv) then Exit;
  6760. glVertexStream1iv := wglGetProcAddress('glVertexStream1iv');
  6761. if not Assigned(glVertexStream1iv) then Exit;
  6762. glVertexStream1fv := wglGetProcAddress('glVertexStream1fv');
  6763. if not Assigned(glVertexStream1fv) then Exit;
  6764. glVertexStream1dv := wglGetProcAddress('glVertexStream1dv');
  6765. if not Assigned(glVertexStream1dv) then Exit;
  6766. glVertexStream2s := wglGetProcAddress('glVertexStream2s');
  6767. if not Assigned(glVertexStream2s) then Exit;
  6768. glVertexStream2i := wglGetProcAddress('glVertexStream2i');
  6769. if not Assigned(glVertexStream2i) then Exit;
  6770. glVertexStream2f := wglGetProcAddress('glVertexStream2f');
  6771. if not Assigned(glVertexStream2f) then Exit;
  6772. glVertexStream2d := wglGetProcAddress('glVertexStream2d');
  6773. if not Assigned(glVertexStream2d) then Exit;
  6774. glVertexStream2sv := wglGetProcAddress('glVertexStream2sv');
  6775. if not Assigned(glVertexStream2sv) then Exit;
  6776. glVertexStream2iv := wglGetProcAddress('glVertexStream2iv');
  6777. if not Assigned(glVertexStream2iv) then Exit;
  6778. glVertexStream2fv := wglGetProcAddress('glVertexStream2fv');
  6779. if not Assigned(glVertexStream2fv) then Exit;
  6780. glVertexStream2dv := wglGetProcAddress('glVertexStream2dv');
  6781. if not Assigned(glVertexStream2dv) then Exit;
  6782. glVertexStream3s := wglGetProcAddress('glVertexStream3s');
  6783. if not Assigned(glVertexStream3s) then Exit;
  6784. glVertexStream3i := wglGetProcAddress('glVertexStream3i');
  6785. if not Assigned(glVertexStream3i) then Exit;
  6786. glVertexStream3f := wglGetProcAddress('glVertexStream3f');
  6787. if not Assigned(glVertexStream3f) then Exit;
  6788. glVertexStream3d := wglGetProcAddress('glVertexStream3d');
  6789. if not Assigned(glVertexStream3d) then Exit;
  6790. glVertexStream3sv := wglGetProcAddress('glVertexStream3sv');
  6791. if not Assigned(glVertexStream3sv) then Exit;
  6792. glVertexStream3iv := wglGetProcAddress('glVertexStream3iv');
  6793. if not Assigned(glVertexStream3iv) then Exit;
  6794. glVertexStream3fv := wglGetProcAddress('glVertexStream3fv');
  6795. if not Assigned(glVertexStream3fv) then Exit;
  6796. glVertexStream3dv := wglGetProcAddress('glVertexStream3dv');
  6797. if not Assigned(glVertexStream3dv) then Exit;
  6798. glVertexStream4s := wglGetProcAddress('glVertexStream4s');
  6799. if not Assigned(glVertexStream4s) then Exit;
  6800. glVertexStream4i := wglGetProcAddress('glVertexStream4i');
  6801. if not Assigned(glVertexStream4i) then Exit;
  6802. glVertexStream4f := wglGetProcAddress('glVertexStream4f');
  6803. if not Assigned(glVertexStream4f) then Exit;
  6804. glVertexStream4d := wglGetProcAddress('glVertexStream4d');
  6805. if not Assigned(glVertexStream4d) then Exit;
  6806. glVertexStream4sv := wglGetProcAddress('glVertexStream4sv');
  6807. if not Assigned(glVertexStream4sv) then Exit;
  6808. glVertexStream4iv := wglGetProcAddress('glVertexStream4iv');
  6809. if not Assigned(glVertexStream4iv) then Exit;
  6810. glVertexStream4fv := wglGetProcAddress('glVertexStream4fv');
  6811. if not Assigned(glVertexStream4fv) then Exit;
  6812. glVertexStream4dv := wglGetProcAddress('glVertexStream4dv');
  6813. if not Assigned(glVertexStream4dv) then Exit;
  6814. glNormalStream3b := wglGetProcAddress('glNormalStream3b');
  6815. if not Assigned(glNormalStream3b) then Exit;
  6816. glNormalStream3s := wglGetProcAddress('glNormalStream3s');
  6817. if not Assigned(glNormalStream3s) then Exit;
  6818. glNormalStream3i := wglGetProcAddress('glNormalStream3i');
  6819. if not Assigned(glNormalStream3i) then Exit;
  6820. glNormalStream3f := wglGetProcAddress('glNormalStream3f');
  6821. if not Assigned(glNormalStream3f) then Exit;
  6822. glNormalStream3d := wglGetProcAddress('glNormalStream3d');
  6823. if not Assigned(glNormalStream3d) then Exit;
  6824. glNormalStream3bv := wglGetProcAddress('glNormalStream3bv');
  6825. if not Assigned(glNormalStream3bv) then Exit;
  6826. glNormalStream3sv := wglGetProcAddress('glNormalStream3sv');
  6827. if not Assigned(glNormalStream3sv) then Exit;
  6828. glNormalStream3iv := wglGetProcAddress('glNormalStream3iv');
  6829. if not Assigned(glNormalStream3iv) then Exit;
  6830. glNormalStream3fv := wglGetProcAddress('glNormalStream3fv');
  6831. if not Assigned(glNormalStream3fv) then Exit;
  6832. glNormalStream3dv := wglGetProcAddress('glNormalStream3dv');
  6833. if not Assigned(glNormalStream3dv) then Exit;
  6834. glClientActiveVertexStream := wglGetProcAddress('glClientActiveVertexStream');
  6835. if not Assigned(glClientActiveVertexStream) then Exit;
  6836. glVertexBlendEnvi := wglGetProcAddress('glVertexBlendEnvi');
  6837. if not Assigned(glVertexBlendEnvi) then Exit;
  6838. glVertexBlendEnvf := wglGetProcAddress('glVertexBlendEnvf');
  6839. if not Assigned(glVertexBlendEnvf) then Exit;
  6840. Result := TRUE;
  6841. end;
  6842. end;
  6843. {$IFDEF Windows}
  6844. function Load_WGL_I3D_image_buffer: Boolean;
  6845. var
  6846. extstring: String;
  6847. begin
  6848. Result := FALSE;
  6849. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  6850. if not Assigned(wglGetExtensionsStringARB) then Exit;
  6851. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  6852. if glext_ExtensionSupported('WGL_I3D_image_buffer', extstring) then
  6853. begin
  6854. wglCreateImageBufferI3D := wglGetProcAddress('wglCreateImageBufferI3D');
  6855. if not Assigned(wglCreateImageBufferI3D) then Exit;
  6856. wglDestroyImageBufferI3D := wglGetProcAddress('wglDestroyImageBufferI3D');
  6857. if not Assigned(wglDestroyImageBufferI3D) then Exit;
  6858. wglAssociateImageBufferEventsI3D := wglGetProcAddress('wglAssociateImageBufferEventsI3D');
  6859. if not Assigned(wglAssociateImageBufferEventsI3D) then Exit;
  6860. wglReleaseImageBufferEventsI3D := wglGetProcAddress('wglReleaseImageBufferEventsI3D');
  6861. if not Assigned(wglReleaseImageBufferEventsI3D) then Exit;
  6862. Result := TRUE;
  6863. end;
  6864. end;
  6865. function Load_WGL_I3D_swap_frame_lock: Boolean;
  6866. var
  6867. extstring: String;
  6868. begin
  6869. Result := FALSE;
  6870. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  6871. if not Assigned(wglGetExtensionsStringARB) then Exit;
  6872. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  6873. if glext_ExtensionSupported('WGL_I3D_swap_frame_lock', extstring) then
  6874. begin
  6875. wglEnableFrameLockI3D := wglGetProcAddress('wglEnableFrameLockI3D');
  6876. if not Assigned(wglEnableFrameLockI3D) then Exit;
  6877. wglDisableFrameLockI3D := wglGetProcAddress('wglDisableFrameLockI3D');
  6878. if not Assigned(wglDisableFrameLockI3D) then Exit;
  6879. wglIsEnabledFrameLockI3D := wglGetProcAddress('wglIsEnabledFrameLockI3D');
  6880. if not Assigned(wglIsEnabledFrameLockI3D) then Exit;
  6881. wglQueryFrameLockMasterI3D := wglGetProcAddress('wglQueryFrameLockMasterI3D');
  6882. if not Assigned(wglQueryFrameLockMasterI3D) then Exit;
  6883. Result := TRUE;
  6884. end;
  6885. end;
  6886. function Load_WGL_I3D_swap_frame_usage: Boolean;
  6887. var
  6888. extstring: String;
  6889. begin
  6890. Result := FALSE;
  6891. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  6892. if not Assigned(wglGetExtensionsStringARB) then Exit;
  6893. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  6894. if glext_ExtensionSupported('WGL_I3D_swap_frame_usage', extstring) then
  6895. begin
  6896. wglGetFrameUsageI3D := wglGetProcAddress('wglGetFrameUsageI3D');
  6897. if not Assigned(wglGetFrameUsageI3D) then Exit;
  6898. wglBeginFrameTrackingI3D := wglGetProcAddress('wglBeginFrameTrackingI3D');
  6899. if not Assigned(wglBeginFrameTrackingI3D) then Exit;
  6900. wglEndFrameTrackingI3D := wglGetProcAddress('wglEndFrameTrackingI3D');
  6901. if not Assigned(wglEndFrameTrackingI3D) then Exit;
  6902. wglQueryFrameTrackingI3D := wglGetProcAddress('wglQueryFrameTrackingI3D');
  6903. if not Assigned(wglQueryFrameTrackingI3D) then Exit;
  6904. Result := TRUE;
  6905. end;
  6906. end;
  6907. {$ENDIF}
  6908. function Load_GL_3DFX_texture_compression_FXT1: Boolean;
  6909. var
  6910. extstring: String;
  6911. begin
  6912. Result := FALSE;
  6913. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6914. if glext_ExtensionSupported('GL_3DFX_texture_compression_FXT1', extstring) then
  6915. begin
  6916. Result := TRUE;
  6917. end;
  6918. end;
  6919. function Load_GL_IBM_cull_vertex: Boolean;
  6920. var
  6921. extstring: String;
  6922. begin
  6923. Result := FALSE;
  6924. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6925. if glext_ExtensionSupported('GL_IBM_cull_vertex', extstring) then
  6926. begin
  6927. Result := TRUE;
  6928. end;
  6929. end;
  6930. function Load_GL_IBM_multimode_draw_arrays: Boolean;
  6931. var
  6932. extstring: String;
  6933. begin
  6934. Result := FALSE;
  6935. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6936. if glext_ExtensionSupported('GL_IBM_multimode_draw_arrays', extstring) then
  6937. begin
  6938. glMultiModeDrawArraysIBM := wglGetProcAddress('glMultiModeDrawArraysIBM');
  6939. if not Assigned(glMultiModeDrawArraysIBM) then Exit;
  6940. glMultiModeDrawElementsIBM := wglGetProcAddress('glMultiModeDrawElementsIBM');
  6941. if not Assigned(glMultiModeDrawElementsIBM) then Exit;
  6942. Result := TRUE;
  6943. end;
  6944. end;
  6945. function Load_GL_IBM_raster_pos_clip: Boolean;
  6946. var
  6947. extstring: String;
  6948. begin
  6949. Result := FALSE;
  6950. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6951. if glext_ExtensionSupported('GL_IBM_raster_pos_clip', extstring) then
  6952. begin
  6953. Result := TRUE;
  6954. end;
  6955. end;
  6956. function Load_GL_IBM_texture_mirrored_repeat: Boolean;
  6957. var
  6958. extstring: String;
  6959. begin
  6960. Result := FALSE;
  6961. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6962. if glext_ExtensionSupported('GL_IBM_texture_mirrored_repeat', extstring) then
  6963. begin
  6964. Result := TRUE;
  6965. end;
  6966. end;
  6967. function Load_GL_IBM_vertex_array_lists: Boolean;
  6968. var
  6969. extstring: String;
  6970. begin
  6971. Result := FALSE;
  6972. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6973. if glext_ExtensionSupported('GL_IBM_vertex_array_lists', extstring) then
  6974. begin
  6975. glColorPointerListIBM := wglGetProcAddress('glColorPointerListIBM');
  6976. if not Assigned(glColorPointerListIBM) then Exit;
  6977. glSecondaryColorPointerListIBM := wglGetProcAddress('glSecondaryColorPointerListIBM');
  6978. if not Assigned(glSecondaryColorPointerListIBM) then Exit;
  6979. glEdgeFlagPointerListIBM := wglGetProcAddress('glEdgeFlagPointerListIBM');
  6980. if not Assigned(glEdgeFlagPointerListIBM) then Exit;
  6981. glFogCoordPointerListIBM := wglGetProcAddress('glFogCoordPointerListIBM');
  6982. if not Assigned(glFogCoordPointerListIBM) then Exit;
  6983. glNormalPointerListIBM := wglGetProcAddress('glNormalPointerListIBM');
  6984. if not Assigned(glNormalPointerListIBM) then Exit;
  6985. glTexCoordPointerListIBM := wglGetProcAddress('glTexCoordPointerListIBM');
  6986. if not Assigned(glTexCoordPointerListIBM) then Exit;
  6987. glVertexPointerListIBM := wglGetProcAddress('glVertexPointerListIBM');
  6988. if not Assigned(glVertexPointerListIBM) then Exit;
  6989. Result := TRUE;
  6990. end;
  6991. end;
  6992. function Load_GL_MESA_resize_buffers: Boolean;
  6993. var
  6994. extstring: String;
  6995. begin
  6996. Result := FALSE;
  6997. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  6998. if glext_ExtensionSupported('GL_MESA_resize_buffers', extstring) then
  6999. begin
  7000. glResizeBuffersMESA := wglGetProcAddress('glResizeBuffersMESA');
  7001. if not Assigned(glResizeBuffersMESA) then Exit;
  7002. Result := TRUE;
  7003. end;
  7004. end;
  7005. function Load_GL_MESA_window_pos: Boolean;
  7006. var
  7007. extstring: String;
  7008. begin
  7009. Result := FALSE;
  7010. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7011. if glext_ExtensionSupported('GL_MESA_window_pos', extstring) then
  7012. begin
  7013. glWindowPos2dMESA := wglGetProcAddress('glWindowPos2dMESA');
  7014. if not Assigned(glWindowPos2dMESA) then Exit;
  7015. glWindowPos2fMESA := wglGetProcAddress('glWindowPos2fMESA');
  7016. if not Assigned(glWindowPos2fMESA) then Exit;
  7017. glWindowPos2iMESA := wglGetProcAddress('glWindowPos2iMESA');
  7018. if not Assigned(glWindowPos2iMESA) then Exit;
  7019. glWindowPos2sMESA := wglGetProcAddress('glWindowPos2sMESA');
  7020. if not Assigned(glWindowPos2sMESA) then Exit;
  7021. glWindowPos2ivMESA := wglGetProcAddress('glWindowPos2ivMESA');
  7022. if not Assigned(glWindowPos2ivMESA) then Exit;
  7023. glWindowPos2svMESA := wglGetProcAddress('glWindowPos2svMESA');
  7024. if not Assigned(glWindowPos2svMESA) then Exit;
  7025. glWindowPos2fvMESA := wglGetProcAddress('glWindowPos2fvMESA');
  7026. if not Assigned(glWindowPos2fvMESA) then Exit;
  7027. glWindowPos2dvMESA := wglGetProcAddress('glWindowPos2dvMESA');
  7028. if not Assigned(glWindowPos2dvMESA) then Exit;
  7029. glWindowPos3iMESA := wglGetProcAddress('glWindowPos3iMESA');
  7030. if not Assigned(glWindowPos3iMESA) then Exit;
  7031. glWindowPos3sMESA := wglGetProcAddress('glWindowPos3sMESA');
  7032. if not Assigned(glWindowPos3sMESA) then Exit;
  7033. glWindowPos3fMESA := wglGetProcAddress('glWindowPos3fMESA');
  7034. if not Assigned(glWindowPos3fMESA) then Exit;
  7035. glWindowPos3dMESA := wglGetProcAddress('glWindowPos3dMESA');
  7036. if not Assigned(glWindowPos3dMESA) then Exit;
  7037. glWindowPos3ivMESA := wglGetProcAddress('glWindowPos3ivMESA');
  7038. if not Assigned(glWindowPos3ivMESA) then Exit;
  7039. glWindowPos3svMESA := wglGetProcAddress('glWindowPos3svMESA');
  7040. if not Assigned(glWindowPos3svMESA) then Exit;
  7041. glWindowPos3fvMESA := wglGetProcAddress('glWindowPos3fvMESA');
  7042. if not Assigned(glWindowPos3fvMESA) then Exit;
  7043. glWindowPos3dvMESA := wglGetProcAddress('glWindowPos3dvMESA');
  7044. if not Assigned(glWindowPos3dvMESA) then Exit;
  7045. glWindowPos4iMESA := wglGetProcAddress('glWindowPos4iMESA');
  7046. if not Assigned(glWindowPos4iMESA) then Exit;
  7047. glWindowPos4sMESA := wglGetProcAddress('glWindowPos4sMESA');
  7048. if not Assigned(glWindowPos4sMESA) then Exit;
  7049. glWindowPos4fMESA := wglGetProcAddress('glWindowPos4fMESA');
  7050. if not Assigned(glWindowPos4fMESA) then Exit;
  7051. glWindowPos4dMESA := wglGetProcAddress('glWindowPos4dMESA');
  7052. if not Assigned(glWindowPos4dMESA) then Exit;
  7053. glWindowPos4ivMESA := wglGetProcAddress('glWindowPos4ivMESA');
  7054. if not Assigned(glWindowPos4ivMESA) then Exit;
  7055. glWindowPos4svMESA := wglGetProcAddress('glWindowPos4svMESA');
  7056. if not Assigned(glWindowPos4svMESA) then Exit;
  7057. glWindowPos4fvMESA := wglGetProcAddress('glWindowPos4fvMESA');
  7058. if not Assigned(glWindowPos4fvMESA) then Exit;
  7059. glWindowPos4dvMESA := wglGetProcAddress('glWindowPos4dvMESA');
  7060. if not Assigned(glWindowPos4dvMESA) then Exit;
  7061. Result := TRUE;
  7062. end;
  7063. end;
  7064. function Load_GL_OML_interlace: Boolean;
  7065. var
  7066. extstring: String;
  7067. begin
  7068. Result := FALSE;
  7069. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7070. if glext_ExtensionSupported('GL_OML_interlace', extstring) then
  7071. begin
  7072. Result := TRUE;
  7073. end;
  7074. end;
  7075. function Load_GL_OML_resample: Boolean;
  7076. var
  7077. extstring: String;
  7078. begin
  7079. Result := FALSE;
  7080. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7081. if glext_ExtensionSupported('GL_OML_resample', extstring) then
  7082. begin
  7083. Result := TRUE;
  7084. end;
  7085. end;
  7086. function Load_GL_OML_subsample: Boolean;
  7087. var
  7088. extstring: String;
  7089. begin
  7090. Result := FALSE;
  7091. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7092. if glext_ExtensionSupported('GL_OML_subsample', extstring) then
  7093. begin
  7094. Result := TRUE;
  7095. end;
  7096. end;
  7097. function Load_GL_SGIS_generate_mipmap: Boolean;
  7098. var
  7099. extstring: String;
  7100. begin
  7101. Result := FALSE;
  7102. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7103. if glext_ExtensionSupported('GL_SGIS_generate_mipmap', extstring) then
  7104. begin
  7105. Result := TRUE;
  7106. end;
  7107. end;
  7108. function Load_GL_SGIS_multisample: Boolean;
  7109. var
  7110. extstring: String;
  7111. begin
  7112. Result := FALSE;
  7113. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7114. if glext_ExtensionSupported('GL_SGIS_multisample', extstring) then
  7115. begin
  7116. glSampleMaskSGIS := wglGetProcAddress('glSampleMaskSGIS');
  7117. if not Assigned(glSampleMaskSGIS) then Exit;
  7118. glSamplePatternSGIS := wglGetProcAddress('glSamplePatternSGIS');
  7119. if not Assigned(glSamplePatternSGIS) then Exit;
  7120. Result := TRUE;
  7121. end;
  7122. end;
  7123. function Load_GL_SGIS_pixel_texture: Boolean;
  7124. var
  7125. extstring: String;
  7126. begin
  7127. Result := FALSE;
  7128. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7129. if glext_ExtensionSupported('GL_SGIS_pixel_texture', extstring) then
  7130. begin
  7131. glPixelTexGenParameteriSGIS := wglGetProcAddress('glPixelTexGenParameteriSGIS');
  7132. if not Assigned(glPixelTexGenParameteriSGIS) then Exit;
  7133. glPixelTexGenParameterfSGIS := wglGetProcAddress('glPixelTexGenParameterfSGIS');
  7134. if not Assigned(glPixelTexGenParameterfSGIS) then Exit;
  7135. glGetPixelTexGenParameterivSGIS := wglGetProcAddress('glGetPixelTexGenParameterivSGIS');
  7136. if not Assigned(glGetPixelTexGenParameterivSGIS) then Exit;
  7137. glGetPixelTexGenParameterfvSGIS := wglGetProcAddress('glGetPixelTexGenParameterfvSGIS');
  7138. if not Assigned(glGetPixelTexGenParameterfvSGIS) then Exit;
  7139. Result := TRUE;
  7140. end;
  7141. end;
  7142. function Load_GL_SGIS_texture_border_clamp: Boolean;
  7143. var
  7144. extstring: String;
  7145. begin
  7146. Result := FALSE;
  7147. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7148. if glext_ExtensionSupported('GL_SGIS_texture_border_clamp', extstring) then
  7149. begin
  7150. Result := TRUE;
  7151. end;
  7152. end;
  7153. function Load_GL_SGIS_texture_color_mask: Boolean;
  7154. var
  7155. extstring: String;
  7156. begin
  7157. Result := FALSE;
  7158. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7159. if glext_ExtensionSupported('GL_SGIS_texture_color_mask', extstring) then
  7160. begin
  7161. glTextureColorMaskSGIS := wglGetProcAddress('glTextureColorMaskSGIS');
  7162. if not Assigned(glTextureColorMaskSGIS) then Exit;
  7163. Result := TRUE;
  7164. end;
  7165. end;
  7166. function Load_GL_SGIS_texture_edge_clamp: Boolean;
  7167. var
  7168. extstring: String;
  7169. begin
  7170. Result := FALSE;
  7171. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7172. if glext_ExtensionSupported('GL_SGIS_texture_edge_clamp', extstring) then
  7173. begin
  7174. Result := TRUE;
  7175. end;
  7176. end;
  7177. function Load_GL_SGIS_texture_lod: Boolean;
  7178. var
  7179. extstring: String;
  7180. begin
  7181. Result := FALSE;
  7182. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7183. if glext_ExtensionSupported('GL_SGIS_texture_lod', extstring) then
  7184. begin
  7185. Result := TRUE;
  7186. end;
  7187. end;
  7188. function Load_GL_SGIS_depth_texture: Boolean;
  7189. var
  7190. extstring: String;
  7191. begin
  7192. Result := FALSE;
  7193. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7194. if glext_ExtensionSupported('GL_SGIS_depth_texture', extstring) then
  7195. begin
  7196. Result := TRUE;
  7197. end;
  7198. end;
  7199. function Load_GL_SGIX_fog_offset: Boolean;
  7200. var
  7201. extstring: String;
  7202. begin
  7203. Result := FALSE;
  7204. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7205. if glext_ExtensionSupported('GL_SGIX_fog_offset', extstring) then
  7206. begin
  7207. Result := TRUE;
  7208. end;
  7209. end;
  7210. function Load_GL_SGIX_interlace: Boolean;
  7211. var
  7212. extstring: String;
  7213. begin
  7214. Result := FALSE;
  7215. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7216. if glext_ExtensionSupported('GL_SGIX_interlace', extstring) then
  7217. begin
  7218. Result := TRUE;
  7219. end;
  7220. end;
  7221. function Load_GL_SGIX_shadow_ambient: Boolean;
  7222. var
  7223. extstring: String;
  7224. begin
  7225. Result := FALSE;
  7226. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7227. if glext_ExtensionSupported('GL_SGIX_shadow_ambient', extstring) then
  7228. begin
  7229. Result := TRUE;
  7230. end;
  7231. end;
  7232. function Load_GL_SGI_color_matrix: Boolean;
  7233. var
  7234. extstring: String;
  7235. begin
  7236. Result := FALSE;
  7237. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7238. if glext_ExtensionSupported('GL_SGI_color_matrix', extstring) then
  7239. begin
  7240. Result := TRUE;
  7241. end;
  7242. end;
  7243. function Load_GL_SGI_color_table: Boolean;
  7244. var
  7245. extstring: String;
  7246. begin
  7247. Result := FALSE;
  7248. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7249. if glext_ExtensionSupported('GL_SGI_color_table', extstring) then
  7250. begin
  7251. glColorTableSGI := wglGetProcAddress('glColorTableSGI');
  7252. if not Assigned(glColorTableSGI) then Exit;
  7253. glCopyColorTableSGI := wglGetProcAddress('glCopyColorTableSGI');
  7254. if not Assigned(glCopyColorTableSGI) then Exit;
  7255. glColorTableParameterivSGI := wglGetProcAddress('glColorTableParameterivSGI');
  7256. if not Assigned(glColorTableParameterivSGI) then Exit;
  7257. glColorTableParameterfvSGI := wglGetProcAddress('glColorTableParameterfvSGI');
  7258. if not Assigned(glColorTableParameterfvSGI) then Exit;
  7259. glGetColorTableSGI := wglGetProcAddress('glGetColorTableSGI');
  7260. if not Assigned(glGetColorTableSGI) then Exit;
  7261. glGetColorTableParameterivSGI := wglGetProcAddress('glGetColorTableParameterivSGI');
  7262. if not Assigned(glGetColorTableParameterivSGI) then Exit;
  7263. glGetColorTableParameterfvSGI := wglGetProcAddress('glGetColorTableParameterfvSGI');
  7264. if not Assigned(glGetColorTableParameterfvSGI) then Exit;
  7265. Result := TRUE;
  7266. end;
  7267. end;
  7268. function Load_GL_SGI_texture_color_table: Boolean;
  7269. var
  7270. extstring: String;
  7271. begin
  7272. Result := FALSE;
  7273. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7274. if glext_ExtensionSupported('GL_SGI_texture_color_table', extstring) then
  7275. begin
  7276. Result := TRUE;
  7277. end;
  7278. end;
  7279. function Load_GL_SUN_vertex: Boolean;
  7280. var
  7281. extstring: String;
  7282. begin
  7283. Result := FALSE;
  7284. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7285. if glext_ExtensionSupported('GL_SUN_vertex', extstring) then
  7286. begin
  7287. glColor4ubVertex2fSUN := wglGetProcAddress('glColor4ubVertex2fSUN');
  7288. if not Assigned(glColor4ubVertex2fSUN) then Exit;
  7289. glColor4ubVertex2fvSUN := wglGetProcAddress('glColor4ubVertex2fvSUN');
  7290. if not Assigned(glColor4ubVertex2fvSUN) then Exit;
  7291. glColor4ubVertex3fSUN := wglGetProcAddress('glColor4ubVertex3fSUN');
  7292. if not Assigned(glColor4ubVertex3fSUN) then Exit;
  7293. glColor4ubVertex3fvSUN := wglGetProcAddress('glColor4ubVertex3fvSUN');
  7294. if not Assigned(glColor4ubVertex3fvSUN) then Exit;
  7295. glColor3fVertex3fSUN := wglGetProcAddress('glColor3fVertex3fSUN');
  7296. if not Assigned(glColor3fVertex3fSUN) then Exit;
  7297. glColor3fVertex3fvSUN := wglGetProcAddress('glColor3fVertex3fvSUN');
  7298. if not Assigned(glColor3fVertex3fvSUN) then Exit;
  7299. glNormal3fVertex3fSUN := wglGetProcAddress('glNormal3fVertex3fSUN');
  7300. if not Assigned(glNormal3fVertex3fSUN) then Exit;
  7301. glNormal3fVertex3fvSUN := wglGetProcAddress('glNormal3fVertex3fvSUN');
  7302. if not Assigned(glNormal3fVertex3fvSUN) then Exit;
  7303. glColor4fNormal3fVertex3fSUN := wglGetProcAddress('glColor4fNormal3fVertex3fSUN');
  7304. if not Assigned(glColor4fNormal3fVertex3fSUN) then Exit;
  7305. glColor4fNormal3fVertex3fvSUN := wglGetProcAddress('glColor4fNormal3fVertex3fvSUN');
  7306. if not Assigned(glColor4fNormal3fVertex3fvSUN) then Exit;
  7307. glTexCoord2fVertex3fSUN := wglGetProcAddress('glTexCoord2fVertex3fSUN');
  7308. if not Assigned(glTexCoord2fVertex3fSUN) then Exit;
  7309. glTexCoord2fVertex3fvSUN := wglGetProcAddress('glTexCoord2fVertex3fvSUN');
  7310. if not Assigned(glTexCoord2fVertex3fvSUN) then Exit;
  7311. glTexCoord4fVertex4fSUN := wglGetProcAddress('glTexCoord4fVertex4fSUN');
  7312. if not Assigned(glTexCoord4fVertex4fSUN) then Exit;
  7313. glTexCoord4fVertex4fvSUN := wglGetProcAddress('glTexCoord4fVertex4fvSUN');
  7314. if not Assigned(glTexCoord4fVertex4fvSUN) then Exit;
  7315. glTexCoord2fColor4ubVertex3fSUN := wglGetProcAddress('glTexCoord2fColor4ubVertex3fSUN');
  7316. if not Assigned(glTexCoord2fColor4ubVertex3fSUN) then Exit;
  7317. glTexCoord2fColor4ubVertex3fvSUN := wglGetProcAddress('glTexCoord2fColor4ubVertex3fvSUN');
  7318. if not Assigned(glTexCoord2fColor4ubVertex3fvSUN) then Exit;
  7319. glTexCoord2fColor3fVertex3fSUN := wglGetProcAddress('glTexCoord2fColor3fVertex3fSUN');
  7320. if not Assigned(glTexCoord2fColor3fVertex3fSUN) then Exit;
  7321. glTexCoord2fColor3fVertex3fvSUN := wglGetProcAddress('glTexCoord2fColor3fVertex3fvSUN');
  7322. if not Assigned(glTexCoord2fColor3fVertex3fvSUN) then Exit;
  7323. glTexCoord2fNormal3fVertex3fSUN := wglGetProcAddress('glTexCoord2fNormal3fVertex3fSUN');
  7324. if not Assigned(glTexCoord2fNormal3fVertex3fSUN) then Exit;
  7325. glTexCoord2fNormal3fVertex3fvSUN := wglGetProcAddress('glTexCoord2fNormal3fVertex3fvSUN');
  7326. if not Assigned(glTexCoord2fNormal3fVertex3fvSUN) then Exit;
  7327. glTexCoord2fColor4fNormal3fVertex3fSUN := wglGetProcAddress('glTexCoord2fColor4fNormal3fVertex3fSUN');
  7328. if not Assigned(glTexCoord2fColor4fNormal3fVertex3fSUN) then Exit;
  7329. glTexCoord2fColor4fNormal3fVertex3fvSUN := wglGetProcAddress('glTexCoord2fColor4fNormal3fVertex3fvSUN');
  7330. if not Assigned(glTexCoord2fColor4fNormal3fVertex3fvSUN) then Exit;
  7331. glTexCoord4fColor4fNormal3fVertex4fSUN := wglGetProcAddress('glTexCoord4fColor4fNormal3fVertex4fSUN');
  7332. if not Assigned(glTexCoord4fColor4fNormal3fVertex4fSUN) then Exit;
  7333. glTexCoord4fColor4fNormal3fVertex4fvSUN := wglGetProcAddress('glTexCoord4fColor4fNormal3fVertex4fvSUN');
  7334. if not Assigned(glTexCoord4fColor4fNormal3fVertex4fvSUN) then Exit;
  7335. glReplacementCodeuiVertex3fSUN := wglGetProcAddress('glReplacementCodeuiVertex3fSUN');
  7336. if not Assigned(glReplacementCodeuiVertex3fSUN) then Exit;
  7337. glReplacementCodeuiVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiVertex3fvSUN');
  7338. if not Assigned(glReplacementCodeuiVertex3fvSUN) then Exit;
  7339. glReplacementCodeuiColor4ubVertex3fSUN := wglGetProcAddress('glReplacementCodeuiColor4ubVertex3fSUN');
  7340. if not Assigned(glReplacementCodeuiColor4ubVertex3fSUN) then Exit;
  7341. glReplacementCodeuiColor4ubVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiColor4ubVertex3fvSUN');
  7342. if not Assigned(glReplacementCodeuiColor4ubVertex3fvSUN) then Exit;
  7343. glReplacementCodeuiColor3fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiColor3fVertex3fSUN');
  7344. if not Assigned(glReplacementCodeuiColor3fVertex3fSUN) then Exit;
  7345. glReplacementCodeuiColor3fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiColor3fVertex3fvSUN');
  7346. if not Assigned(glReplacementCodeuiColor3fVertex3fvSUN) then Exit;
  7347. glReplacementCodeuiNormal3fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiNormal3fVertex3fSUN');
  7348. if not Assigned(glReplacementCodeuiNormal3fVertex3fSUN) then Exit;
  7349. glReplacementCodeuiNormal3fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiNormal3fVertex3fvSUN');
  7350. if not Assigned(glReplacementCodeuiNormal3fVertex3fvSUN) then Exit;
  7351. glReplacementCodeuiColor4fNormal3fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiColor4fNormal3fVertex3fSUN');
  7352. if not Assigned(glReplacementCodeuiColor4fNormal3fVertex3fSUN) then Exit;
  7353. glReplacementCodeuiColor4fNormal3fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiColor4fNormal3fVertex3fvSUN');
  7354. if not Assigned(glReplacementCodeuiColor4fNormal3fVertex3fvSUN) then Exit;
  7355. glReplacementCodeuiTexCoord2fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fVertex3fSUN');
  7356. if not Assigned(glReplacementCodeuiTexCoord2fVertex3fSUN) then Exit;
  7357. glReplacementCodeuiTexCoord2fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fVertex3fvSUN');
  7358. if not Assigned(glReplacementCodeuiTexCoord2fVertex3fvSUN) then Exit;
  7359. glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN');
  7360. if not Assigned(glReplacementCodeuiTexCoord2fNormal3fVertex3fSUN) then Exit;
  7361. glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN');
  7362. if not Assigned(glReplacementCodeuiTexCoord2fNormal3fVertex3fvSUN) then Exit;
  7363. glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN');
  7364. if not Assigned(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fSUN) then Exit;
  7365. glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN := wglGetProcAddress('glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN');
  7366. if not Assigned(glReplacementCodeuiTexCoord2fColor4fNormal3fVertex3fvSUN) then Exit;
  7367. Result := TRUE;
  7368. end;
  7369. end;
  7370. function Load_GL_ARB_fragment_program: Boolean;
  7371. var
  7372. extstring: String;
  7373. begin
  7374. Result := FALSE;
  7375. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7376. if glext_ExtensionSupported('GL_ARB_fragment_program', extstring) then
  7377. begin
  7378. glProgramStringARB := wglGetProcAddress('glProgramStringARB');
  7379. if not Assigned(glProgramStringARB) then Exit;
  7380. glBindProgramARB := wglGetProcAddress('glBindProgramARB');
  7381. if not Assigned(glBindProgramARB) then Exit;
  7382. glDeleteProgramsARB := wglGetProcAddress('glDeleteProgramsARB');
  7383. if not Assigned(glDeleteProgramsARB) then Exit;
  7384. glGenProgramsARB := wglGetProcAddress('glGenProgramsARB');
  7385. if not Assigned(glGenProgramsARB) then Exit;
  7386. glProgramEnvParameter4dARB := wglGetProcAddress('glProgramEnvParameter4dARB');
  7387. if not Assigned(glProgramEnvParameter4dARB) then Exit;
  7388. glProgramEnvParameter4dvARB := wglGetProcAddress('glProgramEnvParameter4dvARB');
  7389. if not Assigned(glProgramEnvParameter4dvARB) then Exit;
  7390. glProgramEnvParameter4fARB := wglGetProcAddress('glProgramEnvParameter4fARB');
  7391. if not Assigned(glProgramEnvParameter4fARB) then Exit;
  7392. glProgramEnvParameter4fvARB := wglGetProcAddress('glProgramEnvParameter4fvARB');
  7393. if not Assigned(glProgramEnvParameter4fvARB) then Exit;
  7394. glProgramLocalParameter4dARB := wglGetProcAddress('glProgramLocalParameter4dARB');
  7395. if not Assigned(glProgramLocalParameter4dARB) then Exit;
  7396. glProgramLocalParameter4dvARB := wglGetProcAddress('glProgramLocalParameter4dvARB');
  7397. if not Assigned(glProgramLocalParameter4dvARB) then Exit;
  7398. glProgramLocalParameter4fARB := wglGetProcAddress('glProgramLocalParameter4fARB');
  7399. if not Assigned(glProgramLocalParameter4fARB) then Exit;
  7400. glProgramLocalParameter4fvARB := wglGetProcAddress('glProgramLocalParameter4fvARB');
  7401. if not Assigned(glProgramLocalParameter4fvARB) then Exit;
  7402. glGetProgramEnvParameterdvARB := wglGetProcAddress('glGetProgramEnvParameterdvARB');
  7403. if not Assigned(glGetProgramEnvParameterdvARB) then Exit;
  7404. glGetProgramEnvParameterfvARB := wglGetProcAddress('glGetProgramEnvParameterfvARB');
  7405. if not Assigned(glGetProgramEnvParameterfvARB) then Exit;
  7406. glGetProgramLocalParameterdvARB := wglGetProcAddress('glGetProgramLocalParameterdvARB');
  7407. if not Assigned(glGetProgramLocalParameterdvARB) then Exit;
  7408. glGetProgramLocalParameterfvARB := wglGetProcAddress('glGetProgramLocalParameterfvARB');
  7409. if not Assigned(glGetProgramLocalParameterfvARB) then Exit;
  7410. glGetProgramivARB := wglGetProcAddress('glGetProgramivARB');
  7411. if not Assigned(glGetProgramivARB) then Exit;
  7412. glGetProgramStringARB := wglGetProcAddress('glGetProgramStringARB');
  7413. if not Assigned(glGetProgramStringARB) then Exit;
  7414. glIsProgramARB := wglGetProcAddress('glIsProgramARB');
  7415. if not Assigned(glIsProgramARB) then Exit;
  7416. Result := TRUE;
  7417. end;
  7418. end;
  7419. function Load_GL_ATI_text_fragment_shader: Boolean;
  7420. var
  7421. extstring: String;
  7422. begin
  7423. Result := FALSE;
  7424. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7425. if glext_ExtensionSupported('GL_ATI_text_fragment_shader', extstring) then
  7426. begin
  7427. Result := TRUE;
  7428. end;
  7429. end;
  7430. function Load_GL_APPLE_client_storage: Boolean;
  7431. var
  7432. extstring: String;
  7433. begin
  7434. Result := FALSE;
  7435. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7436. if glext_ExtensionSupported('GL_APPLE_client_storage', extstring) then
  7437. begin
  7438. Result := TRUE;
  7439. end;
  7440. end;
  7441. function Load_GL_APPLE_element_array: Boolean;
  7442. var
  7443. extstring: String;
  7444. begin
  7445. Result := FALSE;
  7446. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7447. if glext_ExtensionSupported('GL_APPLE_element_array', extstring) then
  7448. begin
  7449. glElementPointerAPPLE := wglGetProcAddress('glElementPointerAPPLE');
  7450. if not Assigned(glElementPointerAPPLE) then Exit;
  7451. glDrawElementArrayAPPLE := wglGetProcAddress('glDrawElementArrayAPPLE');
  7452. if not Assigned(glDrawElementArrayAPPLE) then Exit;
  7453. glDrawRangeElementArrayAPPLE := wglGetProcAddress('glDrawRangeElementArrayAPPLE');
  7454. if not Assigned(glDrawRangeElementArrayAPPLE) then Exit;
  7455. glMultiDrawElementArrayAPPLE := wglGetProcAddress('glMultiDrawElementArrayAPPLE');
  7456. if not Assigned(glMultiDrawElementArrayAPPLE) then Exit;
  7457. glMultiDrawRangeElementArrayAPPLE := wglGetProcAddress('glMultiDrawRangeElementArrayAPPLE');
  7458. if not Assigned(glMultiDrawRangeElementArrayAPPLE) then Exit;
  7459. Result := TRUE;
  7460. end;
  7461. end;
  7462. function Load_GL_APPLE_fence: Boolean;
  7463. var
  7464. extstring: String;
  7465. begin
  7466. Result := FALSE;
  7467. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7468. if glext_ExtensionSupported('GL_APPLE_fence', extstring) then
  7469. begin
  7470. glGenFencesAPPLE := wglGetProcAddress('glGenFencesAPPLE');
  7471. if not Assigned(glGenFencesAPPLE) then Exit;
  7472. glDeleteFencesAPPLE := wglGetProcAddress('glDeleteFencesAPPLE');
  7473. if not Assigned(glDeleteFencesAPPLE) then Exit;
  7474. glSetFenceAPPLE := wglGetProcAddress('glSetFenceAPPLE');
  7475. if not Assigned(glSetFenceAPPLE) then Exit;
  7476. glIsFenceAPPLE := wglGetProcAddress('glIsFenceAPPLE');
  7477. if not Assigned(glIsFenceAPPLE) then Exit;
  7478. glTestFenceAPPLE := wglGetProcAddress('glTestFenceAPPLE');
  7479. if not Assigned(glTestFenceAPPLE) then Exit;
  7480. glFinishFenceAPPLE := wglGetProcAddress('glFinishFenceAPPLE');
  7481. if not Assigned(glFinishFenceAPPLE) then Exit;
  7482. glTestObjectAPPLE := wglGetProcAddress('glTestObjectAPPLE');
  7483. if not Assigned(glTestObjectAPPLE) then Exit;
  7484. glFinishObjectAPPLE := wglGetProcAddress('glFinishObjectAPPLE');
  7485. if not Assigned(glFinishObjectAPPLE) then Exit;
  7486. Result := TRUE;
  7487. end;
  7488. end;
  7489. function Load_GL_APPLE_vertex_array_object: Boolean;
  7490. var
  7491. extstring: String;
  7492. begin
  7493. Result := FALSE;
  7494. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7495. if glext_ExtensionSupported('GL_APPLE_vertex_array_object', extstring) then
  7496. begin
  7497. glBindVertexArrayAPPLE := wglGetProcAddress('glBindVertexArrayAPPLE');
  7498. if not Assigned(glBindVertexArrayAPPLE) then Exit;
  7499. glDeleteVertexArraysAPPLE := wglGetProcAddress('glDeleteVertexArraysAPPLE');
  7500. if not Assigned(glDeleteVertexArraysAPPLE) then Exit;
  7501. glGenVertexArraysAPPLE := wglGetProcAddress('glGenVertexArraysAPPLE');
  7502. if not Assigned(glGenVertexArraysAPPLE) then Exit;
  7503. glIsVertexArrayAPPLE := wglGetProcAddress('glIsVertexArrayAPPLE');
  7504. if not Assigned(glIsVertexArrayAPPLE) then Exit;
  7505. Result := TRUE;
  7506. end;
  7507. end;
  7508. function Load_GL_APPLE_vertex_array_range: Boolean;
  7509. var
  7510. extstring: String;
  7511. begin
  7512. Result := FALSE;
  7513. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7514. if glext_ExtensionSupported('GL_APPLE_vertex_array_range', extstring) then
  7515. begin
  7516. glVertexArrayRangeAPPLE := wglGetProcAddress('glVertexArrayRangeAPPLE');
  7517. if not Assigned(glVertexArrayRangeAPPLE) then Exit;
  7518. glFlushVertexArrayRangeAPPLE := wglGetProcAddress('glFlushVertexArrayRangeAPPLE');
  7519. if not Assigned(glFlushVertexArrayRangeAPPLE) then Exit;
  7520. glVertexArrayParameteriAPPLE := wglGetProcAddress('glVertexArrayParameteriAPPLE');
  7521. if not Assigned(glVertexArrayParameteriAPPLE) then Exit;
  7522. Result := TRUE;
  7523. end;
  7524. end;
  7525. function load_GL_ARB_vertex_buffer_object : boolean;
  7526. var extstring:string;
  7527. begin
  7528. Result:=false;
  7529. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7530. if glext_ExtensionSupported('GL_ARB_vertex_buffer_object',extstring) then
  7531. begin
  7532. glBindBufferARB := wglGetProcAddress('glBindBufferARB');
  7533. if not Assigned(glBindBufferARB) then Exit;
  7534. glDeleteBuffersARB := wglGetProcAddress('glDeleteBuffersARB');
  7535. if not Assigned(glDeleteBuffersARB) then Exit;
  7536. glGenBuffersARB := wglGetProcAddress('glGenBuffersARB');
  7537. if not Assigned(glGenBuffersARB) then Exit;
  7538. glIsBufferARB := wglGetProcAddress('glIsBufferARB');
  7539. if not Assigned(glIsBufferARB) then Exit;
  7540. glBufferDataARB := wglGetProcAddress('glBufferDataARB');
  7541. if not Assigned(glBufferDataARB) then Exit;
  7542. glBufferSubDataARB := wglGetProcAddress('glBufferSubDataARB');
  7543. if not Assigned(glBufferSubDataARB) then Exit;
  7544. glGetBufferSubDataARB := wglGetProcAddress('glGetBufferSubDataARB');
  7545. if not Assigned(glGetBufferSubDataARB) then Exit;
  7546. glMapBufferARB := wglGetProcAddress('glMapBufferARB');
  7547. if not Assigned(glMapBufferARB) then Exit;
  7548. glUnmapBufferARB := wglGetProcAddress('glUnmapBufferARB');
  7549. if not Assigned(glMapBufferARB) then Exit;
  7550. glGetBufferParameterivARB := wglGetProcAddress('glGetBufferParameterivARB');
  7551. if not Assigned(glGetBufferParameterivARB) then Exit;
  7552. glGetBufferPointervARB := wglGetProcAddress('glGetBufferPointervARB');
  7553. if not Assigned(glGetBufferPointervARB) then Exit;
  7554. Result:=true;
  7555. end;
  7556. end;
  7557. {$IFDEF Windows}
  7558. function Load_WGL_ARB_pixel_format: Boolean;
  7559. var
  7560. extstring: String;
  7561. begin
  7562. Result := FALSE;
  7563. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7564. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7565. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7566. if glext_ExtensionSupported('WGL_ARB_pixel_format', extstring) then
  7567. begin
  7568. wglGetPixelFormatAttribivARB := wglGetProcAddress('wglGetPixelFormatAttribivARB');
  7569. if not Assigned(wglGetPixelFormatAttribivARB) then Exit;
  7570. wglGetPixelFormatAttribfvARB := wglGetProcAddress('wglGetPixelFormatAttribfvARB');
  7571. if not Assigned(wglGetPixelFormatAttribfvARB) then Exit;
  7572. wglChoosePixelFormatARB := wglGetProcAddress('wglChoosePixelFormatARB');
  7573. if not Assigned(wglChoosePixelFormatARB) then Exit;
  7574. Result := TRUE;
  7575. end;
  7576. end;
  7577. function Load_WGL_ARB_make_current_read: Boolean;
  7578. var
  7579. extstring: String;
  7580. begin
  7581. Result := FALSE;
  7582. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7583. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7584. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7585. if glext_ExtensionSupported('WGL_ARB_make_current_read', extstring) then
  7586. begin
  7587. wglMakeContextCurrentARB := wglGetProcAddress('wglMakeContextCurrentARB');
  7588. if not Assigned(wglMakeContextCurrentARB) then Exit;
  7589. wglGetCurrentReadDCARB := wglGetProcAddress('wglGetCurrentReadDCARB');
  7590. if not Assigned(wglGetCurrentReadDCARB) then Exit;
  7591. Result := TRUE;
  7592. end;
  7593. end;
  7594. function Load_WGL_ARB_pbuffer: Boolean;
  7595. var
  7596. extstring: String;
  7597. begin
  7598. Result := FALSE;
  7599. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7600. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7601. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7602. if glext_ExtensionSupported('WGL_ARB_pbuffer', extstring) then
  7603. begin
  7604. wglCreatePbufferARB := wglGetProcAddress('wglCreatePbufferARB');
  7605. if not Assigned(wglCreatePbufferARB) then Exit;
  7606. wglGetPbufferDCARB := wglGetProcAddress('wglGetPbufferDCARB');
  7607. if not Assigned(wglGetPbufferDCARB) then Exit;
  7608. wglReleasePbufferDCARB := wglGetProcAddress('wglReleasePbufferDCARB');
  7609. if not Assigned(wglReleasePbufferDCARB) then Exit;
  7610. wglDestroyPbufferARB := wglGetProcAddress('wglDestroyPbufferARB');
  7611. if not Assigned(wglDestroyPbufferARB) then Exit;
  7612. wglQueryPbufferARB := wglGetProcAddress('wglQueryPbufferARB');
  7613. if not Assigned(wglQueryPbufferARB) then Exit;
  7614. Result := TRUE;
  7615. end;
  7616. end;
  7617. function Load_WGL_EXT_swap_control: Boolean;
  7618. var
  7619. extstring: String;
  7620. begin
  7621. Result := FALSE;
  7622. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7623. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7624. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7625. if glext_ExtensionSupported('WGL_EXT_swap_control', extstring) then
  7626. begin
  7627. wglSwapIntervalEXT := wglGetProcAddress('wglSwapIntervalEXT');
  7628. if not Assigned(wglSwapIntervalEXT) then Exit;
  7629. wglGetSwapIntervalEXT := wglGetProcAddress('wglGetSwapIntervalEXT');
  7630. if not Assigned(wglGetSwapIntervalEXT) then Exit;
  7631. Result := TRUE;
  7632. end;
  7633. end;
  7634. function Load_WGL_ARB_render_texture: Boolean;
  7635. var
  7636. extstring: String;
  7637. begin
  7638. Result := FALSE;
  7639. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7640. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7641. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7642. if glext_ExtensionSupported('WGL_ARB_render_texture', extstring) then
  7643. begin
  7644. wglBindTexImageARB := wglGetProcAddress('wglBindTexImageARB');
  7645. if not Assigned(wglBindTexImageARB) then Exit;
  7646. wglReleaseTexImageARB := wglGetProcAddress('wglReleaseTexImageARB');
  7647. if not Assigned(wglReleaseTexImageARB) then Exit;
  7648. wglSetPbufferAttribARB := wglGetProcAddress('wglSetPbufferAttribARB');
  7649. if not Assigned(wglSetPbufferAttribARB) then Exit;
  7650. Result := TRUE;
  7651. end;
  7652. end;
  7653. function Load_WGL_EXT_extensions_string: Boolean;
  7654. var
  7655. extstring: String;
  7656. begin
  7657. Result := FALSE;
  7658. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7659. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7660. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7661. if glext_ExtensionSupported('WGL_EXT_extensions_string', extstring) then
  7662. begin
  7663. wglGetExtensionsStringEXT := wglGetProcAddress('wglGetExtensionsStringEXT');
  7664. if not Assigned(wglGetExtensionsStringEXT) then Exit;
  7665. Result := TRUE;
  7666. end;
  7667. end;
  7668. function Load_WGL_EXT_make_current_read: Boolean;
  7669. var
  7670. extstring: String;
  7671. begin
  7672. Result := FALSE;
  7673. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7674. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7675. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7676. if glext_ExtensionSupported('WGL_EXT_make_current_read', extstring) then
  7677. begin
  7678. wglMakeContextCurrentEXT := wglGetProcAddress('wglMakeContextCurrentEXT');
  7679. if not Assigned(wglMakeContextCurrentEXT) then Exit;
  7680. wglGetCurrentReadDCEXT := wglGetProcAddress('wglGetCurrentReadDCEXT');
  7681. if not Assigned(wglGetCurrentReadDCEXT) then Exit;
  7682. Result := TRUE;
  7683. end;
  7684. end;
  7685. function Load_WGL_EXT_pbuffer: Boolean;
  7686. var
  7687. extstring: String;
  7688. begin
  7689. Result := FALSE;
  7690. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7691. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7692. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7693. if glext_ExtensionSupported('WGL_EXT_pbuffer', extstring) then
  7694. begin
  7695. wglCreatePbufferEXT := wglGetProcAddress('wglCreatePbufferEXT');
  7696. if not Assigned(wglCreatePbufferEXT) then Exit;
  7697. wglGetPbufferDCEXT := wglGetProcAddress('wglGetPbufferDCEXT');
  7698. if not Assigned(wglGetPbufferDCEXT) then Exit;
  7699. wglReleasePbufferDCEXT := wglGetProcAddress('wglReleasePbufferDCEXT');
  7700. if not Assigned(wglReleasePbufferDCEXT) then Exit;
  7701. wglDestroyPbufferEXT := wglGetProcAddress('wglDestroyPbufferEXT');
  7702. if not Assigned(wglDestroyPbufferEXT) then Exit;
  7703. wglQueryPbufferEXT := wglGetProcAddress('wglQueryPbufferEXT');
  7704. if not Assigned(wglQueryPbufferEXT) then Exit;
  7705. Result := TRUE;
  7706. end;
  7707. end;
  7708. function Load_WGL_EXT_pixel_format: Boolean;
  7709. var
  7710. extstring: String;
  7711. begin
  7712. Result := FALSE;
  7713. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7714. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7715. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7716. if glext_ExtensionSupported('WGL_EXT_pixel_format', extstring) then
  7717. begin
  7718. wglGetPixelFormatAttribivEXT := wglGetProcAddress('wglGetPixelFormatAttribivEXT');
  7719. if not Assigned(wglGetPixelFormatAttribivEXT) then Exit;
  7720. wglGetPixelFormatAttribfvEXT := wglGetProcAddress('wglGetPixelFormatAttribfvEXT');
  7721. if not Assigned(wglGetPixelFormatAttribfvEXT) then Exit;
  7722. wglChoosePixelFormatEXT := wglGetProcAddress('wglChoosePixelFormatEXT');
  7723. if not Assigned(wglChoosePixelFormatEXT) then Exit;
  7724. Result := TRUE;
  7725. end;
  7726. end;
  7727. function Load_WGL_I3D_digital_video_control: Boolean;
  7728. var
  7729. extstring: String;
  7730. begin
  7731. Result := FALSE;
  7732. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7733. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7734. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7735. if glext_ExtensionSupported('WGL_I3D_digital_video_control', extstring) then
  7736. begin
  7737. wglGetDigitalVideoParametersI3D := wglGetProcAddress('wglGetDigitalVideoParametersI3D');
  7738. if not Assigned(wglGetDigitalVideoParametersI3D) then Exit;
  7739. wglSetDigitalVideoParametersI3D := wglGetProcAddress('wglSetDigitalVideoParametersI3D');
  7740. if not Assigned(wglSetDigitalVideoParametersI3D) then Exit;
  7741. Result := TRUE;
  7742. end;
  7743. end;
  7744. function Load_WGL_I3D_gamma: Boolean;
  7745. var
  7746. extstring: String;
  7747. begin
  7748. Result := FALSE;
  7749. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7750. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7751. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7752. if glext_ExtensionSupported('WGL_I3D_gamma', extstring) then
  7753. begin
  7754. wglGetGammaTableParametersI3D := wglGetProcAddress('wglGetGammaTableParametersI3D');
  7755. if not Assigned(wglGetGammaTableParametersI3D) then Exit;
  7756. wglSetGammaTableParametersI3D := wglGetProcAddress('wglSetGammaTableParametersI3D');
  7757. if not Assigned(wglSetGammaTableParametersI3D) then Exit;
  7758. wglGetGammaTableI3D := wglGetProcAddress('wglGetGammaTableI3D');
  7759. if not Assigned(wglGetGammaTableI3D) then Exit;
  7760. wglSetGammaTableI3D := wglGetProcAddress('wglSetGammaTableI3D');
  7761. if not Assigned(wglSetGammaTableI3D) then Exit;
  7762. Result := TRUE;
  7763. end;
  7764. end;
  7765. function Load_WGL_I3D_genlock: Boolean;
  7766. var
  7767. extstring: String;
  7768. begin
  7769. Result := FALSE;
  7770. wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7771. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7772. extstring := String(PChar(wglGetExtensionsStringARB(wglGetCurrentDC)));
  7773. if glext_ExtensionSupported('WGL_I3D_genlock', extstring) then
  7774. begin
  7775. wglEnableGenlockI3D := wglGetProcAddress('wglEnableGenlockI3D');
  7776. if not Assigned(wglEnableGenlockI3D) then Exit;
  7777. wglDisableGenlockI3D := wglGetProcAddress('wglDisableGenlockI3D');
  7778. if not Assigned(wglDisableGenlockI3D) then Exit;
  7779. wglIsEnabledGenlockI3D := wglGetProcAddress('wglIsEnabledGenlockI3D');
  7780. if not Assigned(wglIsEnabledGenlockI3D) then Exit;
  7781. wglGenlockSourceI3D := wglGetProcAddress('wglGenlockSourceI3D');
  7782. if not Assigned(wglGenlockSourceI3D) then Exit;
  7783. wglGetGenlockSourceI3D := wglGetProcAddress('wglGetGenlockSourceI3D');
  7784. if not Assigned(wglGetGenlockSourceI3D) then Exit;
  7785. wglGenlockSourceEdgeI3D := wglGetProcAddress('wglGenlockSourceEdgeI3D');
  7786. if not Assigned(wglGenlockSourceEdgeI3D) then Exit;
  7787. wglGetGenlockSourceEdgeI3D := wglGetProcAddress('wglGetGenlockSourceEdgeI3D');
  7788. if not Assigned(wglGetGenlockSourceEdgeI3D) then Exit;
  7789. wglGenlockSampleRateI3D := wglGetProcAddress('wglGenlockSampleRateI3D');
  7790. if not Assigned(wglGenlockSampleRateI3D) then Exit;
  7791. wglGetGenlockSampleRateI3D := wglGetProcAddress('wglGetGenlockSampleRateI3D');
  7792. if not Assigned(wglGetGenlockSampleRateI3D) then Exit;
  7793. wglGenlockSourceDelayI3D := wglGetProcAddress('wglGenlockSourceDelayI3D');
  7794. if not Assigned(wglGenlockSourceDelayI3D) then Exit;
  7795. wglGetGenlockSourceDelayI3D := wglGetProcAddress('wglGetGenlockSourceDelayI3D');
  7796. if not Assigned(wglGetGenlockSourceDelayI3D) then Exit;
  7797. wglQueryGenlockMaxSourceDelayI3D := wglGetProcAddress('wglQueryGenlockMaxSourceDelayI3D');
  7798. if not Assigned(wglQueryGenlockMaxSourceDelayI3D) then Exit;
  7799. Result := TRUE;
  7800. end;
  7801. end;
  7802. {$ENDIF}
  7803. function Load_GL_ARB_matrix_palette: Boolean;
  7804. var
  7805. extstring: String;
  7806. begin
  7807. Result := FALSE;
  7808. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7809. if glext_ExtensionSupported('GL_ARB_matrix_palette', extstring) then
  7810. begin
  7811. glCurrentPaletteMatrixARB := wglGetProcAddress('glCurrentPaletteMatrixARB');
  7812. if not Assigned(glCurrentPaletteMatrixARB) then Exit;
  7813. glMatrixIndexubvARB := wglGetProcAddress('glMatrixIndexubvARB');
  7814. if not Assigned(glMatrixIndexubvARB) then Exit;
  7815. glMatrixIndexusvARB := wglGetProcAddress('glMatrixIndexusvARB');
  7816. if not Assigned(glMatrixIndexusvARB) then Exit;
  7817. glMatrixIndexuivARB := wglGetProcAddress('glMatrixIndexuivARB');
  7818. if not Assigned(glMatrixIndexuivARB) then Exit;
  7819. glMatrixIndexPointerARB := wglGetProcAddress('glMatrixIndexPointerARB');
  7820. if not Assigned(glMatrixIndexPointerARB) then Exit;
  7821. Result := TRUE;
  7822. end;
  7823. end;
  7824. function Load_GL_NV_element_array: Boolean;
  7825. var
  7826. extstring: String;
  7827. begin
  7828. Result := FALSE;
  7829. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7830. if glext_ExtensionSupported('GL_NV_element_array', extstring) then
  7831. begin
  7832. glElementPointerNV := wglGetProcAddress('glElementPointerNV');
  7833. if not Assigned(glElementPointerNV) then Exit;
  7834. glDrawElementArrayNV := wglGetProcAddress('glDrawElementArrayNV');
  7835. if not Assigned(glDrawElementArrayNV) then Exit;
  7836. glDrawRangeElementArrayNV := wglGetProcAddress('glDrawRangeElementArrayNV');
  7837. if not Assigned(glDrawRangeElementArrayNV) then Exit;
  7838. glMultiDrawElementArrayNV := wglGetProcAddress('glMultiDrawElementArrayNV');
  7839. if not Assigned(glMultiDrawElementArrayNV) then Exit;
  7840. glMultiDrawRangeElementArrayNV := wglGetProcAddress('glMultiDrawRangeElementArrayNV');
  7841. if not Assigned(glMultiDrawRangeElementArrayNV) then Exit;
  7842. Result := TRUE;
  7843. end;
  7844. end;
  7845. function Load_GL_NV_float_buffer: Boolean;
  7846. var
  7847. extstring: String;
  7848. begin
  7849. Result := FALSE;
  7850. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7851. if glext_ExtensionSupported('GL_NV_float_buffer', extstring) then
  7852. begin
  7853. Result := TRUE;
  7854. end;
  7855. end;
  7856. function Load_GL_NV_fragment_program: Boolean;
  7857. var
  7858. extstring: String;
  7859. begin
  7860. Result := FALSE;
  7861. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7862. if glext_ExtensionSupported('GL_NV_fragment_program', extstring) then
  7863. begin
  7864. glProgramNamedParameter4fNV := wglGetProcAddress('glProgramNamedParameter4fNV');
  7865. if not Assigned(glProgramNamedParameter4fNV) then Exit;
  7866. glProgramNamedParameter4dNV := wglGetProcAddress('glProgramNamedParameter4dNV');
  7867. if not Assigned(glProgramNamedParameter4dNV) then Exit;
  7868. glGetProgramNamedParameterfvNV := wglGetProcAddress('glGetProgramNamedParameterfvNV');
  7869. if not Assigned(glGetProgramNamedParameterfvNV) then Exit;
  7870. glGetProgramNamedParameterdvNV := wglGetProcAddress('glGetProgramNamedParameterdvNV');
  7871. if not Assigned(glGetProgramNamedParameterdvNV) then Exit;
  7872. glProgramLocalParameter4dARB := wglGetProcAddress('glProgramLocalParameter4dARB');
  7873. if not Assigned(glProgramLocalParameter4dARB) then Exit;
  7874. glProgramLocalParameter4dvARB := wglGetProcAddress('glProgramLocalParameter4dvARB');
  7875. if not Assigned(glProgramLocalParameter4dvARB) then Exit;
  7876. glProgramLocalParameter4fARB := wglGetProcAddress('glProgramLocalParameter4fARB');
  7877. if not Assigned(glProgramLocalParameter4fARB) then Exit;
  7878. glProgramLocalParameter4fvARB := wglGetProcAddress('glProgramLocalParameter4fvARB');
  7879. if not Assigned(glProgramLocalParameter4fvARB) then Exit;
  7880. glGetProgramLocalParameterdvARB := wglGetProcAddress('glGetProgramLocalParameterdvARB');
  7881. if not Assigned(glGetProgramLocalParameterdvARB) then Exit;
  7882. glGetProgramLocalParameterfvARB := wglGetProcAddress('glGetProgramLocalParameterfvARB');
  7883. if not Assigned(glGetProgramLocalParameterfvARB) then Exit;
  7884. Result := TRUE;
  7885. end;
  7886. end;
  7887. function Load_GL_NV_primitive_restart: Boolean;
  7888. var
  7889. extstring: String;
  7890. begin
  7891. Result := FALSE;
  7892. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7893. if glext_ExtensionSupported('GL_NV_primitive_restart', extstring) then
  7894. begin
  7895. glPrimitiveRestartNV := wglGetProcAddress('glPrimitiveRestartNV');
  7896. if not Assigned(glPrimitiveRestartNV) then Exit;
  7897. glPrimitiveRestartIndexNV := wglGetProcAddress('glPrimitiveRestartIndexNV');
  7898. if not Assigned(glPrimitiveRestartIndexNV) then Exit;
  7899. Result := TRUE;
  7900. end;
  7901. end;
  7902. function Load_GL_NV_vertex_program2: Boolean;
  7903. var
  7904. extstring: String;
  7905. begin
  7906. Result := FALSE;
  7907. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7908. if glext_ExtensionSupported('GL_NV_vertex_program2', extstring) then
  7909. begin
  7910. Result := TRUE;
  7911. end;
  7912. end;
  7913. {$IFDEF Windows}
  7914. function Load_WGL_NV_render_texture_rectangle: Boolean;
  7915. var
  7916. extstring: String;
  7917. begin
  7918. Result := FALSE;
  7919. @wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7920. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7921. extstring := wglGetExtensionsStringARB(wglGetCurrentDC);
  7922. if glext_ExtensionSupported('WGL_NV_render_texture_rectangle', extstring) then
  7923. begin
  7924. Result := TRUE;
  7925. end;
  7926. end;
  7927. {$ENDIF}
  7928. function Load_GL_NV_pixel_data_range: Boolean;
  7929. var
  7930. extstring: String;
  7931. begin
  7932. Result := FALSE;
  7933. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7934. if glext_ExtensionSupported('GL_NV_pixel_data_range', extstring) then
  7935. begin
  7936. @glPixelDataRangeNV := wglGetProcAddress('glPixelDataRangeNV');
  7937. if not Assigned(glPixelDataRangeNV) then Exit;
  7938. @glFlushPixelDataRangeNV := wglGetProcAddress('glFlushPixelDataRangeNV');
  7939. if not Assigned(glFlushPixelDataRangeNV) then Exit;
  7940. {$IFDEF Windows}
  7941. @wglAllocateMemoryNV := wglGetProcAddress('wglAllocateMemoryNV');
  7942. if not Assigned(wglAllocateMemoryNV) then Exit;
  7943. @wglFreeMemoryNV := wglGetProcAddress('wglFreeMemoryNV');
  7944. if not Assigned(wglFreeMemoryNV) then Exit;
  7945. {$ENDIF}
  7946. Result := TRUE;
  7947. end;
  7948. end;
  7949. function Load_GL_EXT_texture_rectangle: Boolean;
  7950. var
  7951. extstring: String;
  7952. begin
  7953. Result := FALSE;
  7954. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7955. if glext_ExtensionSupported('GL_EXT_texture_rectangle', extstring) then
  7956. begin
  7957. Result := TRUE;
  7958. end;
  7959. end;
  7960. function Load_GL_S3_s3tc: Boolean;
  7961. var
  7962. extstring: String;
  7963. begin
  7964. Result := FALSE;
  7965. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7966. if glext_ExtensionSupported('GL_S3_s3tc', extstring) then
  7967. begin
  7968. Result := TRUE;
  7969. end;
  7970. end;
  7971. function Load_GL_ATI_draw_buffers: Boolean;
  7972. var
  7973. extstring: String;
  7974. begin
  7975. Result := FALSE;
  7976. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  7977. if glext_ExtensionSupported('GL_ATI_draw_buffers', extstring) then
  7978. begin
  7979. @glDrawBuffersATI := wglGetProcAddress('glDrawBuffersATI');
  7980. if not Assigned(glDrawBuffersATI) then Exit;
  7981. Result := TRUE;
  7982. end;
  7983. end;
  7984. {$IFDEF Windows}
  7985. function Load_WGL_ATI_pixel_format_float: Boolean;
  7986. var
  7987. extstring: String;
  7988. begin
  7989. Result := FALSE;
  7990. @wglGetExtensionsStringARB := wglGetProcAddress('wglGetExtensionsStringARB');
  7991. if not Assigned(wglGetExtensionsStringARB) then Exit;
  7992. extstring := wglGetExtensionsStringARB(wglGetCurrentDC);
  7993. if glext_ExtensionSupported('WGL_ATI_pixel_format_float', extstring) then
  7994. begin
  7995. Result := TRUE;
  7996. end;
  7997. end;
  7998. {$ENDIF}
  7999. function Load_GL_ATI_texture_env_combine3: Boolean;
  8000. var
  8001. extstring: String;
  8002. begin
  8003. Result := FALSE;
  8004. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8005. if glext_ExtensionSupported('GL_ATI_texture_env_combine3', extstring) then
  8006. begin
  8007. Result := TRUE;
  8008. end;
  8009. end;
  8010. function Load_GL_ATI_texture_float: Boolean;
  8011. var
  8012. extstring: String;
  8013. begin
  8014. Result := FALSE;
  8015. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8016. if glext_ExtensionSupported('GL_ATI_texture_float', extstring) then
  8017. begin
  8018. Result := TRUE;
  8019. end;
  8020. end;
  8021. function Load_GL_NV_texture_expand_normal: Boolean;
  8022. var
  8023. extstring: String;
  8024. begin
  8025. Result := FALSE;
  8026. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8027. if glext_ExtensionSupported('GL_NV_texture_expand_normal', extstring) then
  8028. begin
  8029. Result := TRUE;
  8030. end;
  8031. end;
  8032. function Load_GL_NV_half_float: Boolean;
  8033. var
  8034. extstring: String;
  8035. begin
  8036. Result := FALSE;
  8037. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8038. if glext_ExtensionSupported('GL_NV_half_float', extstring) then
  8039. begin
  8040. @glVertex2hNV := wglGetProcAddress('glVertex2hNV');
  8041. if not Assigned(glVertex2hNV) then Exit;
  8042. @glVertex2hvNV := wglGetProcAddress('glVertex2hvNV');
  8043. if not Assigned(glVertex2hvNV) then Exit;
  8044. @glVertex3hNV := wglGetProcAddress('glVertex3hNV');
  8045. if not Assigned(glVertex3hNV) then Exit;
  8046. @glVertex3hvNV := wglGetProcAddress('glVertex3hvNV');
  8047. if not Assigned(glVertex3hvNV) then Exit;
  8048. @glVertex4hNV := wglGetProcAddress('glVertex4hNV');
  8049. if not Assigned(glVertex4hNV) then Exit;
  8050. @glVertex4hvNV := wglGetProcAddress('glVertex4hvNV');
  8051. if not Assigned(glVertex4hvNV) then Exit;
  8052. @glNormal3hNV := wglGetProcAddress('glNormal3hNV');
  8053. if not Assigned(glNormal3hNV) then Exit;
  8054. @glNormal3hvNV := wglGetProcAddress('glNormal3hvNV');
  8055. if not Assigned(glNormal3hvNV) then Exit;
  8056. @glColor3hNV := wglGetProcAddress('glColor3hNV');
  8057. if not Assigned(glColor3hNV) then Exit;
  8058. @glColor3hvNV := wglGetProcAddress('glColor3hvNV');
  8059. if not Assigned(glColor3hvNV) then Exit;
  8060. @glColor4hNV := wglGetProcAddress('glColor4hNV');
  8061. if not Assigned(glColor4hNV) then Exit;
  8062. @glColor4hvNV := wglGetProcAddress('glColor4hvNV');
  8063. if not Assigned(glColor4hvNV) then Exit;
  8064. @glTexCoord1hNV := wglGetProcAddress('glTexCoord1hNV');
  8065. if not Assigned(glTexCoord1hNV) then Exit;
  8066. @glTexCoord1hvNV := wglGetProcAddress('glTexCoord1hvNV');
  8067. if not Assigned(glTexCoord1hvNV) then Exit;
  8068. @glTexCoord2hNV := wglGetProcAddress('glTexCoord2hNV');
  8069. if not Assigned(glTexCoord2hNV) then Exit;
  8070. @glTexCoord2hvNV := wglGetProcAddress('glTexCoord2hvNV');
  8071. if not Assigned(glTexCoord2hvNV) then Exit;
  8072. @glTexCoord3hNV := wglGetProcAddress('glTexCoord3hNV');
  8073. if not Assigned(glTexCoord3hNV) then Exit;
  8074. @glTexCoord3hvNV := wglGetProcAddress('glTexCoord3hvNV');
  8075. if not Assigned(glTexCoord3hvNV) then Exit;
  8076. @glTexCoord4hNV := wglGetProcAddress('glTexCoord4hNV');
  8077. if not Assigned(glTexCoord4hNV) then Exit;
  8078. @glTexCoord4hvNV := wglGetProcAddress('glTexCoord4hvNV');
  8079. if not Assigned(glTexCoord4hvNV) then Exit;
  8080. @glMultiTexCoord1hNV := wglGetProcAddress('glMultiTexCoord1hNV');
  8081. if not Assigned(glMultiTexCoord1hNV) then Exit;
  8082. @glMultiTexCoord1hvNV := wglGetProcAddress('glMultiTexCoord1hvNV');
  8083. if not Assigned(glMultiTexCoord1hvNV) then Exit;
  8084. @glMultiTexCoord2hNV := wglGetProcAddress('glMultiTexCoord2hNV');
  8085. if not Assigned(glMultiTexCoord2hNV) then Exit;
  8086. @glMultiTexCoord2hvNV := wglGetProcAddress('glMultiTexCoord2hvNV');
  8087. if not Assigned(glMultiTexCoord2hvNV) then Exit;
  8088. @glMultiTexCoord3hNV := wglGetProcAddress('glMultiTexCoord3hNV');
  8089. if not Assigned(glMultiTexCoord3hNV) then Exit;
  8090. @glMultiTexCoord3hvNV := wglGetProcAddress('glMultiTexCoord3hvNV');
  8091. if not Assigned(glMultiTexCoord3hvNV) then Exit;
  8092. @glMultiTexCoord4hNV := wglGetProcAddress('glMultiTexCoord4hNV');
  8093. if not Assigned(glMultiTexCoord4hNV) then Exit;
  8094. @glMultiTexCoord4hvNV := wglGetProcAddress('glMultiTexCoord4hvNV');
  8095. if not Assigned(glMultiTexCoord4hvNV) then Exit;
  8096. @glFogCoordhNV := wglGetProcAddress('glFogCoordhNV');
  8097. if not Assigned(glFogCoordhNV) then Exit;
  8098. @glFogCoordhvNV := wglGetProcAddress('glFogCoordhvNV');
  8099. if not Assigned(glFogCoordhvNV) then Exit;
  8100. @glSecondaryColor3hNV := wglGetProcAddress('glSecondaryColor3hNV');
  8101. if not Assigned(glSecondaryColor3hNV) then Exit;
  8102. @glSecondaryColor3hvNV := wglGetProcAddress('glSecondaryColor3hvNV');
  8103. if not Assigned(glSecondaryColor3hvNV) then Exit;
  8104. @glVertexWeighthNV := wglGetProcAddress('glVertexWeighthNV');
  8105. if not Assigned(glVertexWeighthNV) then Exit;
  8106. @glVertexWeighthvNV := wglGetProcAddress('glVertexWeighthvNV');
  8107. if not Assigned(glVertexWeighthvNV) then Exit;
  8108. @glVertexAttrib1hNV := wglGetProcAddress('glVertexAttrib1hNV');
  8109. if not Assigned(glVertexAttrib1hNV) then Exit;
  8110. @glVertexAttrib1hvNV := wglGetProcAddress('glVertexAttrib1hvNV');
  8111. if not Assigned(glVertexAttrib1hvNV) then Exit;
  8112. @glVertexAttrib2hNV := wglGetProcAddress('glVertexAttrib2hNV');
  8113. if not Assigned(glVertexAttrib2hNV) then Exit;
  8114. @glVertexAttrib2hvNV := wglGetProcAddress('glVertexAttrib2hvNV');
  8115. if not Assigned(glVertexAttrib2hvNV) then Exit;
  8116. @glVertexAttrib3hNV := wglGetProcAddress('glVertexAttrib3hNV');
  8117. if not Assigned(glVertexAttrib3hNV) then Exit;
  8118. @glVertexAttrib3hvNV := wglGetProcAddress('glVertexAttrib3hvNV');
  8119. if not Assigned(glVertexAttrib3hvNV) then Exit;
  8120. @glVertexAttrib4hNV := wglGetProcAddress('glVertexAttrib4hNV');
  8121. if not Assigned(glVertexAttrib4hNV) then Exit;
  8122. @glVertexAttrib4hvNV := wglGetProcAddress('glVertexAttrib4hvNV');
  8123. if not Assigned(glVertexAttrib4hvNV) then Exit;
  8124. @glVertexAttribs1hvNV := wglGetProcAddress('glVertexAttribs1hvNV');
  8125. if not Assigned(glVertexAttribs1hvNV) then Exit;
  8126. @glVertexAttribs2hvNV := wglGetProcAddress('glVertexAttribs2hvNV');
  8127. if not Assigned(glVertexAttribs2hvNV) then Exit;
  8128. @glVertexAttribs3hvNV := wglGetProcAddress('glVertexAttribs3hvNV');
  8129. if not Assigned(glVertexAttribs3hvNV) then Exit;
  8130. @glVertexAttribs4hvNV := wglGetProcAddress('glVertexAttribs4hvNV');
  8131. if not Assigned(glVertexAttribs4hvNV) then Exit;
  8132. Result := TRUE;
  8133. end;
  8134. end;
  8135. function Load_GL_ATI_map_object_buffer: Boolean;
  8136. var
  8137. extstring: String;
  8138. begin
  8139. Result := FALSE;
  8140. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8141. if glext_ExtensionSupported('GL_ATI_map_object_buffer', extstring) then
  8142. begin
  8143. @glMapObjectBufferATI := wglGetProcAddress('glMapObjectBufferATI');
  8144. if not Assigned(glMapObjectBufferATI) then Exit;
  8145. @glUnmapObjectBufferATI := wglGetProcAddress('glUnmapObjectBufferATI');
  8146. if not Assigned(glUnmapObjectBufferATI) then Exit;
  8147. Result := TRUE;
  8148. end;
  8149. end;
  8150. function Load_GL_ATI_separate_stencil: Boolean;
  8151. var
  8152. extstring: String;
  8153. begin
  8154. Result := FALSE;
  8155. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8156. if glext_ExtensionSupported('GL_ATI_separate_stencil', extstring) then
  8157. begin
  8158. @glStencilOpSeparateATI := wglGetProcAddress('glStencilOpSeparateATI');
  8159. if not Assigned(glStencilOpSeparateATI) then Exit;
  8160. @glStencilFuncSeparateATI := wglGetProcAddress('glStencilFuncSeparateATI');
  8161. if not Assigned(glStencilFuncSeparateATI) then Exit;
  8162. Result := TRUE;
  8163. end;
  8164. end;
  8165. function Load_GL_ATI_vertex_attrib_array_object: Boolean;
  8166. var
  8167. extstring: String;
  8168. begin
  8169. Result := FALSE;
  8170. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8171. if glext_ExtensionSupported('GL_ATI_vertex_attrib_array_object', extstring) then
  8172. begin
  8173. @glVertexAttribArrayObjectATI := wglGetProcAddress('glVertexAttribArrayObjectATI');
  8174. if not Assigned(glVertexAttribArrayObjectATI) then Exit;
  8175. @glGetVertexAttribArrayObjectfvATI := wglGetProcAddress('glGetVertexAttribArrayObjectfvATI');
  8176. if not Assigned(glGetVertexAttribArrayObjectfvATI) then Exit;
  8177. @glGetVertexAttribArrayObjectivATI := wglGetProcAddress('glGetVertexAttribArrayObjectivATI');
  8178. if not Assigned(glGetVertexAttribArrayObjectivATI) then Exit;
  8179. Result := TRUE;
  8180. end;
  8181. end;
  8182. function Load_GL_ARB_occlusion_query: Boolean;
  8183. var
  8184. extstring: String;
  8185. begin
  8186. Result := FALSE;
  8187. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8188. if glext_ExtensionSupported('GL_ARB_occlusion_query', extstring) then
  8189. begin
  8190. @glGenQueriesARB := wglGetProcAddress('glGenQueriesARB');
  8191. if not Assigned(glGenQueriesARB) then Exit;
  8192. @glDeleteQueriesARB := wglGetProcAddress('glDeleteQueriesARB');
  8193. if not Assigned(glDeleteQueriesARB) then Exit;
  8194. @glIsQueryARB := wglGetProcAddress('glIsQueryARB');
  8195. if not Assigned(glIsQueryARB) then Exit;
  8196. @glBeginQueryARB := wglGetProcAddress('glBeginQueryARB');
  8197. if not Assigned(glBeginQueryARB) then Exit;
  8198. @glEndQueryARB := wglGetProcAddress('glEndQueryARB');
  8199. if not Assigned(glEndQueryARB) then Exit;
  8200. @glGetQueryivARB := wglGetProcAddress('glGetQueryivARB');
  8201. if not Assigned(glGetQueryivARB) then Exit;
  8202. @glGetQueryObjectivARB := wglGetProcAddress('glGetQueryObjectivARB');
  8203. if not Assigned(glGetQueryObjectivARB) then Exit;
  8204. @glGetQueryObjectuivARB := wglGetProcAddress('glGetQueryObjectuivARB');
  8205. if not Assigned(glGetQueryObjectuivARB) then Exit;
  8206. Result := TRUE;
  8207. end;
  8208. end;
  8209. function Load_GL_ARB_shader_objects: Boolean;
  8210. var
  8211. extstring: String;
  8212. begin
  8213. Result := FALSE;
  8214. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8215. if glext_ExtensionSupported('GL_ARB_shader_objects', extstring) then
  8216. begin
  8217. @glDeleteObjectARB := wglGetProcAddress('glDeleteObjectARB');
  8218. if not Assigned(glDeleteObjectARB) then Exit;
  8219. @glGetHandleARB := wglGetProcAddress('glGetHandleARB');
  8220. if not Assigned(glGetHandleARB) then Exit;
  8221. @glDetachObjectARB := wglGetProcAddress('glDetachObjectARB');
  8222. if not Assigned(glDetachObjectARB) then Exit;
  8223. @glCreateShaderObjectARB := wglGetProcAddress('glCreateShaderObjectARB');
  8224. if not Assigned(glCreateShaderObjectARB) then Exit;
  8225. @glShaderSourceARB := wglGetProcAddress('glShaderSourceARB');
  8226. if not Assigned(glShaderSourceARB) then Exit;
  8227. @glCompileShaderARB := wglGetProcAddress('glCompileShaderARB');
  8228. if not Assigned(glCompileShaderARB) then Exit;
  8229. @glCreateProgramObjectARB := wglGetProcAddress('glCreateProgramObjectARB');
  8230. if not Assigned(glCreateProgramObjectARB) then Exit;
  8231. @glAttachObjectARB := wglGetProcAddress('glAttachObjectARB');
  8232. if not Assigned(glAttachObjectARB) then Exit;
  8233. @glLinkProgramARB := wglGetProcAddress('glLinkProgramARB');
  8234. if not Assigned(glLinkProgramARB) then Exit;
  8235. @glUseProgramObjectARB := wglGetProcAddress('glUseProgramObjectARB');
  8236. if not Assigned(glUseProgramObjectARB) then Exit;
  8237. @glValidateProgramARB := wglGetProcAddress('glValidateProgramARB');
  8238. if not Assigned(glValidateProgramARB) then Exit;
  8239. @glUniform1fARB := wglGetProcAddress('glUniform1fARB');
  8240. if not Assigned(glUniform1fARB) then Exit;
  8241. @glUniform2fARB := wglGetProcAddress('glUniform2fARB');
  8242. if not Assigned(glUniform2fARB) then Exit;
  8243. @glUniform3fARB := wglGetProcAddress('glUniform3fARB');
  8244. if not Assigned(glUniform3fARB) then Exit;
  8245. @glUniform4fARB := wglGetProcAddress('glUniform4fARB');
  8246. if not Assigned(glUniform4fARB) then Exit;
  8247. @glUniform1iARB := wglGetProcAddress('glUniform1iARB');
  8248. if not Assigned(glUniform1iARB) then Exit;
  8249. @glUniform2iARB := wglGetProcAddress('glUniform2iARB');
  8250. if not Assigned(glUniform2iARB) then Exit;
  8251. @glUniform3iARB := wglGetProcAddress('glUniform3iARB');
  8252. if not Assigned(glUniform3iARB) then Exit;
  8253. @glUniform4iARB := wglGetProcAddress('glUniform4iARB');
  8254. if not Assigned(glUniform4iARB) then Exit;
  8255. @glUniform1fvARB := wglGetProcAddress('glUniform1fvARB');
  8256. if not Assigned(glUniform1fvARB) then Exit;
  8257. @glUniform2fvARB := wglGetProcAddress('glUniform2fvARB');
  8258. if not Assigned(glUniform2fvARB) then Exit;
  8259. @glUniform3fvARB := wglGetProcAddress('glUniform3fvARB');
  8260. if not Assigned(glUniform3fvARB) then Exit;
  8261. @glUniform4fvARB := wglGetProcAddress('glUniform4fvARB');
  8262. if not Assigned(glUniform4fvARB) then Exit;
  8263. @glUniform1ivARB := wglGetProcAddress('glUniform1ivARB');
  8264. if not Assigned(glUniform1ivARB) then Exit;
  8265. @glUniform2ivARB := wglGetProcAddress('glUniform2ivARB');
  8266. if not Assigned(glUniform2ivARB) then Exit;
  8267. @glUniform3ivARB := wglGetProcAddress('glUniform3ivARB');
  8268. if not Assigned(glUniform3ivARB) then Exit;
  8269. @glUniform4ivARB := wglGetProcAddress('glUniform4ivARB');
  8270. if not Assigned(glUniform4ivARB) then Exit;
  8271. @glUniformMatrix2fvARB := wglGetProcAddress('glUniformMatrix2fvARB');
  8272. if not Assigned(glUniformMatrix2fvARB) then Exit;
  8273. @glUniformMatrix3fvARB := wglGetProcAddress('glUniformMatrix3fvARB');
  8274. if not Assigned(glUniformMatrix3fvARB) then Exit;
  8275. @glUniformMatrix4fvARB := wglGetProcAddress('glUniformMatrix4fvARB');
  8276. if not Assigned(glUniformMatrix4fvARB) then Exit;
  8277. @glGetObjectParameterfvARB := wglGetProcAddress('glGetObjectParameterfvARB');
  8278. if not Assigned(glGetObjectParameterfvARB) then Exit;
  8279. @glGetObjectParameterivARB := wglGetProcAddress('glGetObjectParameterivARB');
  8280. if not Assigned(glGetObjectParameterivARB) then Exit;
  8281. @glGetInfoLogARB := wglGetProcAddress('glGetInfoLogARB');
  8282. if not Assigned(glGetInfoLogARB) then Exit;
  8283. @glGetAttachedObjectsARB := wglGetProcAddress('glGetAttachedObjectsARB');
  8284. if not Assigned(glGetAttachedObjectsARB) then Exit;
  8285. @glGetUniformLocationARB := wglGetProcAddress('glGetUniformLocationARB');
  8286. if not Assigned(glGetUniformLocationARB) then Exit;
  8287. @glGetActiveUniformARB := wglGetProcAddress('glGetActiveUniformARB');
  8288. if not Assigned(glGetActiveUniformARB) then Exit;
  8289. @glGetUniformfvARB := wglGetProcAddress('glGetUniformfvARB');
  8290. if not Assigned(glGetUniformfvARB) then Exit;
  8291. @glGetUniformivARB := wglGetProcAddress('glGetUniformivARB');
  8292. if not Assigned(glGetUniformivARB) then Exit;
  8293. @glGetShaderSourceARB := wglGetProcAddress('glGetShaderSourceARB');
  8294. if not Assigned(glGetShaderSourceARB) then Exit;
  8295. Result := TRUE;
  8296. end;
  8297. end;
  8298. function Load_GL_ARB_vertex_shader: Boolean;
  8299. var
  8300. extstring: String;
  8301. begin
  8302. Result := FALSE;
  8303. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8304. if glext_ExtensionSupported('GL_ARB_vertex_shader', extstring) then
  8305. begin
  8306. @glVertexAttrib1fARB := wglGetProcAddress('glVertexAttrib1fARB');
  8307. if not Assigned(glVertexAttrib1fARB) then Exit;
  8308. @glVertexAttrib1sARB := wglGetProcAddress('glVertexAttrib1sARB');
  8309. if not Assigned(glVertexAttrib1sARB) then Exit;
  8310. @glVertexAttrib1dARB := wglGetProcAddress('glVertexAttrib1dARB');
  8311. if not Assigned(glVertexAttrib1dARB) then Exit;
  8312. @glVertexAttrib2fARB := wglGetProcAddress('glVertexAttrib2fARB');
  8313. if not Assigned(glVertexAttrib2fARB) then Exit;
  8314. @glVertexAttrib2sARB := wglGetProcAddress('glVertexAttrib2sARB');
  8315. if not Assigned(glVertexAttrib2sARB) then Exit;
  8316. @glVertexAttrib2dARB := wglGetProcAddress('glVertexAttrib2dARB');
  8317. if not Assigned(glVertexAttrib2dARB) then Exit;
  8318. @glVertexAttrib3fARB := wglGetProcAddress('glVertexAttrib3fARB');
  8319. if not Assigned(glVertexAttrib3fARB) then Exit;
  8320. @glVertexAttrib3sARB := wglGetProcAddress('glVertexAttrib3sARB');
  8321. if not Assigned(glVertexAttrib3sARB) then Exit;
  8322. @glVertexAttrib3dARB := wglGetProcAddress('glVertexAttrib3dARB');
  8323. if not Assigned(glVertexAttrib3dARB) then Exit;
  8324. @glVertexAttrib4fARB := wglGetProcAddress('glVertexAttrib4fARB');
  8325. if not Assigned(glVertexAttrib4fARB) then Exit;
  8326. @glVertexAttrib4sARB := wglGetProcAddress('glVertexAttrib4sARB');
  8327. if not Assigned(glVertexAttrib4sARB) then Exit;
  8328. @glVertexAttrib4dARB := wglGetProcAddress('glVertexAttrib4dARB');
  8329. if not Assigned(glVertexAttrib4dARB) then Exit;
  8330. @glVertexAttrib4NubARB := wglGetProcAddress('glVertexAttrib4NubARB');
  8331. if not Assigned(glVertexAttrib4NubARB) then Exit;
  8332. @glVertexAttrib1fvARB := wglGetProcAddress('glVertexAttrib1fvARB');
  8333. if not Assigned(glVertexAttrib1fvARB) then Exit;
  8334. @glVertexAttrib1svARB := wglGetProcAddress('glVertexAttrib1svARB');
  8335. if not Assigned(glVertexAttrib1svARB) then Exit;
  8336. @glVertexAttrib1dvARB := wglGetProcAddress('glVertexAttrib1dvARB');
  8337. if not Assigned(glVertexAttrib1dvARB) then Exit;
  8338. @glVertexAttrib2fvARB := wglGetProcAddress('glVertexAttrib2fvARB');
  8339. if not Assigned(glVertexAttrib2fvARB) then Exit;
  8340. @glVertexAttrib2svARB := wglGetProcAddress('glVertexAttrib2svARB');
  8341. if not Assigned(glVertexAttrib2svARB) then Exit;
  8342. @glVertexAttrib2dvARB := wglGetProcAddress('glVertexAttrib2dvARB');
  8343. if not Assigned(glVertexAttrib2dvARB) then Exit;
  8344. @glVertexAttrib3fvARB := wglGetProcAddress('glVertexAttrib3fvARB');
  8345. if not Assigned(glVertexAttrib3fvARB) then Exit;
  8346. @glVertexAttrib3svARB := wglGetProcAddress('glVertexAttrib3svARB');
  8347. if not Assigned(glVertexAttrib3svARB) then Exit;
  8348. @glVertexAttrib3dvARB := wglGetProcAddress('glVertexAttrib3dvARB');
  8349. if not Assigned(glVertexAttrib3dvARB) then Exit;
  8350. @glVertexAttrib4fvARB := wglGetProcAddress('glVertexAttrib4fvARB');
  8351. if not Assigned(glVertexAttrib4fvARB) then Exit;
  8352. @glVertexAttrib4svARB := wglGetProcAddress('glVertexAttrib4svARB');
  8353. if not Assigned(glVertexAttrib4svARB) then Exit;
  8354. @glVertexAttrib4dvARB := wglGetProcAddress('glVertexAttrib4dvARB');
  8355. if not Assigned(glVertexAttrib4dvARB) then Exit;
  8356. @glVertexAttrib4ivARB := wglGetProcAddress('glVertexAttrib4ivARB');
  8357. if not Assigned(glVertexAttrib4ivARB) then Exit;
  8358. @glVertexAttrib4bvARB := wglGetProcAddress('glVertexAttrib4bvARB');
  8359. if not Assigned(glVertexAttrib4bvARB) then Exit;
  8360. @glVertexAttrib4ubvARB := wglGetProcAddress('glVertexAttrib4ubvARB');
  8361. if not Assigned(glVertexAttrib4ubvARB) then Exit;
  8362. @glVertexAttrib4usvARB := wglGetProcAddress('glVertexAttrib4usvARB');
  8363. if not Assigned(glVertexAttrib4usvARB) then Exit;
  8364. @glVertexAttrib4uivARB := wglGetProcAddress('glVertexAttrib4uivARB');
  8365. if not Assigned(glVertexAttrib4uivARB) then Exit;
  8366. @glVertexAttrib4NbvARB := wglGetProcAddress('glVertexAttrib4NbvARB');
  8367. if not Assigned(glVertexAttrib4NbvARB) then Exit;
  8368. @glVertexAttrib4NsvARB := wglGetProcAddress('glVertexAttrib4NsvARB');
  8369. if not Assigned(glVertexAttrib4NsvARB) then Exit;
  8370. @glVertexAttrib4NivARB := wglGetProcAddress('glVertexAttrib4NivARB');
  8371. if not Assigned(glVertexAttrib4NivARB) then Exit;
  8372. @glVertexAttrib4NubvARB := wglGetProcAddress('glVertexAttrib4NubvARB');
  8373. if not Assigned(glVertexAttrib4NubvARB) then Exit;
  8374. @glVertexAttrib4NusvARB := wglGetProcAddress('glVertexAttrib4NusvARB');
  8375. if not Assigned(glVertexAttrib4NusvARB) then Exit;
  8376. @glVertexAttrib4NuivARB := wglGetProcAddress('glVertexAttrib4NuivARB');
  8377. if not Assigned(glVertexAttrib4NuivARB) then Exit;
  8378. @glVertexAttribPointerARB := wglGetProcAddress('glVertexAttribPointerARB');
  8379. if not Assigned(glVertexAttribPointerARB) then Exit;
  8380. @glEnableVertexAttribArrayARB := wglGetProcAddress('glEnableVertexAttribArrayARB');
  8381. if not Assigned(glEnableVertexAttribArrayARB) then Exit;
  8382. @glDisableVertexAttribArrayARB := wglGetProcAddress('glDisableVertexAttribArrayARB');
  8383. if not Assigned(glDisableVertexAttribArrayARB) then Exit;
  8384. @glBindAttribLocationARB := wglGetProcAddress('glBindAttribLocationARB');
  8385. if not Assigned(glBindAttribLocationARB) then Exit;
  8386. @glGetActiveAttribARB := wglGetProcAddress('glGetActiveAttribARB');
  8387. if not Assigned(glGetActiveAttribARB) then Exit;
  8388. @glGetAttribLocationARB := wglGetProcAddress('glGetAttribLocationARB');
  8389. if not Assigned(glGetAttribLocationARB) then Exit;
  8390. @glGetVertexAttribdvARB := wglGetProcAddress('glGetVertexAttribdvARB');
  8391. if not Assigned(glGetVertexAttribdvARB) then Exit;
  8392. @glGetVertexAttribfvARB := wglGetProcAddress('glGetVertexAttribfvARB');
  8393. if not Assigned(glGetVertexAttribfvARB) then Exit;
  8394. @glGetVertexAttribivARB := wglGetProcAddress('glGetVertexAttribivARB');
  8395. if not Assigned(glGetVertexAttribivARB) then Exit;
  8396. @glGetVertexAttribPointervARB := wglGetProcAddress('glGetVertexAttribPointervARB');
  8397. if not Assigned(glGetVertexAttribPointervARB) then Exit;
  8398. Result := TRUE;
  8399. end;
  8400. end;
  8401. function Load_GL_ARB_fragment_shader: Boolean;
  8402. var
  8403. extstring: String;
  8404. begin
  8405. Result := FALSE;
  8406. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8407. if glext_ExtensionSupported('GL_ARB_fragment_shader', extstring) then
  8408. begin
  8409. Result := TRUE;
  8410. end;
  8411. end;
  8412. function Load_GL_ARB_shading_language_100: Boolean;
  8413. var
  8414. extstring: String;
  8415. begin
  8416. Result := FALSE;
  8417. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8418. if glext_ExtensionSupported('GL_ARB_shading_language_100', extstring) then
  8419. begin
  8420. Result := TRUE;
  8421. end;
  8422. end;
  8423. function Load_GL_ARB_texture_non_power_of_two: Boolean;
  8424. var
  8425. extstring: String;
  8426. begin
  8427. Result := FALSE;
  8428. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8429. if glext_ExtensionSupported('GL_ARB_texture_non_power_of_two', extstring) then
  8430. begin
  8431. Result := TRUE;
  8432. end;
  8433. end;
  8434. function Load_GL_ARB_point_sprite: Boolean;
  8435. var
  8436. extstring: String;
  8437. begin
  8438. Result := FALSE;
  8439. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8440. if glext_ExtensionSupported('GL_ARB_point_sprite', extstring) then
  8441. begin
  8442. Result := TRUE;
  8443. end;
  8444. end;
  8445. function Load_GL_EXT_depth_bounds_test: Boolean;
  8446. var
  8447. extstring: String;
  8448. begin
  8449. Result := FALSE;
  8450. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8451. if glext_ExtensionSupported('GL_EXT_depth_bounds_test', extstring) then
  8452. begin
  8453. @glDepthBoundsEXT := wglGetProcAddress('glDepthBoundsEXT');
  8454. if not Assigned(glDepthBoundsEXT) then Exit;
  8455. Result := TRUE;
  8456. end;
  8457. end;
  8458. function Load_GL_EXT_texture_mirror_clamp: Boolean;
  8459. var
  8460. extstring: String;
  8461. begin
  8462. Result := FALSE;
  8463. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8464. if glext_ExtensionSupported('GL_EXT_texture_mirror_clamp', extstring) then
  8465. begin
  8466. Result := TRUE;
  8467. end;
  8468. end;
  8469. function Load_GL_EXT_blend_equation_separate: Boolean;
  8470. var
  8471. extstring: String;
  8472. begin
  8473. Result := FALSE;
  8474. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8475. if glext_ExtensionSupported('GL_EXT_blend_equation_separate', extstring) then
  8476. begin
  8477. @glBlendEquationSeparateEXT := wglGetProcAddress('glBlendEquationSeparateEXT');
  8478. if not Assigned(glBlendEquationSeparateEXT) then Exit;
  8479. Result := TRUE;
  8480. end;
  8481. end;
  8482. function Load_GL_MESA_pack_invert: Boolean;
  8483. var
  8484. extstring: String;
  8485. begin
  8486. Result := FALSE;
  8487. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8488. if glext_ExtensionSupported('GL_MESA_pack_invert', extstring) then
  8489. begin
  8490. Result := TRUE;
  8491. end;
  8492. end;
  8493. function Load_GL_MESA_ycbcr_texture: Boolean;
  8494. var
  8495. extstring: String;
  8496. begin
  8497. Result := FALSE;
  8498. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8499. if glext_ExtensionSupported('GL_MESA_ycbcr_texture', extstring) then
  8500. begin
  8501. Result := TRUE;
  8502. end;
  8503. end;
  8504. function Load_GL_ARB_fragment_program_shadow: Boolean;
  8505. var
  8506. extstring: String;
  8507. begin
  8508. Result := FALSE;
  8509. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8510. if glext_ExtensionSupported('GL_ARB_fragment_program_shadow', extstring) then
  8511. begin
  8512. Result := TRUE;
  8513. end;
  8514. end;
  8515. function Load_GL_NV_fragment_program_option: Boolean;
  8516. var
  8517. extstring: String;
  8518. begin
  8519. Result := FALSE;
  8520. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8521. if glext_ExtensionSupported('GL_NV_fragment_program_option', extstring) then
  8522. begin
  8523. Result := TRUE;
  8524. end;
  8525. end;
  8526. function Load_GL_EXT_pixel_buffer_object: Boolean;
  8527. var
  8528. extstring: String;
  8529. begin
  8530. Result := FALSE;
  8531. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8532. if glext_ExtensionSupported('GL_EXT_pixel_buffer_object', extstring) then
  8533. begin
  8534. Result := TRUE;
  8535. end;
  8536. end;
  8537. function Load_GL_NV_fragment_program2: Boolean;
  8538. var
  8539. extstring: String;
  8540. begin
  8541. Result := FALSE;
  8542. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8543. if glext_ExtensionSupported('GL_NV_fragment_program2', extstring) then
  8544. begin
  8545. Result := TRUE;
  8546. end;
  8547. end;
  8548. function Load_GL_NV_vertex_program2_option: Boolean;
  8549. var
  8550. extstring: String;
  8551. begin
  8552. Result := FALSE;
  8553. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8554. if glext_ExtensionSupported('GL_NV_vertex_program2_option', extstring) then
  8555. begin
  8556. Result := TRUE;
  8557. end;
  8558. end;
  8559. function Load_GL_NV_vertex_program3: Boolean;
  8560. var
  8561. extstring: String;
  8562. begin
  8563. Result := FALSE;
  8564. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8565. if glext_ExtensionSupported('GL_NV_vertex_program3', extstring) then
  8566. begin
  8567. Result := TRUE;
  8568. end;
  8569. end;
  8570. function Load_GL_ARB_draw_buffers: Boolean;
  8571. var
  8572. extstring: PChar;
  8573. begin
  8574. Result := FALSE;
  8575. extstring := glGetString(GL_EXTENSIONS);
  8576. if glext_ExtensionSupported('GL_ARB_draw_buffers', extstring) then
  8577. begin
  8578. glDrawBuffersARB := wglGetProcAddress('glDrawBuffersARB');
  8579. if not Assigned(glDrawBuffersARB) then Exit;
  8580. Result := TRUE;
  8581. end;
  8582. end;
  8583. function Load_GL_ARB_texture_rectangle: Boolean;
  8584. var
  8585. extstring: PChar;
  8586. begin
  8587. Result := FALSE;
  8588. extstring := glGetString(GL_EXTENSIONS);
  8589. if glext_ExtensionSupported('GL_ARB_texture_rectangle', extstring) then
  8590. begin
  8591. Result := TRUE;
  8592. end;
  8593. end;
  8594. function Load_GL_ARB_color_buffer_float: Boolean;
  8595. var
  8596. extstring: PChar;
  8597. begin
  8598. Result := FALSE;
  8599. extstring := glGetString(GL_EXTENSIONS);
  8600. if glext_ExtensionSupported('GL_ARB_color_buffer_float', extstring) then
  8601. begin
  8602. glClampColorARB := wglGetProcAddress('glClampColorARB');
  8603. if not Assigned(glClampColorARB) then Exit;
  8604. Result := TRUE;
  8605. end;
  8606. end;
  8607. function Load_GL_ARB_half_float_pixel: Boolean;
  8608. var
  8609. extstring: PChar;
  8610. begin
  8611. Result := FALSE;
  8612. extstring := glGetString(GL_EXTENSIONS);
  8613. if glext_ExtensionSupported('GL_ARB_half_float_pixel', extstring) then
  8614. begin
  8615. Result := TRUE;
  8616. end;
  8617. end;
  8618. function Load_GL_ARB_texture_float: Boolean;
  8619. var
  8620. extstring: PChar;
  8621. begin
  8622. Result := FALSE;
  8623. extstring := glGetString(GL_EXTENSIONS);
  8624. if glext_ExtensionSupported('GL_ARB_texture_float', extstring) then
  8625. begin
  8626. Result := TRUE;
  8627. end;
  8628. end;
  8629. function Load_GL_EXT_texture_compression_dxt1: Boolean;
  8630. var
  8631. extstring: PChar;
  8632. begin
  8633. Result := FALSE;
  8634. extstring := glGetString(GL_EXTENSIONS);
  8635. if glext_ExtensionSupported('GL_EXT_texture_compression_dxt1', extstring) then
  8636. begin
  8637. Result := TRUE;
  8638. end;
  8639. end;
  8640. function Load_GL_ARB_pixel_buffer_object: Boolean;
  8641. var
  8642. extstring: PChar;
  8643. begin
  8644. Result := FALSE;
  8645. extstring := glGetString(GL_EXTENSIONS);
  8646. if glext_ExtensionSupported('GL_ARB_pixel_buffer_object', extstring) then
  8647. begin
  8648. Result := TRUE;
  8649. end;
  8650. end;
  8651. function Load_GL_EXT_framebuffer_object: Boolean;
  8652. var
  8653. extstring: PChar;
  8654. begin
  8655. Result := FALSE;
  8656. extstring := glGetString(GL_EXTENSIONS);
  8657. if glext_ExtensionSupported('GL_EXT_framebuffer_object', extstring) then
  8658. begin
  8659. glIsRenderbufferEXT := wglGetProcAddress('glIsRenderbufferEXT');
  8660. if not Assigned(glIsRenderbufferEXT) then Exit;
  8661. glBindRenderbufferEXT := wglGetProcAddress('glBindRenderbufferEXT');
  8662. if not Assigned(glBindRenderbufferEXT) then Exit;
  8663. glDeleteRenderbuffersEXT := wglGetProcAddress('glDeleteRenderbuffersEXT');
  8664. if not Assigned(glDeleteRenderbuffersEXT) then Exit;
  8665. glGenRenderbuffersEXT := wglGetProcAddress('glGenRenderbuffersEXT');
  8666. if not Assigned(glGenRenderbuffersEXT) then Exit;
  8667. glRenderbufferStorageEXT := wglGetProcAddress('glRenderbufferStorageEXT');
  8668. if not Assigned(glRenderbufferStorageEXT) then Exit;
  8669. glGetRenderbufferParameterivEXT := wglGetProcAddress('glGetRenderbufferParameterivEXT');
  8670. if not Assigned(glGetRenderbufferParameterivEXT) then Exit;
  8671. glIsFramebufferEXT := wglGetProcAddress('glIsFramebufferEXT');
  8672. if not Assigned(glIsFramebufferEXT) then Exit;
  8673. glBindFramebufferEXT := wglGetProcAddress('glBindFramebufferEXT');
  8674. if not Assigned(glBindFramebufferEXT) then Exit;
  8675. glDeleteFramebuffersEXT := wglGetProcAddress('glDeleteFramebuffersEXT');
  8676. if not Assigned(glDeleteFramebuffersEXT) then Exit;
  8677. glGenFramebuffersEXT := wglGetProcAddress('glGenFramebuffersEXT');
  8678. if not Assigned(glGenFramebuffersEXT) then Exit;
  8679. glCheckFramebufferStatusEXT := wglGetProcAddress('glCheckFramebufferStatusEXT');
  8680. if not Assigned(glCheckFramebufferStatusEXT) then Exit;
  8681. glFramebufferTexture1DEXT := wglGetProcAddress('glFramebufferTexture1DEXT');
  8682. if not Assigned(glFramebufferTexture1DEXT) then Exit;
  8683. glFramebufferTexture2DEXT := wglGetProcAddress('glFramebufferTexture2DEXT');
  8684. if not Assigned(glFramebufferTexture2DEXT) then Exit;
  8685. glFramebufferTexture3DEXT := wglGetProcAddress('glFramebufferTexture3DEXT');
  8686. if not Assigned(glFramebufferTexture3DEXT) then Exit;
  8687. glFramebufferRenderbufferEXT := wglGetProcAddress('glFramebufferRenderbufferEXT');
  8688. if not Assigned(glFramebufferRenderbufferEXT) then Exit;
  8689. glGetFramebufferAttachmentParameterivEXT := wglGetProcAddress('glGetFramebufferAttachmentParameterivEXT');
  8690. if not Assigned(glGetFramebufferAttachmentParameterivEXT) then Exit;
  8691. glGenerateMipmapEXT := wglGetProcAddress('glGenerateMipmapEXT');
  8692. if not Assigned(glGenerateMipmapEXT) then Exit;
  8693. Result := TRUE;
  8694. end;
  8695. end;
  8696. function Load_GL_ARB_framebuffer_object(LoadAsCore: boolean): Boolean;
  8697. var
  8698. extstring: String;
  8699. begin
  8700. Result := False;
  8701. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8702. if LoadAsCore or glext_ExtensionSupported('GL_ARB_framebuffer_object', extstring) then
  8703. begin
  8704. glIsRenderbuffer := wglGetProcAddress('glIsRenderbuffer');
  8705. if not Assigned(glIsRenderbuffer) then Exit;
  8706. glBindRenderbuffer := wglGetProcAddress('glBindRenderbuffer');
  8707. if not Assigned(glBindRenderbuffer) then Exit;
  8708. glDeleteRenderbuffers := wglGetProcAddress('glDeleteRenderbuffers');
  8709. if not Assigned(glDeleteRenderbuffers) then Exit;
  8710. glGenRenderbuffers := wglGetProcAddress('glGenRenderbuffers');
  8711. if not Assigned(glGenRenderbuffers) then Exit;
  8712. glRenderbufferStorage := wglGetProcAddress('glRenderbufferStorage');
  8713. if not Assigned(glRenderbufferStorage) then Exit;
  8714. glGetRenderbufferParameteriv := wglGetProcAddress('glGetRenderbufferParameteriv');
  8715. if not Assigned(glGetRenderbufferParameteriv) then Exit;
  8716. glIsFramebuffer := wglGetProcAddress('glIsFramebuffer');
  8717. if not Assigned(glIsFramebuffer) then Exit;
  8718. glBindFramebuffer := wglGetProcAddress('glBindFramebuffer');
  8719. if not Assigned(glBindFramebuffer) then Exit;
  8720. glDeleteFramebuffers := wglGetProcAddress('glDeleteFramebuffers');
  8721. if not Assigned(glDeleteFramebuffers) then Exit;
  8722. glGenFramebuffers := wglGetProcAddress('glGenFramebuffers');
  8723. if not Assigned(glGenFramebuffers) then Exit;
  8724. glCheckFramebufferStatus := wglGetProcAddress('glCheckFramebufferStatus');
  8725. if not Assigned(glCheckFramebufferStatus) then Exit;
  8726. glFramebufferTexture1D := wglGetProcAddress('glFramebufferTexture1D');
  8727. if not Assigned(glFramebufferTexture1D) then Exit;
  8728. glFramebufferTexture2D := wglGetProcAddress('glFramebufferTexture2D');
  8729. if not Assigned(glFramebufferTexture2D) then Exit;
  8730. glFramebufferTexture3D := wglGetProcAddress('glFramebufferTexture3D');
  8731. if not Assigned(glFramebufferTexture3D) then Exit;
  8732. glFramebufferRenderbuffer := wglGetProcAddress('glFramebufferRenderbuffer');
  8733. if not Assigned(glFramebufferRenderbuffer) then Exit;
  8734. glGetFramebufferAttachmentParameteriv := wglGetProcAddress('glGetFramebufferAttachmentParameteriv');
  8735. if not Assigned(glGetFramebufferAttachmentParameteriv) then Exit;
  8736. glGenerateMipmap := wglGetProcAddress('glGenerateMipmap');
  8737. if not Assigned(glGenerateMipmap) then Exit;
  8738. glBlitFramebuffer := wglGetProcAddress('glBlitFramebuffer');
  8739. if not Assigned(glBlitFramebuffer) then Exit;
  8740. glRenderbufferStorageMultisample := wglGetProcAddress('glRenderbufferStorageMultisample');
  8741. if not Assigned(glRenderbufferStorageMultisample) then Exit;
  8742. glFramebufferTextureLayer := wglGetProcAddress('glFramebufferTextureLayer');
  8743. if not Assigned(glFramebufferTextureLayer) then Exit;
  8744. Result := True;
  8745. end;
  8746. end;
  8747. function Load_GL_ARB_map_buffer_range(LoadAsCore: boolean): Boolean;
  8748. var
  8749. extstring: String;
  8750. begin
  8751. Result := False;
  8752. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8753. if LoadAsCore or glext_ExtensionSupported('GL_ARB_map_buffer_range', extstring) then
  8754. begin
  8755. glMapBufferRange := wglGetProcAddress('glMapBufferRange');
  8756. if not Assigned(glMapBufferRange) then Exit;
  8757. glFlushMappedBufferRange := wglGetProcAddress('glFlushMappedBufferRange');
  8758. if not Assigned(glFlushMappedBufferRange) then Exit;
  8759. Result := True;
  8760. end;
  8761. end;
  8762. function Load_GL_ARB_vertex_array_object(LoadAsCore: boolean): Boolean;
  8763. var
  8764. extstring: String;
  8765. begin
  8766. Result := False;
  8767. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8768. if LoadAsCore or glext_ExtensionSupported('GL_ARB_vertex_array_object', extstring) then
  8769. begin
  8770. glBindVertexArray := wglGetProcAddress('glBindVertexArray');
  8771. if not Assigned(glBindVertexArray) then Exit;
  8772. glDeleteVertexArrays := wglGetProcAddress('glDeleteVertexArrays');
  8773. if not Assigned(glDeleteVertexArrays) then Exit;
  8774. glGenVertexArrays := wglGetProcAddress('glGenVertexArrays');
  8775. if not Assigned(glGenVertexArrays) then Exit;
  8776. glIsVertexArray := wglGetProcAddress('glIsVertexArray');
  8777. if not Assigned(glIsVertexArray) then Exit;
  8778. Result := True;
  8779. end;
  8780. end;
  8781. function Load_GL_ARB_copy_buffer(LoadAsCore: boolean): Boolean;
  8782. var
  8783. extstring: String;
  8784. begin
  8785. Result := False;
  8786. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8787. if LoadAsCore or glext_ExtensionSupported('GL_ARB_copy_buffer', extstring) then
  8788. begin
  8789. glCopyBufferSubData := wglGetProcAddress('glCopyBufferSubData');
  8790. if not Assigned(glCopyBufferSubData) then Exit;
  8791. Result := True;
  8792. end;
  8793. end;
  8794. function Load_GL_ARB_uniform_buffer_object(LoadAsCore: boolean): Boolean;
  8795. var
  8796. extstring: String;
  8797. begin
  8798. Result := False;
  8799. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8800. if LoadAsCore or glext_ExtensionSupported('GL_ARB_uniform_buffer_object', extstring) then
  8801. begin
  8802. glGetUniformIndices := wglGetProcAddress('glGetUniformIndices');
  8803. if not Assigned(glGetUniformIndices) then Exit;
  8804. glGetActiveUniformsiv := wglGetProcAddress('glGetActiveUniformsiv');
  8805. if not Assigned(glGetActiveUniformsiv) then Exit;
  8806. glGetActiveUniformName := wglGetProcAddress('glGetActiveUniformName');
  8807. if not Assigned(glGetActiveUniformName) then Exit;
  8808. glGetUniformBlockIndex := wglGetProcAddress('glGetUniformBlockIndex');
  8809. if not Assigned(glGetUniformBlockIndex) then Exit;
  8810. glGetActiveUniformBlockiv := wglGetProcAddress('glGetActiveUniformBlockiv');
  8811. if not Assigned(glGetActiveUniformBlockiv) then Exit;
  8812. glGetActiveUniformBlockName := wglGetProcAddress('glGetActiveUniformBlockName');
  8813. if not Assigned(glGetActiveUniformBlockName) then Exit;
  8814. glUniformBlockBinding := wglGetProcAddress('glUniformBlockBinding');
  8815. if not Assigned(glUniformBlockBinding) then Exit;
  8816. (* Shared entry points *)
  8817. glBindBufferRange := wglGetProcAddress('glBindBufferRange');
  8818. if not Assigned(glBindBufferRange) then Exit;
  8819. glBindBufferBase := wglGetProcAddress('glBindBufferBase');
  8820. if not Assigned(glBindBufferBase) then Exit;
  8821. glGetIntegeri_v := wglGetProcAddress('glGetIntegeri_v');
  8822. if not Assigned(glGetIntegeri_v) then Exit;
  8823. Result := True;
  8824. end;
  8825. end;
  8826. function Load_GL_ARB_draw_elements_base_vertex(LoadAsCore: boolean): Boolean;
  8827. var
  8828. extstring: String;
  8829. begin
  8830. Result := False;
  8831. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8832. if LoadAsCore or glext_ExtensionSupported('GL_ARB_draw_elements_base_vertex', extstring) then
  8833. begin
  8834. glDrawElementsBaseVertex := wglGetProcAddress('glDrawElementsBaseVertex');
  8835. if not Assigned(glDrawElementsBaseVertex) then Exit;
  8836. glDrawRangeElementsBaseVertex := wglGetProcAddress('glDrawRangeElementsBaseVertex');
  8837. if not Assigned(glDrawRangeElementsBaseVertex) then Exit;
  8838. glDrawElementsInstancedBaseVertex := wglGetProcAddress('glDrawElementsInstancedBaseVertex');
  8839. if not Assigned(glDrawElementsInstancedBaseVertex) then Exit;
  8840. glMultiDrawElementsBaseVertex := wglGetProcAddress('glMultiDrawElementsBaseVertex');
  8841. if not Assigned(glMultiDrawElementsBaseVertex) then Exit;
  8842. Result := True;
  8843. end;
  8844. end;
  8845. function Load_GL_ARB_provoking_vertex(LoadAsCore: boolean): Boolean;
  8846. var
  8847. extstring: String;
  8848. begin
  8849. Result := False;
  8850. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8851. if LoadAsCore or glext_ExtensionSupported('GL_ARB_provoking_vertex', extstring) then
  8852. begin
  8853. glProvokingVertex := wglGetProcAddress('glProvokingVertex');
  8854. if not Assigned(glProvokingVertex) then Exit;
  8855. Result := True;
  8856. end;
  8857. end;
  8858. function Load_GL_ARB_sync(LoadAsCore: boolean): Boolean;
  8859. var
  8860. extstring: String;
  8861. begin
  8862. Result := False;
  8863. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8864. if LoadAsCore or glext_ExtensionSupported('GL_ARB_sync', extstring) then
  8865. begin
  8866. glFenceSync := wglGetProcAddress('glFenceSync');
  8867. if not Assigned(glFenceSync) then Exit;
  8868. glIsSync := wglGetProcAddress('glIsSync');
  8869. if not Assigned(glIsSync) then Exit;
  8870. glDeleteSync := wglGetProcAddress('glDeleteSync');
  8871. if not Assigned(glDeleteSync) then Exit;
  8872. glClientWaitSync := wglGetProcAddress('glClientWaitSync');
  8873. if not Assigned(glClientWaitSync) then Exit;
  8874. glWaitSync := wglGetProcAddress('glWaitSync');
  8875. if not Assigned(glWaitSync) then Exit;
  8876. glGetInteger64v := wglGetProcAddress('glGetInteger64v');
  8877. if not Assigned(glGetInteger64v) then Exit;
  8878. glGetSynciv := wglGetProcAddress('glGetSynciv');
  8879. if not Assigned(glGetSynciv) then Exit;
  8880. Result := True;
  8881. end;
  8882. end;
  8883. function Load_GL_ARB_texture_multisample(LoadAsCore: boolean): Boolean;
  8884. var
  8885. extstring: String;
  8886. begin
  8887. Result := False;
  8888. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8889. if LoadAsCore or glext_ExtensionSupported('GL_ARB_texture_multisample', extstring) then
  8890. begin
  8891. glTexImage2DMultisample := wglGetProcAddress('glTexImage2DMultisample');
  8892. if not Assigned(glTexImage2DMultisample) then Exit;
  8893. glTexImage3DMultisample := wglGetProcAddress('glTexImage3DMultisample');
  8894. if not Assigned(glTexImage3DMultisample) then Exit;
  8895. glGetMultisamplefv := wglGetProcAddress('glGetMultisamplefv');
  8896. if not Assigned(glGetMultisamplefv) then Exit;
  8897. glSampleMaski := wglGetProcAddress('glSampleMaski');
  8898. if not Assigned(glSampleMaski) then Exit;
  8899. Result := True;
  8900. end;
  8901. end;
  8902. function Load_GL_ARB_sampler_objects(LoadAsCore: boolean): Boolean;
  8903. var
  8904. extstring: String;
  8905. begin
  8906. Result := False;
  8907. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8908. if LoadAsCore or glext_ExtensionSupported('GL_ARB_sampler_objects', extstring) then
  8909. begin
  8910. glGenSamplers := wglGetProcAddress('glGenSamplers');
  8911. if not Assigned(glGenSamplers) then Exit;
  8912. glDeleteSamplers := wglGetProcAddress('glDeleteSamplers');
  8913. if not Assigned(glDeleteSamplers) then Exit;
  8914. glIsSampler := wglGetProcAddress('glIsSampler');
  8915. if not Assigned(glIsSampler) then Exit;
  8916. glBindSampler := wglGetProcAddress('glBindSampler');
  8917. if not Assigned(glBindSampler) then Exit;
  8918. glSamplerParameteri := wglGetProcAddress('glSamplerParameteri');
  8919. if not Assigned(glSamplerParameteri) then Exit;
  8920. glSamplerParameteriv := wglGetProcAddress('glSamplerParameteriv');
  8921. if not Assigned(glSamplerParameteriv) then Exit;
  8922. glSamplerParameterf := wglGetProcAddress('glSamplerParameterf');
  8923. if not Assigned(glSamplerParameterf) then Exit;
  8924. glSamplerParameterfv := wglGetProcAddress('glSamplerParameterfv');
  8925. if not Assigned(glSamplerParameterfv) then Exit;
  8926. glSamplerParameterIiv := wglGetProcAddress('glSamplerParameterIiv');
  8927. if not Assigned(glSamplerParameterIiv) then Exit;
  8928. glSamplerParameterIuiv := wglGetProcAddress('glSamplerParameterIuiv');
  8929. if not Assigned(glSamplerParameterIuiv) then Exit;
  8930. glGetSamplerParameteriv := wglGetProcAddress('glGetSamplerParameteriv');
  8931. if not Assigned(glGetSamplerParameteriv) then Exit;
  8932. glGetSamplerParameterIiv := wglGetProcAddress('glGetSamplerParameterIiv');
  8933. if not Assigned(glGetSamplerParameterIiv) then Exit;
  8934. glGetSamplerParameterfv := wglGetProcAddress('glGetSamplerParameterfv');
  8935. if not Assigned(glGetSamplerParameterfv) then Exit;
  8936. glGetSamplerParameterIuiv := wglGetProcAddress('glGetSamplerParameterIuiv');
  8937. if not Assigned(glGetSamplerParameterIuiv) then Exit;
  8938. Result := True;
  8939. end;
  8940. end;
  8941. function Load_GL_ARB_blend_func_extended(LoadAsCore: boolean): Boolean;
  8942. var
  8943. extstring: String;
  8944. begin
  8945. Result := False;
  8946. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8947. if LoadAsCore or glext_ExtensionSupported('GL_ARB_blend_func_extended', extstring) then
  8948. begin
  8949. glBindFragDataLocationIndexed := wglGetProcAddress('glBindFragDataLocationIndexed');
  8950. if not Assigned(glBindFragDataLocationIndexed) then Exit;
  8951. glGetFragDataIndex := wglGetProcAddress('glGetFragDataIndex');
  8952. if not Assigned(glGetFragDataIndex) then Exit;
  8953. Result := True;
  8954. end;
  8955. end;
  8956. function Load_GL_ARB_timer_query(LoadAsCore: boolean): Boolean;
  8957. var
  8958. extstring: String;
  8959. begin
  8960. Result := False;
  8961. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8962. if LoadAsCore or glext_ExtensionSupported('GL_ARB_timer_query', extstring) then
  8963. begin
  8964. glQueryCounter := wglGetProcAddress('glQueryCounter');
  8965. if not Assigned(glQueryCounter) then Exit;
  8966. glGetQueryObjecti64v := wglGetProcAddress('glGetQueryObjecti64v');
  8967. if not Assigned(glGetQueryObjecti64v) then Exit;
  8968. glGetQueryObjectui64v := wglGetProcAddress('glGetQueryObjectui64v');
  8969. if not Assigned(glGetQueryObjectui64v) then Exit;
  8970. Result := True;
  8971. end;
  8972. end;
  8973. function Load_GL_ARB_vertex_type_2_10_10_10_rev(LoadAsCore: boolean): Boolean;
  8974. var
  8975. extstring: String;
  8976. begin
  8977. Result := False;
  8978. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  8979. if LoadAsCore or glext_ExtensionSupported('GL_ARB_vertex_type_2_10_10_10_rev', extstring) then
  8980. begin
  8981. glVertexP2ui := wglGetProcAddress('glVertexP2ui');
  8982. if not Assigned(glVertexP2ui) then Exit;
  8983. glVertexP2uiv := wglGetProcAddress('glVertexP2uiv');
  8984. if not Assigned(glVertexP2uiv) then Exit;
  8985. glVertexP3ui := wglGetProcAddress('glVertexP3ui');
  8986. if not Assigned(glVertexP3ui) then Exit;
  8987. glVertexP3uiv := wglGetProcAddress('glVertexP3uiv');
  8988. if not Assigned(glVertexP3uiv) then Exit;
  8989. glVertexP4ui := wglGetProcAddress('glVertexP4ui');
  8990. if not Assigned(glVertexP4ui) then Exit;
  8991. glVertexP4uiv := wglGetProcAddress('glVertexP4uiv');
  8992. if not Assigned(glVertexP4uiv) then Exit;
  8993. glTexCoordP1ui := wglGetProcAddress('glTexCoordP1ui');
  8994. if not Assigned(glTexCoordP1ui) then Exit;
  8995. glTexCoordP1uiv := wglGetProcAddress('glTexCoordP1uiv');
  8996. if not Assigned(glTexCoordP1uiv) then Exit;
  8997. glTexCoordP2ui := wglGetProcAddress('glTexCoordP2ui');
  8998. if not Assigned(glTexCoordP2ui) then Exit;
  8999. glTexCoordP2uiv := wglGetProcAddress('glTexCoordP2uiv');
  9000. if not Assigned(glTexCoordP2uiv) then Exit;
  9001. glTexCoordP3ui := wglGetProcAddress('glTexCoordP3ui');
  9002. if not Assigned(glTexCoordP3ui) then Exit;
  9003. glTexCoordP3uiv := wglGetProcAddress('glTexCoordP3uiv');
  9004. if not Assigned(glTexCoordP3uiv) then Exit;
  9005. glTexCoordP4ui := wglGetProcAddress('glTexCoordP4ui');
  9006. if not Assigned(glTexCoordP4ui) then Exit;
  9007. glTexCoordP4uiv := wglGetProcAddress('glTexCoordP4uiv');
  9008. if not Assigned(glTexCoordP4uiv) then Exit;
  9009. glMultiTexCoordP1ui := wglGetProcAddress('glMultiTexCoordP1ui');
  9010. if not Assigned(glMultiTexCoordP1ui) then Exit;
  9011. glMultiTexCoordP1uiv := wglGetProcAddress('glMultiTexCoordP1uiv');
  9012. if not Assigned(glMultiTexCoordP1uiv) then Exit;
  9013. glMultiTexCoordP2ui := wglGetProcAddress('glMultiTexCoordP2ui');
  9014. if not Assigned(glMultiTexCoordP2ui) then Exit;
  9015. glMultiTexCoordP2uiv := wglGetProcAddress('glMultiTexCoordP2uiv');
  9016. if not Assigned(glMultiTexCoordP2uiv) then Exit;
  9017. glMultiTexCoordP3ui := wglGetProcAddress('glMultiTexCoordP3ui');
  9018. if not Assigned(glMultiTexCoordP3ui) then Exit;
  9019. glMultiTexCoordP3uiv := wglGetProcAddress('glMultiTexCoordP3uiv');
  9020. if not Assigned(glMultiTexCoordP3uiv) then Exit;
  9021. glMultiTexCoordP4ui := wglGetProcAddress('glMultiTexCoordP4ui');
  9022. if not Assigned(glMultiTexCoordP4ui) then Exit;
  9023. glMultiTexCoordP4uiv := wglGetProcAddress('glMultiTexCoordP4uiv');
  9024. if not Assigned(glMultiTexCoordP4uiv) then Exit;
  9025. glNormalP3ui := wglGetProcAddress('glNormalP3ui');
  9026. if not Assigned(glNormalP3ui) then Exit;
  9027. glNormalP3uiv := wglGetProcAddress('glNormalP3uiv');
  9028. if not Assigned(glNormalP3uiv) then Exit;
  9029. glColorP3ui := wglGetProcAddress('glColorP3ui');
  9030. if not Assigned(glColorP3ui) then Exit;
  9031. glColorP3uiv := wglGetProcAddress('glColorP3uiv');
  9032. if not Assigned(glColorP3uiv) then Exit;
  9033. glColorP4ui := wglGetProcAddress('glColorP4ui');
  9034. if not Assigned(glColorP4ui) then Exit;
  9035. glColorP4uiv := wglGetProcAddress('glColorP4uiv');
  9036. if not Assigned(glColorP4uiv) then Exit;
  9037. glSecondaryColorP3ui := wglGetProcAddress('glSecondaryColorP3ui');
  9038. if not Assigned(glSecondaryColorP3ui) then Exit;
  9039. glSecondaryColorP3uiv := wglGetProcAddress('glSecondaryColorP3uiv');
  9040. if not Assigned(glSecondaryColorP3uiv) then Exit;
  9041. glVertexAttribP1ui := wglGetProcAddress('glVertexAttribP1ui');
  9042. if not Assigned(glVertexAttribP1ui) then Exit;
  9043. glVertexAttribP1uiv := wglGetProcAddress('glVertexAttribP1uiv');
  9044. if not Assigned(glVertexAttribP1uiv) then Exit;
  9045. glVertexAttribP2ui := wglGetProcAddress('glVertexAttribP2ui');
  9046. if not Assigned(glVertexAttribP2ui) then Exit;
  9047. glVertexAttribP2uiv := wglGetProcAddress('glVertexAttribP2uiv');
  9048. if not Assigned(glVertexAttribP2uiv) then Exit;
  9049. glVertexAttribP3ui := wglGetProcAddress('glVertexAttribP3ui');
  9050. if not Assigned(glVertexAttribP3ui) then Exit;
  9051. glVertexAttribP3uiv := wglGetProcAddress('glVertexAttribP3uiv');
  9052. if not Assigned(glVertexAttribP3uiv) then Exit;
  9053. glVertexAttribP4ui := wglGetProcAddress('glVertexAttribP4ui');
  9054. if not Assigned(glVertexAttribP4ui) then Exit;
  9055. glVertexAttribP4uiv := wglGetProcAddress('glVertexAttribP4uiv');
  9056. if not Assigned(glVertexAttribP4uiv) then Exit;
  9057. Result := True;
  9058. end;
  9059. end;
  9060. function Load_GL_ARB_gpu_shader_fp64(LoadAsCore: boolean): Boolean;
  9061. var
  9062. extstring: String;
  9063. begin
  9064. Result := False;
  9065. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9066. if LoadAsCore or glext_ExtensionSupported('GL_ARB_gpu_shader_fp64', extstring) then
  9067. begin
  9068. glUniform1d := wglGetProcAddress('glUniform1d');
  9069. if not Assigned(glUniform1d) then Exit;
  9070. glUniform2d := wglGetProcAddress('glUniform2d');
  9071. if not Assigned(glUniform2d) then Exit;
  9072. glUniform3d := wglGetProcAddress('glUniform3d');
  9073. if not Assigned(glUniform3d) then Exit;
  9074. glUniform4d := wglGetProcAddress('glUniform4d');
  9075. if not Assigned(glUniform4d) then Exit;
  9076. glUniform1dv := wglGetProcAddress('glUniform1dv');
  9077. if not Assigned(glUniform1dv) then Exit;
  9078. glUniform2dv := wglGetProcAddress('glUniform2dv');
  9079. if not Assigned(glUniform2dv) then Exit;
  9080. glUniform3dv := wglGetProcAddress('glUniform3dv');
  9081. if not Assigned(glUniform3dv) then Exit;
  9082. glUniform4dv := wglGetProcAddress('glUniform4dv');
  9083. if not Assigned(glUniform4dv) then Exit;
  9084. glUniformMatrix2dv := wglGetProcAddress('glUniformMatrix2dv');
  9085. if not Assigned(glUniformMatrix2dv) then Exit;
  9086. glUniformMatrix3dv := wglGetProcAddress('glUniformMatrix3dv');
  9087. if not Assigned(glUniformMatrix3dv) then Exit;
  9088. glUniformMatrix4dv := wglGetProcAddress('glUniformMatrix4dv');
  9089. if not Assigned(glUniformMatrix4dv) then Exit;
  9090. glUniformMatrix2x3dv := wglGetProcAddress('glUniformMatrix2x3dv');
  9091. if not Assigned(glUniformMatrix2x3dv) then Exit;
  9092. glUniformMatrix2x4dv := wglGetProcAddress('glUniformMatrix2x4dv');
  9093. if not Assigned(glUniformMatrix2x4dv) then Exit;
  9094. glUniformMatrix3x2dv := wglGetProcAddress('glUniformMatrix3x2dv');
  9095. if not Assigned(glUniformMatrix3x2dv) then Exit;
  9096. glUniformMatrix3x4dv := wglGetProcAddress('glUniformMatrix3x4dv');
  9097. if not Assigned(glUniformMatrix3x4dv) then Exit;
  9098. glUniformMatrix4x2dv := wglGetProcAddress('glUniformMatrix4x2dv');
  9099. if not Assigned(glUniformMatrix4x2dv) then Exit;
  9100. glUniformMatrix4x3dv := wglGetProcAddress('glUniformMatrix4x3dv');
  9101. if not Assigned(glUniformMatrix4x3dv) then Exit;
  9102. glGetUniformdv := wglGetProcAddress('glGetUniformdv');
  9103. if not Assigned(glGetUniformdv) then Exit;
  9104. { Ignore presence/absence of functions below.
  9105. See their special definition in
  9106. http://www.opengl.org/registry/specs/ARB/gpu_shader_fp64.txt:
  9107. "All of the following ProgramUniform* functions are supported if and only
  9108. if EXT_direct_state_access is supported." }
  9109. glProgramUniform1dEXT := wglGetProcAddress('glProgramUniform1dEXT');
  9110. // if not Assigned(glProgramUniform1dEXT) then Exit;
  9111. glProgramUniform2dEXT := wglGetProcAddress('glProgramUniform2dEXT');
  9112. // if not Assigned(glProgramUniform2dEXT) then Exit;
  9113. glProgramUniform3dEXT := wglGetProcAddress('glProgramUniform3dEXT');
  9114. // if not Assigned(glProgramUniform3dEXT) then Exit;
  9115. glProgramUniform4dEXT := wglGetProcAddress('glProgramUniform4dEXT');
  9116. // if not Assigned(glProgramUniform4dEXT) then Exit;
  9117. glProgramUniform1dvEXT := wglGetProcAddress('glProgramUniform1dvEXT');
  9118. // if not Assigned(glProgramUniform1dvEXT) then Exit;
  9119. glProgramUniform2dvEXT := wglGetProcAddress('glProgramUniform2dvEXT');
  9120. // if not Assigned(glProgramUniform2dvEXT) then Exit;
  9121. glProgramUniform3dvEXT := wglGetProcAddress('glProgramUniform3dvEXT');
  9122. // if not Assigned(glProgramUniform3dvEXT) then Exit;
  9123. glProgramUniform4dvEXT := wglGetProcAddress('glProgramUniform4dvEXT');
  9124. // if not Assigned(glProgramUniform4dvEXT) then Exit;
  9125. glProgramUniformMatrix2dvEXT := wglGetProcAddress('glProgramUniformMatrix2dvEXT');
  9126. // if not Assigned(glProgramUniformMatrix2dvEXT) then Exit;
  9127. glProgramUniformMatrix3dvEXT := wglGetProcAddress('glProgramUniformMatrix3dvEXT');
  9128. // if not Assigned(glProgramUniformMatrix3dvEXT) then Exit;
  9129. glProgramUniformMatrix4dvEXT := wglGetProcAddress('glProgramUniformMatrix4dvEXT');
  9130. // if not Assigned(glProgramUniformMatrix4dvEXT) then Exit;
  9131. glProgramUniformMatrix2x3dvEXT := wglGetProcAddress('glProgramUniformMatrix2x3dvEXT');
  9132. // if not Assigned(glProgramUniformMatrix2x3dvEXT) then Exit;
  9133. glProgramUniformMatrix2x4dvEXT := wglGetProcAddress('glProgramUniformMatrix2x4dvEXT');
  9134. // if not Assigned(glProgramUniformMatrix2x4dvEXT) then Exit;
  9135. glProgramUniformMatrix3x2dvEXT := wglGetProcAddress('glProgramUniformMatrix3x2dvEXT');
  9136. // if not Assigned(glProgramUniformMatrix3x2dvEXT) then Exit;
  9137. glProgramUniformMatrix3x4dvEXT := wglGetProcAddress('glProgramUniformMatrix3x4dvEXT');
  9138. // if not Assigned(glProgramUniformMatrix3x4dvEXT) then Exit;
  9139. glProgramUniformMatrix4x2dvEXT := wglGetProcAddress('glProgramUniformMatrix4x2dvEXT');
  9140. // if not Assigned(glProgramUniformMatrix4x2dvEXT) then Exit;
  9141. glProgramUniformMatrix4x3dvEXT := wglGetProcAddress('glProgramUniformMatrix4x3dvEXT');
  9142. // if not Assigned(glProgramUniformMatrix4x3dvEXT) then Exit;
  9143. Result := True;
  9144. end;
  9145. end;
  9146. function Load_GL_ARB_shader_subroutine(LoadAsCore: boolean): Boolean;
  9147. var
  9148. extstring: String;
  9149. begin
  9150. Result := False;
  9151. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9152. if LoadAsCore or glext_ExtensionSupported('GL_ARB_shader_subroutine', extstring) then
  9153. begin
  9154. glGetSubroutineUniformLocation := wglGetProcAddress('glGetSubroutineUniformLocation');
  9155. if not Assigned(glGetSubroutineUniformLocation) then Exit;
  9156. glGetSubroutineIndex := wglGetProcAddress('glGetSubroutineIndex');
  9157. if not Assigned(glGetSubroutineIndex) then Exit;
  9158. glGetActiveSubroutineUniformiv := wglGetProcAddress('glGetActiveSubroutineUniformiv');
  9159. if not Assigned(glGetActiveSubroutineUniformiv) then Exit;
  9160. glGetActiveSubroutineUniformName := wglGetProcAddress('glGetActiveSubroutineUniformName');
  9161. if not Assigned(glGetActiveSubroutineUniformName) then Exit;
  9162. glGetActiveSubroutineName := wglGetProcAddress('glGetActiveSubroutineName');
  9163. if not Assigned(glGetActiveSubroutineName) then Exit;
  9164. glUniformSubroutinesuiv := wglGetProcAddress('glUniformSubroutinesuiv');
  9165. if not Assigned(glUniformSubroutinesuiv) then Exit;
  9166. glGetUniformSubroutineuiv := wglGetProcAddress('glGetUniformSubroutineuiv');
  9167. if not Assigned(glGetUniformSubroutineuiv) then Exit;
  9168. glGetProgramStageiv := wglGetProcAddress('glGetProgramStageiv');
  9169. if not Assigned(glGetProgramStageiv) then Exit;
  9170. Result := True;
  9171. end;
  9172. end;
  9173. function Load_GL_ARB_tessellation_shader(LoadAsCore: boolean): Boolean;
  9174. var
  9175. extstring: String;
  9176. begin
  9177. Result := False;
  9178. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9179. if LoadAsCore or glext_ExtensionSupported('GL_ARB_tessellation_shader', extstring) then
  9180. begin
  9181. glPatchParameteri := wglGetProcAddress('glPatchParameteri');
  9182. if not Assigned(glPatchParameteri) then Exit;
  9183. glPatchParameterfv := wglGetProcAddress('glPatchParameterfv');
  9184. if not Assigned(glPatchParameterfv) then Exit;
  9185. Result := True;
  9186. end;
  9187. end;
  9188. function Load_GL_ARB_transform_feedback2(LoadAsCore: boolean): Boolean;
  9189. var
  9190. extstring: String;
  9191. begin
  9192. Result := False;
  9193. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9194. if LoadAsCore or glext_ExtensionSupported('GL_ARB_transform_feedback2', extstring) then
  9195. begin
  9196. glBindTransformFeedback := wglGetProcAddress('glBindTransformFeedback');
  9197. if not Assigned(glBindTransformFeedback) then Exit;
  9198. glDeleteTransformFeedbacks := wglGetProcAddress('glDeleteTransformFeedbacks');
  9199. if not Assigned(glDeleteTransformFeedbacks) then Exit;
  9200. glGenTransformFeedbacks := wglGetProcAddress('glGenTransformFeedbacks');
  9201. if not Assigned(glGenTransformFeedbacks) then Exit;
  9202. glIsTransformFeedback := wglGetProcAddress('glIsTransformFeedback');
  9203. if not Assigned(glIsTransformFeedback) then Exit;
  9204. glPauseTransformFeedback := wglGetProcAddress('glPauseTransformFeedback');
  9205. if not Assigned(glPauseTransformFeedback) then Exit;
  9206. glResumeTransformFeedback := wglGetProcAddress('glResumeTransformFeedback');
  9207. if not Assigned(glResumeTransformFeedback) then Exit;
  9208. glDrawTransformFeedback := wglGetProcAddress('glDrawTransformFeedback');
  9209. if not Assigned(glDrawTransformFeedback) then Exit;
  9210. Result := True;
  9211. end;
  9212. end;
  9213. function Load_GL_ARB_transform_feedback3(LoadAsCore: boolean): Boolean;
  9214. var
  9215. extstring: String;
  9216. begin
  9217. Result := False;
  9218. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9219. if LoadAsCore or glext_ExtensionSupported('GL_ARB_transform_feedback3', extstring) then
  9220. begin
  9221. glDrawTransformFeedbackStream := wglGetProcAddress('glDrawTransformFeedbackStream');
  9222. if not Assigned(glDrawTransformFeedbackStream) then Exit;
  9223. glBeginQueryIndexed := wglGetProcAddress('glBeginQueryIndexed');
  9224. if not Assigned(glBeginQueryIndexed) then Exit;
  9225. glEndQueryIndexed := wglGetProcAddress('glEndQueryIndexed');
  9226. if not Assigned(glEndQueryIndexed) then Exit;
  9227. glGetQueryIndexediv := wglGetProcAddress('glGetQueryIndexediv');
  9228. if not Assigned(glGetQueryIndexediv) then Exit;
  9229. Result := True;
  9230. end;
  9231. end;
  9232. procedure Load_GL_version_1_4x (var allOK: Boolean);
  9233. var
  9234. extstring: String;
  9235. begin
  9236. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9237. glBlendFuncSeparate := wglGetProcAddress('glBlendFuncSeparate');
  9238. if not Assigned(glBlendFuncSeparate) then allOK := false;
  9239. glFogCoordf := wglGetProcAddress('glFogCoordf');
  9240. if not Assigned(glFogCoordf) then allOK := false;
  9241. glFogCoordfv := wglGetProcAddress('glFogCoordfv');
  9242. if not Assigned(glFogCoordfv) then allOK := false;
  9243. glFogCoordd := wglGetProcAddress('glFogCoordd');
  9244. if not Assigned(glFogCoordd) then allOK := false;
  9245. glFogCoorddv := wglGetProcAddress('glFogCoorddv');
  9246. if not Assigned(glFogCoorddv) then allOK := false;
  9247. glFogCoordPointer := wglGetProcAddress('glFogCoordPointer');
  9248. if not Assigned(glFogCoordPointer) then allOK := false;
  9249. glMultiDrawArrays := wglGetProcAddress('glMultiDrawArrays');
  9250. if not Assigned(glMultiDrawArrays) then allOK := false;
  9251. glMultiDrawElements := wglGetProcAddress('glMultiDrawElements');
  9252. if not Assigned(glMultiDrawElements) then allOK := false;
  9253. glPointParameterf := wglGetProcAddress('glPointParameterf');
  9254. if not Assigned(glPointParameterf) then allOK := false;
  9255. glPointParameterfv := wglGetProcAddress('glPointParameterfv');
  9256. if not Assigned(glPointParameterfv) then allOK := false;
  9257. glPointParameteri := wglGetProcAddress('glPointParameteri');
  9258. if not Assigned(glPointParameteri) then allOK := false;
  9259. glPointParameteriv := wglGetProcAddress('glPointParameteriv');
  9260. if not Assigned(glPointParameteriv) then allOK := false;
  9261. glSecondaryColor3b := wglGetProcAddress('glSecondaryColor3b');
  9262. if not Assigned(glSecondaryColor3b) then allOK := false;
  9263. glSecondaryColor3bv := wglGetProcAddress('glSecondaryColor3bv');
  9264. if not Assigned(glSecondaryColor3bv) then allOK := false;
  9265. glSecondaryColor3d := wglGetProcAddress('glSecondaryColor3d');
  9266. if not Assigned(glSecondaryColor3d) then allOK := false;
  9267. glSecondaryColor3dv := wglGetProcAddress('glSecondaryColor3dv');
  9268. if not Assigned(glSecondaryColor3dv) then allOK := false;
  9269. glSecondaryColor3f := wglGetProcAddress('glSecondaryColor3f');
  9270. if not Assigned(glSecondaryColor3f) then allOK := false;
  9271. glSecondaryColor3fv := wglGetProcAddress('glSecondaryColor3fv');
  9272. if not Assigned(glSecondaryColor3fv) then allOK := false;
  9273. glSecondaryColor3i := wglGetProcAddress('glSecondaryColor3i');
  9274. if not Assigned(glSecondaryColor3i) then allOK := false;
  9275. glSecondaryColor3iv := wglGetProcAddress('glSecondaryColor3iv');
  9276. if not Assigned(glSecondaryColor3iv) then allOK := false;
  9277. glSecondaryColor3s := wglGetProcAddress('glSecondaryColor3s');
  9278. if not Assigned(glSecondaryColor3s) then allOK := false;
  9279. glSecondaryColor3sv := wglGetProcAddress('glSecondaryColor3sv');
  9280. if not Assigned(glSecondaryColor3sv) then allOK := false;
  9281. glSecondaryColor3ub := wglGetProcAddress('glSecondaryColor3ub');
  9282. if not Assigned(glSecondaryColor3ub) then allOK := false;
  9283. glSecondaryColor3ubv := wglGetProcAddress('glSecondaryColor3ubv');
  9284. if not Assigned(glSecondaryColor3ubv) then allOK := false;
  9285. glSecondaryColor3ui := wglGetProcAddress('glSecondaryColor3ui');
  9286. if not Assigned(glSecondaryColor3ui) then allOK := false;
  9287. glSecondaryColor3uiv := wglGetProcAddress('glSecondaryColor3uiv');
  9288. if not Assigned(glSecondaryColor3uiv) then allOK := false;
  9289. glSecondaryColor3us := wglGetProcAddress('glSecondaryColor3us');
  9290. if not Assigned(glSecondaryColor3us) then allOK := false;
  9291. glSecondaryColor3usv := wglGetProcAddress('glSecondaryColor3usv');
  9292. if not Assigned(glSecondaryColor3usv) then allOK := false;
  9293. glSecondaryColorPointer := wglGetProcAddress('glSecondaryColorPointer');
  9294. if not Assigned(glSecondaryColorPointer) then allOK := false;
  9295. glWindowPos2d := wglGetProcAddress('glWindowPos2d');
  9296. if not Assigned(glWindowPos2d) then allOK := false;
  9297. glWindowPos2dv := wglGetProcAddress('glWindowPos2dv');
  9298. if not Assigned(glWindowPos2dv) then allOK := false;
  9299. glWindowPos2f := wglGetProcAddress('glWindowPos2f');
  9300. if not Assigned(glWindowPos2f) then allOK := false;
  9301. glWindowPos2fv := wglGetProcAddress('glWindowPos2fv');
  9302. if not Assigned(glWindowPos2fv) then allOK := false;
  9303. glWindowPos2i := wglGetProcAddress('glWindowPos2i');
  9304. if not Assigned(glWindowPos2i) then allOK := false;
  9305. glWindowPos2iv := wglGetProcAddress('glWindowPos2iv');
  9306. if not Assigned(glWindowPos2iv) then allOK := false;
  9307. glWindowPos2s := wglGetProcAddress('glWindowPos2s');
  9308. if not Assigned(glWindowPos2s) then allOK := false;
  9309. glWindowPos2sv := wglGetProcAddress('glWindowPos2sv');
  9310. if not Assigned(glWindowPos2sv) then allOK := false;
  9311. glWindowPos3d := wglGetProcAddress('glWindowPos3d');
  9312. if not Assigned(glWindowPos3d) then allOK := false;
  9313. glWindowPos3dv := wglGetProcAddress('glWindowPos3dv');
  9314. if not Assigned(glWindowPos3dv) then allOK := false;
  9315. glWindowPos3f := wglGetProcAddress('glWindowPos3f');
  9316. if not Assigned(glWindowPos3f) then allOK := false;
  9317. glWindowPos3fv := wglGetProcAddress('glWindowPos3fv');
  9318. if not Assigned(glWindowPos3fv) then allOK := false;
  9319. glWindowPos3i := wglGetProcAddress('glWindowPos3i');
  9320. if not Assigned(glWindowPos3i) then allOK := false;
  9321. glWindowPos3iv := wglGetProcAddress('glWindowPos3iv');
  9322. if not Assigned(glWindowPos3iv) then allOK := false;
  9323. glWindowPos3s := wglGetProcAddress('glWindowPos3s');
  9324. if not Assigned(glWindowPos3s) then allOK := false;
  9325. glWindowPos3sv := wglGetProcAddress('glWindowPos3sv');
  9326. if not Assigned(glWindowPos3sv) then allOK := false;
  9327. Load_GL_version_1_3x(allOK);
  9328. end;
  9329. function Load_GL_version_1_4: boolean;
  9330. begin
  9331. result := true;
  9332. Load_GL_version_1_4x(result);
  9333. end;
  9334. procedure Load_GL_version_1_5x (var allOK: Boolean);
  9335. var
  9336. extstring: string;
  9337. begin
  9338. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9339. glGenQueries := wglGetProcAddress('glGenQueries');
  9340. if not Assigned(glGenQueries) then allOK := false;
  9341. glDeleteQueries := wglGetProcAddress('glDeleteQueries');
  9342. if not Assigned(glDeleteQueries) then allOK := false;
  9343. glIsQuery := wglGetProcAddress('glIsQuery');
  9344. if not Assigned(glIsQuery) then allOK := false;
  9345. glBeginQuery := wglGetProcAddress('glBeginQuery');
  9346. if not Assigned(glBeginQuery) then allOK := false;
  9347. glEndQuery := wglGetProcAddress('glEndQuery');
  9348. if not Assigned(glEndQuery) then allOK := false;
  9349. glGetQueryiv := wglGetProcAddress('glGetQueryiv');
  9350. if not Assigned(glGetQueryiv) then allOK := false;
  9351. glGetQueryObjectiv := wglGetProcAddress('glGetQueryObjectiv');
  9352. if not Assigned(glGetQueryObjectiv) then allOK := false;
  9353. glGetQueryObjectuiv := wglGetProcAddress('glGetQueryObjectuiv');
  9354. if not Assigned(glGetQueryObjectuiv) then allOK := false;
  9355. glBindBuffer := wglGetProcAddress('glBindBuffer');
  9356. if not Assigned(glBindBuffer) then allOK := false;
  9357. glDeleteBuffers := wglGetProcAddress('glDeleteBuffers');
  9358. if not Assigned(glDeleteBuffers) then allOK := false;
  9359. glGenBuffers := wglGetProcAddress('glGenBuffers');
  9360. if not Assigned(glGenBuffers) then allOK := false;
  9361. glIsBuffer := wglGetProcAddress('glIsBuffer');
  9362. if not Assigned(glIsBuffer) then allOK := false;
  9363. glBufferData := wglGetProcAddress('glBufferData');
  9364. if not Assigned(glBufferData) then allOK := false;
  9365. glBufferSubData := wglGetProcAddress('glBufferSubData');
  9366. if not Assigned(glBufferSubData) then allOK := false;
  9367. glGetBufferSubData := wglGetProcAddress('glGetBufferSubData');
  9368. if not Assigned(glGetBufferSubData) then allOK := false;
  9369. glMapBuffer := wglGetProcAddress('glMapBuffer');
  9370. if not Assigned(glMapBuffer) then allOK := false;
  9371. glUnmapBuffer := wglGetProcAddress('glUnmapBuffer');
  9372. if not Assigned(glUnmapBuffer) then allOK := false;
  9373. glGetBufferParameteriv := wglGetProcAddress('glGetBufferParameteriv');
  9374. if not Assigned(glGetBufferParameteriv) then allOK := false;
  9375. glGetBufferPointerv := wglGetProcAddress('glGetBufferPointerv');
  9376. if not Assigned(glGetBufferPointerv) then allOK := false;
  9377. Load_GL_version_1_4x(allOK);
  9378. end;
  9379. function Load_GL_version_1_5: boolean;
  9380. begin
  9381. result := true;
  9382. Load_GL_version_1_5x(result);
  9383. end;
  9384. procedure Load_GL_version_2_0x (var allOK: Boolean);
  9385. var
  9386. extstring: String;
  9387. begin
  9388. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9389. glBlendEquationSeparate := wglGetProcAddress('glBlendEquationSeparate');
  9390. if not Assigned(glBlendEquationSeparate) then allOK := false;
  9391. glDrawBuffers := wglGetProcAddress('glDrawBuffers');
  9392. if not Assigned(glDrawBuffers) then allOK := false;
  9393. glStencilOpSeparate := wglGetProcAddress('glStencilOpSeparate');
  9394. if not Assigned(glStencilOpSeparate) then allOK := false;
  9395. glStencilFuncSeparate := wglGetProcAddress('glStencilFuncSeparate');
  9396. if not Assigned(glStencilFuncSeparate) then allOK := false;
  9397. glStencilMaskSeparate := wglGetProcAddress('glStencilMaskSeparate');
  9398. if not Assigned(glStencilMaskSeparate) then allOK := false;
  9399. glAttachShader := wglGetProcAddress('glAttachShader');
  9400. if not Assigned(glAttachShader) then allOK := false;
  9401. glBindAttribLocation := wglGetProcAddress('glBindAttribLocation');
  9402. if not Assigned(glBindAttribLocation) then allOK := false;
  9403. glCompileShader := wglGetProcAddress('glCompileShader');
  9404. if not Assigned(glCompileShader) then allOK := false;
  9405. glCreateProgram := wglGetProcAddress('glCreateProgram');
  9406. if not Assigned(glCreateProgram) then allOK := false;
  9407. glCreateShader := wglGetProcAddress('glCreateShader');
  9408. if not Assigned(glCreateShader) then allOK := false;
  9409. glDeleteProgram := wglGetProcAddress('glDeleteProgram');
  9410. if not Assigned(glDeleteProgram) then allOK := false;
  9411. glDeleteShader := wglGetProcAddress('glDeleteShader');
  9412. if not Assigned(glDeleteShader) then allOK := false;
  9413. glDetachShader := wglGetProcAddress('glDetachShader');
  9414. if not Assigned(glDetachShader) then allOK := false;
  9415. glDisableVertexAttribArray := wglGetProcAddress('glDisableVertexAttribArray');
  9416. if not Assigned(glDisableVertexAttribArray) then allOK := false;
  9417. glEnableVertexAttribArray := wglGetProcAddress('glEnableVertexAttribArray');
  9418. if not Assigned(glEnableVertexAttribArray) then allOK := false;
  9419. glGetActiveAttrib := wglGetProcAddress('glGetActiveAttrib');
  9420. if not Assigned(glGetActiveAttrib) then allOK := false;
  9421. glGetActiveUniform := wglGetProcAddress('glGetActiveUniform');
  9422. if not Assigned(glGetActiveUniform) then allOK := false;
  9423. glGetAttachedShaders := wglGetProcAddress('glGetAttachedShaders');
  9424. if not Assigned(glGetAttachedShaders) then allOK := false;
  9425. glGetAttribLocation := wglGetProcAddress('glGetAttribLocation');
  9426. if not Assigned(glGetAttribLocation) then allOK := false;
  9427. glGetProgramiv := wglGetProcAddress('glGetProgramiv');
  9428. if not Assigned(glGetProgramiv) then allOK := false;
  9429. glGetProgramInfoLog := wglGetProcAddress('glGetProgramInfoLog');
  9430. if not Assigned(glGetProgramInfoLog) then allOK := false;
  9431. glGetShaderiv := wglGetProcAddress('glGetShaderiv');
  9432. if not Assigned(glGetShaderiv) then allOK := false;
  9433. glGetShaderInfoLog := wglGetProcAddress('glGetShaderInfoLog');
  9434. if not Assigned(glGetShaderInfoLog) then allOK := false;
  9435. glGetShaderSource := wglGetProcAddress('glGetShaderSource');
  9436. if not Assigned(glGetShaderSource) then allOK := false;
  9437. glGetUniformLocation := wglGetProcAddress('glGetUniformLocation');
  9438. if not Assigned(glGetUniformLocation) then allOK := false;
  9439. glGetUniformfv := wglGetProcAddress('glGetUniformfv');
  9440. if not Assigned(glGetUniformfv) then allOK := false;
  9441. glGetUniformiv := wglGetProcAddress('glGetUniformiv');
  9442. if not Assigned(glGetUniformiv) then allOK := false;
  9443. glGetVertexAttribdv := wglGetProcAddress('glGetVertexAttribdv');
  9444. if not Assigned(glGetVertexAttribdv) then allOK := false;
  9445. glGetVertexAttribfv := wglGetProcAddress('glGetVertexAttribfv');
  9446. if not Assigned(glGetVertexAttribfv) then allOK := false;
  9447. glGetVertexAttribiv := wglGetProcAddress('glGetVertexAttribiv');
  9448. if not Assigned(glGetVertexAttribiv) then allOK := false;
  9449. glGetVertexAttribPointerv := wglGetProcAddress('glGetVertexAttribPointerv');
  9450. if not Assigned(glGetVertexAttribPointerv) then allOK := false;
  9451. glIsProgram := wglGetProcAddress('glIsProgram');
  9452. if not Assigned(glIsProgram) then allOK := false;
  9453. glIsShader := wglGetProcAddress('glIsShader');
  9454. if not Assigned(glIsShader) then allOK := false;
  9455. glLinkProgram := wglGetProcAddress('glLinkProgram');
  9456. if not Assigned(glLinkProgram) then allOK := false;
  9457. glShaderSource := wglGetProcAddress('glShaderSource');
  9458. if not Assigned(glShaderSource) then allOK := false;
  9459. glUseProgram := wglGetProcAddress('glUseProgram');
  9460. if not Assigned(glUseProgram) then allOK := false;
  9461. glUniform1f := wglGetProcAddress('glUniform1f');
  9462. if not Assigned(glUniform1f) then allOK := false;
  9463. glUniform2f := wglGetProcAddress('glUniform2f');
  9464. if not Assigned(glUniform2f) then allOK := false;
  9465. glUniform3f := wglGetProcAddress('glUniform3f');
  9466. if not Assigned(glUniform3f) then allOK := false;
  9467. glUniform4f := wglGetProcAddress('glUniform4f');
  9468. if not Assigned(glUniform4f) then allOK := false;
  9469. glUniform1i := wglGetProcAddress('glUniform1i');
  9470. if not Assigned(glUniform1i) then allOK := false;
  9471. glUniform2i := wglGetProcAddress('glUniform2i');
  9472. if not Assigned(glUniform2i) then allOK := false;
  9473. glUniform3i := wglGetProcAddress('glUniform3i');
  9474. if not Assigned(glUniform3i) then allOK := false;
  9475. glUniform4i := wglGetProcAddress('glUniform4i');
  9476. if not Assigned(glUniform4i) then allOK := false;
  9477. glUniform1fv := wglGetProcAddress('glUniform1fv');
  9478. if not Assigned(glUniform1fv) then allOK := false;
  9479. glUniform2fv := wglGetProcAddress('glUniform2fv');
  9480. if not Assigned(glUniform2fv) then allOK := false;
  9481. glUniform3fv := wglGetProcAddress('glUniform3fv');
  9482. if not Assigned(glUniform3fv) then allOK := false;
  9483. glUniform4fv := wglGetProcAddress('glUniform4fv');
  9484. if not Assigned(glUniform4fv) then allOK := false;
  9485. glUniform1iv := wglGetProcAddress('glUniform1iv');
  9486. if not Assigned(glUniform1iv) then allOK := false;
  9487. glUniform2iv := wglGetProcAddress('glUniform2iv');
  9488. if not Assigned(glUniform2iv) then allOK := false;
  9489. glUniform3iv := wglGetProcAddress('glUniform3iv');
  9490. if not Assigned(glUniform3iv) then allOK := false;
  9491. glUniform4iv := wglGetProcAddress('glUniform4iv');
  9492. if not Assigned(glUniform4iv) then allOK := false;
  9493. glUniformMatrix2fv := wglGetProcAddress('glUniformMatrix2fv');
  9494. if not Assigned(glUniformMatrix2fv) then allOK := false;
  9495. glUniformMatrix3fv := wglGetProcAddress('glUniformMatrix3fv');
  9496. if not Assigned(glUniformMatrix3fv) then allOK := false;
  9497. glUniformMatrix4fv := wglGetProcAddress('glUniformMatrix4fv');
  9498. if not Assigned(glUniformMatrix4fv) then allOK := false;
  9499. glValidateProgram := wglGetProcAddress('glValidateProgram');
  9500. if not Assigned(glValidateProgram) then allOK := false;
  9501. glVertexAttrib1d := wglGetProcAddress('glVertexAttrib1d');
  9502. if not Assigned(glVertexAttrib1d) then allOK := false;
  9503. glVertexAttrib1dv := wglGetProcAddress('glVertexAttrib1dv');
  9504. if not Assigned(glVertexAttrib1dv) then allOK := false;
  9505. glVertexAttrib1f := wglGetProcAddress('glVertexAttrib1f');
  9506. if not Assigned(glVertexAttrib1f) then allOK := false;
  9507. glVertexAttrib1fv := wglGetProcAddress('glVertexAttrib1fv');
  9508. if not Assigned(glVertexAttrib1fv) then allOK := false;
  9509. glVertexAttrib1s := wglGetProcAddress('glVertexAttrib1s');
  9510. if not Assigned(glVertexAttrib1s) then allOK := false;
  9511. glVertexAttrib1sv := wglGetProcAddress('glVertexAttrib1sv');
  9512. if not Assigned(glVertexAttrib1sv) then allOK := false;
  9513. glVertexAttrib2d := wglGetProcAddress('glVertexAttrib2d');
  9514. if not Assigned(glVertexAttrib2d) then allOK := false;
  9515. glVertexAttrib2dv := wglGetProcAddress('glVertexAttrib2dv');
  9516. if not Assigned(glVertexAttrib2dv) then allOK := false;
  9517. glVertexAttrib2f := wglGetProcAddress('glVertexAttrib2f');
  9518. if not Assigned(glVertexAttrib2f) then allOK := false;
  9519. glVertexAttrib2fv := wglGetProcAddress('glVertexAttrib2fv');
  9520. if not Assigned(glVertexAttrib2fv) then allOK := false;
  9521. glVertexAttrib2s := wglGetProcAddress('glVertexAttrib2s');
  9522. if not Assigned(glVertexAttrib2s) then allOK := false;
  9523. glVertexAttrib2sv := wglGetProcAddress('glVertexAttrib2sv');
  9524. if not Assigned(glVertexAttrib2sv) then allOK := false;
  9525. glVertexAttrib3d := wglGetProcAddress('glVertexAttrib3d');
  9526. if not Assigned(glVertexAttrib3d) then allOK := false;
  9527. glVertexAttrib3dv := wglGetProcAddress('glVertexAttrib3dv');
  9528. if not Assigned(glVertexAttrib3dv) then allOK := false;
  9529. glVertexAttrib3f := wglGetProcAddress('glVertexAttrib3f');
  9530. if not Assigned(glVertexAttrib3f) then allOK := false;
  9531. glVertexAttrib3fv := wglGetProcAddress('glVertexAttrib3fv');
  9532. if not Assigned(glVertexAttrib3fv) then allOK := false;
  9533. glVertexAttrib3s := wglGetProcAddress('glVertexAttrib3s');
  9534. if not Assigned(glVertexAttrib3s) then allOK := false;
  9535. glVertexAttrib3sv := wglGetProcAddress('glVertexAttrib3sv');
  9536. if not Assigned(glVertexAttrib3sv) then allOK := false;
  9537. glVertexAttrib4Nbv := wglGetProcAddress('glVertexAttrib4Nbv');
  9538. if not Assigned(glVertexAttrib4Nbv) then allOK := false;
  9539. glVertexAttrib4Niv := wglGetProcAddress('glVertexAttrib4Niv');
  9540. if not Assigned(glVertexAttrib4Niv) then allOK := false;
  9541. glVertexAttrib4Nsv := wglGetProcAddress('glVertexAttrib4Nsv');
  9542. if not Assigned(glVertexAttrib4Nsv) then allOK := false;
  9543. glVertexAttrib4Nub := wglGetProcAddress('glVertexAttrib4Nub');
  9544. if not Assigned(glVertexAttrib4Nub) then allOK := false;
  9545. glVertexAttrib4Nubv := wglGetProcAddress('glVertexAttrib4Nubv');
  9546. if not Assigned(glVertexAttrib4Nubv) then allOK := false;
  9547. glVertexAttrib4Nuiv := wglGetProcAddress('glVertexAttrib4Nuiv');
  9548. if not Assigned(glVertexAttrib4Nuiv) then allOK := false;
  9549. glVertexAttrib4Nusv := wglGetProcAddress('glVertexAttrib4Nusv');
  9550. if not Assigned(glVertexAttrib4Nusv) then allOK := false;
  9551. glVertexAttrib4bv := wglGetProcAddress('glVertexAttrib4bv');
  9552. if not Assigned(glVertexAttrib4bv) then allOK := false;
  9553. glVertexAttrib4d := wglGetProcAddress('glVertexAttrib4d');
  9554. if not Assigned(glVertexAttrib4d) then allOK := false;
  9555. glVertexAttrib4dv := wglGetProcAddress('glVertexAttrib4dv');
  9556. if not Assigned(glVertexAttrib4dv) then allOK := false;
  9557. glVertexAttrib4f := wglGetProcAddress('glVertexAttrib4f');
  9558. if not Assigned(glVertexAttrib4f) then allOK := false;
  9559. glVertexAttrib4fv := wglGetProcAddress('glVertexAttrib4fv');
  9560. if not Assigned(glVertexAttrib4fv) then allOK := false;
  9561. glVertexAttrib4iv := wglGetProcAddress('glVertexAttrib4iv');
  9562. if not Assigned(glVertexAttrib4iv) then allOK := false;
  9563. glVertexAttrib4s := wglGetProcAddress('glVertexAttrib4s');
  9564. if not Assigned(glVertexAttrib4s) then allOK := false;
  9565. glVertexAttrib4sv := wglGetProcAddress('glVertexAttrib4sv');
  9566. if not Assigned(glVertexAttrib4sv) then allOK := false;
  9567. glVertexAttrib4ubv := wglGetProcAddress('glVertexAttrib4ubv');
  9568. if not Assigned(glVertexAttrib4ubv) then allOK := false;
  9569. glVertexAttrib4uiv := wglGetProcAddress('glVertexAttrib4uiv');
  9570. if not Assigned(glVertexAttrib4uiv) then allOK := false;
  9571. glVertexAttrib4usv := wglGetProcAddress('glVertexAttrib4usv');
  9572. if not Assigned(glVertexAttrib4usv) then allOK := false;
  9573. glVertexAttribPointer := wglGetProcAddress('glVertexAttribPointer');
  9574. if not Assigned(glVertexAttribPointer) then allOK := false;
  9575. Load_GL_version_1_5x(allOK);
  9576. end;
  9577. function Load_GL_version_2_0: boolean;
  9578. begin
  9579. result := true;
  9580. Load_GL_version_2_0x(result);
  9581. end;
  9582. function glext_LoadExtension(ext: String): Boolean;
  9583. begin
  9584. Result := FALSE;
  9585. if ext = 'GL_version_1_2' then Result := Load_GL_version_1_2
  9586. else if ext = 'GL_ARB_imaging' then Result := Load_GL_ARB_imaging
  9587. else if ext = 'GL_version_1_3' then Result := Load_GL_version_1_3
  9588. else if ext = 'GL_ARB_multitexture' then Result := Load_GL_ARB_multitexture
  9589. else if ext = 'GL_ARB_transpose_matrix' then Result := Load_GL_ARB_transpose_matrix
  9590. else if ext = 'GL_ARB_multisample' then Result := Load_GL_ARB_multisample
  9591. else if ext = 'GL_ARB_texture_env_add' then Result := Load_GL_ARB_texture_env_add
  9592. {$IFDEF Windows}
  9593. else if ext = 'WGL_ARB_extensions_string' then Result := Load_WGL_ARB_extensions_string
  9594. else if ext = 'WGL_ARB_buffer_region' then Result := Load_WGL_ARB_buffer_region
  9595. {$ENDIF}
  9596. else if ext = 'GL_ARB_texture_cube_map' then Result := Load_GL_ARB_texture_cube_map
  9597. else if ext = 'GL_ARB_depth_texture' then Result := Load_GL_ARB_depth_texture
  9598. else if ext = 'GL_ARB_point_parameters' then Result := Load_GL_ARB_point_parameters
  9599. else if ext = 'GL_ARB_shadow' then Result := Load_GL_ARB_shadow
  9600. else if ext = 'GL_ARB_shadow_ambient' then Result := Load_GL_ARB_shadow_ambient
  9601. else if ext = 'GL_ARB_texture_border_clamp' then Result := Load_GL_ARB_texture_border_clamp
  9602. else if ext = 'GL_ARB_texture_compression' then Result := Load_GL_ARB_texture_compression
  9603. else if ext = 'GL_ARB_texture_env_combine' then Result := Load_GL_ARB_texture_env_combine
  9604. else if ext = 'GL_ARB_texture_env_crossbar' then Result := Load_GL_ARB_texture_env_crossbar
  9605. else if ext = 'GL_ARB_texture_env_dot3' then Result := Load_GL_ARB_texture_env_dot3
  9606. else if ext = 'GL_ARB_texture_mirrored_repeat' then Result := Load_GL_ARB_texture_mirrored_repeat
  9607. else if ext = 'GL_ARB_vertex_blend' then Result := Load_GL_ARB_vertex_blend
  9608. else if ext = 'GL_ARB_vertex_program' then Result := Load_GL_ARB_vertex_program
  9609. else if ext = 'GL_ARB_window_pos' then Result := Load_GL_ARB_window_pos
  9610. else if ext = 'GL_EXT_422_pixels' then Result := Load_GL_EXT_422_pixels
  9611. else if ext = 'GL_EXT_abgr' then Result := Load_GL_EXT_abgr
  9612. else if ext = 'GL_EXT_bgra' then Result := Load_GL_EXT_bgra
  9613. else if ext = 'GL_EXT_blend_color' then Result := Load_GL_EXT_blend_color
  9614. else if ext = 'GL_EXT_blend_func_separate' then Result := Load_GL_EXT_blend_func_separate
  9615. else if ext = 'GL_EXT_blend_logic_op' then Result := Load_GL_EXT_blend_logic_op
  9616. else if ext = 'GL_EXT_blend_minmax' then Result := Load_GL_EXT_blend_minmax
  9617. else if ext = 'GL_EXT_blend_subtract' then Result := Load_GL_EXT_blend_subtract
  9618. else if ext = 'GL_EXT_clip_volume_hint' then Result := Load_GL_EXT_clip_volume_hint
  9619. else if ext = 'GL_EXT_color_subtable' then Result := Load_GL_EXT_color_subtable
  9620. else if ext = 'GL_EXT_compiled_vertex_array' then Result := Load_GL_EXT_compiled_vertex_array
  9621. else if ext = 'GL_EXT_convolution' then Result := Load_GL_EXT_convolution
  9622. else if ext = 'GL_EXT_fog_coord' then Result := Load_GL_EXT_fog_coord
  9623. else if ext = 'GL_EXT_histogram' then Result := Load_GL_EXT_histogram
  9624. else if ext = 'GL_EXT_multi_draw_arrays' then Result := Load_GL_EXT_multi_draw_arrays
  9625. else if ext = 'GL_EXT_packed_pixels' then Result := Load_GL_EXT_packed_pixels
  9626. else if ext = 'GL_EXT_paletted_texture' then Result := Load_GL_EXT_paletted_texture
  9627. else if ext = 'GL_EXT_point_parameters' then Result := Load_GL_EXT_point_parameters
  9628. else if ext = 'GL_EXT_polygon_offset' then Result := Load_GL_EXT_polygon_offset
  9629. else if ext = 'GL_EXT_secondary_color' then Result := Load_GL_EXT_secondary_color
  9630. else if ext = 'GL_EXT_separate_specular_color' then Result := Load_GL_EXT_separate_specular_color
  9631. else if ext = 'GL_EXT_shadow_funcs' then Result := Load_GL_EXT_shadow_funcs
  9632. else if ext = 'GL_EXT_shared_texture_palette' then Result := Load_GL_EXT_shared_texture_palette
  9633. else if ext = 'GL_EXT_stencil_two_side' then Result := Load_GL_EXT_stencil_two_side
  9634. else if ext = 'GL_EXT_stencil_wrap' then Result := Load_GL_EXT_stencil_wrap
  9635. else if ext = 'GL_EXT_subtexture' then Result := Load_GL_EXT_subtexture
  9636. else if ext = 'GL_EXT_texture3D' then Result := Load_GL_EXT_texture3D
  9637. else if ext = 'GL_EXT_texture_compression_s3tc' then Result := Load_GL_EXT_texture_compression_s3tc
  9638. else if ext = 'GL_EXT_texture_env_add' then Result := Load_GL_EXT_texture_env_add
  9639. else if ext = 'GL_EXT_texture_env_combine' then Result := Load_GL_EXT_texture_env_combine
  9640. else if ext = 'GL_EXT_texture_env_dot3' then Result := Load_GL_EXT_texture_env_dot3
  9641. else if ext = 'GL_EXT_texture_filter_anisotropic' then Result := Load_GL_EXT_texture_filter_anisotropic
  9642. else if ext = 'GL_EXT_texture_lod_bias' then Result := Load_GL_EXT_texture_lod_bias
  9643. else if ext = 'GL_EXT_texture_object' then Result := Load_GL_EXT_texture_object
  9644. else if ext = 'GL_EXT_vertex_array' then Result := Load_GL_EXT_vertex_array
  9645. else if ext = 'GL_EXT_vertex_shader' then Result := Load_GL_EXT_vertex_shader
  9646. else if ext = 'GL_EXT_vertex_weighting' then Result := Load_GL_EXT_vertex_weighting
  9647. else if ext = 'GL_HP_occlusion_test' then Result := Load_GL_HP_occlusion_test
  9648. else if ext = 'GL_NV_blend_square' then Result := Load_GL_NV_blend_square
  9649. else if ext = 'GL_NV_copy_depth_to_color' then Result := Load_GL_NV_copy_depth_to_color
  9650. else if ext = 'GL_NV_depth_clamp' then Result := Load_GL_NV_depth_clamp
  9651. else if ext = 'GL_NV_evaluators' then Result := Load_GL_NV_evaluators
  9652. else if ext = 'GL_NV_fence' then Result := Load_GL_NV_fence
  9653. else if ext = 'GL_NV_fog_distance' then Result := Load_GL_NV_fog_distance
  9654. else if ext = 'GL_NV_light_max_exponent' then Result := Load_GL_NV_light_max_exponent
  9655. else if ext = 'GL_NV_multisample_filter_hint' then Result := Load_GL_NV_multisample_filter_hint
  9656. else if ext = 'GL_NV_occlusion_query' then Result := Load_GL_NV_occlusion_query
  9657. else if ext = 'GL_NV_packed_depth_stencil' then Result := Load_GL_NV_packed_depth_stencil
  9658. else if ext = 'GL_NV_point_sprite' then Result := Load_GL_NV_point_sprite
  9659. else if ext = 'GL_NV_register_combiners' then Result := Load_GL_NV_register_combiners
  9660. else if ext = 'GL_NV_register_combiners2' then Result := Load_GL_NV_register_combiners2
  9661. else if ext = 'GL_NV_texgen_emboss' then Result := Load_GL_NV_texgen_emboss
  9662. else if ext = 'GL_NV_texgen_reflection' then Result := Load_GL_NV_texgen_reflection
  9663. else if ext = 'GL_NV_texture_compression_vtc' then Result := Load_GL_NV_texture_compression_vtc
  9664. else if ext = 'GL_NV_texture_env_combine4' then Result := Load_GL_NV_texture_env_combine4
  9665. else if ext = 'GL_NV_texture_rectangle' then Result := Load_GL_NV_texture_rectangle
  9666. else if ext = 'GL_NV_texture_shader' then Result := Load_GL_NV_texture_shader
  9667. else if ext = 'GL_NV_texture_shader2' then Result := Load_GL_NV_texture_shader2
  9668. else if ext = 'GL_NV_texture_shader3' then Result := Load_GL_NV_texture_shader3
  9669. else if ext = 'GL_NV_vertex_array_range' then Result := Load_GL_NV_vertex_array_range
  9670. else if ext = 'GL_NV_vertex_array_range2' then Result := Load_GL_NV_vertex_array_range2
  9671. else if ext = 'GL_NV_vertex_program' then Result := Load_GL_NV_vertex_program
  9672. else if ext = 'GL_NV_vertex_program1_1' then Result := Load_GL_NV_vertex_program1_1
  9673. else if ext = 'GL_ATI_element_array' then Result := Load_GL_ATI_element_array
  9674. else if ext = 'GL_ATI_envmap_bumpmap' then Result := Load_GL_ATI_envmap_bumpmap
  9675. else if ext = 'GL_ATI_fragment_shader' then Result := Load_GL_ATI_fragment_shader
  9676. else if ext = 'GL_ATI_pn_triangles' then Result := Load_GL_ATI_pn_triangles
  9677. else if ext = 'GL_ATI_texture_mirror_once' then Result := Load_GL_ATI_texture_mirror_once
  9678. else if ext = 'GL_ATI_vertex_array_object' then Result := Load_GL_ATI_vertex_array_object
  9679. else if ext = 'GL_ATI_vertex_streams' then Result := Load_GL_ATI_vertex_streams
  9680. {$IFDEF Windows}
  9681. else if ext = 'WGL_I3D_image_buffer' then Result := Load_WGL_I3D_image_buffer
  9682. else if ext = 'WGL_I3D_swap_frame_lock' then Result := Load_WGL_I3D_swap_frame_lock
  9683. else if ext = 'WGL_I3D_swap_frame_usage' then Result := Load_WGL_I3D_swap_frame_usage
  9684. {$ENDIF}
  9685. else if ext = 'GL_3DFX_texture_compression_FXT1' then Result := Load_GL_3DFX_texture_compression_FXT1
  9686. else if ext = 'GL_IBM_cull_vertex' then Result := Load_GL_IBM_cull_vertex
  9687. else if ext = 'GL_IBM_multimode_draw_arrays' then Result := Load_GL_IBM_multimode_draw_arrays
  9688. else if ext = 'GL_IBM_raster_pos_clip' then Result := Load_GL_IBM_raster_pos_clip
  9689. else if ext = 'GL_IBM_texture_mirrored_repeat' then Result := Load_GL_IBM_texture_mirrored_repeat
  9690. else if ext = 'GL_IBM_vertex_array_lists' then Result := Load_GL_IBM_vertex_array_lists
  9691. else if ext = 'GL_MESA_resize_buffers' then Result := Load_GL_MESA_resize_buffers
  9692. else if ext = 'GL_MESA_window_pos' then Result := Load_GL_MESA_window_pos
  9693. else if ext = 'GL_OML_interlace' then Result := Load_GL_OML_interlace
  9694. else if ext = 'GL_OML_resample' then Result := Load_GL_OML_resample
  9695. else if ext = 'GL_OML_subsample' then Result := Load_GL_OML_subsample
  9696. else if ext = 'GL_SGIS_generate_mipmap' then Result := Load_GL_SGIS_generate_mipmap
  9697. else if ext = 'GL_SGIS_multisample' then Result := Load_GL_SGIS_multisample
  9698. else if ext = 'GL_SGIS_pixel_texture' then Result := Load_GL_SGIS_pixel_texture
  9699. else if ext = 'GL_SGIS_texture_border_clamp' then Result := Load_GL_SGIS_texture_border_clamp
  9700. else if ext = 'GL_SGIS_texture_color_mask' then Result := Load_GL_SGIS_texture_color_mask
  9701. else if ext = 'GL_SGIS_texture_edge_clamp' then Result := Load_GL_SGIS_texture_edge_clamp
  9702. else if ext = 'GL_SGIS_texture_lod' then Result := Load_GL_SGIS_texture_lod
  9703. else if ext = 'GL_SGIS_depth_texture' then Result := Load_GL_SGIS_depth_texture
  9704. else if ext = 'GL_SGIX_fog_offset' then Result := Load_GL_SGIX_fog_offset
  9705. else if ext = 'GL_SGIX_interlace' then Result := Load_GL_SGIX_interlace
  9706. else if ext = 'GL_SGIX_shadow_ambient' then Result := Load_GL_SGIX_shadow_ambient
  9707. else if ext = 'GL_SGI_color_matrix' then Result := Load_GL_SGI_color_matrix
  9708. else if ext = 'GL_SGI_color_table' then Result := Load_GL_SGI_color_table
  9709. else if ext = 'GL_SGI_texture_color_table' then Result := Load_GL_SGI_texture_color_table
  9710. else if ext = 'GL_SUN_vertex' then Result := Load_GL_SUN_vertex
  9711. else if ext = 'GL_ARB_fragment_program' then Result := Load_GL_ARB_fragment_program
  9712. else if ext = 'GL_ATI_text_fragment_shader' then Result := Load_GL_ATI_text_fragment_shader
  9713. else if ext = 'GL_APPLE_client_storage' then Result := Load_GL_APPLE_client_storage
  9714. else if ext = 'GL_APPLE_element_array' then Result := Load_GL_APPLE_element_array
  9715. else if ext = 'GL_APPLE_fence' then Result := Load_GL_APPLE_fence
  9716. else if ext = 'GL_APPLE_vertex_array_object' then Result := Load_GL_APPLE_vertex_array_object
  9717. else if ext = 'GL_APPLE_vertex_array_range' then Result := Load_GL_APPLE_vertex_array_range
  9718. {$IFDEF Windows}
  9719. else if ext = 'WGL_ARB_pixel_format' then Result := Load_WGL_ARB_pixel_format
  9720. else if ext = 'WGL_ARB_make_current_read' then Result := Load_WGL_ARB_make_current_read
  9721. else if ext = 'WGL_ARB_pbuffer' then Result := Load_WGL_ARB_pbuffer
  9722. else if ext = 'WGL_EXT_swap_control' then Result := Load_WGL_EXT_swap_control
  9723. else if ext = 'WGL_ARB_render_texture' then Result := Load_WGL_ARB_render_texture
  9724. else if ext = 'WGL_EXT_extensions_string' then Result := Load_WGL_EXT_extensions_string
  9725. else if ext = 'WGL_EXT_make_current_read' then Result := Load_WGL_EXT_make_current_read
  9726. else if ext = 'WGL_EXT_pbuffer' then Result := Load_WGL_EXT_pbuffer
  9727. else if ext = 'WGL_EXT_pixel_format' then Result := Load_WGL_EXT_pixel_format
  9728. else if ext = 'WGL_I3D_digital_video_control' then Result := Load_WGL_I3D_digital_video_control
  9729. else if ext = 'WGL_I3D_gamma' then Result := Load_WGL_I3D_gamma
  9730. else if ext = 'WGL_I3D_genlock' then Result := Load_WGL_I3D_genlock
  9731. {$ENDIF}
  9732. else if ext = 'GL_ARB_matrix_palette' then Result := Load_GL_ARB_matrix_palette
  9733. else if ext = 'GL_NV_element_array' then Result := Load_GL_NV_element_array
  9734. else if ext = 'GL_NV_float_buffer' then Result := Load_GL_NV_float_buffer
  9735. else if ext = 'GL_NV_fragment_program' then Result := Load_GL_NV_fragment_program
  9736. else if ext = 'GL_NV_primitive_restart' then Result := Load_GL_NV_primitive_restart
  9737. else if ext = 'GL_NV_vertex_program2' then Result := Load_GL_NV_vertex_program2
  9738. {$IFDEF Windows}
  9739. else if ext = 'WGL_NV_render_texture_rectangle' then Result := Load_WGL_NV_render_texture_rectangle
  9740. {$ENDIF}
  9741. else if ext = 'GL_NV_pixel_data_range' then Result := Load_GL_NV_pixel_data_range
  9742. else if ext = 'GL_EXT_texture_rectangle' then Result := Load_GL_EXT_texture_rectangle
  9743. else if ext = 'GL_S3_s3tc' then Result := Load_GL_S3_s3tc
  9744. else if ext = 'GL_ATI_draw_buffers' then Result := Load_GL_ATI_draw_buffers
  9745. {$IFDEF Windows}
  9746. else if ext = 'WGL_ATI_pixel_format_float' then Result := Load_WGL_ATI_pixel_format_float
  9747. {$ENDIF}
  9748. else if ext = 'GL_ATI_texture_env_combine3' then Result := Load_GL_ATI_texture_env_combine3
  9749. else if ext = 'GL_ATI_texture_float' then Result := Load_GL_ATI_texture_float
  9750. else if ext = 'GL_NV_texture_expand_normal' then Result := Load_GL_NV_texture_expand_normal
  9751. else if ext = 'GL_NV_half_float' then Result := Load_GL_NV_half_float
  9752. else if ext = 'GL_ATI_map_object_buffer' then Result := Load_GL_ATI_map_object_buffer
  9753. else if ext = 'GL_ATI_separate_stencil' then Result := Load_GL_ATI_separate_stencil
  9754. else if ext = 'GL_ATI_vertex_attrib_array_object' then Result := Load_GL_ATI_vertex_attrib_array_object
  9755. else if ext = 'GL_ARB_vertex_buffer_object' then Result := Load_GL_ARB_vertex_buffer_object
  9756. else if ext = 'GL_ARB_occlusion_query' then Result := Load_GL_ARB_occlusion_query
  9757. else if ext = 'GL_ARB_shader_objects' then Result := Load_GL_ARB_shader_objects
  9758. else if ext = 'GL_ARB_vertex_shader' then Result := Load_GL_ARB_vertex_shader
  9759. else if ext = 'GL_ARB_fragment_shader' then Result := Load_GL_ARB_fragment_shader
  9760. else if ext = 'GL_ARB_shading_language_100' then Result := Load_GL_ARB_shading_language_100
  9761. else if ext = 'GL_ARB_texture_non_power_of_two' then Result := Load_GL_ARB_texture_non_power_of_two
  9762. else if ext = 'GL_ARB_point_sprite' then Result := Load_GL_ARB_point_sprite
  9763. else if ext = 'GL_EXT_depth_bounds_test' then Result := Load_GL_EXT_depth_bounds_test
  9764. else if ext = 'GL_EXT_texture_mirror_clamp' then Result := Load_GL_EXT_texture_mirror_clamp
  9765. else if ext = 'GL_EXT_blend_equation_separate' then Result := Load_GL_EXT_blend_equation_separate
  9766. else if ext = 'GL_MESA_pack_invert' then Result := Load_GL_MESA_pack_invert
  9767. else if ext = 'GL_MESA_ycbcr_texture' then Result := Load_GL_MESA_ycbcr_texture
  9768. else if ext = 'GL_ARB_fragment_program_shadow' then Result := Load_GL_ARB_fragment_program_shadow
  9769. else if ext = 'GL_NV_fragment_program_option' then Result := Load_GL_NV_fragment_program_option
  9770. else if ext = 'GL_EXT_pixel_buffer_object' then Result := Load_GL_EXT_pixel_buffer_object
  9771. else if ext = 'GL_NV_fragment_program2' then Result := Load_GL_NV_fragment_program2
  9772. else if ext = 'GL_NV_vertex_program2_option' then Result := Load_GL_NV_vertex_program2_option
  9773. else if ext = 'GL_NV_vertex_program3' then Result := Load_GL_NV_vertex_program3
  9774. else if ext = 'GL_ARB_draw_buffers' then Result := Load_GL_ARB_draw_buffers
  9775. else if ext = 'GL_ARB_texture_rectangle' then Result := Load_GL_ARB_texture_rectangle
  9776. else if ext = 'GL_ARB_color_buffer_float' then Result := Load_GL_ARB_color_buffer_float
  9777. else if ext = 'GL_ARB_half_float_pixel' then Result := Load_GL_ARB_half_float_pixel
  9778. else if ext = 'GL_ARB_texture_float' then Result := Load_GL_ARB_texture_float
  9779. else if ext = 'GL_EXT_texture_compression_dxt1' then Result := Load_GL_EXT_texture_compression_dxt1
  9780. else if ext = 'GL_ARB_pixel_buffer_object' then Result := Load_GL_ARB_pixel_buffer_object
  9781. else if ext = 'GL_EXT_framebuffer_object' then Result := Load_GL_EXT_framebuffer_object
  9782. else if ext = 'GL_version_1_4' then Result := Load_GL_version_1_4
  9783. else if ext = 'GL_version_1_5' then Result := Load_GL_version_1_5
  9784. else if ext = 'GL_version_2_0' then Result := Load_GL_version_2_0
  9785. end;
  9786. procedure Load_GL_version_2_1x (var allOK: Boolean);
  9787. begin
  9788. glUniformMatrix2x3fv := wglGetProcAddress('glUniformMatrix2x3fv');
  9789. if not Assigned(glUniformMatrix2x3fv) then allOK := false;
  9790. glUniformMatrix3x2fv := wglGetProcAddress('glUniformMatrix3x2fv');
  9791. if not Assigned(glUniformMatrix3x2fv) then allOK := false;
  9792. glUniformMatrix2x4fv := wglGetProcAddress('glUniformMatrix2x4fv');
  9793. if not Assigned(glUniformMatrix2x4fv) then allOK := false;
  9794. glUniformMatrix4x2fv := wglGetProcAddress('glUniformMatrix4x2fv');
  9795. if not Assigned(glUniformMatrix4x2fv) then allOK := false;
  9796. glUniformMatrix3x4fv := wglGetProcAddress('glUniformMatrix3x4fv');
  9797. if not Assigned(glUniformMatrix3x4fv) then allOK := false;
  9798. glUniformMatrix4x3fv := wglGetProcAddress('glUniformMatrix4x3fv');
  9799. if not Assigned(glUniformMatrix4x3fv) then allOK := false;
  9800. Load_GL_VERSION_2_0x(allOK);
  9801. end;
  9802. function Load_GL_version_2_1: boolean;
  9803. begin
  9804. result := true;
  9805. Load_GL_version_2_1x(result);
  9806. end;
  9807. procedure Load_GL_version_3_0x (var allOK: boolean; out isVersion: Boolean);
  9808. begin
  9809. glColorMaski := wglGetProcAddress('glColorMaski');
  9810. isVersion := Assigned(glColorMaski);
  9811. if not Assigned(glColorMaski) then allOK := false;
  9812. glGetBooleani_v := wglGetProcAddress('glGetBooleani_v');
  9813. if not Assigned(glGetBooleani_v) then allOK := false;
  9814. glGetIntegeri_v := wglGetProcAddress('glGetIntegeri_v');
  9815. if not Assigned(glGetIntegeri_v) then allOK := false;
  9816. glEnablei := wglGetProcAddress('glEnablei');
  9817. if not Assigned(glEnablei) then allOK := false;
  9818. glDisablei := wglGetProcAddress('glDisablei');
  9819. if not Assigned(glDisablei) then allOK := false;
  9820. glIsEnabledi := wglGetProcAddress('glIsEnabledi');
  9821. if not Assigned(glIsEnabledi) then allOK := false;
  9822. glBeginTransformFeedback := wglGetProcAddress('glBeginTransformFeedback');
  9823. if not Assigned(glBeginTransformFeedback) then allOK := false;
  9824. glEndTransformFeedback := wglGetProcAddress('glEndTransformFeedback');
  9825. if not Assigned(glEndTransformFeedback) then allOK := false;
  9826. glBindBufferRange := wglGetProcAddress('glBindBufferRange');
  9827. if not Assigned(glBindBufferRange) then allOK := false;
  9828. glBindBufferBase := wglGetProcAddress('glBindBufferBase');
  9829. if not Assigned(glBindBufferBase) then allOK := false;
  9830. glTransformFeedbackVaryings := wglGetProcAddress('glTransformFeedbackVaryings');
  9831. if not Assigned(glTransformFeedbackVaryings) then allOK := false;
  9832. glGetTransformFeedbackVarying := wglGetProcAddress('glGetTransformFeedbackVarying');
  9833. if not Assigned(glGetTransformFeedbackVarying) then allOK := false;
  9834. glClampColor := wglGetProcAddress('glClampColor');
  9835. if not Assigned(glClampColor) then allOK := false;
  9836. glBeginConditionalRender := wglGetProcAddress('glBeginConditionalRender');
  9837. if not Assigned(glBeginConditionalRender) then allOK := false;
  9838. glEndConditionalRender := wglGetProcAddress('glEndConditionalRender');
  9839. if not Assigned(glEndConditionalRender) then allOK := false;
  9840. glVertexAttribIPointer := wglGetProcAddress('glVertexAttribIPointer');
  9841. if not Assigned(glVertexAttribIPointer) then allOK := false;
  9842. glGetVertexAttribIiv := wglGetProcAddress('glGetVertexAttribIiv');
  9843. if not Assigned(glGetVertexAttribIiv) then allOK := false;
  9844. glGetVertexAttribIuiv := wglGetProcAddress('glGetVertexAttribIuiv');
  9845. if not Assigned(glGetVertexAttribIuiv) then allOK := false;
  9846. glVertexAttribI1i := wglGetProcAddress('glVertexAttribI1i');
  9847. if not Assigned(glVertexAttribI1i) then allOK := false;
  9848. glVertexAttribI2i := wglGetProcAddress('glVertexAttribI2i');
  9849. if not Assigned(glVertexAttribI2i) then allOK := false;
  9850. glVertexAttribI3i := wglGetProcAddress('glVertexAttribI3i');
  9851. if not Assigned(glVertexAttribI3i) then allOK := false;
  9852. glVertexAttribI4i := wglGetProcAddress('glVertexAttribI4i');
  9853. if not Assigned(glVertexAttribI4i) then allOK := false;
  9854. glVertexAttribI1ui := wglGetProcAddress('glVertexAttribI1ui');
  9855. if not Assigned(glVertexAttribI1ui) then allOK := false;
  9856. glVertexAttribI2ui := wglGetProcAddress('glVertexAttribI2ui');
  9857. if not Assigned(glVertexAttribI2ui) then allOK := false;
  9858. glVertexAttribI3ui := wglGetProcAddress('glVertexAttribI3ui');
  9859. if not Assigned(glVertexAttribI3ui) then allOK := false;
  9860. glVertexAttribI4ui := wglGetProcAddress('glVertexAttribI4ui');
  9861. if not Assigned(glVertexAttribI4ui) then allOK := false;
  9862. glVertexAttribI1iv := wglGetProcAddress('glVertexAttribI1iv');
  9863. if not Assigned(glVertexAttribI1iv) then allOK := false;
  9864. glVertexAttribI2iv := wglGetProcAddress('glVertexAttribI2iv');
  9865. if not Assigned(glVertexAttribI2iv) then allOK := false;
  9866. glVertexAttribI3iv := wglGetProcAddress('glVertexAttribI3iv');
  9867. if not Assigned(glVertexAttribI3iv) then allOK := false;
  9868. glVertexAttribI4iv := wglGetProcAddress('glVertexAttribI4iv');
  9869. if not Assigned(glVertexAttribI4iv) then allOK := false;
  9870. glVertexAttribI1uiv := wglGetProcAddress('glVertexAttribI1uiv');
  9871. if not Assigned(glVertexAttribI1uiv) then allOK := false;
  9872. glVertexAttribI2uiv := wglGetProcAddress('glVertexAttribI2uiv');
  9873. if not Assigned(glVertexAttribI2uiv) then allOK := false;
  9874. glVertexAttribI3uiv := wglGetProcAddress('glVertexAttribI3uiv');
  9875. if not Assigned(glVertexAttribI3uiv) then allOK := false;
  9876. glVertexAttribI4uiv := wglGetProcAddress('glVertexAttribI4uiv');
  9877. if not Assigned(glVertexAttribI4uiv) then allOK := false;
  9878. glVertexAttribI4bv := wglGetProcAddress('glVertexAttribI4bv');
  9879. if not Assigned(glVertexAttribI4bv) then allOK := false;
  9880. glVertexAttribI4sv := wglGetProcAddress('glVertexAttribI4sv');
  9881. if not Assigned(glVertexAttribI4sv) then allOK := false;
  9882. glVertexAttribI4ubv := wglGetProcAddress('glVertexAttribI4ubv');
  9883. if not Assigned(glVertexAttribI4ubv) then allOK := false;
  9884. glVertexAttribI4usv := wglGetProcAddress('glVertexAttribI4usv');
  9885. if not Assigned(glVertexAttribI4usv) then allOK := false;
  9886. glGetUniformuiv := wglGetProcAddress('glGetUniformuiv');
  9887. if not Assigned(glGetUniformuiv) then allOK := false;
  9888. glBindFragDataLocation := wglGetProcAddress('glBindFragDataLocation');
  9889. if not Assigned(glBindFragDataLocation) then allOK := false;
  9890. glGetFragDataLocation := wglGetProcAddress('glGetFragDataLocation');
  9891. if not Assigned(glGetFragDataLocation) then allOK := false;
  9892. glUniform1ui := wglGetProcAddress('glUniform1ui');
  9893. if not Assigned(glUniform1ui) then allOK := false;
  9894. glUniform2ui := wglGetProcAddress('glUniform2ui');
  9895. if not Assigned(glUniform2ui) then allOK := false;
  9896. glUniform3ui := wglGetProcAddress('glUniform3ui');
  9897. if not Assigned(glUniform3ui) then allOK := false;
  9898. glUniform4ui := wglGetProcAddress('glUniform4ui');
  9899. if not Assigned(glUniform4ui) then allOK := false;
  9900. glUniform1uiv := wglGetProcAddress('glUniform1uiv');
  9901. if not Assigned(glUniform1uiv) then allOK := false;
  9902. glUniform2uiv := wglGetProcAddress('glUniform2uiv');
  9903. if not Assigned(glUniform2uiv) then allOK := false;
  9904. glUniform3uiv := wglGetProcAddress('glUniform3uiv');
  9905. if not Assigned(glUniform3uiv) then allOK := false;
  9906. glUniform4uiv := wglGetProcAddress('glUniform4uiv');
  9907. if not Assigned(glUniform4uiv) then allOK := false;
  9908. glTexParameterIiv := wglGetProcAddress('glTexParameterIiv');
  9909. if not Assigned(glTexParameterIiv) then allOK := false;
  9910. glTexParameterIuiv := wglGetProcAddress('glTexParameterIuiv');
  9911. if not Assigned(glTexParameterIuiv) then allOK := false;
  9912. glGetTexParameterIiv := wglGetProcAddress('glGetTexParameterIiv');
  9913. if not Assigned(glGetTexParameterIiv) then allOK := false;
  9914. glGetTexParameterIuiv := wglGetProcAddress('glGetTexParameterIuiv');
  9915. if not Assigned(glGetTexParameterIuiv) then allOK := false;
  9916. glClearBufferiv := wglGetProcAddress('glClearBufferiv');
  9917. if not Assigned(glClearBufferiv) then allOK := false;
  9918. glClearBufferuiv := wglGetProcAddress('glClearBufferuiv');
  9919. if not Assigned(glClearBufferuiv) then allOK := false;
  9920. glClearBufferfv := wglGetProcAddress('glClearBufferfv');
  9921. if not Assigned(glClearBufferfv) then allOK := false;
  9922. glClearBufferfi := wglGetProcAddress('glClearBufferfi');
  9923. if not Assigned(glClearBufferfi) then allOK := false;
  9924. glGetStringi := wglGetProcAddress('glGetStringi');
  9925. if not Assigned(glGetStringi) then allOK := false;
  9926. if not Load_GL_ARB_framebuffer_object(true) then allOK := false;
  9927. if not Load_GL_ARB_map_buffer_range(true) then allOK := false;
  9928. if not Load_GL_ARB_vertex_array_object(true) then allOK := false;
  9929. Load_GL_VERSION_2_1x(allOK);
  9930. end;
  9931. function Load_GL_version_3_0: boolean;
  9932. var
  9933. dummy: boolean;
  9934. begin
  9935. result := true;
  9936. Load_GL_version_3_0x(result, dummy);
  9937. end;
  9938. function Load_GL_version_3_0_CORE: boolean;
  9939. var
  9940. dummy: boolean;
  9941. begin
  9942. Load_GL_version_3_0x(dummy, result);
  9943. glGetError(); //clear errors for invalid enums
  9944. end;
  9945. function Load_GL_Debug_output: Boolean;
  9946. var
  9947. extstring: String;
  9948. begin
  9949. Result := False;
  9950. extstring := String(PChar(glGetString(GL_EXTENSIONS)));
  9951. if glext_ExtensionSupported('GL_KHR_debug', extstring) then
  9952. begin
  9953. glDebugMessageCallback := wglGetProcAddress('glDebugMessageCallback');
  9954. if not Assigned(glDebugMessageCallback) then Exit;
  9955. glDebugMessageControl := wglGetProcAddress('glDebugMessageControl');
  9956. if not Assigned(glDebugMessageControl) then Exit;
  9957. Result := True;
  9958. end;
  9959. if not Result and glext_ExtensionSupported('GL_ARB_debug_output', extstring) then
  9960. begin
  9961. glDebugMessageCallback := wglGetProcAddress('glDebugMessageCallbackARB');
  9962. if not Assigned(glDebugMessageCallback) then Exit;
  9963. glDebugMessageControl := wglGetProcAddress('glDebugMessageControlARB');
  9964. if not Assigned(glDebugMessageControl) then Exit;
  9965. Result := True;
  9966. end;
  9967. end;
  9968. procedure Load_GL_VERSION_3_1x(var allOK: boolean; out isVersion: Boolean);
  9969. var
  9970. dummy: boolean;
  9971. begin
  9972. glDrawArraysInstanced := wglGetProcAddress('glDrawArraysInstanced');
  9973. isVersion := Assigned(glDrawArraysInstanced);
  9974. if not Assigned(glDrawArraysInstanced) then allOK := false;
  9975. glDrawElementsInstanced := wglGetProcAddress('glDrawElementsInstanced');
  9976. if not Assigned(glDrawElementsInstanced) then allOK := false;
  9977. glTexBuffer := wglGetProcAddress('glTexBuffer');
  9978. if not Assigned(glTexBuffer) then allOK := false;
  9979. glPrimitiveRestartIndex := wglGetProcAddress('glPrimitiveRestartIndex');
  9980. if not Assigned(glPrimitiveRestartIndex) then allOK := false;
  9981. if not Load_GL_ARB_copy_buffer(true) then allOK := false;
  9982. if not Load_GL_ARB_uniform_buffer_object(true) then allOK := false;
  9983. Load_GL_VERSION_3_0x(allOK, dummy);
  9984. end;
  9985. function Load_GL_version_3_1: boolean;
  9986. var
  9987. dummy: boolean;
  9988. begin
  9989. result := true;
  9990. Load_GL_version_3_1x(result, dummy);
  9991. end;
  9992. function Load_GL_version_3_1_CORE: boolean;
  9993. var
  9994. dummy: boolean;
  9995. begin
  9996. Load_GL_version_3_1x(dummy, result);
  9997. glGetError(); //clear errors for invalid enums
  9998. end;
  9999. procedure Load_GL_VERSION_3_2x(var allOK: boolean; out isVersion: Boolean);
  10000. var
  10001. dummy: boolean;
  10002. begin
  10003. glGetInteger64i_v := wglGetProcAddress('glGetInteger64i_v');
  10004. isVersion := Assigned(glGetInteger64i_v);
  10005. if not Assigned(glGetInteger64i_v) then allOK := false;
  10006. glGetBufferParameteri64v := wglGetProcAddress('glGetBufferParameteri64v');
  10007. if not Assigned(glGetBufferParameteri64v) then allOK := false;
  10008. glProgramParameteri := wglGetProcAddress('glProgramParameteri');
  10009. if not Assigned(glProgramParameteri) then allOK := false;
  10010. glFramebufferTexture := wglGetProcAddress('glFramebufferTexture');
  10011. if not Assigned(glFramebufferTexture) then allOK := false;
  10012. if not Load_GL_ARB_draw_elements_base_vertex(true) then allOK := false;
  10013. if not Load_GL_ARB_provoking_vertex(true) then allOK := false;
  10014. if not Load_GL_ARB_sync(true) then allOK := false;
  10015. if not Load_GL_ARB_texture_multisample(true) then allOK := false;
  10016. Load_GL_VERSION_3_1x(allOK, dummy);
  10017. end;
  10018. function Load_GL_version_3_2: boolean;
  10019. var
  10020. dummy: boolean;
  10021. begin
  10022. result := true;
  10023. Load_GL_version_3_2x(result, dummy);
  10024. end;
  10025. function Load_GL_version_3_2_CORE: boolean;
  10026. var
  10027. dummy: boolean;
  10028. begin
  10029. result := true;
  10030. Load_GL_version_3_2x(dummy, dummy);
  10031. glGetError(); //clear errors for invalid enums
  10032. end;
  10033. procedure Load_GL_VERSION_3_3x(var allOK: boolean; out isVersion: Boolean);
  10034. var
  10035. dummy: boolean;
  10036. begin
  10037. isVersion := Load_GL_ARB_blend_func_extended(true);
  10038. if not isVersion then allOK := false;
  10039. if not Load_GL_ARB_sampler_objects(true) then allOK := false;
  10040. if not Load_GL_ARB_timer_query(true) then allOK := false;
  10041. if not Load_GL_ARB_vertex_type_2_10_10_10_rev(true) then allOK := false;
  10042. Load_GL_VERSION_3_2x(allOK, dummy);
  10043. end;
  10044. function Load_GL_version_3_3: boolean;
  10045. var
  10046. dummy: boolean;
  10047. begin
  10048. result := true;
  10049. Load_GL_version_3_3x(result, dummy);
  10050. end;
  10051. function Load_GL_version_3_3_CORE: boolean;
  10052. var
  10053. dummy: boolean;
  10054. begin
  10055. result := true;
  10056. Load_GL_version_3_3x(dummy, result);
  10057. glGetError(); //clear errors for invalid enums
  10058. end;
  10059. procedure Load_GL_VERSION_4_0x(var allOK: boolean; out isVersion: Boolean);
  10060. var
  10061. dummy: boolean;
  10062. begin
  10063. isVersion := Load_GL_ARB_gpu_shader_fp64(true);
  10064. if not isVersion then allOK := false;
  10065. if not Load_GL_ARB_shader_subroutine(true) then allOK := false;
  10066. if not Load_GL_ARB_tessellation_shader(true) then allOK := false;
  10067. if not Load_GL_ARB_transform_feedback2(true) then allOK := false;
  10068. if not Load_GL_ARB_transform_feedback3(true) then allOK := false;
  10069. Load_GL_VERSION_3_3x(allOK, dummy);
  10070. end;
  10071. function Load_GL_version_4_0: boolean;
  10072. var
  10073. dummy: boolean;
  10074. begin
  10075. result := true;
  10076. Load_GL_version_4_0x(result, dummy);
  10077. end;
  10078. function Load_GL_version_4_0_CORE: boolean;
  10079. var
  10080. dummy: boolean;
  10081. begin
  10082. result := true;
  10083. Load_GL_version_4_0x(dummy, dummy);
  10084. glGetError(); //clear errors for invalid enums
  10085. end;
  10086. function Load_GL_VERSION_4_3(): Boolean;
  10087. var
  10088. dummy: boolean;
  10089. begin
  10090. Result := true;
  10091. if not Load_GL_Debug_output() then result := false;
  10092. Load_GL_VERSION_4_0x(result, dummy);
  10093. end;
  10094. function Load_GL_version_4_3_CORE: boolean;
  10095. var
  10096. dummy, dummy2: boolean;
  10097. begin
  10098. result := Load_GL_Debug_output();
  10099. Load_GL_VERSION_4_0x(dummy, dummy2);
  10100. glGetError(); //clear errors for invalid enums
  10101. end;
  10102. end.