EXT_disjoint_timer_query: getQueryEXT() method

Limited availability

This feature is not Baseline because it does not work in some of the most widely-used browsers.

The EXT_disjoint_timer_query.getQueryEXT() method of the WebGL API returns information about a query target.

Syntax

js
getQueryEXT(target, pname)

Parameters

target

A GLenum specifying the target of the time query. Must be ext.TIMESTAMP_EXT or ext.TIME_ELAPSED_EXT.

pname

A GLenum specifying which information to return. Must be ext.CURRENT_QUERY_EXT or ext.QUERY_COUNTER_BITS_EXT.

Return value

Depends on pname:

  • If pname is ext.CURRENT_QUERY_EXT: A WebGLQuery object, which is the currently active query for the given target.
  • If pname is ext.QUERY_COUNTER_BITS_EXT: A GLint indicating the number of bits used to hold the query result for the given target.

Examples

js
const ext = gl.getExtension("EXT_disjoint_timer_query");
const startQuery = ext.createQueryEXT();
ext.queryCounterEXT(startQuery, ext.TIMESTAMP_EXT);

const currentQuery = ext.getQueryEXT(ext.TIMESTAMP_EXT, ext.CURRENT_QUERY_EXT);

Specifications

Specification
WebGL EXT_disjoint_timer_query Extension Specification

Browser compatibility

desktop mobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
WebView on iOS
getQueryEXT
Chrome – No support
Chrome 47 – 64 (Release date: 2015-12-01)
footnote Removed in 65 and later
footnote Removed due to the GLitch exploit.
Chrome – Partial support
Chrome 70 (Release date: 2018-10-16)
footnote Partial support
footnote Only supported on macOS.
Edge – Partial support
Edge 79 (Release date: 2020-01-15)
footnote Partial support
footnote Only supported on macOS.
Firefox – No support
Firefox 51 – 58 (Release date: 2017-01-24)
footnote Removed in 59 and later
footnote Removed due to the GLitch exploit.
Opera – No support
Opera 34 – 51 (Release date: 2015-12-08)
footnote Removed in 52 and later
footnote Removed due to the GLitch exploit.
Opera – Partial support
Opera 57 (Release date: 2018-11-28)
footnote Partial support
footnote Only supported on macOS.
Safari – No support
Safari
footnote No support
Chrome Android – No support
Chrome Android 47 – 64 (Release date: 2015-12-02)
footnote Removed in 65 and later
footnote Removed due to the GLitch exploit.
Firefox for Android – No support
Firefox for Android
footnote No support
Opera Android – No support
Opera Android 34 – 46 (Release date: 2015-12-16)
footnote Removed in 47 and later
footnote Removed due to the GLitch exploit.
Safari on iOS – No support
Safari on iOS
footnote No support
Samsung Internet – No support
Samsung Internet 5 – 8.2 (Release date: 2016-12-15)
footnote Removed in 9 and later
footnote Removed due to the GLitch exploit.
WebView Android – No support
WebView Android 47 – 64 (Release date: 2015-12-02)
footnote Removed in 65 and later
footnote Removed due to the GLitch exploit.
WebView on iOS – No support
WebView on iOS
footnote No support

Legend

Tip: you can click/tap on a cell for more information.

Full support
Full support
Partial support
Partial support
No support
No support
Has more compatibility info.

See also