set default aspect ratio of w:h to 16:9
This commit is contained in:
parent
631498b167
commit
b17987dd53
|
|
@ -3,17 +3,25 @@
|
||||||
<head>
|
<head>
|
||||||
<title>ZLM RTC demo</title>
|
<title>ZLM RTC demo</title>
|
||||||
<script src="./ZLMRTCClient.js"></script>
|
<script src="./ZLMRTCClient.js"></script>
|
||||||
|
<style>
|
||||||
|
video {
|
||||||
|
width: 40vw;
|
||||||
|
max-height: 50vh;
|
||||||
|
height: 22.5vw; /* 默认和宽:高为 16:9 */
|
||||||
|
object-fit: contain;
|
||||||
|
background-color: grey;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body>
|
<body>
|
||||||
|
|
||||||
<div style="text-align: center;">
|
<div style="text-align: center;">
|
||||||
<div>
|
<div>
|
||||||
<video id='video' controls autoplay style="text-align:left;width:40%;">
|
<video id='video' controls autoplay>
|
||||||
Your browser is too old which doesn't support HTML5 video.
|
Your browser is too old which doesn't support HTML5 video.
|
||||||
</video>
|
</video>
|
||||||
|
|
||||||
<video id='selfVideo' controls autoplay style="text-align:right;width:40%;">
|
<video id='selfVideo' controls autoplay>
|
||||||
Your browser is too old which doesn't support HTML5 video.
|
Your browser is too old which doesn't support HTML5 video.
|
||||||
</video>
|
</video>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue