Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation
This project
Loading...
Sign in
蒋秀川
/
miniProject
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 1d8b3e9c
authored
Oct 31, 2023
by
李乾广
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
修改bug
1 parent
c001e402
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
7 deletions
h5/public/index.html
h5/src/components/vionPlayer/index.vue
h5/src/views/extension/index.vue
h5/public/index.html
View file @
1d8b3e9
...
@@ -4,6 +4,9 @@
...
@@ -4,6 +4,9 @@
<meta
charset=
"utf-8"
>
<meta
charset=
"utf-8"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1.0"
>
<meta
name=
"viewport"
content=
"width=device-width,initial-scale=1.0"
>
<meta
http-equiv=
"Cache-Control"
content=
"no-cache, no-store, must-revalidate"
/>
<meta
http-equiv=
"Pragma"
content=
"no-cache"
/>
<meta
http-equiv=
"Expires"
content=
"0"
/>
<link
rel=
"icon"
href=
"<%= BASE_URL %>favicon.ico"
>
<link
rel=
"icon"
href=
"<%= BASE_URL %>favicon.ico"
>
<title>
<
%= htmlWebpackPlugin.options.title %>
</title>
<title>
<
%= htmlWebpackPlugin.options.title %>
</title>
<script
src=
"/jessibuca-pro/jessibuca-pro-demo.js"
></script>
<script
src=
"/jessibuca-pro/jessibuca-pro-demo.js"
></script>
...
...
h5/src/components/vionPlayer/index.vue
View file @
1d8b3e9
...
@@ -240,7 +240,7 @@ export default {
...
@@ -240,7 +240,7 @@ export default {
const
targetType
=
typeList
[
this
.
mirrorIndex
%
2
];
const
targetType
=
typeList
[
this
.
mirrorIndex
%
2
];
this
.
_jessibuca
.
setMirrorRotate
(
targetType
);
this
.
_jessibuca
.
setMirrorRotate
(
targetType
);
},
},
screenshot
(
filename
=
''
,
format
=
'jpeg'
,
quality
=
0.2
,
type
=
'base64'
)
{
screenshot
(
filename
=
''
,
format
=
'jpeg'
,
quality
=
1
,
type
=
'base64'
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
return
new
Promise
((
resolve
,
reject
)
=>
{
// 如果是播放状态
// 如果是播放状态
const
isPlaying
=
this
.
_jessibuca
.
isPlaying
();
const
isPlaying
=
this
.
_jessibuca
.
isPlaying
();
...
@@ -258,7 +258,7 @@ export default {
...
@@ -258,7 +258,7 @@ export default {
const
canvas
=
getWatermarkCanvasImg
(
this
.
player
.
width
,
this
.
player
.
height
,
this
.
watermarkText
,
image
);;
const
canvas
=
getWatermarkCanvasImg
(
this
.
player
.
width
,
this
.
player
.
height
,
this
.
watermarkText
,
image
);;
// 将带有水印的 Canvas 转换回 base64
// 将带有水印的 Canvas 转换回 base64
const
watermarkedBase64
=
canvas
.
toDataURL
(
'image/
png'
);
const
watermarkedBase64
=
canvas
.
toDataURL
(
'image/
jpeg'
,
0.5
);
// 现在,watermarkedBase64 包含了带有水印的 base64 图像数据
// 现在,watermarkedBase64 包含了带有水印的 base64 图像数据
// console.log(watermarkedBase64);
// console.log(watermarkedBase64);
...
@@ -272,7 +272,7 @@ export default {
...
@@ -272,7 +272,7 @@ export default {
image
.
src
=
this
.
_jessibuca
.
screenshot
(
filename
,
format
,
quality
,
type
);
image
.
src
=
this
.
_jessibuca
.
screenshot
(
filename
,
format
,
quality
,
type
);
});
});
},
},
screenshotOrigin
(
filename
=
''
,
format
=
'jpeg'
,
quality
=
0.2
,
type
=
'base64'
)
{
screenshotOrigin
(
filename
=
''
,
format
=
'jpeg'
,
quality
=
1
,
type
=
'base64'
)
{
return
this
.
_jessibuca
.
screenshot
(
filename
,
format
,
quality
,
type
);
return
this
.
_jessibuca
.
screenshot
(
filename
,
format
,
quality
,
type
);
}
}
},
},
...
...
h5/src/views/extension/index.vue
View file @
1d8b3e9
...
@@ -93,19 +93,20 @@ export default {
...
@@ -93,19 +93,20 @@ export default {
// 云台控制
// 云台控制
ptzControlClick
(
type
)
{
ptzControlClick
(
type
)
{
console
.
log
(
type
)
console
.
log
(
type
)
if
(
type
!=
'stop'
)
{
this
.
nowPanTilt
=
this
.
panTiltList
[
type
]
}
let
par
=
{
let
par
=
{
direction
:
this
.
panTiltList
[
type
],
direction
:
this
.
panTiltList
[
type
],
speed
:
2
,
speed
:
2
,
gateUnid
:
this
.
params
.
gateUnid
,
gateUnid
:
this
.
params
.
gateUnid
,
appKey
:
this
.
params
.
appKey
,
appKey
:
this
.
params
.
appKey
,
}
}
if
(
type
!=
'stop'
)
{
this
.
nowPanTilt
=
this
.
panTiltList
[
type
]
}
else
{
par
.
direction
=
this
.
nowPanTilt
}
// 加密
// 加密
let
parStr
=
this
.
aesEncrypt
(
par
)
let
parStr
=
this
.
aesEncrypt
(
par
)
if
(
type
==
'stop'
)
{
if
(
type
==
'stop'
)
{
par
.
direction
=
this
.
nowPanTilt
tourApi
.
ptzStop
({
param
:
parStr
}).
then
(
res
=>
{
tourApi
.
ptzStop
({
param
:
parStr
}).
then
(
res
=>
{
console
.
log
(
res
)
console
.
log
(
res
)
})
})
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment