Sideway
output.to from Sideway
Draft for Information Only

Content

Manim Scene_file_writer.py
 Codes in Scene_file_writer.py
  Import
  Class SceneFileWriter(object)
   Configuration
   Functions
 Source and Reference

Manim Scene_file_writer.py

Codes in Scene_file_writer.py

Available codes defined in manimlib.scene.scene_file_writer.py

image

Import

import numpy as np
from pydub import AudioSegment
import shutil
import subprocess
import os
import _thread as thread
from time import sleep
import datetime

import manimlib.constants as consts
from manimlib.constants import FFMPEG_BIN
from manimlib.constants import STREAMING_IP
from manimlib.constants import STREAMING_PORT
from manimlib.constants import STREAMING_PROTOCOL
from manimlib.utils.config_ops import digest_config
from manimlib.utils.file_ops import guarantee_existence
from manimlib.utils.file_ops import add_extension_if_not_present
from manimlib.utils.file_ops import get_sorted_integer_files
from manimlib.utils.sounds import get_full_sound_file_path

Class SceneFileWriter(object)

class manimlib.scene.scene_file_writer.SceneFileWriter(object)version 19Dec2019

Configuration

    CONFIG = {
        "write_to_movie": False,
        # TODO, save_pngs is doing nothing
        "save_pngs": False,
        "png_mode": "RGBA",
        "save_last_frame": False,
        "movie_file_extension": ".mp4",
        "gif_file_extension": ".gif",
        "livestreaming": False,
        "to_twitch": False,
        "twitch_key": None,
        # Previous output_file_name
        # TODO, address this in extract_scene et. al.
        "file_name": None,
        "output_directory": None,
    }

Functions

  • def __init__(self, scene, **kwargs)
  • def init_output_directories(self)
  • def get_default_module_directory(self)
  • def get_default_scene_name(self)
  • def get_resolution_directory(self)
  • def get_image_file_path(self)
  • def get_next_partial_movie_path(self)
  • def get_movie_file_path(self)
  • def init_audio(self)
  • def create_audio_segment(self)
  • def add_audio_segment(self, new_segment, time=None, gain_to_background=None)
  • def add_sound(self, sound_file, time=None, gain=None, **kwargs)
  • def begin_animation(self, allow_write=False)
  • def end_animation(self, allow_write=False)
  • def write_frame(self, frame)
  • def save_final_image(self, image)
  • def idle_stream(self)
  • def finish(self)
  • def open_movie_pipe(self)
  • def close_movie_pipe(self)
  • def combine_movie_files(self)
  • def print_file_ready_message(self, file_path)

Source and Reference

https://github.com/3b1b/manim19Dec2019

©sideway

ID: 200702202 Last Updated: 22/7/2020 Revision: 0

IMAGE

Home 5

Business

Management

HBR 3

Information

Recreation

Hobbies 8

Culture

Chinese 1097

English 337

Reference 67

Computer

Hardware 149

Software

Application 198

Digitization 25

Latex 7

Manim 115

Numeric 19

Programming

Web 283

Unicode 494

HTML 65

CSS 58

ASP.NET 149

OS 389

DeskTop 7

Python 19

Knowledge

Mathematics

Formulas 8

Algebra 25

Number Theory 206

Trigonometry 18

Geometry 21

Calculus 67

Complex Analysis 21

Engineering

Tables 8

Mechanical

Mechanics 1

Rigid Bodies

Statics 92

Dynamics 37

Fluid 5

Fluid Kinematics 5

Control

Process Control 1

Acoustics 19

FiniteElement 2

Physics

Electric 27

Biology 1

Geography 1


Copyright © 2000-2020 Sideway . All rights reserved Disclaimers last modified on 06 September 2019