Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'release/ui/buttons_texture.py')
-rw-r--r--release/ui/buttons_texture.py204
1 files changed, 32 insertions, 172 deletions
diff --git a/release/ui/buttons_texture.py b/release/ui/buttons_texture.py
index 90ce40b4832..29e43981fd2 100644
--- a/release/ui/buttons_texture.py
+++ b/release/ui/buttons_texture.py
@@ -2,8 +2,8 @@
import bpy
class TextureButtonsPanel(bpy.types.Panel):
- __space_type__ = 'PROPERTIES'
- __region_type__ = 'WINDOW'
+ __space_type__ = "PROPERTIES"
+ __region_type__ = "WINDOW"
__context__ = "texture"
def poll(self, context):
@@ -210,51 +210,35 @@ class TEXTURE_PT_influence(TextureSlotPanel):
sub.itemR(tex, factor, text=name, slider=True)
if ma:
- if ma.type in ['SURFACE', 'HALO', 'WIRE']:
- split = layout.split()
-
- col = split.column()
- col.itemL(text="Diffuse:")
- factor_but(col, tex.map_diffuse, "map_diffuse", "diffuse_factor", "Intensity")
- factor_but(col, tex.map_colordiff, "map_colordiff", "colordiff_factor", "Color")
- factor_but(col, tex.map_alpha, "map_alpha", "alpha_factor", "Alpha")
- factor_but(col, tex.map_translucency, "map_translucency", "translucency_factor", "Translucency")
-
- col.itemL(text="Specular:")
- factor_but(col, tex.map_specular, "map_specular", "specular_factor", "Intensity")
- factor_but(col, tex.map_colorspec, "map_colorspec", "colorspec_factor", "Color")
- factor_but(col, tex.map_hardness, "map_hardness", "hardness_factor", "Hardness")
-
- col = split.column()
- col.itemL(text="Shading:")
- factor_but(col, tex.map_ambient, "map_ambient", "ambient_factor", "Ambient")
- factor_but(col, tex.map_emit, "map_emit", "emit_factor", "Emit")
- factor_but(col, tex.map_mirror, "map_mirror", "mirror_factor", "Mirror")
- factor_but(col, tex.map_raymir, "map_raymir", "raymir_factor", "Ray Mirror")
-
- col.itemL(text="Geometry:")
- factor_but(col, tex.map_normal, "map_normal", "normal_factor", "Normal")
- factor_but(col, tex.map_warp, "map_warp", "warp_factor", "Warp")
- factor_but(col, tex.map_displacement, "map_displacement", "displacement_factor", "Displace")
-
- #sub = col.column()
- #sub.active = tex.map_translucency or tex.map_emit or tex.map_alpha or tex.map_raymir or tex.map_hardness or tex.map_ambient or tex.map_specularity or tex.map_reflection or tex.map_mirror
- #sub.itemR(tex, "default_value", text="Amount", slider=True)
- elif ma.type == 'VOLUME':
- split = layout.split()
-
- col = split.column()
- factor_but(col, tex.map_density, "map_density", "density_factor", "Density")
- factor_but(col, tex.map_emission, "map_emission", "emission_factor", "Emission")
- factor_but(col, tex.map_absorption, "map_absorption", "absorption_factor", "Absorption")
- factor_but(col, tex.map_scattering, "map_scattering", "scattering_factor", "Scattering")
-
- col = split.column()
- col.itemL(text=" ")
- factor_but(col, tex.map_alpha, "map_coloremission", "coloremission_factor", "Emission Color")
- factor_but(col, tex.map_colorabsorption, "map_colorabsorption", "colorabsorption_factor", "Absorption Color")
-
+ split = layout.split()
+
+ col = split.column()
+ col.itemL(text="Diffuse:")
+ factor_but(col, tex.map_diffuse, "map_diffuse", "diffuse_factor", "Intensity")
+ factor_but(col, tex.map_colordiff, "map_colordiff", "colordiff_factor", "Color")
+ factor_but(col, tex.map_alpha, "map_alpha", "alpha_factor", "Alpha")
+ factor_but(col, tex.map_translucency, "map_translucency", "translucency_factor", "Translucency")
+
+ col.itemL(text="Specular:")
+ factor_but(col, tex.map_specular, "map_specular", "specular_factor", "Intensity")
+ factor_but(col, tex.map_colorspec, "map_colorspec", "colorspec_factor", "Color")
+ factor_but(col, tex.map_hardness, "map_hardness", "hardness_factor", "Hardness")
+ col = split.column()
+ col.itemL(text="Shading:")
+ factor_but(col, tex.map_ambient, "map_ambient", "ambient_factor", "Ambient")
+ factor_but(col, tex.map_emit, "map_emit", "emit_factor", "Emit")
+ factor_but(col, tex.map_mirror, "map_mirror", "mirror_factor", "Mirror")
+ factor_but(col, tex.map_raymir, "map_raymir", "raymir_factor", "Ray Mirror")
+
+ col.itemL(text="Geometry:")
+ factor_but(col, tex.map_normal, "map_normal", "normal_factor", "Normal")
+ factor_but(col, tex.map_warp, "map_warp", "warp_factor", "Warp")
+ factor_but(col, tex.map_displacement, "map_displacement", "displacement_factor", "Displace")
+
+ #sub = col.column()
+ #sub.active = tex.map_translucency or tex.map_emit or tex.map_alpha or tex.map_raymir or tex.map_hardness or tex.map_ambient or tex.map_specularity or tex.map_reflection or tex.map_mirror
+ #sub.itemR(tex, "default_value", text="Amount", slider=True)
elif la:
row = layout.row()
factor_but(row, tex.map_color, "map_color", "color_factor", "Color")
@@ -609,133 +593,13 @@ class TEXTURE_PT_distortednoise(TextureTypePanel):
layout.itemR(tex, "noise_basis", text="Basis")
flow = layout.column_flow()
- flow.itemR(tex, "distortion", text="Distortion")
+ flow.itemR(tex, "distortion_amount", text="Distortion")
flow.itemR(tex, "noise_size", text="Size")
flow.itemR(tex, "nabla")
-
-class TEXTURE_PT_voxeldata(TextureButtonsPanel):
- __idname__= "TEXTURE_PT_voxeldata"
- __label__ = "Voxel Data"
-
- def poll(self, context):
- tex = context.texture
- return (tex and tex.type == 'VOXEL_DATA')
-
- def draw(self, context):
- layout = self.layout
-
- tex = context.texture
- vd = tex.voxeldata
-
- layout.itemR(vd, "file_format")
- if vd.file_format in ['BLENDER_VOXEL', 'RAW_8BIT']:
- layout.itemR(vd, "source_path")
- if vd.file_format == 'RAW_8BIT':
- layout.itemR(vd, "resolution")
- elif vd.file_format == 'SMOKE':
- layout.itemR(vd, "domain_object")
-
- layout.itemR(vd, "still")
- row = layout.row()
- row.active = vd.still
- row.itemR(vd, "still_frame_number")
-
- layout.itemR(vd, "interpolation")
- layout.itemR(vd, "intensity")
-
-class TEXTURE_PT_pointdensity(TextureButtonsPanel):
- __idname__= "TEXTURE_PT_pointdensity"
- __label__ = "Point Density"
-
- def poll(self, context):
- tex = context.texture
- return (tex and tex.type == 'POINT_DENSITY')
-
- def draw(self, context):
- layout = self.layout
-
- tex = context.texture
- pd = tex.pointdensity
-
- layout.itemR(pd, "point_source", expand=True)
-
- split = layout.split()
-
- col = split.column()
- if pd.point_source == 'PARTICLE_SYSTEM':
- col.itemL(text="Object:")
- col.itemR(pd, "object", text="")
-
- sub = col.column()
- sub.enabled = pd.object
- if pd.object:
- sub.itemL(text="System:")
- sub.item_pointerR(pd, "particle_system", pd.object, "particle_systems", text="")
- sub.itemL(text="Cache:")
- sub.itemR(pd, "particle_cache", text="")
- else:
- col.itemL(text="Object:")
- col.itemR(pd, "object", text="")
- col.itemL(text="Cache:")
- col.itemR(pd, "vertices_cache", text="")
-
- col.itemS()
-
- col.itemL(text="Color Source:")
- col.itemR(pd, "color_source", text="")
- if pd.color_source in ('PARTICLE_SPEED', 'PARTICLE_VELOCITY'):
- col.itemR(pd, "speed_scale")
- if pd.color_source in ('PARTICLE_SPEED', 'PARTICLE_AGE'):
- layout.template_color_ramp(pd.color_ramp, expand=True)
-
- col = split.column()
- col.itemL()
- col.itemR(pd, "radius")
- col.itemL(text="Falloff:")
- col.itemR(pd, "falloff", text="")
- if pd.falloff == 'SOFT':
- col.itemR(pd, "falloff_softness")
-
-class TEXTURE_PT_pointdensity_turbulence(TextureButtonsPanel):
- __label__ = "Turbulence"
-
- def poll(self, context):
- tex = context.texture
- return (tex and tex.type == 'POINT_DENSITY')
-
- def draw_header(self, context):
- layout = self.layout
-
- tex = context.texture
- pd = tex.pointdensity
-
- layout.itemR(pd, "turbulence", text="")
-
- def draw(self, context):
- layout = self.layout
-
- tex = context.texture
- pd = tex.pointdensity
- layout.active = pd.turbulence
-
- split = layout.split()
-
- col = split.column()
- col.itemL(text="Influence:")
- col.itemR(pd, "turbulence_influence", text="")
- col.itemL(text="Noise Basis:")
- col.itemR(pd, "noise_basis", text="")
-
- col = split.column()
- col.itemL()
- col.itemR(pd, "turbulence_size")
- col.itemR(pd, "turbulence_depth")
- col.itemR(pd, "turbulence_strength")
bpy.types.register(TEXTURE_PT_context_texture)
bpy.types.register(TEXTURE_PT_preview)
-
-bpy.types.register(TEXTURE_PT_clouds) # Texture Type Panels
+bpy.types.register(TEXTURE_PT_clouds)
bpy.types.register(TEXTURE_PT_wood)
bpy.types.register(TEXTURE_PT_marble)
bpy.types.register(TEXTURE_PT_magic)
@@ -749,10 +613,6 @@ bpy.types.register(TEXTURE_PT_envmap)
bpy.types.register(TEXTURE_PT_musgrave)
bpy.types.register(TEXTURE_PT_voronoi)
bpy.types.register(TEXTURE_PT_distortednoise)
-bpy.types.register(TEXTURE_PT_voxeldata)
-bpy.types.register(TEXTURE_PT_pointdensity)
-bpy.types.register(TEXTURE_PT_pointdensity_turbulence)
-
bpy.types.register(TEXTURE_PT_colors)
bpy.types.register(TEXTURE_PT_mapping)
bpy.types.register(TEXTURE_PT_influence)