Last active
September 4, 2020 11:50
-
-
Save Ze1598/eabd9f423b50f5a943bc8cbc54a6325e to your computer and use it in GitHub Desktop.
model-viewer demo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html> | |
<head> | |
<title>3D Test</title> | |
<link rel="stylesheet" href="model-viewer-demo.css"> | |
</head> | |
<body> | |
<div id="holder"> | |
<div id="text"> | |
<h1 class="sample-text">Play around with the model on the right!</h1> | |
<h1 class="sample-text">Just watch it rotate on its own or do it yourself with the mouse</h1> | |
<h1 class="sample-text">You can also zoom in the model!</h1> | |
</div> | |
<div id="model"> | |
<model-viewer src="RobotExpressive.glb" alt="A 3D model of a robot" auto-rotate="" camera-controls="" background-color="#455A64"></model-viewer> | |
</div> | |
</div> | |
<!-- Loads model-viewer for modern browsers --> | |
<script type="module" src="https://unpkg.com/@google/model-viewer/dist/model-viewer.js"></script> | |
<!-- Loads model-viewer for older browsers --> | |
<script nomodule src="https://unpkg.com/@google/model-viewer/dist/model-viewer-legacy.js"></script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment