Differences between WebGL and OpenGL - Stack Overflow

文章推薦指數: 80 %
投票人數:10人

WebGL is a cross-platform, royalty-free web standard for a low-level 3D graphics API based on OpenGL ES 2.0, exposed through the HTML5 Canvas ... Home Public Questions Tags Users Companies Collectives ExploreCollectives Teams StackOverflowforTeams –Startcollaboratingandsharingorganizationalknowledge. CreateafreeTeam WhyTeams? Teams CreatefreeTeam Collectives™onStackOverflow Findcentralized,trustedcontentandcollaboratearoundthetechnologiesyouusemost. LearnmoreaboutCollectives Teams Q&Aforwork Connectandshareknowledgewithinasinglelocationthatisstructuredandeasytosearch. LearnmoreaboutTeams DifferencesbetweenWebGLandOpenGL AskQuestion Asked 10years,8monthsago Modified 3years,3monthsago Viewed 45ktimes 50 16 CananyonegivemeasimpleanswerabouttheexactdifferencebetweenOpenGLandWebGL?Ineedmorespecificonthefollowing: programmingsemantics,API'sinheritence,API'sextensionsetc. I'velookedatthefollowingsitebutitisnotverycleartome: http://www.khronos.org/webgl/wiki/WebGL_and_OpenGL_Differences openglwebgl Share Follow editedNov30,2018at12:44 doppelgreener 4,61099goldbadges4848silverbadges6262bronzebadges askedDec11,2011at6:49 DeepakDeepak 95622goldbadges88silverbadges1414bronzebadges 1 3 "programmingsymantecs,api'sinheritence,api'sextension"xD – User Oct14,2012at10:43 Addacomment  |  4Answers 4 Sortedby: Resettodefault Highestscore(default) Trending(recentvotescountmore) Datemodified(newestfirst) Datecreated(oldestfirst) 52 WebGLis"OpenGLES2",notplainOpenGL(theESstandsfor'forEmbeddedSystems').Sothere'sthefirstdifference.OpenGLESisessentiallyasubsetofOpenGL.Inaddition,WebGLisalmostthesameasOpenGLES2,buthassomesubtledifferences,explainedinthelinkyouprovide.There'snotmuchtoaddtothatlink,it'saprettyclearexplanationofwhatisdifferentbetweenOpenGLES2andWebgl. Share Follow answeredDec11,2011at6:59 Mike'Pomax'KamermansMike'Pomax'Kamermans 45.5k1515goldbadges9696silverbadges140140bronzebadges Addacomment  |  38 OpenGLisadesktopcomputer-centricAPI(likeDirect3D).WebGLisderivedfromOpenGLES2.0(intendedformobiledevices)whichhaslesscapabilitiesandissimplertouse. WebGLisalsodesignedtoruninabrowser,andhasthereforeafewlimitationsmorethenOpenGLES2.0. UnlikeOpenGL,WebGLdoesnotrequirenativedriversupport.AwrappercalledANGLE,whichSafari,ChromeandFirefoxusecantranslateWebGLcallsandGLSLtoeitherOpenGL/GLSLorDirect3D/HLSL PleaseseetheKhronoswikiforadetailedanswer:http://www.khronos.org/webgl/wiki/WebGL_and_OpenGL_Differences Share Follow editedDec11,2015at19:30 user719662 answeredJan4,2012at23:55 FlorianBöschFlorianBösch 27k1111goldbadges4747silverbadges5353bronzebadges Addacomment  |  11 WebGLismeanttoruninabrowser(webapplications). WebGLisasoftwarelibrarythatextendsthecapabilityoftheJavaScriptprogramminglanguagetoallowittogenerateinteractive3Dgraphicswithinanycompatiblewebbrowser. ... ItusestheHTML5canvaselementandisaccessedusingDocumentObjectModelinterfaces.AutomaticmemorymanagementisprovidedaspartoftheJavaScriptlanguage. OpenGListypicallyusedindesktopapplications.Itisacross-language,cross-platformspecification,ofwhichWebGLismore-or-lessasubset. Share Follow answeredDec11,2011at6:58 MattBallMattBall 347k9797goldbadges633633silverbadges698698bronzebadges Addacomment  |  4 Theconsortium(https://www.khronos.org/webgl/)definitionisquotedbelow. WebGLisacross-platform,royalty-freewebstandardforalow-level3DgraphicsAPIbasedonOpenGLES2.0,exposedthroughtheHTML5CanvaselementasDocumentObjectModelinterfaces.DevelopersfamiliarwithOpenGLES2.0willrecognizeWebGLasaShader-basedAPIusingGLSL,withconstructsthataresemanticallysimilartothoseoftheunderlyingOpenGLES2.0API.ItstaysveryclosetotheOpenGLES2.0specification,withsomeconcessionsmadeforwhatdevelopersexpectoutofmemory-managedlanguagessuchasJavaScript. OpenGLandWebGLhavesimilarsemanticsbutarecodedindifferentlanguages.YouwillseeatthebasiclevelthatmostofdifferencesareintheprogramminglanguageconstructsofC/C++vsJavaScript WebGLandOpenGLshowsthesimilaritiesbetweenthetwo,OpenGLinC/C++andWebGLinJavaScript. Share Follow editedJun20,2020at9:12 CommunityBot 111silverbadge answeredSep27,2016at15:56 ap-osdap-osd 2,2941515silverbadges1616bronzebadges 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?Browseotherquestionstaggedopenglwebgloraskyourownquestion. TheOverflowBlog WhyAIishavinganon-premmoment(Ep.476) Opensourceandaccidentalinnovation FeaturedonMeta Recentsiteinstability,majoroutages–July/August2022 PleasewelcomeValuedAssociate#1301-Emerson The[maintenance]tagisbeingburninated StagingGroundWorkflow:QuestionLifecycle Whatshouldwedowithimproperlycitedposts? Visitchat Related 153 What'stheconceptofanddifferencesbetweenFramebufferandRenderbufferinOpenGL? 149 DifferencesandrelationshipbetweenglActiveTextureandglBindTexture 0 UsingTEXTURE_2DwithThree.js 16 Are1DTexturesSupportedinWebGLyet? 2 HowareverticestransformedinWebGLinindexedandnon-indexedgeometries? 2 WebGL-INVALID_OPERATION:texImage2D:ArrayBufferViewnotbigenoughforrequest 0 QualitydifferencesbetweenHTML,CanvasandWebGL 2 webglperformancedifferencesbetweenfirefoxandchrome HotNetworkQuestions Whatisacpuclockphysically? Breakerpanellocationnexttosink.Isthisokay? Oldceilinglightfixturewith9wires(5black/4white)-howtoinstallanewfixture? HowdoIdeterminefromthedocumentationwhattypeofexceptionafunctioncanthrow? Whydoweneedregularizationforlinearleastsquaresgiventhatalineisthesimplestmodelpossible? Isitsafetodrillacableexitholeinaseatpost? Whatisthesignificanceofreachingmajorversion1.0.0? Howdoweensureanorbitofasatellitedoesn’tinterferewithexistingones? Sampletwonumbersfrom1to10;maximizetheexpectedproduct Ismymacfilevaultencrypted? Drawingabondingcurve Hasanyonesysnthesizedperfluorocubane(AKAoctafluorocubane)? Doplanetsloseenergywhilerotating? Howtodecidewhetherarecordingcontainsasignalofinterest? Oldscifibook:detective,alienconspiracy,changeappearancemachine,hugebraininspaceship,aliencommunicatesbyflashinglightsfromstomach Carry-lesssumgivenabaseb Howtociteapaperwithauthorsinnon-alphabeticalorder? Howtoadequatelysecurealiquidfillinginapieceofpastry? Howdoyouremovetheannoyingbishoponh3? Whydoes'onsteroids'suggestthemeaningofexaggerationorenhancement? Whyshouldanoverheatedwheelbeapproachedfromthefront/backandnotinlinewiththeaxle? Wishtoknowallaboutplanes,wheredoistart? Changingrowofequationindifferentpositioninlatex ClearScreeninPowerShellandCommandLinewithouterasingeverything morehotquestions Questionfeed SubscribetoRSS Questionfeed TosubscribetothisRSSfeed,copyandpastethisURLintoyourRSSreader. Yourprivacy Byclicking“Acceptallcookies”,youagreeStackExchangecanstorecookiesonyourdeviceanddiscloseinformationinaccordancewithourCookiePolicy. Acceptallcookies Customizesettings  



請為這篇文章評分?