Coder Social home page Coder Social logo

Comments (4)

BradLarson avatar BradLarson commented on July 23, 2024

imageAvailableCallback is triggered on the next execution of newFramebufferAvailable(), which is kicked off synchronously by the line

picture.processImage(synchronously:true)

The block will complete execution as a result, and should have a non-nil value in outputImage. If this didn't work, at least one of the example applications would fail during synchronous image processing.

What cases are you seeing this fail for? Is it possible there's a bad input image?

from gpuimage2.

cloke avatar cloke commented on July 23, 2024

This started happening when I updated to master about 3 days ago, before that I never saw the issue. After pulling in master it was happening in all situations. Its possible it is related to my general swift 3 update. I'll back out my hack and see if I can get some more concrete details.

from gpuimage2.

cloke avatar cloke commented on July 23, 2024

I was able to track this down to the fact that I am doing something like this in my code:

output.imageAvailableCallback = callback

Which is essentially overwriting the callback in the framework. I had been using the Swift 2 version of GPUImage2 and this didn't seem to be a problem. Is there a more appropriate way to be notified when the output image is available?

from gpuimage2.

cloke avatar cloke commented on July 23, 2024

So it turns out I was sort of mixing two concepts together in the wrong way. I was using the filterWithPipeline extension and then also processing things unintentionally a second time with extra code. Fixing this has made my image render time drastically faster. Whats weird is the broken code worked on swift 2 as the app has been in production for almost 4 months, but with swift 3 the problem was front and center.

from gpuimage2.

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.