This package has been deprecated

Author message:

use expo-gl instead

expo-graphics

2.0.0 • Public • Published

NPM


expo-graphics

This package has been deprecated in favor of using GLView directly.

Tools to help simplify and manage GL state.

Installation

yarn add expo-graphics

Usage

Import the library into your JavaScript file:

import ExpoGraphics from 'expo-graphics';

Components

ExpoGraphics.View

A view that assists with common GL tasks.

Props

Property Type Default Description
isShadowsEnabled ?boolean false Overrides the render buffer allowing for shadows, this works by default on Android: iOS Only
onRender (delta: number) => void null Called every frame with delta time since the last frame
onContextCreate ({gl, canvas?, width, height, scale }) => Promise null Called with the newly created GL context
onShouldReloadContext () => boolean null A delegate function that requests permission to reload the GL context when the app returns to the foreground
onResize (layout: Layout) => void null Invoked when the view changes size, or the device orientation changes, returning the {x, y, width, height, scale}

Package Sidebar

Install

npm i expo-graphics

Weekly Downloads

19

Version

2.0.0

License

MIT

Unpacked Size

10 kB

Total Files

7

Last publish

Collaborators

  • evanbacon
  • expoadmin