|
@@ -6,6 +6,8 @@ import "plyr/dist/plyr.css";
|
|
|
import Plyr from "plyr";
|
|
|
import { Vue3Lottie } from "vue3-lottie";
|
|
|
import audioBga from "../images/audioBga.json";
|
|
|
+import audioBga1 from "../images/leftCloud.json";
|
|
|
+import audioBga2 from "../images/rightCloud.json";
|
|
|
import videobg from "../images/videobg.png";
|
|
|
import backImg from "../images/back.png";
|
|
|
import {
|
|
@@ -26,6 +28,8 @@ export default defineComponent({
|
|
|
const videoBgUrl = decodeURIComponent(route.query.videoBgUrl as string || '');
|
|
|
const playType = resourceUrl.lastIndexOf('mp4') !== -1 ? 'Video' : 'Audio'
|
|
|
const lottieDom = ref()
|
|
|
+ const lottieDom1 = ref()
|
|
|
+ const lottieDom2 = ref()
|
|
|
const landscapeScreen = ref(false)
|
|
|
let _plrl:any
|
|
|
const playIngShow = ref(true)
|
|
@@ -246,10 +250,14 @@ export default defineComponent({
|
|
|
const { pauseVisualDraw, playVisualDraw } = audioVisualDraw(audioDom, canvasDom)
|
|
|
_plrl.on('play', () => {
|
|
|
lottieDom.value.play()
|
|
|
+ lottieDom1.value.play()
|
|
|
+ lottieDom2.value.play()
|
|
|
playVisualDraw()
|
|
|
});
|
|
|
_plrl.on('pause', () => {
|
|
|
lottieDom.value.pause()
|
|
|
+ lottieDom1.value.pause()
|
|
|
+ lottieDom2.value.pause()
|
|
|
pauseVisualDraw()
|
|
|
});
|
|
|
}
|
|
@@ -297,8 +305,8 @@ export default defineComponent({
|
|
|
});
|
|
|
// 初始化五线谱
|
|
|
function initStaff(){
|
|
|
- //const src = `${vaildMusicScoreUrl()}/instrument/#/simple-detail?id=${musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;
|
|
|
- const src = `http://192.168.3.122:3000/instrument.html#/simple-detail?id=${musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;
|
|
|
+ const src = `${vaildMusicScoreUrl()}/instrument/#/simple-detail?id=${musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;
|
|
|
+ //const src = `http://192.168.3.122:3000/instrument.html#/simple-detail?id=${musicSheetId}&musicRenderType=${staffState.musicRenderType}&part-index=${staffState.partIndex}`;
|
|
|
staffState.staffSrc = src
|
|
|
window.addEventListener('message', (event) => {
|
|
|
const { api, height } = event.data;
|
|
@@ -404,6 +412,8 @@ export default defineComponent({
|
|
|
<div class={styles.audioBox}>
|
|
|
<canvas class={styles.audioVisualizer} id="audioVisualizer"></canvas>
|
|
|
<Vue3Lottie ref={lottieDom} class={styles.audioBga} animationData={audioBga} autoPlay={false} loop={true}></Vue3Lottie>
|
|
|
+ <Vue3Lottie ref={lottieDom1} class={styles.audioBga1} animationData={audioBga1} autoPlay={false} loop={true}></Vue3Lottie>
|
|
|
+ <Vue3Lottie ref={lottieDom2} class={styles.audioBga2} animationData={audioBga2} autoPlay={false} loop={true}></Vue3Lottie>
|
|
|
<audio
|
|
|
crossorigin="anonymous"
|
|
|
id="audioMediaSrc"
|