Git Product home page Git Product logo

Comments (5)

gregfenton avatar gregfenton commented on June 5, 2024

I am running into problems with my project as well. Things using ExpoPixi.Sketch and sketch.takeScreenshotAsync() worked fine on expo v38 for a "signature capture" solution. With the upgrade to expo v39, I am getting this in my console:

EXGL: gl.pixelStorei() doesn't support this parameter yet!

Though I don't know that this is the root of my issue. (My app keeps failing trying to upload the byte stream coming back from takeScreenshotAsync(). Still investigating . . .)

During my investigation, I decided to try the examples from this proect (expo-pixi/examples).

To get them running (successfully!!!) in my iOS simulator, here's what I did:

  1. Run git clone https://github.com/expo/expo-pixi.git
  2. Run cd expo-pixi/examples/sketch
  3. Run yarn install <<--- there will be errors
  4. Edit package.json changing the entry for "expo-pixi" to:
    • "expo-pixi": "^1.2.0",
  5. Run expo upgrade <<--- I answered "yes" to all questions (though I skipped upgrading client on emulators)
  6. Run expo install expo-gl <<-- without this, expo start will fail complaining about expo-gl not being available
  7. Run expo start

And the app runs in the iOS simulator just fine, with the exception of the warning message in the console mentioned above.

Still investigating the uploading the byte-stream issue...

from expo-pixi.

gregfenton avatar gregfenton commented on June 5, 2024

Follow up: my code is back to working. Was not (necessarily?) an issue with Expo-Pixi. It seems that the behaviour of fetch() has changed with my upgrade to expo v39.

I was doing:

  const {uri} = await sketch.takeSnapshotAsync({format: 'png', compress: 0.1});
  let response = await fetch(uri);
  let blob = await response.blob();
  uploadToFirebaseStorage(blob, "my-new-file-name.png");

that worked under expo v38, but with v39 it was failing with a network error from the fetch() line.

With v39, this is the code that is now working:

  const {uri} = await sketch.takeSnapshotAsync({format: 'png', compress: 0.1});
  let str = await FileSystem.readAsStringAsync(uri, {encoding: 'base64'});
  str = 'data:image/png;base64,' + str;
  let response = await fetch(uri);
  let blob = await response.blob();
  uploadToFirebaseStorage(blob, "my-new-file-name.png");

(If anyone can recommend a clearer approach to the above, much appreciate in advance!!)

So, from my POV, there was a behaviour change between v38 and v39 but expo-pixi wasn't to blame in my use case and it is now working again!

from expo-pixi.

quentez avatar quentez commented on June 5, 2024

Same here. Getting this on Expo 39:

EXGL: gl.pixelStorei() doesn't support this parameter yet!

from expo-pixi.

gregfenton avatar gregfenton commented on June 5, 2024

Same here. Getting this on Expo 39:

I still get that warning, but it doesn't seem to impede capabilities that I can tell.

from expo-pixi.

msamirma avatar msamirma commented on June 5, 2024

I will close this issue as these warning not cause issue when running expo-pixi

from expo-pixi.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.