custom.wxml 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. <!-- template custom -->
  2. <template name='custom'>
  3. <view class="template-custom">
  4. <view class="players-container">
  5. <view wx:for="{{streamList}}" wx:key="streamID" wx:if="{{item.src && (item.hasVideo || item.hasAudio)}}" class="view-container player-container {{item.isVisible?'':'none'}}" style="left:{{item.xAxis}};top:{{item.yAxis}};width:{{item.width}};height:{{item.height}};z-index:{{item.zIndex}};">
  6. <live-player
  7. class="player"
  8. id="{{item.streamID}}"
  9. data-userid="{{item.userID}}"
  10. data-streamid="{{item.streamID}}"
  11. data-streamtype="{{item.streamType}}"
  12. src= "{{item.src}}"
  13. mode= "{{item.mode}}"
  14. autoplay= "{{item.autoplay}}"
  15. mute-audio= "{{item.muteAudio}}"
  16. mute-video= "{{item.muteVideo}}"
  17. orientation= "{{item.orientation}}"
  18. object-fit= "{{item.objectFit}}"
  19. background-mute= "{{item.enableBackgroundMute}}"
  20. min-cache= "{{item.minCache}}"
  21. max-cache= "{{item.maxCache}}"
  22. sound-mode= "{{item.soundMode}}"
  23. enable-recv-message= "{{item.enableRecvMessage}}"
  24. auto-pause-if-navigate= "{{item.autoPauseIfNavigate}}"
  25. auto-pause-if-open-native= "{{item.autoPauseIfOpenNative}}"
  26. debug="{{debug}}"
  27. bindstatechange="_playerStateChange"
  28. bindfullscreenchange="_playerFullscreenChange"
  29. bindnetstatus="_playerNetStatus"
  30. bindaudiovolumenotify ="_playerAudioVolumeNotify"
  31. />
  32. </view>
  33. </view>
  34. <view class="view-container pusher-container {{pusher.isVisible?'':'none'}}" style="left:{{pusher.xAxis}};top:{{pusher.yAxis}};width:{{pusher.width}};height:{{pusher.height}};z-index:{{pusher.zIndex}};">
  35. <live-pusher
  36. class="pusher"
  37. url="{{pusher.url}}"
  38. mode="{{pusher.mode}}"
  39. autopush="{{pusher.autopush}}"
  40. enable-camera="{{pusher.enableCamera}}"
  41. enable-mic="{{pusher.enableMic}}"
  42. muted="{{!pusher.enableMic}}"
  43. enable-agc="{{pusher.enableAgc}}"
  44. enable-ans="{{pusher.enableAns}}"
  45. enable-ear-monitor="{{pusher.enableEarMonitor}}"
  46. auto-focus="{{pusher.enableAutoFocus}}"
  47. zoom="{{pusher.enableZoom}}"
  48. min-bitrate="{{pusher.minBitrate}}"
  49. max-bitrate="{{pusher.maxBitrate}}"
  50. video-width="{{pusher.videoWidth}}"
  51. video-height="{{pusher.videoHeight}}"
  52. beauty="{{pusher.beautyLevel}}"
  53. whiteness="{{pusher.whitenessLevel}}"
  54. orientation="{{pusher.videoOrientation}}"
  55. aspect="{{pusher.videoAspect}}"
  56. device-position="{{pusher.frontCamera}}"
  57. remote-mirror="{{pusher.enableRemoteMirror}}"
  58. local-mirror="{{pusher.localMirror}}"
  59. background-mute="{{pusher.enableBackgroundMute}}"
  60. audio-quality="{{pusher.audioQuality}}"
  61. audio-volume-type="{{pusher.audioVolumeType}}"
  62. audio-reverb-type="{{pusher.audioReverbType}}"
  63. waiting-image="{{pusher.waitingImage}}"
  64. debug="{{debug}}"
  65. bindstatechange="_pusherStateChangeHandler"
  66. bindnetstatus="_pusherNetStatusHandler"
  67. binderror="_pusherErrorHandler"
  68. bindbgmstart="_pusherBGMStartHandler"
  69. bindbgmprogress="_pusherBGMProgressHandler"
  70. bindbgmcomplete="_pusherBGMCompleteHandler"
  71. bindaudiovolumenotify="_pusherAudioVolumeNotify"
  72. />
  73. </view>
  74. </view>
  75. </template>