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

remove package:js #37

Open
jarrodcolburn opened this issue May 4, 2024 · 2 comments
Open

remove package:js #37

jarrodcolburn opened this issue May 4, 2024 · 2 comments

Comments

@jarrodcolburn
Copy link

#28 accomplished half it's stated goal
✅ move from dart:html
❌ to package:web

I feel like in order to fully move to package:web would require removal of package:js

@jarrodcolburn
Copy link
Author

jarrodcolburn commented May 4, 2024

for example, the custom js classes in file at https://github.com/flutter-webrtc/dart-webrtc/blob/main/lib/src/rtc_transform_stream.dart are implemented in package:web so be replaced with

// rtc_transform_stream.dart
// can replace existing file with the following
export 'package:web/web.dart'
    show
        WritableStream,
        ReadableStream,
        TransformStream,
        TransformStreamDefaultController,
        RTCEncodedAudioFrame,
        RTCEncodedVideoFrame,
        RTCEncodedAudioFrameMetadata,
        RTCEncodedVideoFrameMetadata,
        RTCTransformEvent,
        RTCRtpScriptTransformer,
        RTCRtpScriptTransform;

// TODO: figure out how to replace legacy classes: EncodedStreams & RTCEncodedFrame

@jarrodcolburn
Copy link
Author

I'm trying to do it on my fork https://github.com/jarrodcolburn/dart-webrtc/tree/remove_package_js But I'm not familiar enough with the webrtc. Like in file https://github.com/jarrodcolburn/dart-webrtc/blob/4b507ef3c5ec633947fd7c9652d6aef1c72009e8/lib/src/e2ee.worker/e2ee.cryptor.dart#L246

does this go from

readable.pipeThrough(transformer).pipeTo(writable);

to

      transformer.readable.pipeTo(writable);

And the functions like getUnencryptedBytes that call a psuedo superclasss RTCEncodedFrame does that need to run for both Audio and Video?

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

1 participant