-
Notifications
You must be signed in to change notification settings - Fork 405
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
[BUG] iOS MediaElement overall not working #2334
Comments
We don't yet support .NET 9. We will release .NET 9 support when it GAs next month. You may follow our progress here: #2215 |
Hello and thanks for the quick reply, I quoted an SDK version that is also installed on my OS and not the target Version. |
Ok. You are using dotnet 8.x with xcode 16? In that case we do support it. I don't where I got the idea you were using dotnet 9. That is on me. I am sorry. I am reopening this report. |
Yes, I am using XCode 16.0 (16A242d) for compiling on the mac with .net 8.x. Thanks for reopening! |
Please ensure your local environment is using the required tools:
global.json
|
After I had completed all the steps, I deleted the app, cleaned up the project folder and tried debugging again: Error Output MediaElement[0:] OnAppearing: MediaElement 2024-11-11 21:10:49.646557+0100 CommunityToolkit.Maui.Sample[97552:9090636] [plugin] AddInstanceForFactory: No factory registered for id F8BB1C28-BAE8-11D6-9C31-00039315CD46 2024-11-11 21:10:49.646904+0100 CommunityToolkit.Maui.Sample[97552:9090636] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0 2024-11-11 21:10:49.647002+0100 CommunityToolkit.Maui.Sample[97552:9090636] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818 2024-11-11 21:10:49.647098+0100 CommunityToolkit.Maui.Sample[97552:9090636] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0 2024-11-11 21:10:49.647205+0100 CommunityToolkit.Maui.Sample[97552:9090636] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818 2024-11-11 21:10:49.647768+0100 CommunityToolkit.Maui.Sample[97552:9090636] HALDefaultDevice.cpp:742 Could not find default device for dOut 2024-11-11 21:10:49.647814+0100 CommunityToolkit.Maui.Sample[97552:9090636] [ddagg] AggregateDevice.mm:882 couldn't get default output device, ID = 0, err = 0! [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: None, New State: Stopped [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: Stopped, New State: Opening Thread started: #14 [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media opened. Thread started: #15 [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: Opening, New State: Paused 2024-11-11 21:10:51.304254+0100 CommunityToolkit.Maui.Sample[97552:9091358] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID 2024-11-11 21:10:51.305083+0100 CommunityToolkit.Maui.Sample[97552:9091313] - changing property cornerCurve in transform-only layer, will have no effect 2024-11-11 21:10:51.305103+0100 CommunityToolkit.Maui.Sample[97552:9091358] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.305156+0100 CommunityToolkit.Maui.Sample[97552:9091358] CA_UISoundClient.cpp:152 * * * NULL AQIONode object 2024-11-11 21:10:51.305272+0100 CommunityToolkit.Maui.Sample[97552:9091313] - changing property cornerCurve in transform-only layer, will have no effect 2024-11-11 21:10:51.305334+0100 CommunityToolkit.Maui.Sample[97552:9091358] CA_UISoundClient.cpp:1169 Can't make UISound Renderer 2024-11-11 21:10:51.305386+0100 CommunityToolkit.Maui.Sample[97552:9091313] - changing property cornerCurve in transform-only layer, will have no effect 2024-11-11 21:10:51.306465+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306509+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306537+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306562+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306616+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306650+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306686+0100 CommunityToolkit.Maui.Sample[97552:9091370] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 21:10:51.306754+0100 CommunityToolkit.Maui.Sample[97552:9091313] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 2024-11-11 21:10:51.306887+0100 CommunityToolkit.Maui.Sample[97552:9091313] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 2024-11-11 21:10:51.307026+0100 CommunityToolkit.Maui.Sample[97552:9091313] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 Thread started: #16 Thread started: #17 Thread started: #18 [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: Paused, New State: Failed [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media failed. Error: The operation could not be completed - An unknown error occurred (-12746) [0:] MediaManager: Error: The operation could not be completed - An unknown error occurred (-12746) [0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Duration: 00:09:56.4583333 Thread finished: #6 Thread finished: #12 Thread finished: #16 Thread finished: #13 Thread finished: #8 Der Thread 6 hat mit Code 0 (0x0) geendet. Der Thread 12 hat mit Code 0 (0x0) geendet. Der Thread 16 hat mit Code 0 (0x0) geendet. Der Thread 13 hat mit Code 0 (0x0) geendet. Der Thread 8 hat mit Code 0 (0x0) geendet. Workload Update summary:
PS C:\Users\buurned\Documents\Maui-main\samples> dotnet workload install maui Willkommen bei .NET 8.0!SDK-Version: 8.0.403 TelemetrieDie .NET-Tools erfassen Nutzungsdaten, damit wir die Plattform stetig verbessern können. Diese werden von Microsoft erfasst und mit der Community geteilt. Sie können das Erfassen von Telemetriedaten deaktivieren, indem Sie die Umgebungsvariable DOTNET_CLI_TELEMETRY_OPTOUT in Ihrer bevorzugten Shell auf "1" oder TRUE festlegen. Weitere Informationen zu Telemetriedaten in .NET-CLI-Tools finden Sie hier: https://aka.ms/dotnet-cli-telemetry Ein ASP.NET Core-HTTPS-Entwicklungszertifikat installiert. Schreiben Sie Ihre erste App: https://aka.ms/dotnet-hello-world
|
@brminnick @ne0rrmatrix can you verify the issue and assign a label? Maybe the solution is not too complicated! |
Is there an existing issue for this?
Did you read the "Reporting a bug" section on Contributing file?
Current Behavior
When trying to show a Video with MediaElement different errors appear.
TL;DR:
MediaElement does not work:
With similar error messages as in the previous versions, in addition I could now also get AudioHardware errors.
I have already found several issues referencing this problem or similar problems, the problem is that most of them are already set to “Complete” due to the last merge in the master branch. I also could not find a ticket that exists explicitly for this issue.
I have found a pull request that should fix the problem, but unfortunately it didn't work.
Originally posted by @brminnick in #2251 (comment)
Also couldn't find the new ticket.
I have tested the following: On iOS 18.0 (iPhone 16 Pro, Pro Max) Simulator display a MediaElement in:
Unfortunately, this also occurs in your sample project.
Debug Output from iOS 18.0 - iPhone 16 Pro (Screenshot below):
Stacktrace on MauiSample
2024-11-11 12:19:17.354241+0100 CommunityToolkit.Maui.Sample[47625:8651002] [plugin] AddInstanceForFactory: No factory registered for id <CFUUID 0x600000ab92c0> F8BB1C28-BAE8-11D6-9C31-00039315CD46
2024-11-11 12:19:17.354593+0100 CommunityToolkit.Maui.Sample[47625:8651002] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0
2024-11-11 12:19:17.354698+0100 CommunityToolkit.Maui.Sample[47625:8651002] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818
2024-11-11 12:19:17.354789+0100 CommunityToolkit.Maui.Sample[47625:8651002] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0
2024-11-11 12:19:17.354889+0100 CommunityToolkit.Maui.Sample[47625:8651002] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818
2024-11-11 12:19:17.355452+0100 CommunityToolkit.Maui.Sample[47625:8651002] HALDefaultDevice.cpp:742 Could not find default device for dOut
2024-11-11 12:19:17.355490+0100 CommunityToolkit.Maui.Sample[47625:8651002] [ddagg] AggregateDevice.mm:882 couldn't get default output device, ID = 0, err = 0!
[0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: None, New State: Stopped
[0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: Stopped, New State: Opening
Thread started: #12
[0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media opened.
2024-11-11 12:19:17.451131+0100 CommunityToolkit.Maui.Sample[47625:8651136] [connection] nw_connection_copy_connected_local_endpoint_block_invoke [C1] Connection has no local endpoint
2024-11-11 12:19:17.451243+0100 CommunityToolkit.Maui.Sample[47625:8651136] [connection] nw_connection_copy_connected_local_endpoint_block_invoke [C1] Connection has no local endpoint
[0:] CommunityToolkit.Maui.Sample.Pages.Views.MediaElementPage: Information: Media State Changed. Old State: Opening, New State: Paused
2024-11-11 12:19:19.335200+0100 CommunityToolkit.Maui.Sample[47625:8651391] <CATransformLayer: 0x600000b3a0a0> - changing property cornerCurve in transform-only layer, will have no effect
2024-11-11 12:19:19.335239+0100 CommunityToolkit.Maui.Sample[47625:8651390] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID
2024-11-11 12:19:19.335329+0100 CommunityToolkit.Maui.Sample[47625:8651391] <CATransformLayer: 0x600000b29b80> - changing property cornerCurve in transform-only layer, will have no effect
2024-11-11 12:19:19.335446+0100 CommunityToolkit.Maui.Sample[47625:8651391] <CATransformLayer: 0x600000b3d100> - changing property cornerCurve in transform-only layer, will have no effect
2024-11-11 12:19:19.336129+0100 CommunityToolkit.Maui.Sample[47625:8651390] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.336182+0100 CommunityToolkit.Maui.Sample[47625:8651390] CA_UISoundClient.cpp:152 * * * NULL AQIONode object
2024-11-11 12:19:19.336308+0100 CommunityToolkit.Maui.Sample[47625:8651390] CA_UISoundClient.cpp:1169 Can't make UISound Renderer
2024-11-11 12:19:19.337443+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.337501+0100 CommunityToolkit.Maui.Sample[47625:8651402] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID
2024-11-11 12:19:19.337616+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.337700+0100 CommunityToolkit.Maui.Sample[47625:8651402] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID
2024-11-11 12:19:19.337800+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.337831+0100 CommunityToolkit.Maui.Sample[47625:8651402] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID
2024-11-11 12:19:19.337923+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.337970+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.338011+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.338053+0100 CommunityToolkit.Maui.Sample[47625:8651402] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput
2024-11-11 12:19:19.338141+0100 CommunityToolkit.Maui.Sample[47625:8651391] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0
2024-11-11 12:19:19.338305+0100 CommunityToolkit.Maui.Sample[47625:8651391] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0
2024-11-
We are using the MediaElement inside a ListView with following settings:
<ListView x:Name="lvActivities" Grid.Row="0" BackgroundColor="Transparent" CachingStrategy="RecycleElement" HasUnevenRows="true" IsRefreshing="{Binding IsWorking}" ItemTapped="LvActivities_ItemTapped" ItemTemplate="{StaticResource Selector}" ItemsSource="{Binding ActivityTexts}" SelectionMode="Single" SeparatorVisibility="None"> <ListView.Behaviors> <control:CustomInfiniteScrollBehavior /> </ListView.Behaviors> </ListView>
and on our Application we still got this error:Stacktrace own app
2024-11-11 13:06:43.256822+0100 OwnMaui [58147:8715178] [connection] nw_connection_add_timestamp_locked_on_nw_queue [C12] Hit maximum timestamp count, will start dropping events 2024-11-11 13:06:44.957029+0100 OwnMaui [58147:8714292] [plugin] AddInstanceForFactory: No factory registered for id F8BB1C28-BAE8-11D6-9C31-00039315CD46 2024-11-11 13:06:44.957466+0100 OwnMaui [58147:8714292] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0 2024-11-11 13:06:44.957599+0100 OwnMaui [58147:8714292] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818 2024-11-11 13:06:44.957724+0100 OwnMaui [58147:8714292] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0 2024-11-11 13:06:44.957835+0100 OwnMaui [58147:8714292] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device. Error: 560947818 2024-11-11 13:06:44.958555+0100 OwnMaui [58147:8714292] HALDefaultDevice.cpp:742 Could not find default device for dOut 2024-11-11 13:06:44.958601+0100 OwnMaui [58147:8714292] [ddagg] AggregateDevice.mm:882 couldn't get default output device, ID = 0, err = 0! 2024-11-11 13:06:45.026652+0100 OwnMaui [58147:8715178] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID 2024-11-11 13:06:45.026917+0100 OwnMaui [58147:8715178] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.026960+0100 OwnMaui [58147:8715178] CA_UISoundClient.cpp:152 * * * NULL AQIONode object 2024-11-11 13:06:45.027579+0100 OwnMaui [58147:8715178] CA_UISoundClient.cpp:1169 Can't make UISound Renderer 2024-11-11 13:06:45.028768+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.028822+0100 OwnMaui [58147:8715351] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID 2024-11-11 13:06:45.028916+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.028961+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.028994+0100 OwnMaui [58147:8715351] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID 2024-11-11 13:06:45.029085+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.029152+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.029187+0100 OwnMaui [58147:8715351] AudioHardware-mac-imp.cpp:2706 AudioDeviceStop: no device with given ID 2024-11-11 13:06:45.029277+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.029326+0100 OwnMaui [58147:8715351] [aqme] AQMEIO.cpp:379 error -66680 finding/initializing Default-InputOutput 2024-11-11 13:06:45.029401+0100 OwnMaui [58147:8715178] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 2024-11-11 13:06:45.029517+0100 OwnMaui [58147:8715178] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 2024-11-11 13:06:45.029625+0100 OwnMaui [58147:8715178] AudioHardware-mac-imp.cpp:1224 AudioObjectRemovePropertyListener: no object with given ID 0 2024-11-11 13:06:45.241947+0100 OwnMaui [58147:8714292] AudioHardware-mac-imp.cpp:776 AudioObjectSetPropertyData: no object with given ID 0 2024-11-11 13:06:45.242087+0100 OwnMaui [58147:8714292] [as_client] AVAudioSessionImpl_Simulator.mm:106 Failed to set processVolumeScalar on device.
AND
Message: Objective-C exception thrown. Name: UIViewControllerHierarchyInconsistency Reason: child view controller:<AVPlayerViewController: 0x107a40a00> should have parent view controller:<Microsoft_Maui_Controls_Handlers_Compatibility_FormsUITableViewController: 0x121e08c00> but actual parent is:<Microsoft_Maui_Platform_PageViewController: 0x118768690>
On Android, everything works fine.
Maybe someone knows a workaround to fix it for the next update?
Expected Behavior
Showing the Video.
Steps To Reproduce
Link to public reproduction project repository
https://github.com/CommunityToolkit/Maui/tree/main/samples
Environment
Anything else?
Similar bugs:
#1903
#2246
#2251
#2257
The text was updated successfully, but these errors were encountered: