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

Creation of the bridge source #2

Open
Larpoux opened this issue Aug 27, 2024 · 19 comments
Open

Creation of the bridge source #2

Larpoux opened this issue Aug 27, 2024 · 19 comments

Comments

@Larpoux
Copy link
Collaborator

Larpoux commented Aug 27, 2024

Hi @xioxin ,
I am curious to know if you created the bridge cpp sources by hand, or did you find a way to created them automatically from the LabSound sources ?

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

bridge is written manually

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

Oh! You certainly spent much unfunny work to do that 🥇

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

My wish is to bring your plugin to life again, and write a wrapper above it that will be 100% compliant with the W3C Web Audio API recommendation

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

amazing! That's also something I've been wanting to achieve. How do you plan to proceed?

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

Thanks for your feedback.
I am the main Flutter Sound maintener. In fact, unfortunately, I am the only Flutter Sound maintainer 👎

I am working on the future Flutter Sound v10.0 . I want Flutter Sound to be mainly focused on streams. My project is to build v10.0 above the W3C Web Audio API.
I need a 100% W3C compliant library, so that the same code will be able to compile for web and for mobiles.

During some weeks, I tried to port web-audio-api-rs on flutter. My problem is that I don’t master Rust. So before starting, I want to consider other architectures.

If I use LabSoud, there is several architectures possible:

  • I can fork LabSound to add W3C compatibility, and use this new LabSound library in LabSound bridge/Flutter_labsound
  • I can implement this W3C compatibility inside Flutter_LabSound
  • I can implement this W3C compatibility inside a new wrapper above LabSound

What do you think would be the best?

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

You can fork this project (lab_sound_flutter, lab_sound_bridge), and in the future, I will contribute code to the new project. Of course, before forking, I need to slim down the project. I have mistakenly committed binary files such as .so and .dll to Git before. Would it be better to create a GitHub organization to store this project?

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

If your project goes smoothly, I will archive my project.

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

If I work on Flutter-LabSound, we can:

  • I will fork your project and do some Pull requests when I have something to submit,
  • We can transfer your project somewhere (for example Canardoux) and give you full admin privileges on it

This is not important. I will be the only developer, unfortunately.

In every case, don’t spend any time to clean things. I can do that.

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

I can transfer it to you.

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

I could perhaps be referred to as one of the two maintainers. 😂

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

Do you have any ideas how to do full tests? Web Audio API is huge API, and I don’t know how to validate the code before publishing it

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

I don't know much about testing, I will follow this question

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

https://github.com/xioxin/lab_sound_flutter/tree/dev is the latest code of lab_sound_flutter

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

Ok, @xioxin . I am glad to know you. I will receive a new Desk Top machine tomorrow, and I will be busy during one or two days to setup a correct development environment.
Then, I will let you know what are the projects. ❤️

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

What is the main reason to have split your work in two separate projects:

  • lab_sound_bridge
  • flutter_lab_sound

Did you have the idea to be able to use lab_sound_bridge for something else than Flutter?

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

At that time, we used Workflow to compile the corresponding platform binary libraries and automatically release them to Releases. Having a separate repository would be more convenient to implement, but we can also find a way to merge them together.
In the end, lab_sound_flutter can download pre-compiled binary libraries, which can avoid compilation errors caused by the local development environment. It will also be convenient for users who are using pure Dart development to download the binary libraries.
Currently, the dev branch compiles from source code at runtime.

Related:

Dart Native assets feature
dart-lang/sdk#50565

Downloading binary libraries during the flutter build phase
https://github.com/realm/realm-dart/blob/81c8b913b5c9d639fd5d4f09b069eb4fc87de706/flutter/realm_flutter/android/build.gradle#L85

@Larpoux
Copy link
Collaborator Author

Larpoux commented Aug 27, 2024

I see. Thank you for your answer.

Actually I am not sure of the final architecture of my project.
The only thing I am sure, is that you did some painful job with Flutter-sound-lab and that it is too bad that your project is dead.
I want to spend some days (weeks?) to bring back your project to life.
It will compile with a recent flutter, a recent OS, and an uptodate LabSound library.
I will do that.

@xioxin
Copy link
Owner

xioxin commented Aug 27, 2024

That's great! I have already invited you to become a collaborator.
Of course, you can always ask me to transfer the project to your account whenever you want.

feel free to reach out to me anytime if you need any assistance. I have also regained my enthusiasm for this project. (PS: I am more proficient in Dart than C++.)

@Larpoux
Copy link
Collaborator Author

Larpoux commented Sep 3, 2024

Hi, my friend @xioxin .
This post is just to let you know that I am working on lab-sound-flutter.
It will be longer that I expected, because I try to port your project with all the modern tools:

  • a modern flutter plugin
  • A modern ffigen
  • A modern CMake tool
  • A lab-sound lib uptodate
  • Recent dependencies

Things are going well. Just be patient.
PS: you can be proud of what you did. I like your project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants