[flutter/audioplayers]播放资源时报错

/ 5,091评论 / 21787阅读 / 0点赞

前言

问题

无法读取assets文件

E/flutter (32073): [ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: Unable to load asset: assets/file/music.mp3
E/flutter (32073): #0      PlatformAssetBundle.load (package:flutter/src/services/asset_bundle.dart:258:7)
E/flutter (32073): <asynchronous suspension>
E/flutter (32073): #1      AudioCache.fetchToMemory (package:audioplayers/src/audio_cache.dart:75:22)
E/flutter (32073): <asynchronous suspension>
E/flutter (32073): #2      AudioCache.load (package:audioplayers/src/audio_cache.dart:101:31)
E/flutter (32073): <asynchronous suspension>
E/flutter (32073): #3      AudioPlayer.setSourceAsset (package:audioplayers/src/audioplayer.dart:237:17)

本地资源/网络资源都无法播放

......
D/MediaCodecList(32073): codecHandlesFormat: no format, so no extra checks
D/CCodec  (32073): allocate(c2.android.mp3.decoder)
I/CCodec  (32073): setting up 'default' as default (vendor) store
I/CCodec  (32073): Created component [c2.android.mp3.decoder]
D/CCodecConfig(32073): read media type: audio/mpeg
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: algo.buffers.max-count.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: output.subscribed-indices.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: input.buffers.allocator-ids.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: output.buffers.allocator-ids.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: algo.buffers.allocator-ids.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: output.buffers.pool-ids.values
D/ReflectedParamUpdater(32073): extent() != 1 for single value type: algo.buffers.pool-ids.values
......
D/CCodecBufferChannel(32073): [c2.android.mp3.decoder#231] MediaCodec discarded an unknown buffer
I/hw-BpHwBinder(32073): onLastStrongRef automatically unlinking death recipients
......

网络资源加载失败

......
Unexpected error!
D/AudioPlayers(31616): java.io.IOException: Cleartext HTTP traffic to {xxx.域名} not permitted
......
  1. StevenSen说道:

    canadian pharmacy online ship to usa: Large Selection of Medications from Canada – canadian pharmacy ltd

  2. RickyAlage说道:

    mexican pharmacy cheapest mexico drugs buying prescription drugs in mexico

  3. Marcelcrolf说道:

    http://canadaph24.pro/# canadian online drugs

  4. Michaelsew说道:

    http://indiaph24.store/# best online pharmacy india

  5. RickyAlage说道:

    reputable indian pharmacies Generic Medicine India to USA indian pharmacy paypal

  6. StevenSen说道:

    п»їbest mexican online pharmacies: cheapest mexico drugs – mexico pharmacies prescription drugs

  7. RickyAlage说道:

    mexican drugstore online Online Pharmacies in Mexico mexican drugstore online

  8. Michaelsew说道:

    https://canadaph24.pro/# canada rx pharmacy

  9. Marcelcrolf说道:

    http://canadaph24.pro/# global pharmacy canada

  10. RickyAlage说道:

    best online pharmacies in mexico mexico pharmacy best online pharmacies in mexico

  11. Marcelcrolf说道:

    https://mexicoph24.life/# pharmacies in mexico that ship to usa

  12. RickyAlage说道:

    buying from online mexican pharmacy mexican pharmacy reputable mexican pharmacies online

  13. Marcelcrolf说道:

    http://mexicoph24.life/# mexico pharmacies prescription drugs

  14. Michaelsew说道:

    http://mexicoph24.life/# mexican mail order pharmacies

  15. RickyAlage说道:

    buy prescription drugs from india buy medicines from India mail order pharmacy india

  16. Marcelcrolf说道:

    http://mexicoph24.life/# mexican pharmacy

  17. StevenSen说道:

    indianpharmacy com: indian pharmacy fast delivery – pharmacy website india

  18. Marcelcrolf说道:

    https://canadaph24.pro/# online pharmacy canada

  19. RickyAlage说道:

    prescription drugs canada buy online canadian pharmacies canada drug pharmacy

  20. Michaelsew说道:

    http://canadaph24.pro/# canadian pharmacy uk delivery

  21. RickyAlage说道:

    reputable mexican pharmacies online reputable mexican pharmacies online buying prescription drugs in mexico

  22. StevenSen说道:

    global pharmacy canada: Large Selection of Medications from Canada – northwest canadian pharmacy

  23. RickyAlage说道:

    canadian pharmacy meds canadian pharmacies canadian pharmacy 24h com safe

  24. Michaelsew说道:

    https://indiaph24.store/# india pharmacy

  25. RickyAlage说道:

    indian pharmacies safe Generic Medicine India to USA п»їlegitimate online pharmacies india

  26. RickyAlage说道:

    canada drug pharmacy canadian pharmacies canadian mail order pharmacy

  27. Marcelcrolf说道:

    http://indiaph24.store/# world pharmacy india

  28. Michaelsew说道:

    http://indiaph24.store/# Online medicine order

  29. RickyAlage说道:

    medication from mexico pharmacy cheapest mexico drugs mexican online pharmacies prescription drugs

  30. Marcelcrolf说道:

    http://canadaph24.pro/# legitimate canadian pharmacy online

  31. RickyAlage说道:

    mexican rx online Mexican Pharmacy Online mexican rx online

  32. Marcelcrolf说道:

    https://indiaph24.store/# cheapest online pharmacy india

  33. Michaelsew说道:

    https://indiaph24.store/# mail order pharmacy india

  34. Marcelcrolf说道:

    https://canadaph24.pro/# canadian pharmacy antibiotics

  35. RickyAlage说道:

    mail order pharmacy india indian pharmacies safe indianpharmacy com

  36. Marcelcrolf说道:

    https://indiaph24.store/# mail order pharmacy india

  37. RickyAlage说道:

    mexico drug stores pharmacies Mexican Pharmacy Online mexican pharmaceuticals online

  38. Michaelsew说道:

    https://canadaph24.pro/# reliable canadian pharmacy

  39. RickyAlage说道:

    cheapest online pharmacy india indian pharmacy fast delivery buy prescription drugs from india

  40. StevenSen说道:

    buy prescription drugs from india: indian pharmacy – online shopping pharmacy india

  41. Marcelcrolf说道:

    http://canadaph24.pro/# ordering drugs from canada

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注