1 # ##### BEGIN GPL LICENSE BLOCK #####
3 # This program is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU General Public License
5 # as published by the Free Software Foundation; either version 2
6 # of the License, or (at your option) any later version.
8 # This program is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 # GNU General Public License for more details.
13 # You should have received a copy of the GNU General Public License
14 # along with this program; if not, write to the Free Software Foundation,
15 # Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 # ##### END GPL LICENSE BLOCK #####
23 class RENDER_MT_presets(bpy.types.Menu):
24 bl_label = "Render Presets"
25 preset_subdir = "render"
26 preset_operator = "script.execute_preset"
27 draw = bpy.types.Menu.draw_preset
30 class RENDER_MT_ffmpeg_presets(bpy.types.Menu):
31 bl_label = "FFMPEG Presets"
32 preset_subdir = "ffmpeg"
33 preset_operator = "script.python_file_run"
34 draw = bpy.types.Menu.draw_preset
37 class RenderButtonsPanel():
38 bl_space_type = 'PROPERTIES'
39 bl_region_type = 'WINDOW'
41 # COMPAT_ENGINES must be defined in each subclass, external engines can add themselves here
44 def poll(cls, context):
45 rd = context.scene.render
46 return (context.scene and rd.use_game_engine is False) and (rd.engine in cls.COMPAT_ENGINES)
49 class RENDER_PT_render(RenderButtonsPanel, bpy.types.Panel):
51 COMPAT_ENGINES = {'BLENDER_RENDER'}
53 def draw(self, context):
56 rd = context.scene.render
58 split = layout.split()
61 col.operator("render.render", text="Image", icon='RENDER_STILL')
64 col.operator("render.render", text="Animation", icon='RENDER_ANIMATION').animation = True
66 layout.prop(rd, "display_mode", text="Display")
69 class RENDER_PT_layers(RenderButtonsPanel, bpy.types.Panel):
71 bl_options = {'DEFAULT_CLOSED'}
72 COMPAT_ENGINES = {'BLENDER_RENDER'}
74 def draw(self, context):
81 row.template_list(rd, "layers", rd.layers, "active_index", rows=2)
83 col = row.column(align=True)
84 col.operator("scene.render_layer_add", icon='ZOOMIN', text="")
85 col.operator("scene.render_layer_remove", icon='ZOOMOUT', text="")
90 layout.prop(rl, "name")
92 split = layout.split()
95 col.prop(scene, "layers", text="Scene")
97 col.prop(rl, "light_override", text="Light")
98 col.prop(rl, "material_override", text="Material")
101 col.prop(rl, "layers", text="Layer")
102 col.label(text="Mask Layers:")
103 col.prop(rl, "layers_zmask", text="")
106 layout.label(text="Include:")
108 split = layout.split()
111 col.prop(rl, "use_zmask")
113 row.prop(rl, "invert_zmask", text="Negate")
114 row.active = rl.use_zmask
115 col.prop(rl, "use_all_z")
118 col.prop(rl, "use_solid")
119 col.prop(rl, "use_halo")
120 col.prop(rl, "use_ztransp")
121 col.prop(rl, "use_sky")
124 col.prop(rl, "use_edge_enhance")
125 col.prop(rl, "use_strand")
126 col.prop(rl, "use_freestyle")
130 split = layout.split()
133 col.label(text="Passes:")
134 col.prop(rl, "use_pass_combined")
135 col.prop(rl, "use_pass_z")
136 col.prop(rl, "use_pass_vector")
137 col.prop(rl, "use_pass_normal")
138 col.prop(rl, "use_pass_uv")
139 col.prop(rl, "use_pass_mist")
140 col.prop(rl, "use_pass_object_index")
141 col.prop(rl, "use_pass_color")
145 col.prop(rl, "use_pass_diffuse")
147 row.prop(rl, "use_pass_specular")
148 row.prop(rl, "exclude_specular", text="")
150 row.prop(rl, "use_pass_shadow")
151 row.prop(rl, "exclude_shadow", text="")
153 row.prop(rl, "use_pass_emit")
154 row.prop(rl, "exclude_emit", text="")
156 row.prop(rl, "use_pass_ambient_occlusion")
157 row.prop(rl, "exclude_ambient_occlusion", text="")
159 row.prop(rl, "use_pass_environment")
160 row.prop(rl, "exclude_environment", text="")
162 row.prop(rl, "use_pass_indirect")
163 row.prop(rl, "exclude_indirect", text="")
165 row.prop(rl, "use_pass_reflection")
166 row.prop(rl, "exclude_reflection", text="")
168 row.prop(rl, "use_pass_refraction")
169 row.prop(rl, "exclude_refraction", text="")
172 class RENDER_PT_freestyle(RenderButtonsPanel, bpy.types.Panel):
173 bl_label = "Freestyle"
174 COMPAT_ENGINES = {'BLENDER_RENDER'}
177 def poll(cls, context):
178 rd = context.scene.render
179 rl = rd.layers.active
180 return rl and rl.use_freestyle
182 def draw(self, context):
185 rd = context.scene.render
186 rl = rd.layers.active
187 freestyle = rl.freestyle_settings
189 split = layout.split()
192 col.prop(freestyle, "mode", text="Control Mode")
194 if freestyle.mode == "EDITOR":
195 col.label(text="Edge Detection Options:")
196 col.prop(freestyle, "crease_angle")
197 col.prop(freestyle, "sphere_radius")
198 col.prop(freestyle, "kr_derivative_epsilon")
200 lineset = freestyle.linesets.active
202 col.label(text="Line Sets:")
207 row.template_list(freestyle, "linesets", freestyle.linesets, "active_index", rows=rows)
210 subsub = sub.column(align=True)
211 subsub.operator("scene.freestyle_lineset_add", icon='ZOOMIN', text="")
212 subsub.operator("scene.freestyle_lineset_remove", icon='ZOOMOUT', text="")
215 subsub = sub.column(align=True)
216 subsub.operator("scene.freestyle_lineset_move", icon='TRIA_UP', text="").direction = 'UP'
217 subsub.operator("scene.freestyle_lineset_move", icon='TRIA_DOWN', text="").direction = 'DOWN'
220 col.prop(lineset, "name")
221 col.prop(lineset, "select_by_visibility")
222 col.prop(lineset, "select_by_edge_types")
224 if lineset.select_by_visibility:
225 col.label(text="Visibility:")
226 sub = col.row(align=True)
227 sub.prop(lineset, "visibility", expand=True)
228 if lineset.visibility == "RANGE":
229 sub = col.row(align=True)
230 sub.prop(lineset, "qi_start")
231 sub.prop(lineset, "qi_end")
233 if lineset.select_by_edge_types:
234 col.label(text="Edge Types:")
236 row.prop(lineset, "edge_type_negation", expand=True)
238 row.prop(lineset, "edge_type_combination", expand=True)
242 sub.prop(lineset, "select_silhouette")
243 sub.prop(lineset, "select_border")
244 sub.prop(lineset, "select_crease")
245 sub.prop(lineset, "select_ridge")
246 sub.prop(lineset, "select_valley")
247 sub.prop(lineset, "select_suggestive_contour")
248 sub.prop(lineset, "select_material_boundary")
250 sub.prop(lineset, "select_contour")
251 sub.prop(lineset, "select_external_contour")
253 else: # freestyle.mode == "SCRIPT"
255 col.prop(freestyle, "crease_angle")
256 col.prop(freestyle, "sphere_radius")
257 col.prop(freestyle, "use_ridges_and_valleys")
258 col.prop(freestyle, "use_suggestive_contours")
260 sub.prop(freestyle, "kr_derivative_epsilon")
261 sub.active = freestyle.use_suggestive_contours
262 col.prop(freestyle, "use_material_boundaries")
263 col.operator("scene.freestyle_module_add")
265 for i, module in enumerate(freestyle.modules):
267 box.context_pointer_set("freestyle_module", module)
268 row = box.row(align=True)
269 row.prop(module, "is_displayed", text="")
270 row.prop(module, "module_path", text="")
271 row.operator("scene.freestyle_module_remove", icon='X', text="")
272 row.operator("scene.freestyle_module_move", icon='TRIA_UP', text="").direction = 'UP'
273 row.operator("scene.freestyle_module_move", icon='TRIA_DOWN', text="").direction = 'DOWN'
276 class RENDER_PT_freestyle_linestyle(RenderButtonsPanel, bpy.types.Panel):
277 bl_label = "Freestyle: Line Style"
278 COMPAT_ENGINES = {'BLENDER_RENDER'}
281 def poll(cls, context):
282 rd = context.scene.render
283 rl = rd.layers.active
284 if rl and rl.use_freestyle:
285 freestyle = rl.freestyle_settings
286 return freestyle.mode == "EDITOR" and freestyle.linesets.active
289 def draw_modifier_box_header(self, box, modifier):
291 row.context_pointer_set("modifier", modifier)
292 if modifier.expanded:
296 row.operator("scene.freestyle_modifier_toggle_fold", icon=icon, text="", emboss=False)
297 row.label(text=modifier.rna_type.name)
298 row.prop(modifier, "name", text="")
299 row.prop(modifier, "enabled", text="")
300 sub = row.row(align=True)
301 sub.operator("scene.freestyle_modifier_move", icon='TRIA_UP', text="").direction = 'UP'
302 sub.operator("scene.freestyle_modifier_move", icon='TRIA_DOWN', text="").direction = 'DOWN'
303 row.operator("scene.freestyle_modifier_remove", icon='X', text="")
305 def draw_color_modifier(self, context, modifier):
308 col = layout.column(align=True)
309 self.draw_modifier_box_header(col.box(), modifier)
310 if modifier.expanded:
313 row.prop(modifier, "blend", text="")
314 row.prop(modifier, "influence")
315 if modifier.type == "DISTANCE_FROM_OBJECT":
316 box.prop(modifier, "target")
317 box.template_color_ramp(modifier, "color_ramp", expand=True)
318 if modifier.type not in ["ALONG_STROKE"]:
319 row = box.row(align=True)
320 row.prop(modifier, "range_min")
321 row.prop(modifier, "range_max")
323 def draw_alpha_modifier(self, context, modifier):
326 col = layout.column(align=True)
327 self.draw_modifier_box_header(col.box(), modifier)
328 if modifier.expanded:
331 row.prop(modifier, "blend", text="")
332 row.prop(modifier, "influence")
333 if modifier.type == "DISTANCE_FROM_OBJECT":
334 box.prop(modifier, "target")
336 row.prop(modifier, "mapping", text="")
338 sub.prop(modifier, "invert")
339 if modifier.mapping == "CURVE":
341 box.template_curve_mapping(modifier, "curve")
342 if modifier.type not in ["ALONG_STROKE"]:
343 row = box.row(align=True)
344 row.prop(modifier, "range_min")
345 row.prop(modifier, "range_max")
347 def draw_thickness_modifier(self, context, modifier):
350 col = layout.column(align=True)
351 self.draw_modifier_box_header(col.box(), modifier)
352 if modifier.expanded:
355 row.prop(modifier, "blend", text="")
356 row.prop(modifier, "influence")
357 if modifier.type == "DISTANCE_FROM_OBJECT":
358 box.prop(modifier, "target")
360 row.prop(modifier, "mapping", text="")
362 sub.prop(modifier, "invert")
363 if modifier.mapping == "CURVE":
365 box.template_curve_mapping(modifier, "curve")
366 if modifier.type not in ["ALONG_STROKE"]:
367 row = box.row(align=True)
368 row.prop(modifier, "range_min")
369 row.prop(modifier, "range_max")
370 row = box.row(align=True)
371 row.prop(modifier, "value_min")
372 row.prop(modifier, "value_max")
374 def draw(self, context):
377 rd = context.scene.render
378 rl = rd.layers.active
379 lineset = rl.freestyle_settings.linesets.active
380 linestyle = lineset.linestyle
382 split = layout.split()
384 col.template_ID(lineset, "linestyle", new="scene.freestyle_linestyle_new")
387 sub = col.row(align=True)
388 sub.prop(linestyle, "panel", expand=True)
390 if linestyle.panel == "COLOR":
391 col.label(text="Base Color:")
392 col.prop(linestyle, "color", text="")
393 col.label(text="Modifiers:")
394 layout.operator_menu_enum("scene.freestyle_color_modifier_add", "type", text="Add Modifier")
395 for modifier in linestyle.color_modifiers:
396 self.draw_color_modifier(context, modifier)
397 elif linestyle.panel == "ALPHA":
398 col.label(text="Base Transparency:")
399 col.prop(linestyle, "alpha")
400 col.label(text="Modifiers:")
401 layout.operator_menu_enum("scene.freestyle_alpha_modifier_add", "type", text="Add Modifier")
402 for modifier in linestyle.alpha_modifiers:
403 self.draw_alpha_modifier(context, modifier)
404 elif linestyle.panel == "THICKNESS":
405 col.label(text="Base Thickness:")
406 col.prop(linestyle, "thickness")
407 col.label(text="Modifiers:")
408 layout.operator_menu_enum("scene.freestyle_thickness_modifier_add", "type", text="Add Modifier")
409 for modifier in linestyle.thickness_modifiers:
410 self.draw_thickness_modifier(context, modifier)
411 elif linestyle.panel == "STROKES":
413 elif linestyle.panel == "DISTORT":
415 elif linestyle.panel == "MISC":
419 class RENDER_PT_shading(RenderButtonsPanel, bpy.types.Panel):
421 COMPAT_ENGINES = {'BLENDER_RENDER'}
423 def draw(self, context):
426 rd = context.scene.render
428 split = layout.split()
431 col.prop(rd, "use_textures", text="Textures")
432 col.prop(rd, "use_shadows", text="Shadows")
433 col.prop(rd, "use_sss", text="Subsurface Scattering")
434 col.prop(rd, "use_envmaps", text="Environment Map")
437 col.prop(rd, "use_raytrace", text="Ray Tracing")
438 col.prop(rd, "use_color_management")
439 col.prop(rd, "alpha_mode", text="Alpha")
442 class RENDER_PT_performance(RenderButtonsPanel, bpy.types.Panel):
443 bl_label = "Performance"
444 bl_options = {'DEFAULT_CLOSED'}
445 COMPAT_ENGINES = {'BLENDER_RENDER'}
447 def draw(self, context):
450 rd = context.scene.render
452 split = layout.split()
455 col.label(text="Threads:")
456 col.row().prop(rd, "threads_mode", expand=True)
458 sub.enabled = rd.threads_mode == 'FIXED'
459 sub.prop(rd, "threads")
460 sub = col.column(align=True)
461 sub.label(text="Tiles:")
462 sub.prop(rd, "parts_x", text="X")
463 sub.prop(rd, "parts_y", text="Y")
466 col.label(text="Memory:")
468 sub.enabled = not (rd.use_border or rd.use_full_sample)
469 sub.prop(rd, "use_save_buffers")
471 sub.active = rd.use_compositing
472 sub.prop(rd, "use_free_image_textures")
474 sub.active = rd.use_raytrace
475 sub.label(text="Acceleration structure:")
476 sub.prop(rd, "raytrace_method", text="")
477 if rd.raytrace_method == 'OCTREE':
478 sub.prop(rd, "octree_resolution", text="Resolution")
480 sub.prop(rd, "use_instances", text="Instances")
481 sub.prop(rd, "use_local_coords", text="Local Coordinates")
484 class RENDER_PT_post_processing(RenderButtonsPanel, bpy.types.Panel):
485 bl_label = "Post Processing"
486 bl_options = {'DEFAULT_CLOSED'}
487 COMPAT_ENGINES = {'BLENDER_RENDER'}
489 def draw(self, context):
492 rd = context.scene.render
494 split = layout.split()
497 col.prop(rd, "use_compositing")
498 col.prop(rd, "use_sequencer")
501 col.prop(rd, "dither_intensity", text="Dither", slider=True)
505 split = layout.split()
508 col.prop(rd, "use_fields", text="Fields")
510 sub.active = rd.use_fields
511 sub.row().prop(rd, "field_order", expand=True)
512 sub.prop(rd, "use_fields_still", text="Still")
515 col.prop(rd, "use_edge_enhance")
517 sub.active = rd.use_edge_enhance
518 sub.prop(rd, "edge_threshold", text="Threshold", slider=True)
519 sub.prop(rd, "edge_color", text="")
523 split = layout.split()
525 col.prop(rd, "use_freestyle", text="Freestyle")
528 class RENDER_PT_output(RenderButtonsPanel, bpy.types.Panel):
530 COMPAT_ENGINES = {'BLENDER_RENDER'}
532 def draw(self, context):
535 rd = context.scene.render
536 file_format = rd.file_format
538 layout.prop(rd, "filepath", text="")
540 split = layout.split()
542 col.prop(rd, "file_format", text="")
543 col.row().prop(rd, "color_mode", text="Color", expand=True)
546 col.prop(rd, "use_file_extension")
547 col.prop(rd, "use_overwrite")
548 col.prop(rd, "use_placeholder")
550 if file_format in ('AVI_JPEG', 'JPEG'):
551 split = layout.split()
552 split.prop(rd, "file_quality", slider=True)
554 if file_format == 'PNG':
555 split = layout.split()
556 split.prop(rd, "file_quality", slider=True, text="Compression")
558 elif file_format == 'MULTILAYER':
559 split = layout.split()
562 col.label(text="Codec:")
563 col.prop(rd, "exr_codec", text="")
566 elif file_format == 'OPEN_EXR':
567 split = layout.split()
570 col.label(text="Codec:")
571 col.prop(rd, "exr_codec", text="")
573 subsplit = split.split()
574 col = subsplit.column()
575 col.prop(rd, "use_exr_half")
576 col.prop(rd, "exr_zbuf")
578 col = subsplit.column()
579 col.prop(rd, "exr_preview")
581 elif file_format == 'JPEG2000':
582 split = layout.split()
584 col.label(text="Depth:")
585 col.row().prop(rd, "jpeg2k_depth", expand=True)
588 col.prop(rd, "jpeg2k_preset", text="")
589 col.prop(rd, "jpeg2k_ycc")
591 elif file_format in ('CINEON', 'DPX'):
592 split = layout.split()
594 col.prop(rd, "use_cineon_log", text="Convert to Log")
596 col = split.column(align=True)
597 col.active = rd.use_cineon_log
598 col.prop(rd, "cineon_black", text="Black")
599 col.prop(rd, "cineon_white", text="White")
600 col.prop(rd, "cineon_gamma", text="Gamma")
602 elif file_format == 'TIFF':
603 split = layout.split()
604 split.prop(rd, "use_tiff_16bit")
606 elif file_format == 'QUICKTIME_CARBON':
607 split = layout.split()
608 split.operator("scene.render_data_set_quicktime_codec")
610 elif file_format == 'QUICKTIME_QTKIT':
611 split = layout.split()
613 col.prop(rd, "quicktime_codec_type", text="Video Codec")
614 col.prop(rd, "quicktime_codec_spatial_quality", text="Quality")
617 col.prop(rd, "quicktime_audiocodec_type", text="Audio Codec")
618 if rd.quicktime_audiocodec_type != 'No audio':
619 split = layout.split()
621 if rd.quicktime_audiocodec_type == 'LPCM':
622 col.prop(rd, "quicktime_audio_bitdepth", text="")
625 col.prop(rd, "quicktime_audio_samplerate", text="")
627 split = layout.split()
629 if rd.quicktime_audiocodec_type == 'AAC':
630 col.prop(rd, "quicktime_audio_bitrate")
632 subsplit = split.split()
633 col = subsplit.column()
635 if rd.quicktime_audiocodec_type == 'AAC':
636 col.prop(rd, "quicktime_audio_codec_isvbr")
638 col = subsplit.column()
639 col.prop(rd, "quicktime_audio_resampling_hq")
642 class RENDER_PT_encoding(RenderButtonsPanel, bpy.types.Panel):
643 bl_label = "Encoding"
644 bl_options = {'DEFAULT_CLOSED'}
645 COMPAT_ENGINES = {'BLENDER_RENDER'}
648 def poll(cls, context):
649 rd = context.scene.render
650 return rd.file_format in ('FFMPEG', 'XVID', 'H264', 'THEORA')
652 def draw(self, context):
655 rd = context.scene.render
657 layout.menu("RENDER_MT_ffmpeg_presets", text="Presets")
659 split = layout.split()
662 col.prop(rd, "ffmpeg_format")
663 if rd.ffmpeg_format in ('AVI', 'QUICKTIME', 'MKV', 'OGG'):
665 col.prop(rd, "ffmpeg_codec")
669 split = layout.split()
672 col.prop(rd, "ffmpeg_video_bitrate")
675 col.prop(rd, "ffmpeg_gopsize")
677 split = layout.split()
680 col.label(text="Rate:")
681 col.prop(rd, "ffmpeg_minrate", text="Minimum")
682 col.prop(rd, "ffmpeg_maxrate", text="Maximum")
683 col.prop(rd, "ffmpeg_buffersize", text="Buffer")
687 col.prop(rd, "ffmpeg_autosplit")
688 col.label(text="Mux:")
689 col.prop(rd, "ffmpeg_muxrate", text="Rate")
690 col.prop(rd, "ffmpeg_packetsize", text="Packet Size")
693 sub = layout.column()
695 if rd.ffmpeg_format not in ('MP3', ):
696 sub.prop(rd, "ffmpeg_audio_codec", text="Audio Codec")
703 col.prop(rd, "ffmpeg_audio_bitrate")
704 col.prop(rd, "ffmpeg_audio_mixrate")
707 col.prop(rd, "ffmpeg_audio_volume", slider=True)
710 class RENDER_PT_antialiasing(RenderButtonsPanel, bpy.types.Panel):
711 bl_label = "Anti-Aliasing"
712 COMPAT_ENGINES = {'BLENDER_RENDER'}
714 def draw_header(self, context):
715 rd = context.scene.render
717 self.layout.prop(rd, "use_antialiasing", text="")
719 def draw(self, context):
722 rd = context.scene.render
723 layout.active = rd.use_antialiasing
725 split = layout.split()
728 col.row().prop(rd, "antialiasing_samples", expand=True)
730 sub.enabled = not rd.use_border
731 sub.prop(rd, "use_full_sample")
734 col.prop(rd, "pixel_filter_type", text="")
735 col.prop(rd, "filter_size", text="Size")
738 class RENDER_PT_motion_blur(RenderButtonsPanel, bpy.types.Panel):
739 bl_label = "Full Sample Motion Blur"
740 bl_options = {'DEFAULT_CLOSED'}
741 COMPAT_ENGINES = {'BLENDER_RENDER'}
743 def draw_header(self, context):
744 rd = context.scene.render
746 self.layout.prop(rd, "use_motion_blur", text="")
748 def draw(self, context):
751 rd = context.scene.render
752 layout.active = rd.use_motion_blur
755 row.prop(rd, "motion_blur_samples")
756 row.prop(rd, "motion_blur_shutter")
759 class RENDER_PT_dimensions(RenderButtonsPanel, bpy.types.Panel):
760 bl_label = "Dimensions"
761 COMPAT_ENGINES = {'BLENDER_RENDER'}
763 def draw(self, context):
766 scene = context.scene
769 row = layout.row(align=True)
770 row.menu("RENDER_MT_presets", text=bpy.types.RENDER_MT_presets.bl_label)
771 row.operator("render.preset_add", text="", icon="ZOOMIN")
772 row.operator("render.preset_add", text="", icon="ZOOMOUT").remove_active = True
773 split = layout.split()
776 sub = col.column(align=True)
777 sub.label(text="Resolution:")
778 sub.prop(rd, "resolution_x", text="X")
779 sub.prop(rd, "resolution_y", text="Y")
780 sub.prop(rd, "resolution_percentage", text="")
782 sub.label(text="Aspect Ratio:")
783 sub.prop(rd, "pixel_aspect_x", text="X")
784 sub.prop(rd, "pixel_aspect_y", text="Y")
787 row.prop(rd, "use_border", text="Border")
789 sub.active = rd.use_border
790 sub.prop(rd, "use_crop_to_border", text="Crop")
793 sub = col.column(align=True)
794 sub.label(text="Frame Range:")
795 sub.prop(scene, "frame_start", text="Start")
796 sub.prop(scene, "frame_end", text="End")
797 sub.prop(scene, "frame_step", text="Step")
799 sub.label(text="Frame Rate:")
801 sub = col.column(align=True)
803 sub.prop(rd, "fps_base", text="/")
804 subrow = sub.row(align=True)
805 subrow.prop(rd, "frame_map_old", text="Old")
806 subrow.prop(rd, "frame_map_new", text="New")
809 class RENDER_PT_stamp(RenderButtonsPanel, bpy.types.Panel):
811 bl_options = {'DEFAULT_CLOSED'}
812 COMPAT_ENGINES = {'BLENDER_RENDER'}
814 def draw_header(self, context):
815 rd = context.scene.render
817 self.layout.prop(rd, "use_stamp", text="")
819 def draw(self, context):
822 rd = context.scene.render
824 layout.active = rd.use_stamp
826 split = layout.split()
829 col.prop(rd, "use_stamp_time", text="Time")
830 col.prop(rd, "use_stamp_date", text="Date")
831 col.prop(rd, "use_stamp_render_time", text="RenderTime")
832 col.prop(rd, "use_stamp_frame", text="Frame")
833 col.prop(rd, "use_stamp_scene", text="Scene")
834 col.prop(rd, "use_stamp_camera", text="Camera")
835 col.prop(rd, "use_stamp_filename", text="Filename")
836 col.prop(rd, "use_stamp_marker", text="Marker")
837 col.prop(rd, "use_stamp_sequencer_strip", text="Seq. Strip")
840 col.active = rd.use_stamp
841 col.prop(rd, "stamp_foreground", slider=True)
842 col.prop(rd, "stamp_background", slider=True)
844 col.prop(rd, "stamp_font_size", text="Font Size")
846 row = layout.split(percentage=0.2)
847 row.prop(rd, "use_stamp_note", text="Note")
849 sub.active = rd.use_stamp_note
850 sub.prop(rd, "stamp_note_text", text="")
853 class RENDER_PT_bake(RenderButtonsPanel, bpy.types.Panel):
855 bl_options = {'DEFAULT_CLOSED'}
856 COMPAT_ENGINES = {'BLENDER_RENDER'}
858 def draw(self, context):
861 rd = context.scene.render
863 layout.operator("object.bake_image", icon='RENDER_STILL')
865 layout.prop(rd, "bake_type")
867 if rd.bake_type == 'NORMALS':
868 layout.prop(rd, "bake_normal_space")
869 elif rd.bake_type in ('DISPLACEMENT', 'AO'):
870 layout.prop(rd, "use_bake_normalize")
872 # col.prop(rd, "bake_aa_mode")
873 # col.prop(rd, "use_bake_antialiasing")
877 split = layout.split()
880 col.prop(rd, "use_bake_clear")
881 col.prop(rd, "bake_margin")
882 col.prop(rd, "bake_quad_split", text="Split")
885 col.prop(rd, "use_bake_selected_to_active")
887 sub.active = rd.use_bake_selected_to_active
888 sub.prop(rd, "bake_distance")
889 sub.prop(rd, "bake_bias")
899 if __name__ == "__main__":