<s> """<STR_LIT>""" <EOL> import _tmp_material as material <EOL> import sys <EOL> from panda3d . core import load_prc_file_data , Vec4 <EOL> from direct . showbase . ShowBase import ShowBase <EOL> class Application ( ShowBase ) : <EOL> def __init__ ( self ) : <EOL> sys . path . insert ( <NUM_LIT:0> , "<STR_LIT>" ) <EOL> load_prc_file_data ( "<STR_LIT>" , "<STR_LIT>" ) <EOL> load_prc_file_data ( "<STR_LIT>" , "<STR_LIT>" ) <EOL> load_prc_file_data ( "<STR_LIT>" , "<STR_LIT>" ) <EOL> load_prc_file_data ( "<STR_LIT>" , "<STR_LIT>" ) <EOL> from rpcore import RenderPipeline , PointLight <EOL> self . render_pipeline = RenderPipeline ( ) <EOL> self . render_pipeline . mount_mgr . config_dir = "<STR_LIT>" <EOL> self . render_pipeline . set_empty_loading_screen ( ) <EOL> self . render_pipeline . create ( self ) <EOL> sphere = self . loader . loadModel ( "<STR_LIT>" ) <EOL> sphere . reparent_to ( self . render ) <EOL> self . disableMouse ( ) <EOL> self . camLens . setFov ( <NUM_LIT> ) <EOL> self . camLens . setNearFar ( <NUM_LIT> , <NUM_LIT> ) <EOL> self . camera . set_pos ( <NUM_LIT:0> , - <NUM_LIT> , <NUM_LIT:0> ) <EOL> self . camera . look_at ( <NUM_LIT:0> , - <NUM_LIT> , <NUM_LIT:0> ) <EOL> self . render2d . hide ( ) <EOL> self . aspect2d . hide ( ) <EOL> light = PointLight ( ) <EOL> light . pos = <NUM_LIT:10> , - <NUM_LIT:10> , <NUM_LIT:10> <EOL> light . radius = <NUM_LIT> <EOL> light . color = ( <NUM_LIT:1> , <NUM_LIT:1> , <NUM_LIT:1> ) <EOL> light . inner_radius = <NUM_LIT> <EOL> light . energy = <NUM_LIT:3> <EOL> self . render_pipeline . add_light ( light ) <EOL> light = PointLight ( ) <EOL> light . pos = - <NUM_LIT:10> , - <NUM_LIT:10> , <NUM_LIT:10> <EOL> light . radius = <NUM_LIT> <EOL> light . color = ( <NUM_LIT:1> , <NUM_LIT:1> , <NUM_LIT:1> ) <EOL> light . inner_radius = <NUM_LIT> <EOL> light . energy = <NUM_LIT:3> <EOL> self . render_pipeline . add_light ( light ) <EOL> for mat in sphere . find_all_materials ( ) : <EOL> mat . roughness = material . roughness <EOL> mat . base_color = Vec4 ( * ( list ( material . basecolor ) + [ <NUM_LIT:1> ] ) ) <EOL> mat . refractive_index = material . ior <EOL> mat . metallic = <NUM_LIT:1.0> if material . mat_type == "<STR_LIT>" else <NUM_LIT:0.0> <EOL> if material . mat_type == "<STR_LIT>" : <EOL> mat . emission = ( <NUM_LIT:2> , <NUM_LIT:0> , <NUM_LIT:0> , <NUM_LIT:0> ) <EOL> mat . metallic = <NUM_LIT:1.0> <EOL> mat . refractive_index = <NUM_LIT> <EOL> if material . mat_type == "<STR_LIT>" : <EOL> mat . emission = ( <NUM_LIT:5> , <NUM_LIT:0> , <NUM_LIT:0> , <NUM_LIT:0> ) <EOL> mat . metallic = <NUM_LIT:0.0> <EOL> mat . refractive_index = <NUM_LIT> <EOL> for i in range ( <NUM_LIT:10> ) : <EOL> self . taskMgr . step ( ) <EOL> self . win . save_screenshot ( "<STR_LIT>" ) <EOL> self . accept ( "<STR_LIT:r>" , self . reload ) <EOL> def reload ( self ) : <EOL> print ( "<STR_LIT>" ) <EOL> self . render_pipeline . reload_shaders ( ) <EOL> for i in range ( <NUM_LIT:4> ) : <EOL> self . taskMgr . step ( ) <EOL> self . win . save_screenshot ( "<STR_LIT>" ) <EOL> if len ( sys . argv ) <= <NUM_LIT:1> : <EOL> Application ( ) . run ( ) <EOL> else : <EOL> Application ( ) </s>
