Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔧 Cannot find type 'FrameProcessorPluginBase' in scope #1987

Closed
4 of 5 tasks
suwu150 opened this issue Oct 12, 2023 · 9 comments
Closed
4 of 5 tasks

🔧 Cannot find type 'FrameProcessorPluginBase' in scope #1987

suwu150 opened this issue Oct 12, 2023 · 9 comments
Labels
🔧 build error Issue is related to building VisionCamera in your project

Comments

@suwu150
Copy link

suwu150 commented Oct 12, 2023

How were you trying to build the app?

Cannot find type 'FrameProcessorPluginBase' in scope

截屏2023-10-12 16 26 53

Full build logs

Cannot find type 'FrameProcessorPluginBase' in scope

Project dependencies

"@react-native-async-storage/async-storage": "^1.19.3",
    "@shopify/react-native-skia": "^0.1.213",
    "react": "18.2.0",
    "react-native": "0.72.4",
    "react-native-fast-tflite": "^0.3.1",
    "react-native-reanimated": "^3.5.4",
    "react-native-svg": "^13.14.0",
    "react-native-vision-camera": "^3.3.1",
    "react-native-webview": "^13.6.0",
    "react-native-worklets-core": "^0.2.0",
    "url-loader": "^4.1.1",
    "vision-camera-ocr": "^1.0.0"
image

VisionCamera Version

3.3.1

Target platforms

iOS

Operating system

MacOS

Can you build the VisionCamera Example app?

I didn't try (⚠️ your issue might get ignored & closed if you don't try this)

Additional information

@mrousavy
Copy link
Owner

I think it's called FrameProcessorPlugin now, no?

@mrousavy
Copy link
Owner

/// The base class for a Frame Processor Plugin which can be called synchronously from a JS Frame
/// Processor.
///
/// Subclass this class in a Swift or Objective-C class and override the `callback:withArguments:`
/// method, and implement your Frame Processing there.
///
/// Use `[FrameProcessorPluginRegistry addFrameProcessorPlugin:]` to register the Plugin to the
/// VisionCamera Runtime.
@interface FrameProcessorPlugin : NSObject
/// The actual callback when calling this plugin. Any Frame Processing should be handled there.
/// Make sure your code is optimized, as this is a hot path.
- (id _Nullable)callback:(Frame* _Nonnull)frame withArguments:(NSDictionary* _Nullable)arguments;
@end

@mrousavy
Copy link
Owner

Where did you even get the name FrameProcessorPluginBase from? It's not in the docs either, maybe this is a left-over artefact of a V2 implementation. In V3 it's just called FrameProcessorPlugin

@suwu150
Copy link
Author

suwu150 commented Oct 12, 2023

@mrousavy Thank you for your reply. I followed the following steps to proceed。

I integrated it here according to the document https://react-native-vision-camera.com/docs/guides/frame-processor-plugin-list The document integrates plugins, it seems that the plugins here are not compatible with the v3 version anymore

@spiropoulos94
Copy link

Same here for me. All I did is to follow the manual process from npx vision-camera-plugin-builder ios. After registering the global plugin name and setting up the babel.config.js, I stumbled upon the issue mentioned above

@NoahSimajji
Copy link

Guys? i encounter this issue too. Any solution?

@Rakedd
Copy link

Rakedd commented Nov 15, 2023

Ok guys here's the deal, the error come from the plugin vision-camera-ocr, not this repo. Related here, and there's a ongoing PR here, so i retract my comment @mrousavy, it's indeed closed and not relevant here
And thank you for your work 🫡.

@mrousavy
Copy link
Owner

❤️

@Superstar721
Copy link

npm install react-native-vision-camera@latest
or
npm install react-native-vision-camera@latest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🔧 build error Issue is related to building VisionCamera in your project
Projects
None yet
Development

No branches or pull requests

6 participants