1 | import * as React from 'react';
|
2 | import { ComponentOrHandle, SurfaceCreateEvent, GLSnapshot, ExpoWebGLRenderingContext, SnapshotOptions, BaseGLViewProps } from './GLView.types';
|
3 | export declare type GLViewProps = {
|
4 | |
5 |
|
6 |
|
7 |
|
8 | onContextCreate(gl: ExpoWebGLRenderingContext): void;
|
9 | |
10 |
|
11 |
|
12 | msaaSamples: number;
|
13 | |
14 |
|
15 |
|
16 | nativeRef_EXPERIMENTAL?(callback: ComponentOrHandle | null): any;
|
17 | } & BaseGLViewProps;
|
18 |
|
19 |
|
20 |
|
21 | export declare class GLView extends React.Component<GLViewProps> {
|
22 | static NativeView: any;
|
23 | static defaultProps: {
|
24 | msaaSamples: number;
|
25 | };
|
26 | static createContextAsync(): Promise<ExpoWebGLRenderingContext>;
|
27 | static destroyContextAsync(exgl?: ExpoWebGLRenderingContext | number): Promise<boolean>;
|
28 | static takeSnapshotAsync(exgl?: ExpoWebGLRenderingContext | number, options?: SnapshotOptions): Promise<GLSnapshot>;
|
29 | nativeRef: ComponentOrHandle;
|
30 | exglCtxId?: number;
|
31 | render(): JSX.Element;
|
32 | _setNativeRef: (nativeRef: ComponentOrHandle) => void;
|
33 | _onSurfaceCreate: ({ nativeEvent: { exglCtxId } }: SurfaceCreateEvent) => void;
|
34 | startARSessionAsync(): Promise<any>;
|
35 | createCameraTextureAsync(cameraRefOrHandle: ComponentOrHandle): Promise<WebGLTexture>;
|
36 | destroyObjectAsync(glObject: WebGLObject): Promise<boolean>;
|
37 | takeSnapshotAsync(options?: SnapshotOptions): Promise<GLSnapshot>;
|
38 | }
|
39 | declare type WebGLObjectId = any;
|
40 | export declare class WebGLObject {
|
41 | id: WebGLObjectId;
|
42 | constructor(id: WebGLObjectId);
|
43 | toString(): string;
|
44 | }
|
45 | declare class WebGLTexture extends WebGLObject {
|
46 | }
|
47 | export {};
|