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

Black Screen over video call. #177

Closed
wizhob2020 opened this issue Sep 8, 2020 · 40 comments
Closed

Black Screen over video call. #177

wizhob2020 opened this issue Sep 8, 2020 · 40 comments

Comments

@wizhob2020
Copy link

After doing all setup of Agora SDK in my (Flutter )project all things are working, except video screen. i.e I got channel info as well as broad cast id. even sound , but video are black.

@LichKing-2234
Copy link
Contributor

is our demo working?

@vitulgoyani
Copy link

same black screen issue I added that you suggest in note.txt but after in release APK black screen is in video call

@vitulgoyani
Copy link

is our demo working?

no, your demo also not working with the release APK

@umeshlakhani7170
Copy link

i have also same black screen issue when i made release APK.
i also tried that you suggest in readme.txt file
please help us.
Thank you🙏🏼

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 11, 2020 via email

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 11, 2020 via email

@plutoless
Copy link
Contributor

plutoless commented Sep 13, 2020

@wizhob2020 echo happens usually when you have two devices join the same channel and they are too close. i believe it's different issue.

@LichKing-2234
Copy link
Contributor

@vitulgoyani
I have test our demo, it works when released.
https://github.com/AgoraIO-Community/Agora-Flutter-Quickstart/tree/master

by the way, make sure your version is > 3.0.1-dev.5

@umeshlakhani7170
Copy link

in your git tutorial demo, i think are you use 3.0.1-dev.7 version. and by your suggestion i also try 3.0.1-dev.5 version but same problem black screen at video calling screen.

@LichKing-2234
Copy link
Contributor

@umeshlakhani7170 could you release our demo to apk file? Then I can test it.

@umeshlakhani7170
Copy link

This is release APK with this command -> flutter build apk --release

https://sendgb.com/VZlAKMiPewo

@LichKing-2234
Copy link
Contributor

@umeshlakhani7170 seem like the consumer-rules.pro not work. could you pls check is the file exists? locate to agora_rtc_engine/android/consumer-rules.pro

@LichKing-2234
Copy link
Contributor

LichKing-2234 commented Sep 14, 2020

if it not work, you can add these to your app/proguard-rules.pro

-keepattributes *Annotation*
-keep class kotlin.** { *; }
-keep class org.jetbrains.** { *; }

-keep class io.agora.**{*;}

@umeshlakhani7170
Copy link

@umeshlakhani7170 seem like the consumer-rules.pro not work. could you pls check is the file exists? locate to agora_rtc_engine/android/consumer-rules.pro

  • This file not in your github demo code

@umeshlakhani7170
Copy link

umeshlakhani7170 commented Sep 14, 2020

if it not work, you can add these to your app/proguard-rules.pro

-keepattributes *Annotation*
-keep class kotlin.** { *; }
-keep class org.jetbrains.** { *; }

-keep class io.agora.**{*;}

i added this code in your demo app/proguard-rules.pro and made one release APK that not work 😥

@LichKing-2234
Copy link
Contributor

@umeshlakhani7170 could you provide your demo project?

@LichKing-2234
Copy link
Contributor

@umeshlakhani7170
you should refer to this doc to config proguard.
https://developer.android.com/studio/build/shrink-code#enable

@umeshlakhani7170
Copy link

@LichKing-2234
Copy link
Contributor

@umeshlakhani7170
you miss flutter proguard config.

## Flutter wrapper
-keep class io.flutter.app.** { *; }
-keep class io.flutter.plugin.**  { *; }
-keep class io.flutter.util.**  { *; }
-keep class io.flutter.view.**  { *; }
-keep class io.flutter.**  { *; }
-keep class io.flutter.plugins.**  { *; }
-dontwarn io.flutter.embedding.**

@umeshlakhani7170
Copy link

umeshlakhani7170 commented Sep 14, 2020

@umeshlakhani7170
you miss flutter proguard config.

## Flutter wrapper
-keep class io.flutter.app.** { *; }
-keep class io.flutter.plugin.**  { *; }
-keep class io.flutter.util.**  { *; }
-keep class io.flutter.view.**  { *; }
-keep class io.flutter.**  { *; }
-keep class io.flutter.plugins.**  { *; }
-dontwarn io.flutter.embedding.**

This is grate help 👍🏼 Thank you.

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@LichKing-2234
Copy link
Contributor

@wizhob2020 What is your problem? getting too much echo on the
recipient side? are video and audio works?

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@manyopensource
Copy link

Seven days ago encountered the same black screen issue! If nothing has changed since then I believe it's still there!

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@LichKing-2234
Copy link
Contributor

@wizhob2020 @manyopensource black screen only on release mode?

@LichKing-2234
Copy link
Contributor

Our demo works fine whatever debug or release, you can clone and try it.

@LichKing-2234
Copy link
Contributor

@wizhob2020 Sorry, your project is too large. any log when black screen? such as:

E/flutter (27900): [ERROR:flutter/lib/ui/ui_dart_state.cc(166)] Unhandled Exception: PlatformException(error, Incomplete hierarchy for class AgoraRtcEnginePlugin, unresolved classes [io.flutter.embedding.engine.plugins.FlutterPlugin, io.flutter.plugin.common.MethodChannel.MethodCallHandler, io.flutter.plugin.common.EventChannel.StreamHandler], null)
E/flutter (27900): #0      StandardMethodCodec.decodeEnvelope (package:flutter/src/services/message_codecs.dart:572)
E/flutter (27900): #1      MethodChannel._invokeMethod (package:flutter/src/services/platform_channel.dart:161)
E/flutter (27900): <asynchronous suspension>
E/flutter (27900): #2      RtcEngine.createWithAreaCode (package:agora_rtc_engine/src/rtc_engine.dart:88)
E/flutter (27900): <asynchronous suspension>
E/flutter (27900): #3      AgoraInit._initAgoraRtcEngine (package:streaming_platform/controller/stream_ininialize.dart:20)
E/flutter (27900): <asynchronous suspension>
E/flutter (27900): #4      AgoraInit.init (package:streaming_platform/controller/stream_ininialize.dart:10)
E/flutter (27900): <asynchronous suspension>

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 15, 2020 via email

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 16, 2020 via email

@LichKing-2234
Copy link
Contributor

@wizhob2020 I need the log from your logcat, and your device android version.

@LichKing-2234
Copy link
Contributor

@wizhob2020 why add debugDefaultTargetPlatformOverride = TargetPlatform.fuchsia;?
our SDK only supports Android and iOS now. remove this line will work.

@wizhob2020
Copy link
Author

wizhob2020 commented Sep 17, 2020 via email

@Hassanmsaid
Copy link

Make sure to enable your local video after joining the channel

_engine.enableLocalVideo(true);

@lohnsonok
Copy link

lohnsonok commented Jul 7, 2021

Make sure to enable your local video after joining the channel

_engine.enableLocalVideo(true);

Working for me. Thank you

@KhalidScrypt
Copy link

Issue is closed but I had another case with Black screen and couldn't find any solution on internet.
Make sure you're not building the views widget RtcLocalView.SurfaceView() or RtcRemoteView.SurfaceView() before you finish the initialization.
When following the example in Agora.io blog, I just had to add:
initialized ? _viewRows() : Container( height: MediaQuery.of(context).size.height, child: Center(child: CupertinoActivityIndicator()), ),

@JittuPrimo
Copy link

Make sure you have allow camera permission.

@ahmedelmwafy
Copy link

Make sure the Uid in Rtc remote view is the same with the user went live and the user joined to live

RtcRemoteView.SurfaceView( uid: uid, channelId:channelId, )

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