Git Product home page Git Product logo

Comments (5)

mrousavy avatar mrousavy commented on May 26, 2024 1

Good feature request.

from react-native-vision-camera.

drLeonymous avatar drLeonymous commented on May 26, 2024 1

A dirty workaround, just for debugging time, can be:

In CameraView add:

private val codecs = MediaCodecList(MediaCodecList.ALL_CODECS).codecInfos.filter {
    it.isEncoder && it.supportedTypes[0].startsWith("video")
  }
  private val availableVideoCodecs: List<String> = codecs.map { it.name }

Then in init add a log:
Log.i(TAG, "Available Video Codecs: $availableVideoCodecs")

Open LogCat and, filter for TAG name, here CameraView and ... check Available Video Codecs

Available Video Codecs: [c2.android.avc.encoder, OMX.google.h264.encoder, c2.android.h263.encoder, OMX.google.h263.encoder, c2.android.hevc.encoder, c2.android.mpeg4.encoder, OMX.google.mpeg4.encoder, c2.android.vp8.encoder, OMX.google.vp8.encoder, c2.android.vp9.encoder, OMX.google.vp9.encoder]

image

;)

from react-native-vision-camera.

mrousavy avatar mrousavy commented on May 26, 2024 1

Nice find @drLeonymous - I definitely want to expose that API to JS!

from react-native-vision-camera.

eleretic avatar eleretic commented on May 26, 2024

I would suggest falling back to H264 when H265 is unavailable, that would be much safer

from react-native-vision-camera.

mrousavy avatar mrousavy commented on May 26, 2024

Instead of exposing it, you can just pass h265 and it will automatically fall back to h264 if h265 is not supported. Added in VisionCamera 4.0.0

from react-native-vision-camera.

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.