Difference between "webgl" and "experimental-webgl" - Stack ...
文章推薦指數: 80 %
TL;DR: "experimental-webgl" = beta, it was used by browsers before WebGL 1.0 shipped to try to indicate this is not final. Home Public Questions Tags Users Collectives ExploreCollectives FindaJob Jobs Companies Teams StackOverflowforTeams –Collaborateandshareknowledgewithaprivategroup. CreateafreeTeam WhatisTeams? Teams CreatefreeTeam CollectivesonStackOverflow Findcentralized,trustedcontentandcollaboratearoundthetechnologiesyouusemost. Learnmore Teams Q&Aforwork Connectandshareknowledgewithinasinglelocationthatisstructuredandeasytosearch. Learnmore Differencebetween"webgl"and"experimental-webgl" AskQuestion Asked 5years,2monthsago Active 5years,2monthsago Viewed 5ktimes 8 1 Somesitessaythatyoushouldinitializewebglthefollowingway: vargl=c.getContext("webgl")||c.getContext("experimental-webgl"); if(!gl) alert("Thisbrowserdoesn'tsupportWebGL!"); What'sthedifferencebetweenwebglandexperimental-webgl?TheonlydescriptionIcouldfindwasonMDN: getContext(inDOMStringcontextId)RenderingContextReturnsadrawingcontextonthecanvas,ornullifthecontextIDisnotsupported.Adrawingcontextletsyoudrawonthecanvas.CallinggetContextwith"2d"returnsaCanvasRenderingContext2Dobject,whereascallingitwith"experimental-webgl"(or"webgl")returnsaWebGLRenderingContextobject.ThiscontextisonlyavailableonbrowsersthatimplementWebGL. Howeverthismakesthe2seemlikethey'rethesame.Isthereadifference? webgl Share Improvethisquestion Follow askedDec26,2016at0:03 BálintBálint 3,85522goldbadges1414silverbadges2727bronzebadges Addacomment | 1Answer 1 Sortedby: HighestScore(default) Datemodified(newestfirst) Datecreated(oldestfirst) 17 TL;DR:"experimental-webgl"=beta,itwasusedbybrowsersbeforeWebGL1.0shippedtotrytoindicatethisisnotfinal.WhenWebGL1.0shippedandabrowserpassedalltheconformanceteststhenthatbrowserwouldstartaccepting"webgl"and"experimental-webgl"wouldbejustbeasynonymanddeprecated. Longversion: Browservendorsusedtoprefixthingsthatwerenotstandardizedyetorcomplete.Thehopewasdeveloperswouldtrythingsout.Whenthestandardfinalizedtheprefixwouldberemovedandeveryonewouldusetheunprefixedversiononly.Theprefix"experimental-"isleftoverfromthatera.Browservendorsfiguredoutprefixeswereabadideabecause1000sofwebsiteswouldusetheprefixinproductionsitesandthenthebrowserscouldnotremovetheprefixwithoutbreakingthousandsofwebsites. Browservendorshavegenerallyagreednottodothisanymore.Insteadtheyputnewfeaturesbehindflags,askdeveloperstotest,whenthebrowservendorsandstandardscommitteesarereasonablysureeverythingisgoodandstabletheyallowthenewfeaturetorunwithouttheflag.WebGL2wasdonethisnewwaysothereisno"experimental-webgl2",justbrowserflags. Theonlybrowserthatstillneeds"experimental-webgl"isEdge.ItusesthatonlybecauseEdgestilldoesnotimplementtheentireWebGLspec.Forallotherbrowsers"experimental-webgl"isexactlythesameas"webgl"andit'sjustleftoverfromthatoldera PersonallyInolongeruse"experimental-webgl"atall.Thatmeansmycodewon'tworkinEdgeuntiltheyareactuallystandardscompliant.IMOTheyneedthepressureofwebsitesnotworkingtogetthemtospendresourcesfixingtheirbrokenimplementationasit'sbeenbrokenforyearsnow. Share Improvethisanswer Follow editedDec28,2016at5:24 answeredDec27,2016at13:39 gmangman 90.2k2828goldbadges227227silverbadges336336bronzebadges Addacomment | YourAnswer ThanksforcontributingananswertoStackOverflow!Pleasebesuretoanswerthequestion.Providedetailsandshareyourresearch!Butavoid…Askingforhelp,clarification,orrespondingtootheranswers.Makingstatementsbasedonopinion;backthemupwithreferencesorpersonalexperience.Tolearnmore,seeourtipsonwritinggreatanswers. Draftsaved Draftdiscarded Signuporlogin SignupusingGoogle SignupusingFacebook SignupusingEmailandPassword Submit Postasaguest Name Email Required,butnevershown PostYourAnswer Discard Byclicking“PostYourAnswer”,youagreetoourtermsofservice,privacypolicyandcookiepolicy Nottheansweryou'relookingfor?Browseotherquestionstaggedwebgloraskyourownquestion. TheOverflowBlog WelcomingthenewcrewofStackOverflowpodcasthosts FeaturedonMeta StackExchangeQ&AaccesswillnotberestrictedinRussia PlannedmaintenancescheduledforFriday,March18th,00:30-2:00UTC... Improvingthefirst-timeaskerexperience-Whatwasaskingyourfirst... Related 7 Switchcanvascontext 1 Objectselectionwithprocessing.jsin3dscenes 5 DrawingmanyshapesinWebGL 9 EmulatingpalettebasedgraphicsinWebGLv.s.Canvas2D 2 Rats!WebGLhitasnag-howtodebug? 2 VueJS-HowdoIgetWebGLtorenderviaVuewithoutdisappearing? 0 WebGL:Renderingtwoobjectswithseparatetextures 1 Doescanvascontext2d.drawImage(webglCanvas,0,0)blockuntilawebglisfinishedrendering? HotNetworkQuestions Possiblescamforsecuritydeposit-bankoperation CanImakeinfiniteicearrowsusingtheShapeWatercantrip? Howdomigratorydragonsavoidbeingblindedbysun? HowcanIpreventsomeaddedtextfrombecomingpixelatedinMicrosoftPaint? Whatdoestheprogramcounterdo? UnderstandingthisquotebyFeynman BestWaystoAchievethisorganiclook? IsHebrews6:4-6incontradictionwiththeparableontheprodigalson? WhataircraftwastheOlmsteadHighEfficiencyPropellerfor?Whenandhowwasitused? Turningahighlowsignalintoaproperdigitalsignal LWCuseridundefined Workingwithverybadcodebutonadeadline Wherecouldyoustoretheenergyfromatornado? Useoflanguage:"perfectsquare".isthisusefulorahindrance? Howarelightgunsignalshandledatremotelycontrolledairports? NonNobisDomine-Sednominiornomine Shortstoryaboutthestudyofalchemy,withthemesofdiminishingreturnsofacertainkindofacademicprogress WhatisthebasisfortheWesternleaderstobelievethatharsheconomicsanctionswillnotleadtoanuclearwarwithRussiaeventually? Whatistheappropriatespelllevelforthishomebrewspell(DevolvePerson),intendedasamentalcounterparttoHoldPerson? Meaningof'Lastbutnottheleast'inGoogledictionary Isittruethatit'snotillegalforaparenttoselltheir13-year-oldchildtoadrugdealer? Isthisvillageranitwit? Whydon'telectronsfallorcollapsearoundatomwhenanobjectacceleratesrapidly? Macprotectedfromeasyburnstuff morehotquestions Questionfeed SubscribetoRSS Questionfeed TosubscribetothisRSSfeed,copyandpastethisURLintoyourRSSreader. Yourprivacy Byclicking“Acceptallcookies”,youagreeStackExchangecanstorecookiesonyourdeviceanddiscloseinformationinaccordancewithourCookiePolicy. Acceptallcookies Customizesettings
延伸文章資訊
- 1HTMLCanvasElement.getContext() - Web API 接口参考| MDN
"webgl" (或 "experimental-webgl" ) 这将创建一个 WebGLRenderingContext 三维渲染上下文对象。只在实现WebGL 版本1(OpenGL ES ...
- 2簡單地檢測webgl支援以及瀏覽器對WebGL Interface的支援程度
簡單地檢測webgl支援以及瀏覽器對WebGL Interface的支援程度. GitHub Gist: instantly share code, notes, and snippets. ....
- 330 Experimental WebGL Websites - Awwwards
30. WebGL Experimental Websites ☆彡 · Into the Storm by Media.
- 4canvas.getContext( 'experimental-webgl' ) 是什么意思?
早期WebGL的context,还不能通过正式的名称webgl来获取,必须使用experimental-webgl来获取context对象。 但是,随着技术的发展更新,后来就可以通过正式 ...
- 5HTMLCanvasElement.getContext() - Web APIs | MDN
Note: The identifier "experimental-webgl" is used in new implementations of WebGL. These implemen...