josuigoa / CameraMic

Camera & Microphone OpenFL native extension
32 stars 6 forks source link

Compiler error with OpenFL 8.6.4 #11

Closed nightblade9 closed 6 years ago

nightblade9 commented 6 years ago

I tried compiling this on an app with the latest Flixel/Lime/OpenFL. OpenFL is version 8.6.4. I get this error:

C:/HaxeToolkit/haxe/lib/cameramic/git/CameraMic.hx:10: characters 7-23 : Type not found : openfl.utils.JNI

I believe I have the latest version of CameraMic from Git (not the one from haxelib).

Any idea how to fix this? I'm working on a kids app and recording audio is pretty central to the functionality I need.

josuigoa commented 6 years ago

I created this lib for a older version of OpenFL and I haven't tried it since then. It seems that JNI is no longer in that package. You should try changing this line to import lime.system.JNI. I think you will go further with this but I'm not sure it will work.

nightblade9 commented 6 years ago

Sorry you closed this - I didn't get time to investigate.

Can you suggest what's the latest version of OpenFL that works with your library?

Are you committed to keeping it working with the latest version(s)? I got HaxeFlixel 4.4.2 (the latest) yesterday and it demands certain versions of OpenFL, so this can be a problem for me -- knowing the latest supported version will help.

josuigoa commented 6 years ago

oh! I thought I made the commit in the code before closing this.

It's been very long since I used OpenFL, so I can't say when this library started to fail. The openfl.utils.JNI it's been a typedef of lime's JNI for a long time until the first one was deleted. I can't find when this happened.

I committed the new import (I'm sure now 😀 ). Now if you update the library, I should work? I hope so...

I keep this issue closed because the import error causing this should be gone. If you have another error, we'll comment in another issue.