4 class RenderButtonsPanel(bpy.types.Panel):
5 __space_type__ = "BUTTONS_WINDOW"
6 __region_type__ = "WINDOW"
9 class RENDER_PT_shading(RenderButtonsPanel):
12 def draw(self, context):
16 rd = scene.render_data
18 split = layout.split()
21 sub.itemR(rd, "render_shadows", text="Shadows")
22 sub.itemR(rd, "render_sss", text="Subsurface Scattering")
23 sub.itemR(rd, "render_envmaps", text="Environment Map")
24 # sub.itemR(rd, "render_radiosity", text="Radio")
27 sub.itemR(rd, "render_raytracing", text="Ray Tracing")
28 if (rd.render_raytracing):
29 sub.itemR(rd, "octree_resolution", text="Octree")
31 class RENDER_PT_output(RenderButtonsPanel):
34 def draw(self, context):
38 rd = scene.render_data
41 col.itemR(rd, "output_path")
43 split = layout.split()
46 sub.itemR(rd, "image_type")
47 if rd.image_type in ("AVIJPEG", "JPEG"):
48 sub.itemR(rd, "quality", slider=True)
51 sub.itemR(rd, "color_mode")
52 sub.itemR(rd, "alpha_mode")
54 split = layout.split()
57 sub.itemL(text="Distributed Rendering:")
58 sub.itemR(rd, "placeholders")
59 sub.itemR(rd, "no_overwrite")
62 sub.itemL(text="Settings:")
63 sub.itemR(rd, "file_extensions")
64 sub.itemR(rd, "fields", text="Fields")
66 sub.itemR(rd, "fields_still", text="Still")
67 sub.row().itemR(rd, "field_order", expand=True)
70 class RENDER_PT_antialiasing(RenderButtonsPanel):
71 __label__ = "Anti-Aliasing"
73 def draw_header(self, context):
74 rd = context.scene.render_data
77 layout.itemR(rd, "antialiasing", text="")
79 def draw(self, context):
83 rd = scene.render_data
85 split = layout.split()
88 sub.itemL(text="Samples:")
89 sub.row().itemR(rd, "antialiasing_samples", expand=True)
92 sub.itemR(rd, "pixel_filter")
93 sub.itemR(rd, "filter_size", text="Size", slider=True)
94 sub.itemR(rd, "save_buffers")
96 sub.itemR(rd, "full_sample")
98 class RENDER_PT_render(RenderButtonsPanel):
101 def draw(self, context):
102 scene = context.scene
105 rd = scene.render_data
108 row.itemO("SCREEN_OT_render", text="Render Still")
109 row.item_booleanO("SCREEN_OT_render", "anim", True, text="Render Animation")
112 row.itemR(rd, "do_composite")
113 row.itemR(rd, "do_sequence")
116 row.itemR(rd, "free_image_textures")
119 row.itemL(text="Threads:")
120 row.itemL(text="Tiles:")
122 split = layout.split()
124 sub = split.column(align=True)
125 sub.row().itemR(rd, "threads_mode", expand=True)
126 if rd.threads_mode == 'THREADS_FIXED':
127 sub.itemR(rd, "threads")
129 sub = split.column(align=True)
130 sub.itemR(rd, "parts_x", text="X")
131 sub.itemR(rd, "parts_y", text="Y")
134 row.itemR(rd, "panorama")
135 row.itemR(rd, "dither_intensity", text="Dither", slider=True)
136 # row.itemR(rd, "backbuf")
138 class RENDER_PT_dimensions(RenderButtonsPanel):
139 __label__ = "Dimensions"
141 def draw(self, context):
142 scene = context.scene
145 rd = scene.render_data
147 split = layout.split()
149 col = split.column(align=True)
150 col.itemL(text="Resolution:")
151 col.itemR(rd, "resolution_x", text="X")
152 col.itemR(rd, "resolution_y", text="Y")
153 col.itemR(rd, "resolution_percentage", text="")
155 col.itemL(text="Aspect Ratio:")
156 col.itemR(rd, "pixel_aspect_x", text="X")
157 col.itemR(rd, "pixel_aspect_y", text="Y")
159 col.itemR(rd, "border", text="Border")
161 col.itemR(rd, "crop_to_border")
163 col = split.column(align=True)
164 col.itemL(text="Frame Range:")
165 col.itemR(scene, "start_frame", text="Start")
166 col.itemR(scene, "end_frame", text="End")
167 col.itemR(scene, "frame_step", text="Step")
169 col.itemL(text="Frame Rate:")
171 col.itemR(rd, "fps_base",text="/")
173 bpy.types.register(RENDER_PT_render)
174 bpy.types.register(RENDER_PT_dimensions)
175 bpy.types.register(RENDER_PT_antialiasing)
176 bpy.types.register(RENDER_PT_shading)
177 bpy.types.register(RENDER_PT_output)