EN
이 콘텐츠는 한국어로 제공되지 않아 영어 버전으로 표시됩니다.

WebGLContextAttributes object

[This documentation is preliminary and is subject to change.]

A dictionary object of attributes used to initialize the context for the first time.

IE11

 

Members

The WebGLContextAttributes object has these types of members:

Properties

The WebGLContextAttributes object has these properties.

PropertyDescription

alpha

Gets or sets whether the drawing buffer has an alpha channel for alpha compositing and operations.

antialias

Get or set the antialias state on a WebGL rendering context.

depth

Gets or sets whether the drawing buffer has a depth buffer. Returns false if no depth buffer exists.

failIfMajorPerformanceCaveat

A flag that sets whether WebGL creates a context with getContext if system performance is low.

premultipliedAlpha

Gets or sets whether the colors in the drawing buffer are premultiplied alpha values. This property is ignored if the alpha property is false.

preserveDrawingBuffer

Sets or gets whether the drawing buffer's is cleared once content is presented.

 

Remarks

Attributes are a preference, and might not be configurable. To query which properties are actually used for initialization, call getContextAttributes. Here's how they all behave in Internet Explorer 11.

AttributeSupported Returns
alpha yestrue or false.
depth yesInternet Explorer always behaves like true is set.
stencil yestrue or false
antialias yestrue or false..
premultipliedAlpha yesInternet Explorer always behaves like true is set.
preserveDrawingBuffer yestrue or false.
failIfMajorPerformanceCaveat yestrue or false.

 

 

 

표시:
© 2014 Microsoft