{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Option `online` for three.js 3d viewer" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "'SageMath version 8.7, Release Date: 2019-03-23'" ] }, "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "version()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "The default is `online=False`, which prevents rendering on nbviewer.jupyter.org or mybinder.org:" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/html": [ "\n", "\n" ], "text/plain": [ "Graphics3d Object" ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "sphere(viewer='threejs')" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "data": { "text/html": [ "\n", "\n" ], "text/plain": [ "Graphics3d Object" ] }, "execution_count": 3, "metadata": {}, "output_type": "execute_result" } ], "source": [ "sphere(viewer='threejs', online=True)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Viewing this notebook through `nbviewer.jupyter.org`\n", "\n", "Click [here](https://nbviewer.jupyter.org/github/egourgoulhon/SageMathTest/blob/master/Worksheets/threejs_online.ipynb)" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "SageMath 8.7", "language": "", "name": "sagemath" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.6.6" } }, "nbformat": 4, "nbformat_minor": 2 }