Bug 57393 - Extensions3D class API needs to be improved
Summary: Extensions3D class API needs to be improved
Status: RESOLVED CONFIGURATION CHANGED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebGL (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC OS X 10.5
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-03-29 15:34 PDT by Chris Marrin
Modified: 2021-09-07 11:48 PDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Marrin 2011-03-29 15:34:38 PDT
Currently Extensions3D has several API calls whose signatures are wrong or confusing. For instance ensureEnabled() requires that the passed extension be supported (as indicated by supports()). But it says nothing about the consequences of violating that rule. In the implementation in Extensions3DOpenGL.cpp it doesn't even check if building for MAC and asserts otherwise. The call would be better if it were simply enable() and returned a boolean. False would indicate that the extension was not supported and therefore not enabled. Then the caller can take the appropriate action.

There are also several API calls, such as "bool supports(const String&)" which should be const.
Comment 1 Antonio Gomes 2013-08-08 10:59:13 PDT
It looks like a valid work still ( simplifying these APIs.. )

@kbr please advice if I can take it.
Comment 2 Kenneth Russell 2013-08-12 18:40:10 PDT
Please do. I'll unassign myself.