How to properly set VERTEX_PAINT mode from a python script? My goal is to get a rendered image of an PLY mesh from command line.
I wrote this script:

import os
import bpy
import sys
from math import pi

filename = 'web.ply'
in_dir = os.path.join('J:\\', 'aa')
item = os.path.join(in_dir, filename)
out_dir = os.path.join(in_dir, 'out')
os.makedirs(out_dir, exist_ok=True)

bpy.ops.object.delete()
bpy.ops.import_mesh.ply(filepath=os.path.join(item))
bpy.ops.object.lamp_add(type='SUN', radius=100, view_align=False, location=(0, 0, 0), layers=(True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False))
bpy.ops.object.select_all(action='DESELECT')
for ob in bpy.data.objects:
  print (ob.type, ob.name)
  if ob.type == 'MESH':
    bpy.context.scene.objects.active = ob
    ob.select = True
  elif ob.type == 'CAMERA':
    ob.data.clip_end = 1000000
    ob.data.clip_start = 0.01
    ob.select = False
  else:
    ob.select = False

bpy.ops.transform.rotate(value=pi/2, axis=(True, False, False))
bpy.context.scene.render.resolution_x = 692
bpy.context.scene.render.resolution_y = 900
bpy.context.scene.render.alpha_mode = 'TRANSPARENT'

bpy.ops.object.mode_set(mode='VERTEX_PAINT')

for area in bpy.context.screen.areas:
    if area.type == 'VIEW_3D':
        ctx = bpy.context.copy()
        ctx['area'] = area
        ctx['region'] = area.regions[-1]
        bpy.ops.view3d.view_selected(ctx)
        bpy.ops.view3d.camera_to_view_selected(ctx)

bpy.context.scene.render.image_settings.file_format = 'PNG'
bpy.context.scene.render.image_settings.quality = 100
bpy.context.scene.render.filepath = os.path.join(out_dir, filename+'-preview.jpg')
bpy.ops.render.render(write_still=True)

It works, but not properly renders colors. The output image is in gray scale colors!
I think that the issue is bpy.ops.object.mode_set(mode='VERTEX_PAINT') and the position inside the script. Something is wrong. Any tips?
Here a PLY example file: http://156.54.99.175/3d/a.ply

If you used bpy.ops.screen.screenshot(ctx, filepath=destination, full=False) in the correct context it would save a screenshot of what you see in the viewport, but render.render() isn't the same as doing a screenshot.

I think you're getting something like this?

You need to set up a material to pipe the Vertex Color Layer to the material diffuse colour. Right now you are rendering the object with the default material, which doesn't know anything about the Vertex Color layer. The .ply importer doesn't assign a material to your object.

Blender Internal materials.

# assuming there is a material assigned to the object.
obj.data.materials[0].use_vertex_color_paint = True

else it's something like

obj = bpy.data.objects['a']
mat = bpy.data.materials.new('material_1')
obj.active_material = mat
mat.use_vertex_color_paint = True

maybe stick some ambient occlusion on it:

bpy.data.worlds["World"].light_settings.use_ambient_occlusion = True

For cycles materials

via the UI it's pretty easy

Which makes a node setup like this:

If you wanted to script that, that's another matter.

Your script adjusted (expects Blender Internal)

import os
import bpy
import sys
from math import pi

# filename = 'web.ply'
# in_dir = os.path.join('J:\\', 'aa')
filename = 'a.ply'
in_dir = "/home/zeffii/Desktop"
item = os.path.join(in_dir, filename)
out_dir = os.path.join(in_dir, 'out')
os.makedirs(out_dir, exist_ok=True)

bpy.ops.object.delete()
bpy.ops.import_mesh.ply(filepath=item)
bpy.ops.object.lamp_add(
    type='SUN', radius=100,
    view_align=False, location=(0, 0, 0),
    layers=tuple(i == 0 for i in range(20))
)
bpy.ops.object.select_all(action='DESELECT')

for ob in bpy.data.objects:
    print(ob.type, ob.name)
    if ob.type == 'MESH':
        bpy.context.scene.objects.active = ob
        ob.select = True
        mat = bpy.data.materials.new('material_1')
        ob.active_material = mat
        mat.use_vertex_color_paint = True
    elif ob.type == 'CAMERA':
        ob.data.clip_end = 1000000
        ob.data.clip_start = 0.01
        ob.select = False
    else:
        ob.select = False

bpy.ops.transform.rotate(value=pi / 2, axis=(True, False, False))
scn = bpy.context.scene
scn.render.resolution_x = 692
scn.render.resolution_y = 900
scn.render.alpha_mode = 'TRANSPARENT'
bpy.data.worlds["World"].light_settings.use_ambient_occlusion = True

for area in bpy.context.screen.areas:
    if area.type == 'VIEW_3D':
        ctx = bpy.context.copy()
        ctx['area'] = area
        ctx['region'] = area.regions[-1]
        bpy.ops.view3d.view_selected(ctx)
        bpy.ops.view3d.camera_to_view_selected(ctx)

scn.render.image_settings.file_format = 'PNG'
scn.render.image_settings.quality = 100
scn.render.filepath = os.path.join(out_dir, filename + '-preview.jpg')
bpy.ops.render.render(write_still=True)

outputs this:


How to fix bad moving parts? I have bad moving parts in posemode.Take a look at the picture,when in pose mode the panty is not moving with body.all the meshes are perfect but both thighs bones are not working good
here is a link http://sta.sh/01frq6ke1cns

You have to select the bone you want the panties to be parented to then go to Weight paint mode ((shortcut) CtrlTab in object mode) and weight paint them.

See if it works now: http://www.filedropper.com/kok2


Trying to exact copy object "A" location on "x" axis with object "B" following a curve. Both objects need to have matching "x" #'s in the pictures (frames 1, 20, 50, 80, 100), I basically need the red cube and green ball to work as they do, but having the ball as the parent, not child (as shown in suzanne and the cone scenario). The Green Ball (child) and Red Cube (parent) have matching X-axis parameters at all times as they move from left to right. The Blue Cone (child) follows Suzanne (parent), but falls behind and then catches up toward the end of the curve. Both the cube and cone have "clamp-to" constraints on the curves. Any ideas would be great!
[![Frames 1, 20, 50, 80, 100][2]][2]

If you convert the curve into a mesh, then add the shrinkwrap modifier to the cone to follow the mesh, AND add a driver to the x axis of the cone to copy the x axis of "var" (which is the x axis location of Suzanne). The copy location modifier on the cone will not work.


Cycle Backface culling didn't work I will put some screenshot to demonstrate the problem

The backface culling didn't work I put on the option in the menu I have create the material, everything work when I am in the material viewport but when I hit Shift+Z and when I do the render the backface cull don't work

Have I forgot somehing ?enter image description here

In Blender 2.79:
For your backface cull object, go to Object settings and at least disable shadow:

This material node setup is all you need for pure black:

Both shift-Z and F12 render work:

In Blender 2.80 (as of February 27, 2019):
Use the same material node setup as shown above for 2.79. Then go to Material tab and change Blend Mode to Alpha Clip (or something similar):

Cheers!


Toggle orthographic views opposite sides How to ...
    ... toggle views with the opposite 3d space viewing side ?

e.g.

press key for front view and press again for back view

An half solution is to reuse the same hot key.

This method has the benefit of quickly reviewing the front and back side. You can keep the hot key pressed to see one side and press shift to see the other side and release shift to go back to the other view.
Another half solution might be to assign double click (possible with keyboard key) to go to the complementary side view.

When these half solutions work fine the operation still seems a bit complicated.

It is script chenge view to the opposite

import bpy
from bpy_extras import view3d_utils
from mathutils import Vector

def getView(self, context, event):
    region = context.region
    rv3d = context.region_data
    #coord = event.mouse_region_x, event.mouse_region_y
    #view_vector = view3d_utils.region_2d_to_vector_3d(region, rv3d, coord)
    return rv3d.view_rotation * Vector((0.0, 0.0, -1.0))

def findView(self, context, event):
    vector = getView(self, context, event)
    if vector == Vector((0.0, 1.0, 0.0)):
        bpy.ops.view3d.viewnumpad(type='BACK', align_active=False)
    elif vector == Vector((0.0, -1.0, 0.0)):
        bpy.ops.view3d.viewnumpad(type='FRONT', align_active=False)
    elif vector == Vector((1.0, 0.0, 0.0)):
        bpy.ops.view3d.viewnumpad(type='RIGHT', align_active=False)
    elif vector == Vector((-1.0, 0.0, 0.0)):
        bpy.ops.view3d.viewnumpad(type='LEFT', align_active=False)
    elif vector == Vector((0.0, 0.0, 1.0)):
        bpy.ops.view3d.viewnumpad(type='TOP', align_active=False)
    elif vector == Vector((0.0, 0.0, -1.0)):
        bpy.ops.view3d.viewnumpad(type='BOTTOM', align_active=False)

class ModalOperator(bpy.types.Operator):
    """swich view to opposite"""
    bl_idname = "object.modal_operator"
    bl_label = "Simple Modal Operator"

    def invoke(self, context, event):
        findView(self, context, event)
        return {'FINISHED'}

def register():
    bpy.utils.register_class(ModalOperator)

def unregister():
    bpy.utils.unregister_class(ModalOperator)

if __name__ == "__main__":
    register()


Blender not responding while running my script When running my script, it can take up to a few hours depending on how detailed my object is.

While blender is running my script, blender changes its status "no response" (not sure if it's the correct translated word, since I only know the german term for it which is "Keine Rückmeldung") meaning I cannot do or click anything on blender while it's running.

So my question is, is there a way to have a remaining-process-time-ish-pop-up or just a script-is-running-do-not-turn-off-blender-pop-up?

Short answer: No
See: Strange errors using ‘threading’ module

Python scripts run 'blocking', Blender will wait until finsihed. It isn't thread-safe to run python in parallel. You may be able to get around the issues with Blender crashing with python running own threads using a modal operator with timer: Blender UI Multithreading Progressbar. Also consider if a modal operator running the background is suitable for your use case (let it return {'PASS_THROUGH'}).

If your scripts run for hours, you should also investigate why they are so slow. See here what hurts performance: Python performance with Blender operators


correct horizon in 360 rectilinear video I recently got a 360 camera (samsung gear 360) with 2 fisheye lenses, wich are stitched together pretty good in the propriatary Samsung video editor to rectiliniar video. What does not work is a straight horizon :( i know adobe premiere can fix this called roll pan tilt of a 360 video, but i cant afford that, cause student + closed source windows only. So is there a way to correct this in Blender? i've used blender before to cut videos and that works pretty good, but i don't have any idea on this. I know similar things have been asked before, but those answers are over 2 years old and don't quite fit my use case.

tl:dr correct horizon in 360 video to be orthogonal to player

thx in advance

I think that you would have to wrap the rectilinear image onto a world texture using emission, then change orientation with the Mapping node. Use Cycles and reduce samples to 1 for speed. Cycles supports rectilinear rendering. I have tried this before but not rotation around x axis only z.


Procedural polka dot pattern with cycles I would like to generate a polka dot pattern using material nodes.
In the meantime I found this script which seems to achieve exactly what I want.

However, when I create a script node, link to the script internally and pipe the color output to a diffuse shader, my object is rendered black.
Has something changed in Blender preventing this to work? Because I get no errors whatsoever.

OSL is nice but does not run on GPU which limits performance. The Polka pattern is not that hard to construct procedurally using nodes:

Start with a simple dot - a spherical gradient with Color Ramp:

With the ColorRamp you can control the size of the dot.

Next create tiling for procedural textures, but staggered. Extra is a Mapping node to control the size of the whole pattern:

That's it. You can also map it with Cylindrical or Spherical projection.


can I render some elements the way they look in material preview and how to do it? So I have a a scene and I like some elements displayed in material tab so I want to render those this way. I d like to know how to do it for Cycles or Evee both

Edit: I need it for video

First, you can do it in the 3D Viewport only. Find a View menu, and click the Viewport Render Animation. It will render the animation right from the viewport, using EEVEE if in solid or material preview mode. If you disable screen overlays, you can easily get nice renders in EEVEE this way, however, this is limited and inaccurate (not enough screen samples will be used, and softshadows can be blurry and flickering, among other limitations).

Here is the place where you can find View menu:

And then, find this menu command:


Bool tool brush question After using bool tool,brush boolean difference,
how to make brush object stay for another difference bool?

Now, when I apply brush boolean difference, brush object is gone.

If you make the brush object active after Difference brush was added and apply it only for the brush it will remain undeleted, just its Maximum Draw Type will be set to Bounds (it will return to Textured once Difference brush is removed from the object). However the final effect of the brush will be applied to the canvas.


How can I animate a vertex translation of a triangular mesh? I have a triangular mesh in my viewport and I used this Python script to move a single vertex of the mesh (Do You know better methods? I am new to Blender and Python).
import bpy

obj = bpy.context.object

edge = obj.data.edges[0] #An edge, the first one

vIndex1 = edge.vertices[0] #Get the indices of the vertices of this edge
vIndex2 = edge.vertices[1]

v1 = obj.data.vertices[vIndex1] #Get the corresponding vertices
v2 = obj.data.vertices[vIndex2]

vCoord1 = v1.co #Get their coordinates
vCoord2 = v2.co

edgeVector = vCoord2 - vCoord1 #The vector formed by these two vertices

edgeVector.normalize() #So that it has 1 unit length

distance = 0.5 #Say we want to move v2 of this distance of 0.5 units

v2.co += edgeVector * distance #Translate the vertex

My doubt is: how can I create the animation of this translation using scripts?
This is the code to create a triangular mesh:
# Create a triangle mesh
import bpy

# Initialize our vertices
vert=[(0,0,0),(10,0,0),(5,10,0)]

# Add face
face=[(0,1,2)]

# Create mesh and related object
my_mesh=bpy.data.meshes.new("Triangle")
my_obj=bpy.data.objects.new("Triangle",my_mesh)

# Set object location in 3D space
my_obj.location = bpy.context.scene.cursor.location

# make collection
new_collection = bpy.data.collections.new('new_collection')
bpy.context.scene.collection.children.link(new_collection)

# Link object to the scene collection
new_collection.objects.link(my_obj)

# Create object using blender function
my_mesh.from_pydata(vert,[],face)
my_mesh.update(calc_edges=True)

Scripting blenders animation system.
Back in the old days one of the common methods to animate a mesh was via a hook.
Similarly to How to transform a mesh with many objects? here is code to add and assign a hook empty to each vertex of the object named "Triangle" in the scene.
Setup script: add hooks
import bpy

context = bpy.context
scene = context.scene
tri = scene.objects.get("Triangle")
if tri:
    me = tri.data
    for v in me.vertices:
        name = f"Vert_{v.index}"
        bpy.ops.object.empty_add(
                location=tri.matrix_world @ v.co
                )
        mt = context.object
        mt.name = name
        hm = tri.modifiers.new(
                name=name,
                type='HOOK',
                )
        hm.object = mt
        hm.vertex_indices_set([v.index])

To move any vert simply animate the associated hook.
To animate.
Each hook is a proxy for its associated vert in global space.
Demo script, at each 50 frame interval keyframe the location of vertex 2's hook such that it is 25% further from vertex 2 moving along the direction of edge (v1, v2).
import bpy
context = bpy.context

ob = context.object # Hooked object

v1, v2, v3 = [m.object for m in ob.modifiers
        if m.type == 'HOOK' and m.object]
context.scene.frame_set(1)
for frame in range(1, 250, 58):
    v2.keyframe_insert("location", frame=frame)
    v2.location += 0.25 * (v2.location - v1.location)

removing the hooks and / or the hook modifiers returns the triangle back to its original geometry.


Cycles / CUDA Error: Out of Memory I've been struggling a little with Cycles and my GeForce GTX 750 graphic card. Most of the time it works well, but when I try to work with scenes that have custom shaders (like a skin shader with multiple textures, including for displacement), I get an error, both on the viewport and at rendering:

  Cancel | CUDA error: Out of memory in cuLaunchKernel(cuPathTrace, xblocks, yblocks, 1, xthreads, ythreads, 1, 0, 0, args, 0)

Or something like that. Here's a screenshot so you can check it out:

I'm using a PC and Windows 7, with 8Gb of RAM. I can't render this scene with GPU, but using CPU, it renders ok.

My question is: What is causing this issue? I have the latest drivers installed for my graphic card, so I have no idea what this is.

The short answer is that SSS on the GPU eats up a lot of memory, so much so that it is recommended to have more than 1 GB of memory on for your GPU. This was mentioned in one of the videos from the Blender Conference (unfortunately I can't remember which one). Updating your drivers won't really help as that can't add more memory, so for now you are stuck with having to render on the CPU. If you have multiple objects that have SSS shaders on them then you could try just rendering one at a time and then compositing them back together.


Wrapping Landscape to a Sphere I am currently working on a research project where we are making full sized models of Mars and the Moon. I am looking for the best way to wrap a landscape (preferably given through a height map) around a sphere. The user cegaton answered this in a pretty general way as seen here:
(How can I project an object to a sphere) but I was wondering if anyone could provide a more step by step instruction process for I am a new user.

Thank you all very much.

This is a really simple task.
If you have an equirectangular height map, just use the Displacement modifier using the texture as input on a high-resolution sphere.


How to strip files from a .blend I am new and following a tutorial. The teacher links his final .blend file that I downloaded, but he uses a few backgrounds/videos etc that I need to strip out so I can use the same for my personal copy. How can I achieve that?

You can pull from another .blend with File > Append.


Issue with certain mesh vertecies stretching away from bone physics chain So i have these two loops that attach to the head of my low poly model

but i found out that when I rotated the head certain vertices on the head mesh would stretch away from the bones. I thought that I could just leave it be since it wasn't that noticeable but I later found out that moving the head around from the origin of the "rope" armature  causes the same issue to a more noticeable extent.

The vertices affected with the problem stretch in the direction of the head being transformed, they act as if they are where they would be if the transformation value was doubled. I'm guessing there's something wrong with the mesh itself at these affected vertices but I am unsure of any way to identify what is wrong with them specifically.

I followed this tutorial for hair physics https://www.youtube.com/watch?v=02YYfXC7H8U , it's a string of rigid bodies connected by empties.

modifier stack of head mesh:

It looks like you are getting some of the deformation applied twice.
In this case it appears to be a mix between parenting and multiple armatures.

The first thing to do is to check the "Multi Modifier" checkbox on any armature modifiers after the first.

If this doesn't work, you need to use the vertex group field on the armature modifier to make sure each vertex is only influenced by a single armature modifier.


Camera not visible after changing units to mm in Blender I changed SI units to mm and set the scale to 1,1,1. Now my camera is not visible or it is too small. Need help!

Select the camera object in the object list in the top right corner. Then press the forward slash key "/" to isolate the camera. This will hide everything but the camera and zoom in/center the viewport onto the camera.

From there, I'm sure you can figure out how to rescale and reposition the camera to fit the scene.

Changing the units and unit scale should not affect any of your models...I'm curious as to why that happened.


Print to Info or grey out a button if no object is selected - Python script How would you print to the info if no object is selected (no active object), or grey out the buttons for a script that is operating on a mesh object? I understand you could run a
self.report({'INFO'}, 'No Object Selected!')

in a execute function, but I already have an execute function for my Operator which is running fine when an object is selected. Basically I either need a grayed out button when no object is selected, or an error report telling the user to select an object first. I believe this might be possible with a Poll, but I don't know how to write it to check for an active object or not and print error to info, etc.

The poll function of your operator is suitable for this check indeed.
Just let it check whether an object is selected/active in the current context and return a boolean:
import bpy

class HelloObjectOperator(bpy.types.Operator):
    bl_idname = "obj.hello"
    bl_label = "Minimal Object Operator"

    @classmethod
    def poll(cls, context):
        return context.object is not None

    def execute(self, context):
        print("Hello", context.object.name)
        return {'FINISHED'}

bpy.utils.register_class(HelloObjectOperator)

When adding your operator in a panel somewhere:
layout.operator("obj.hello")

The button will automatically grey out when no object is active.


Text fractured with cell fracture add-on doesn't resemble text object on first layer I'm wanting to use the cell fracture add-on with text converted to mesh, however I'm finding that when I run the add-on, what is generated in the second layer is not what I am expecting, meaning it does not resemble the text object on layer one.. When I run the add-on with a uv-sphere (as an example), I will have a fractured sphere that correctly resembles the object on layer one. Here's a couple pictures after running cell fracture.Both with the default settings. What might I be doing wrong outside of the default settings that could fix this? Or does text not work well with cell fracture?

.

Cell Fracture Preparation

Converted extruded text to Mesh.

Edit Mode.  Select All Vertices. Vertex remove doubles.

Object Mode. Add a Remesh Modifer to prepare your mesh for Cell Fracture.  Apply.

Now Begin Cell Fracture.

Warning

The text format conversion to mesh does [not] guarantee a conversion appropriate for cell fracture.


RGB Curves Displacement Symmetry I'm new to vector displacement. I'm trying to get a symmetric displacement through RGB Curves but I can't get it to work. I'm trying to get a guitar shape.
This is my setup so far. As you can see, I achieved symmetry by duplicating the RGB curve and mixing them but utterly broke the mesh doing so.
Is there a better way to acheve what I'm trying to do ?
Thanks in advance
Edit:
Added a bigger node tree picture

Because of the rgb curves the mesh is collapsing on itself. The solution I found was to shift the curves left and right with respectively an add and a subtract node.


operator_enum of object.mesh_add and object.empty_add is displayed unexpected i'm writing an addon, that's simplifying the ui of blender dynamically for mesh-editing only purposes. So i want to simpify the add-menu of the 3d-view. But there i've the Problem, that if i uses this code

layout.operator_enum("object.mesh_add", "type") #new_line
layout.separator() #new_line
layout.operator_enum("object.empty_add", "type") #new_line

it looks like shown in this image:

I'm getting the same result if i'm writing an new menu-object or if i'm replacing code of the original menu-object. I'm using blender 2.76b of the ubuntu repositories (16.04).

Did i do something wrong or is this a bug i've to solve by a few of this lines:

layout.operator("object.<...>_add", icon='<...>', text="<...>").type = "<...>"

thanks.

I've found the solution:

The API has been changed (Code from /usr/share/blender/scripts/startup/bl_ui/space_view3d.py):

class INFO_MT_mesh_add(Menu):
    bl_idname = "INFO_MT_mesh_add"
    bl_label = "Mesh"

    def draw(self, context):
        from .space_view3d_toolbar import VIEW3D_PT_tools_add_object

        layout = self.layout

        layout.operator_context = 'INVOKE_REGION_WIN'

        VIEW3D_PT_tools_add_object.draw_add_mesh(layout)

I was misleaded by this comment in INFO_MT_add:

#layout.operator_menu_enum("object.mesh_add", "type", text="Mesh", icon='OUTLINER_OB_MESH')

This code doesn't work anymore!


How to export fluid animation 100% prebaked and import to UE4 I want to have a object lift out of water and have the water drop(drips) from the object, and doesn't need to be interact with, so it may be 100% pre-baked.
I made the animation in blender, but I can't seem to correctly export the fluid animation to UE4.8.
steps I did:

(Blender 2.74) make simple fluid simulation and bake it (using the Bake button in the Fluid domain Physics tab)
(maybe I need to bake it another way after that?)

(Blender 2.74) Export it to FBX, well here are a lot of options, first im not sure wich version to use FBX 7.4 Binary or 6.1 ASCII Mainly I select version 7.4 and enable Apply Modifiers, Baked Animation, NLA Strips and All actions. (I tried many different options)

(UE4.8) Import FBX, and enable Import morph targets, import animations, import local transform. same goes here I tried a lot of different options.
I hope someone can help me with this and put me in the right direction.

Some time ago I actually found a way to achieve this.

In this video you will learn how to export .abc file from Blender properly, and then you can use this add-on to simply import an .abc file into Unity.

Though the document is in Japanese, I think it's easy to follow.

By following these steps, you can get a nice animation outcome, just as in Blender.


CADMapper DXF into Blender 2.79 I'm attempting to import .DXF files into Blender that were created via CadMapper. I have the import/export add-ons, however when I import the file I get a host of error messages and can not see the file/render. I'm assuming there are specific import settings I need to configure prior to import, but any help would be much appreciated!!

The Blender DXF importer does not work well for 3d objects. I would suggest that you either download a sketchup file and convert it into a format that Blender can import or alternatively, use the Blender-OSM addon. Info should be exactly the same as Cadmapper also uses OSM data.


Reset object rotation My object has been rotated randomly for some reason on all axis. When I import it into Unity the rotation still applies. How can I reset it so it's the right way up?

The rotation which was done in Edit mode can't be reset as it would be possible with rotation in Object mode. Depending on the case, it's possible to use workaround.

Create an empty. While still in Object mode, enable Snap During Transform and choose Snap to Face as type of element. Enable Align Rotation With the Snapping Target button.

Grab empty, hovering the mouse over faces which should be rotated along world axes. I.e. in case of building this will be faces representing the floor.

Once empty is snapped, it gained new rotation values. Parent object to the empty with Ctrl+P.

Select empty and clear its rotation transforms (Alt+R). Object will follow changed rotation and should become aligned along world axes (or at least roughly aligned).

Clear Parent with (Alt+P) by selecting Clear and Keep Transformation.

Select empty, then delete with X.


I can't find the modify option when i select my model i dont get a modifier thing to appear, i am very new to this. what am I doing wrong? (picture shows what im seeing in properties with my model selected)

When importing a model, it's not automatically set as the active object, though it may appear as though it is, by the outlines surrounding it. You can have several selected objects, but only the last selected one is active. Right click on the object, to select it and set it as the active object. Several new tabs should appear in the properties window. Click the one that looks like a wrench, and you should see the option to add modifiers.


How to achieve animated handwriting with variable thickness? There's a nice tutorial here showing how to get such an effect by tracing a real text object and creating a cruve from it.
https://www.youtube.com/watch?v=QUVUR9jupMY

The problem is this makes all the text lines be the same thickness which is unnatural for handwriting.
There's a trick mentioned in the tutorial which is having a plane behind the text curve and moving the sections of the curve you don't want to see behind the plane which could also be used to make same section of the curve less thick but that would take very long to prepare. Is there a less time consuming way to do it?

You can control the thickness of a curve's bevel by changing the radius of a particular segment:

To get something like this:

Examlple file:

Be aware that the tools to create and manipulate curves in blender are not as responsive and sofisticated as other programs out there, so to create complex curves like this, it might be easier to work in Inkscape, Illustrator or other vector graphics program and export the file in SGV format and import it into blender.


Where these white spots in the preview image of the shader come from? The preview image of the shader has some white dots. Is this due to e.g. uncoloured vertices?

This is only a preview for the material, and the white dots are reflection render.

Don't worry about it.


Is every frame of a animation stored in RAM I am currently rendering a animation and it will take a long time but before I let it run for hrs I want to know if every frame of the animation is stored in RAM because my PC only has 2 GB and I don't want blender to stop half way through and have to start again. If this is a issue is there a way to render part of a animation and do the rest later?

No, they're not stored in RAM. For image sequence output, each frame rendered will be immediately written to the disk. Even video output using FFMPEG directly writes to the disk by chunks.

I've tried rendering CG animation directly to video (not recommended) for hours, and there's no sign of increasing memory usage over time.


Extruding a form along a curve + rotating it Is there a way to control the rotation of the extruded mesh along the curve?

To show what I want to do:

And this is what I got so far

Don't worry about the overall proportions and the mat (still on it) But my Problem is that I can't control the rotation of the object along the curve.

I tried to apply the modifiers and just rotate parts of the model by hand, but that leads to certain issues in the edgeflow and I can imagine that there is a much easier and cleaner solution.

To rotate the vertice of a bezier curve: ctrl T, you can also see and change the Tilt value in the 3D properties panel (activated with N) on the  right of the 3D View. alt T to come back to its previous value.


Quad-only topology at the edge of a chamfer Is there a better way to recreate this shape using only quads?

Thanks

Add a vertex at the middle of the triangle. You will need an extra edge loop at each of the horizontal and vertical edges.


How to simulate engines spraying a fluid? You know an aircraft engine? The gigantic fans on the sides of the aeroplane? Well, there will be seven of those in a circle facing to where the powder comes out and it will spray a liquid onto it.

How should I attempt this, please give examples!

Many thanks

Particles:

For the fluid being blown by a fan/turbine, you could try a particle system.
For a really thin fluid/mist, simulating it as a bunch of spheres is probably overkill.

Instead you could try using textured planes (or Billboards):

Add a emitter plane and rotate it 90 so it is standing on its edge:

Add a Particle system to the emitter plane in Properties > Particles.

Blender Internal:

For BI you can use Billboard particles (these don't work in cycles):

Cycles:

For cycles you will need to use a slightly different technique to render billboard objects:

Set the particles to use an object for rendering in Particles > Render > Object.
Add another plane and add a Track To constraint to make it track to the camera (Select the plane and then the camera, then press CtrlT> Track To constraint):

Set the To and Up settings of the constraint in (with the plane active) Properties > Constraints so that the plane faces the camera:

With the emitter plane active, set the Dupli Object to the plane with the constraint and enable Rotation so that the particles will use the rotation defined by the constraint:

Lower the influence of the scene gravity in Particles > Field Weights > Gravity:

Add a Wind force field (ShiftA> Add > Force field > Wind) and rotate it 90 degrees so it is parallel to the emitter plane:

You may want to tweak the strength in Properties > Physics.
Add a Vortex force field and rotate it 90 like the wind force:

Smoke:

If the fluid is really thin, you may want to try a Smoke Simulation.

Note that until Cycles has volumetrics (planned for 2.7) you will not be able to render the smoke in Cycles.


Can I adjust automatically lighting / colour leveling for all frames? I would like to know how to adjust lighting and colour to match each frame level and do not know if this is possible in blender or if I will have to learn and use something like Open-ColourIO.

If I have images as planes projected onto geometry such as mountains or buildings, the images colour levels will very likely all be different, from different cameras etc.

So, how can I balance footage with many frames, and images, to a balanced averaged level for contrast, colour etc, as well as have the image from grease pencil and the 3d scene/objects, have similar levels?

Is this possible, or do I have to do this in another way, and how would you do it if it is not possible, thanks.

The answer given below is probably correct, but it is too complicated for me to understand or probably do.  I assume this task is too difficult at present for an "average low level blender user" to understand, and will probably just do what I can unless another post appears. Thanks

It's a great question, and the "best answer" is a little more complicated than you probably want, as well as depends on your sources of footage.

You are projecting emissions, represented by your RGB code values. This means a few useful things:

Your RGB lights must be aligned to whatever colour space you are using. Typically around these parts that means your RGB lights must be BT.709 with a D65 colour when R=G=B. That's basically scene linear sRGB in other terms.
If you have the source camera encodes, you can convert the "raw" camera encode to a linear 16 bit TIFF with BT.709 lights. This is ideal.
If you don't have the source camera encodes, it's a bit sloppy. You could do a little OCIO magic and make a transform that treats the aesthetic contrast JPEG or whatever as Filmic + Look, and inverts it as best as it can. That will be wrong, but less wrong than using the sRGB transfer function.
If you are using footage, it's going to be either a log encoded footage properly transformed to BT.709 scene linear, or the second hackish case.

Once everything is in the scene referred domain, it is simply a matter of balancing your emissions to a ground truth. This is tricky, but not nearly as tricky as trying to do it without considering 1-4 above.

Hope this helps. If you have more information, post it, and I'll do my best to help you along further if I can.


How to remove the upper and lower checked box out of the render window I'm trying to understand how to remove the upper and lower checked box out of the render window. I tried to adjust several parameters,but I did not succeed...

The aspect ratio in Render>>Dimensions must be X: 1.000 and Y: 1.000

See the image below.

Good luck.


My Blender has no Header When I opened Blender after installing them, I felt that something was wrong.
then I realized that the awkwardness came from how "empty" it was(See the picture below).
Does anyone know how to fix it and/or why it happend?

 As you can see, my Blender has no window, whats so ever.

While I have no immediate answer, here is how you can find out the cause of the problem:

Open a command line shell.
Navigate to where your Blender is installed.
On windows you can Shift RMB in the blender program folder (without any file selected) in Windows Explorer and select Open command window here.
On linux this step is only necessary if you have multiple version of blender installed, otherwise you can just run blender.
Call blender from the shell. On windows, type blender.exe. On linux, type  ./blender.

Now Blender starts and leaves messages in the commandline shell. You will probably see one or more error messages which may lead you to the cause of the problem.

You can try to force Blender to use factory-settings by providing the commandline option as follows:

blender.exe --factory-startup

Some possible causes are:

a broken Addon
An installation error like: "out of disk space", "no write permissions on disk", etc.
Wrong Python version in Path (i am not sure if Blender gets trapped by that)


How do I duplicate an edge? I am trying to follow along with this tutorial. I had to put its speed to 0.25 to be able to view it.
In this tutorial it is shown how the author selects an edge and then duplicates it and "scales" it while dragging.
I have taken some screenshots:

How does he do it, and what is this operation called?
Thank you!

It's a bevel, shortcut Ctrl+B.  They then delete the resulting face to leave a gap between the planes.


How can I use vertex colors as an input in my material? I want to use vertex colors as a mix factor in my material. However when I chose Add->Input the option Vertex Colors doesn't show up. Why can I not access the vertex colors data? I want to avoid using any python scripts or any workarounds with the Attribute node if possible.
Using Blender 2.8.

Even easier than the suggestiong of @Robert Gützkopf: Enable the Node Wrangler Addon. It will put that option exactly where you pointed out it's missing.


How the speed it up a portion of a video, and also all of it? I just started yesterday with Blender, so this is maybe a basic question. I have already seen how to speed it a whole video using "effect strip - speed control". The problem I am trying is when I try to speed it up only a portion of a video, or when trying to speed up a whole video which has different portions. At the moment my project looks like this

As you can see my video has five sequences. Each sequence uses 2 videos which I am putting side to side (one uses 50% of the screen left, the other 50% right). That's why I have those transforms, and then the alpha over, and then the text just to add some caption. I don't know if there is a better way to do this. This video runs at real-time, and it produces what I expected to get. The problem is when I try to speed it up, like by a factor of 4.

Now here is how I try to speed up the whole video:

I chose individually each alpha overlay and added the speed control. Then I moved on top the text, and when I click render animation, it looks fine, but I have some problems with the output video. Using the workflow from above, it produces a video where each segment has everything sped up in the first 15s, and then the following 45s are a static image of the last frame.

I also tried lowering the total frames of the video from 9000 to 2250 (that should be the frames when it is speed x4), but that basically produces a video of 15s first video speed up, then 45s static image, then 15s of the following video, and then it stops.

So my problem is that I don't really know how to speed it parts of a video, or a video as a whole which is composed by parts. When dealing with only 1 video, using speed control I know how to do it. But when working with parts, I dont.

The video gets sped up as you see but it does not affect the length of the strip.  I do not know a way to automate the process but you need to shrink the length of each strip that you are speeding up.  In your case, you are speeding it up by a factor of 4 so you need to make each strip 1/4 of the original length.

Then you need to move all the strips together so there is no space between them.

I did a search on Youtube using this -  blender vse video speed up

and found this video:  https://www.youtube.com/watch?v=NrX1sK_ZQqs

I hope that helps.


Creating Textures for Sold Colour Models I'm trying to create models in the 'low poly' style of the following image.

What is the best way of texturing them?  My main questions are as follows.

To get a similar matt colour as shown in the example, can I just use a flat colour, or do I also need some kind of material?

Are flat colours immune to stretching and scaling issues?  Or would I have to handle it the same as a normal texture.

Does resolution matter when using flat colours, or would it look the same even if the texture was literally one pixel for each colour?

Am I better of doing this by creating the texture in a seperate program, or using something like vertex paint within Blender?

I'm only just getting into texturing, so simple answers appreciated.  Thanks in advance.

As far as I can tell there are no textures in that image, just models with different diffuse colors asigned to the faces. This will help you out:

Add different materials to different parts of a mesh?

Also, to answer your questions, flat colors do not get affected by scaling, they don't use resolution, and you don't need anything more than blender to create the material.


camera track - was good, but breaks after editing an object First, I'm a newb to tracking.

That said, I tracked my scene with a .3 solve rate.
I dropped in a cube and rendered out a short animation... looked great.

I readjusted the position of my cube... nothing more... and now my track is broken.

All tracking points were locked, I did not resolve the scene... just suddenly my object is wobbling all over in the render.

Going back to my LOCKED tracking points, they are no longer staying put.

Anyone else seen this?  Has happened on 2 machines, same reproduction steps.
This last one was first time I tried locking the tracking points.

Memory issue?

Thanks...

Blend file

Original footage (40mb

This looks like a bug, but here's a workaround:

As you open the file don't try to playback the scene or move a frame within the timeline. Instead switch to the Motion Tracking preset and in the the movieclip editor select your video clip and press P to cache or Prefetch the video clip.

On the bottom of the window you'll see a purple line indicating the prefetched frames.

Prefetching will load all of the frames into RAM and that will help you keep the trackers in place. The issue has to do with the video being in a delivery format (mts) in which the video is encoded using I, B, and P frames, which means that the information of a particular frame is not complete in every frame but is reconstructed using information from some preceding and subsequent frames. It's been optimized for playback using prediction vectors and crap like that. The sort story is that Blender needs to read the whole stream to have each frame land in the right place. For a more technical explanation read this

NOTE by default blender will only use 1GB of RAM to cache frames. You can change that number depending on the amount of memory on your system. To do that open the User prefences (CtrlAltU) and on the System tab you'll see the options for the prefetch and cache limits.

The other options you have to prevent this issue is to convert your MTS video file into an image sequence or a video file that uses intra-frame compression codec.

As I said this is likely a bug. You can report it.


How do I change the radius for proportional editing WITHOUT PgUp/PgDn? First of all, I'm aware that there's already very similar questions out there, but I've tried the answers and they don't seem to work. My keyboard doesn't have PgUp/PgDn keys, and for some reason scrolling doesn't do anything. I've also tried adjusting it manually using the thing at the bottom of the tool panel, but that doesn't do anything either. Any suggestions?

If you have trouble using the standard keyboard shortcuts you can adjust your settings to suit your keyboard.

In File->User Preferences under the Input tab you will find a group called Transform Modal Map, under which you will find the shortcut settings to adjust proportional influence. You can adjust these to anything that works for you, be sure to Save User Settings so that the changes are available every time you start blender.


Curve Bevel very inconsistent I've ran into a little problem while trying to create a sort of railing - i've created a plane, subdivided it and then deleted only the faces which left me with this.

Next Step was to convert this into a curve to then bevel it and have a railing - but there lies my problem. The Bevel is very inconsistent and all over the place.

Scale is 1,1,1, all transforms are applied and switching to 2D doesn't help - so after gooogling for a while i'm all out of ideas.
Any help would be much appreciated.
Thank you

You could try a different approach, and use a skin modifier on a mesh object for something like this.

In edit mode mark a vertex as root, select a vertex and choose Mark Root in the modifier. Also add a subdivision surface modifier to smooth the result.

You will likely need to scale the skin down some initially, in edit mode do this by selecting all and using ⌃ Ctrl + A to resize.


How do I stop Blender 2.8 from quitting when I close a project? I was working on a throw away project (a tutorial) and decided I wanted to try a different one. I closed the project, said I didn't want to save it, and it closed, but so did Blender. A bunch of macOS utilities do this, but IMHO it's a terrible choice for a major application.

How can I make that stop? I can't find anything in the preferences.

You cannot stop Blender from quitting when you close a project
I'm afraid, it does not work the way you wish it to work. Blender cannot be opened without some file loaded and it can open only one file at a time. If the file is closed, Blender is closed as well. Even when you start Blender for the first time it loads a file - that is the default scene. You can open multiple instances of Blender with different files. Then if you close one, all the other open instances will remain open. This is just how it works.
You can have multiple scenes in a file and they can have completely different settings - they can even use different render engines for example, only one scene in an open file can be active at a time, but you can switch between them without closing the file or the instance of Blender.


Is it possible to execute two functions on a Pie button via an additional key pressed? The mesh hide has two options, hide selected or hide non selected.
So you need two buttons, but could it be possible to simply call the pie menu and then with an addition button pressed lets say RMB execute the other options?

this would be like this:

Shift+Alt+ RMB calls the Pie menu

LMB executes hide selected
MBB executes hide unselected

I've found an answer on this, but it still need some coding

Standard Pie Menu looks like this:

class PieMenuClass(Menu):
    bl_idname = "pie.pie_menu_class"
    bl_label = ""

    def draw(self, context):
        layout = self.layout
        pie = layout.menu_pie()

        pie.operator("mesh.subdivide", text="Subdivide")
        ...

This Pie adds a subdivide operator. Let's say we add more two options - unsubdivide while holding "Shift" and Smooth subdivide with CTRL pressed.

First add register!!! =)  one more class:

class MYSubdivide(Operator):
    bl_idname = "class.my_subdivide"
    bl_label = "Ctrl - unsubdivide, Shift - Smooth"

    def invoke(self,context,event):
        if event.shift:
            bpy.ops.mesh.subdivide(smoothness = 1)
        elif event.alt:
            bpy.ops.mesh.unsubdivide()
        elif event.ctrl:
                bpy.ops.mesh.subdivide_edgering(number_cuts =1)
        else:
            bpy.ops.mesh.subdivide()

        return {'FINISHED'}

First declaration then changed to call this class:

class PieMenuClass(Menu):
    bl_idname = "pie.pie_menu_class"
    bl_label = ""

    def draw(self, context):
        layout = self.layout
        pie = layout.menu_pie()

        pie.operator("class.my_subdivide", text="Subdivide")

The only problem is that after using this method it's impossible for me to use REDO LAST function F6 ==((  steel need a solution.


How to animate objects duplicating? I want to make a progess bar, but the sort that is discrete, I have my base square, now in next frame, I need another duplicate cube to pop into existence, next to it

Proper way would be to keyframe visibility on a bunch of duplicate objects or Dupligroups.

You get the benefit of instancing and reduced memory usage, you can also group multiple objects together and instance through an empty.

If you don't require such complexity, all objects are the same and in a single mesh, then you can get away with simply animating an Array modifier.


How do you differentiate relative and absolute shape keys? My question regards the difference of relative and absolute shape keys.
As it stands, relative keys are great for easy shapes and are measured on 0-1.
Absolute keys are measured in frames and are used for deforming mesh in more complex ways than relative keys. If you want to use relative and absolute shape keys in the model, it has been suggested to use mask modifier and two overlapping shapes to differentiate the shape keys. This leaves a definite sharp line on the edge of masked parts.
Has anyone seen any examples or videos where someone has used the absolute keys?
I'm interested in this topic, but have not found any material so far in the internet.

Relative Shape keys:
With absolute shape keys, the value shown for each shape in the list represents the current weight or influence of that shape in the current Mix.
Absolute Shape Keys:
With absolute shape keys, the value shown for each shape in the list represents the Evaluation Time at which that shape key will be active.


2.91 Python Mirror UV I am trying to use Python to mirror the UVs of my mesh. The UVs get unwrapped just fine but when I run the mirror command it is just a normal bpy.ops.transform command and the object gets mirrored and the UVs do not change. I looked a bit online and it seems that I need to access the UVs through a couple loops, however I was unable to get them to mirror with that approach.
Does anyone know how to mirror the UVs in Python?
Mirror command from the scripting Info window:
bpy.ops.transform.mirror(orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(True, False, False), use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False)

Mirror command from the interface:

Thank you for the help. Instead of working with the UVs in the loops (which is probably the proper way of doing things) I used the below code. It changes the context to allow bpy.ops.transform.mirror to work.
original_area = bpy.context.area.type
bpy.context.view_layer.objects.active = unreal_mesh

bpy.context.area.type = 'IMAGE_EDITOR'
bpy.ops.object.mode_set(mode='EDIT', toggle=False)

bpy.ops.mesh.reveal()
bpy.ops.mesh.select_all(action='SELECT')
#+ select the uvs
bpy.ops.uv.select_all(action='SELECT')

bpy.ops.transform.mirror(orient_type='GLOBAL', orient_matrix=((1, 0, 0), (0, 1, 0), (0, 0, 1)), orient_matrix_type='GLOBAL', constraint_axis=(True, False, False), use_proportional_edit=False, proportional_edit_falloff='SMOOTH', proportional_size=1, use_proportional_connected=False, use_proportional_projected=False)

#+ return to the original mode where the script was run
bpy.context.area.type = original_area
bpy.ops.object.mode_set(mode='OBJECT', toggle=False)


draw_callback_px in specified area Using the Python code below which draws the text and shape shown in these screenshots, I want to clip the graphics outside the red box shown in my second image so it is not drawn.

Goal:

import bpy, blf, bgl, gpu
from gpu_extras.batch import batch_for_shader

class Test_operator(bpy.types.Operator):
    bl_idname = "object.test_operator"
    bl_label = "test"

    def draw_callback_px(self, op, context):
        self.draw_rec(500, 800, 200, 400, (0.2,0.2,0.2,1.0)) # Window A
        self.draw_rec(500, 800, 400, 428, (0.1,0.1,0.1,1.0)) # Title bar B
        font_id = 1
        blf.size(font_id, 53, 72)
        blf.position(font_id, 500, 300, 0)
        blf.draw(font_id, self.text)

    def draw_rec(self, left, right, bottom, top, color):
        self.shader = gpu.shader.from_builtin('2D_UNIFORM_COLOR')
        self.shader.bind()
        self.shader.uniform_float("color", color)

        vert = ((left, bottom), (left, top), (right, top), (right, bottom))

        bgl.glEnable(bgl.GL_BLEND)
        self.batch_panel = batch_for_shader(
            self.shader, 'TRIS', {"pos" : vert},
            indices=((0, 1, 2), (0, 2, 3)))
        self.batch_panel.draw(self.shader)
        bgl.glDisable(bgl.GL_BLEND)

    def modal(self, context, event):
        context.area.tag_redraw()
        if event.type in {"ESC"}:
            bpy.types.SpaceView3D.draw_handler_remove(self._handle, 'WINDOW')
            return {'CANCELLED'}
        return {'RUNNING_MODAL'}

    def invoke(self, context, event):
        self.text = "Hello World"

        args = (self, context)
        self._handle = bpy.types.SpaceView3D.draw_handler_add(
            self.draw_callback_px, args, 'WINDOW', 'POST_PIXEL'
        )
        context.window_manager.modal_handler_add(self)
        return {'RUNNING_MODAL'}

def register():
    bpy.utils.register_class(Test_operator)
def unregister():
    bpy.utils.unregister_class(Test_operator)
if __name__ == "__main__":
    register()

You can use the scissor test.
        bgl.glEnable(bgl.GL_SCISSOR_TEST)
        bgl.glScissor(500, 200, 300, 200)  # adjust to match your red box
        blf.draw(font_id, self.text)
        bgl.glDisable(bgl.GL_SCISSOR_TEST)


If Cycles is Physically Based, Why Doesn't it Calculate Fresnel Automatically? So, supposedly Cycles calculates light bouncing around fairly accurately to life.  If this is the case, and if Fresnel truly is an optical property due to the viewing angle, why doesn't it just happen? Why does there have to be a node for it?

Cycles could have a shader with in-built fresnel, in fact one is being worked on: https://developer.blender.org/D2313

The reason fresnel is a separate node used to mix diffuse/glossy shaders was an intentional design decision to allow more flexibility when putting shaders together. It allows you to mix shaders in any way you need. One problem with this is that a lot of the time you need to combine shaders in the same way. The alternative is an "ubershader" that combines everything in one black box, such as the Principled BSDF shader in that patch link. By adding the Principled BSDF as a shader node you'd have a single node when you needed a general-purpose physically based shader, or you can choose to roll your own shader combinations if you need more control.

The drill down into your core question of "why doesn't it just happen?": you don't just code "do things physically" and BAM, the renderer is realistic. You need to code each step of the rendering process so that it behaves the way real light would. In the case of Cycles shaders, this step is (currently) left to the user.


How do you unselect vertices without a middle mouse button? I know with a mouse, you can press b in edit mode and then box select using the middle mouse button to deselect vertices (or edges, faces, etc.)
How do you do this if you don't have a middle mouse button?

In Blender you really have to have a middle-mouse-button, but if you don't own a 3 button mouse, you can emulate one in the preferences.

Open User Preferences Control+Alt+u.
Switch the the Input tab.
Enable Emulate 3 Button Mouse.

You can now use Alt+Left-Mouse to perform tasks normally done with the middle mouse button.


How can I reveal these groups inside of collections in blender 2.9 I have project that I worked on in blender 2.6/2.7x and now Im decided to switch to blender 2.9 but  when I open that file I'v got some groups which are gread out and dont see them i view port. How can I make them visable again ?

Click this button and you will get dropdown for restriction tools
Click on monitor looking icon.

Now you can see additional icons  for your objects and collections.
Greyed out object should have monitor icon disabled

Enable the icon to make objects/collection visible again.
Now, you may ask what's the difference between Eye icon and Monitor icon visibility.

Visibility controlled by eye icon is bound to current view layer.
which means it does not affect the visibility of object in other view
layer.

Visibility controlled by Monitor icon is global which means if you
disable it in current view layer then object's visibility in all other view layers are disabled.


Screw modifier creating extra faces I'm using Blender 2.83.5 I have a profile that I'm using with the Screw Modifier.  For some reason it's creating extra faces.  How can I fix this so only one face is created?
Profile Below:

Use Screw Modifier:

Extra faces are create somehow:

If I delete a face another one is behind it.

PS:  This is what I was following
https://youtu.be/R8tXe5oCYXg?t=245
Uploaded blend file

There is an extra vertex on the base shapes:


How can I get the "strip input" toolbar in the Movie Clip Editor? Could anyone please help me with this one? I can't see this small plus icon (png file attached).
I just don't have it! And the result is that I don't have this toolbar: STRIP INPUT. I can squize image or video or change dimension, but I would like to change "working area" (Idk if it is a proper name for it, but my image or video has a black area surrounding I can't remove).
I have check all toolbars but still no clue what to do and how to deal with it.

You need to update to 2.82a: https://www.blender.org/download/
In the View Menu you'll find it:

For making the video fit the preview area, use this:


How to add materials_cycles_converter? I'm Trying to add the Cycles Materials Converter but I can't find materials_cycles_converter? What should i do?

I've looked everywhere on my drive, but no luck. Please help, because I can't find properties in blender, either.

The Cycles Material converter addon is part of Blender Add-ons Contrib. The contrib addons are not part of the official blender releases, they are normally included with daily builds and some of the custom builds available at Graphicall.org. The contrib addons are considered still under development or not suitable to be accepted into the official addons for some reason. New addons will normally be found here for some time while being tested before they are included in the official addons.

If you want to install the cycles material converter by itself you can download the single script from blender's git repository by going to this page and clicking view raw file, then download file. Once it has been saved to your computer you can use the install from file... button in the preferences.

You can also download the entire contrib repository using git, by following the instructions on this page, or you can download a snapshot from here. Once this has downloaded (and extracted if you get a snapshot) you should place the contents into a folder called addons_contrib next to the addons folder installed with blender. While you can add them to the addons folder with the other addons, it can be easier to update them if you keep them separate as well as making it easy to identify which addons are official and which belong to contrib.

Also note that the contrib addons are listed under the testing category so you need to select that to see any contrib addons in the addons list.


AddObject Actuator scripting I have set up a camera with a script and logic bricks so that when I use left mouse button it creates an object and places it at the specific click location.

Nevertheless, I encountered an issue with that the first of my created object doesn't care about the lines following cont.activate(Add)and leaves it at the camera location, just as seen in the picture below (the cube and rectangles are other objects, the one I'm calling is the cone).

Why is that ?

You need to take care of the timing.

Within a single frame (over the complete scene):

sensors evaluation
controllers execution
actuators running
physics, render etc.

The code always runs with "controllers execution". This does not mean that all operations have immediate effect.

Activating an actuator, does not make the actuator running at the moment of the call. The actuator gets a signal to activate. The actuator will run within "actuators running". Which is later than your code.

KX_SCA_AddObjectActuator.objectLastCreated provides you a reference to the last created object by that actuator. That can be last frame or any frame before.

Within the first execution of your Python controller the actuator never added a new object. This means you get None. I expect you get an error each time you trigger the controller the first time as None has no "worldPosition" (always have the console window open when you run Python code with the BGE).

There are several ways to solve the timing issue.

A) Two step processing. You store the position and adjust the position of the new object within the next frame. The drawback is, that you can see the unchanged position for a single frame. This can be annoying.

B) Do not activate the actuator, but let it add the object via instantAddObject(). AFTER that call objectLastCreated will return the just created object.

You code could look like that  (supposed to run in script mode):

import bge

controller = bge.logic.getCurrentController()

mouseSensor = controller.sensors["Ray"]
activationSensor = controller.sensors["Clik"]

if activationSensor.positive and
   mouseSensor.positive:
    addActuator = controller.actuators["add"]
    addActuator.instantAddObject()
    addedObject = addActuator.objectLastCreated
    addedObject.worldPosition = mouseSensor.hitPosition


How do I avoid my video input being distorted? I'm trying to edit some video from a fairly old camera. The video is in 1440x1080 resolution, so my file is set up with those dimensions. However, when I import my video with an Image node, it is squished horizontally, until it's nearly a square.

To fix this, I have to import a still frame (or any other image that's 1440x1080) and put it behind using an Alpha Over node, as well as scaling the video input to ~1.33 times its width. Is there a saner way to fix this issue?

Screenshot of my Current Fix:

Many older cameras use rectangular pixels in their CCDs, and will produce distorted images when imported into software using square pixels.
You should be able to correct your rendered output by adjusting the Aspect Ratio values (x=1.33 in your case) in the Render Tab -> Dimensions Panel.


What does the "Absolute" setting in the Math node do? The documentation is a little unclear.

"Always return non-negative value from any operation input 2 between input 1."

https://www.blender.org/manual/render/blender_render/materials/nodes/types/converter.html

I'd expect the node to ignore the second value altogether, and just give you the absolute value of whatever you piped into the left side. But it's not clear how this node deals with two values. Does it ignore the non-piped value? Does it ignore the second value, regardless? Does it give you whichever input is non-negative? How does it handle two inputs? What "operation" is performed between the two inputs?

What does the "Absolute" setting actually do?

The Absolute mode is similar to the mathematics $\left\vert X \right\vert$ operator. Any negative value is turned positive.

The 2nd input on the node is meaningless and has no effect at all (thanks Carlo for checking this out in Blender's source code).

Below is an example that illustrates the mode. The image has values in the interval $[0, 1]$ (black to white). The first math node multiplies everything by $-1$, thus turning the interval to $[-1, 0]$. Everything that equals or is smaller than $0$ is rendered black, so the image turns black.
When you plug this into the absolute node, all negative numbers are turned positive, and the image is displayed again.


VSE not playing in realtime (not caching)? I have some exr sequences in the VSE, but they won't playback at 25fps.
Some parts play fine (random), but then it feels like it is caching again at 6fps or something. No matter how often the loop is running it always gets these hickups.

The 'cache memory limit' is set to 16000, but that doesn't help.
Is there a way to see if/how much of the cache memory is used, or is there anything else I can do about it?

thx

While you're playing your sequence, you should see a little fps counter in one corner of the preview. If it's red and below your frame rate you set beforehand, than your computer can't handle the preview rendering in real time. This can be related to memory, but (at least from my experience) it more likely depend on your CPU.

What you can do to improve the playback, is setting up proxy files. They're typically smaller so playback is easier.


"panelized" procedural material i'm working with a rust procedural material from another tutorial. I need each panel of my mesh to display an instance of the material, rather than having it connect across edges. That is to say, how it would look "as-built" with individual metal panels. How do I specify that in my shader node network?

Here's what worked:
Mark all edges as seams then select all and UV unwrap.


Texture in Render not right I cant figure out what is wrong with my rendering. The texture is fine in viewport but when I render it loses the color.

In your material the texture is used only for the displacement input, so the color is a dull grey with bump effects.

The viewport is telling you the mapping of the texture, not the end result, which is a more complex task.

I added a copy of the image texture to feed Diffuse color shader.

Don't forget to set all color image texture as "color data" and all displacement or Black and white images as "Non color data".


Baking two procedural materials I ended up creating an eyeball from this tutorial, but I don't know how to bake these two materials into one image. Only one material is baked. Tell me how to solve this problem, please
Eyeball

Answer for user Geri. This is the result:

Here you go:
https://youtu.be/9airvjDaVh4
This will work with procedural materials, and eevee as well. You only need cycles for the baking part.
But basically, you need to put the image texture node you want to bake to - that's also selected - in the other materials.


Bounciness in Rigid Body I tried to make up a rigid body simulation (a torus falling onto a plane) and I have tried to modify the bounciness from 0 up to 400, but I didn't observe any difference.
What this parameter is supposed to do and how do I recognize the effect of the parameter ?

The setting controls how much energy the surface removes from a collision. The parameter can vary between 0.0 and 1.0 (you shouldn't set it outside that range) and a setting of 0.0 indicates no bounciness (all energy is removed). Increasing it up to 1.0 allows energy to remain after the collision.
Note that the collision energy is affected by both objects taking part in the collision so if either of the objects is set to 0.0 then no energy remains and there will be no 'bounce'. The Bounciness from both objects can be multiplied together to give a value of bounciness resulting in those objects colliding.
For example, for two objects each with a bounciness of 1.0, the result of a collision will have 1.0 x 1.0 = 1.0 (ie, all) of the energy before the collision. If either is zero then the result will be zero energy of their initial motion after the collision. For in-between values, the same holds - eg, if both have Bounciness of 0.8 then 0.8 x 0.8 = 0.64 of the energy will remain after the collision - ie, a ball would bounce 64% of the way back up from its starting height if it fell onto the surface.
In your case you likely have the other surface set to its default value of 0.0, resulting in no bounce (since anything multiplied by 0.0 is 0.0).


Blender sverchok lofting with array of boxes I found this threat "How do you loft between curves?" and i used that specific combination of nodes to achieve lofting between curves.

But instead of simply plate, I would like to use array of thin boxes (like wooden planks). How can I archive that?

Edit 5.2.2017:

Here is an example. So the selected curves presents the control curves and the grid presents the interpolation between them. And this interpolation should define the path and the curvature of those arrayed boxes. All dimensions (X,Y,Z) should be usable.

I would approach this differently,

First create the curved surface by lofting,
Use modulo to make a masklist to discard the faces that represent the space in-between the planks
Then finally extrude the faces using the Solidify node (via the Normal to turn the faces into "plank" geometry.

use the SV Import / Export panel to import this gist:
https://gist.github.com/2bda764a9f6aa7e9a6aca69d7181bdaa

here the usage of Solidy Node and Delete Loose (the "rest" verts that aren't used)

as a gist: https://gist.github.com/0216592fedb22856d4f3778e4187cec0


How to stop fluid going straight through a .stl imported obstacle? After looking for answers, I have set the resolution up to 100, changed the obstacle initialization to shell and added a Solidify modifier to the obstacle. See below

Concerning your pipe object, you just need to apply location, rotation and scale and it will work. Press Ctrl+A, choose location, repeat shortcuts to choose rotation and scale.


Boolean difference modifier does not remove a part I'm new to Blender and got the following problem.

As stated in multiple threads on this board the functionality of the boolean difference misbehaves.
I want to reach the following result:

Instead I get this:

I also checked and tried the solutions as described in these threads.

(Using difference modifier on two objects doesn't always work)

(Boolean difference modifier merges two object)

But none of these worked as I always get "Removed 0 Vertices" when I use the command "Remove Doubles".

Right now I am using the v2.79 of Blender.
Also the file for this car is uploaded here.

I would really appreciate if someone could help me out on that. Maybe some other people have the same issue...

Apperently the following approach is also working. Thanks to Jerrynos answer I tried another approach.

Instead of taking the boolean modifier onto the car, I took the joined Cylinders and filled in the settings for the modifier as following:


Particle Info Node in a Different Object So to put it simply, I am trying to create a particle system that emits particles, of course, in a stream and I have a smoke simulation set up so that the particles are on fire. The fire changes color as the particles are "alive" longer. Of course with a smoke sim, you give the domain a material, not the flow object.

My problem is that the flow object has the particle system therefore the particle info node for that system can only be used for that object (if I understand how the particle info node works) but I need to use the particle info from the flow object in my domain material.

Is there any way to do this without any weird scripting stuff or something?

I don't know a exacly soution for your question. But there is a way to do something like that... Instead of using the Particle Livetime you can use the heat Attribute, a Math noder and the ColorRamp.

Rename the Attribute "color" in "heat" (or add a blank Attribute node)
Add a Math node, change to multiply
Enter a colorramp
Connect the Colorramp with the color input of Volume Scatter and Volume Absortion.
Play with the value of the Multiply Node and the Positions inside the Colorramp
If you want thicker Smoke increase the Multiply Value of the density
also play with the temperature settings of the Domain, and Flow

If you know a better way, let me know....


Where is the 'holdout' option for collections in 2.8 I want to ask about the holdout option for collections. In view layer menu I only have 2 options - set exclude and clear exclude, but nowhere I can find a holdout option. Maybe someone knows something about whether it was removed or maybe they changed its place?

I've been facing the problem too, the explanation is that holdout is only working with Cycles !


How to batch import Wavefront OBJ files? Is it possible to batch import Wavefront .obj to blender? I'm working on 2.69.
If I select multiple .obj files, only one gets imported. Also if I hit A on file selection window to select all files (.obj and .mtl) I get an error, nothing gets imported. I have to import several hundreds of .obj into the blender file, is this possible?

Unfortunately, this is not possible by default with Blender 2.5x+ it seems. In 2.49, you could hold Shift then press the Import Obj button and it would prompt you to select a directory with the sequence.

In 2.69, you can do the same with a script — it could be converted into a more usable utility but it works.

import os
import bpy

# put the location to the folder where the objs are located here in this fashion
# this line will only work on windows ie C:\objects
path_to_obj_dir = os.path.join('C:\\', 'objects')

# get list of all files in directory
file_list = sorted(os.listdir(path_to_obj_dir))

# get a list of files ending in 'obj'
obj_list = [item for item in file_list if item.endswith('.obj')]

# loop through the strings in obj_list and add the files to the scene
for item in obj_list:
    path_to_file = os.path.join(path_to_obj_dir, item)
    bpy.ops.import_scene.obj(filepath = path_to_file)

For unix machines the direct path should look like:

# location of obj folder
path_to_obj_dir = '/home/user/Desktop/objects/'


Selected meshes vanish when in object mode So, I’m a total noob at Blender, just started learning it last week by using the Blender Guru’s Donut tutorial. During the process I found a problem with my Solidify Modifiers that I managed to fix (a problem with the normals I believe) but in the process I might have broken something. I’ll explain what happens with a New file (I tried reinstalling Blender 2.81, reseting settings and such and it didn’t work) cause it now happens everytime.

When I open a new file I find this:

Aparently nothing, right? But as you may notice, there is in fact a default cube.

When I change from Object to Edit Mode, I can see that it is selected and it looks normal.

And when I deselect it and go back to Object mode it’s back to normal. This also happens with individual selected faces so I guess the problem is with my selections? Also, this only happens in Solid Mode cause in Render Mode it looks as it’s suppose to be.

Does someone knows what may be causing this? I can’t find anything on the subject (Sorry if there is, I just couldn’t find it).

Thanks in advance ^^

Most definitely a glitch, because the only other instance I know of something like  this happening is when a cube I added in POV-ray rendering disappeared in edit mode because a certain script wasn't installed. Try re-opening Blender, and if that doesn't work, then you may have to uninstall Blender then re-install it.


Is there a way to put a copy rotation constraint with an influence higher than 1? I'm making a little animation with some gears. I want that if I rotate the first gear, all the gears rotate with the gain given by the gears.

For doing that I've choose the copy rotation constraint. But in my case, sometime a gear turn one time and the second turn tiwce. With the copy roation I can only put an influence between 0 and 1.

So my question is : Is there a way to put a copy rotation constraint with an influence higher than 1? Or is there an other solution to do what I want?

1.0 is the maximum influence for any given constraint, so setting it beyond 1.0 is impossible.

Using the Transformation constraint, you could easily map any kind of simple transformation from one object to the other. In the following example, the object being constrained will rotate twice the amount of Cube_target's rotation in the Y axis.

Checking Extrapolation will extend the transformation beyond stated range of values.


How do I curve an edge? Bevel not working! can someone help me with curving an edge? I have a giant spiral and want to make it round instead of being made up of straight lines. Bevel does nothing so guessing there must be a way of selecting everything and making the edges rounded. I've added a pic with the yellow line showing how I want the curve to look like and red line how it is now
Cheers, Dan

You can use the LoopTools > Curve tool: Enable the LoopTools addon (available by default in Blender), select 3 vertices of the edge, right click > LoopTools > Curve. Play with the parameters in the Operator box if needed.


How do I iterate over keyframes in python? I'm trying to export animation data, but my bones never get updated from keyframe to keyframe. This is how I iterate over my actions and keyframes:

for action in bpy.data.actions:
    armature.animation_data.action = action
    bpy.ops.screen.frame_jump(0)
    bpy.context.scene.update()
    while {'FINISHED'} == bpy.ops.screen.keyframe_jump():
        bpy.context.scene.update()
        for boneName in bones_index:
            bone = armature.pose.bones[boneName]
            mat = glob_mat * mathutils.Matrix(bone.matrix)

The 'mat' variable is the bone matrix for each bone. Per frame, the 'mat' variable doesn't seem to change. For example, if I only look at the bone "Leg", the leg pose matrix doesn't seem to change keyframe to keyframe. The matrix is the correct matrix for frame 0, and it is different from my base pose. Am I not getting the pose matrices correctly? Or am I not correctly changing the scene? In the blender console, bpy.ops.screen.keyframe_jump() does exactly what I want, so I don't think that's the issue.

On some further investigation, and looking at other threads, I solved my issue by using the following method to update the scene.

bpy.context.scene.frame_set(bpy.context.scene.frame_current)

So now I'm thinking there is a bug in how bpy.ops.screen.keyframe_jump() is implemented. The line I added should theoretically do nothing (ie. setting the current frame to the current frame should be a no op). The strange thing is that my original implementation worked in the interactive console, but not when I put it in a text/export file and run it from there.


Shading artifacts caused by boolean modifier I tried applying a boolean modifier so I could make some holes inside a mesh, but the result was horrible shading. I've tried smooth lighting and an edge split modifier with sharp edges, but still nothing so far. I even added a new knife cut near the ends so it wouldn't be as noticeable. It's really bugging me, please help! Split concave edges just made a bunch of triangles with even worse shading.

Try selecting your entire mesh in edit mode and hit [ctrl + n] to recalculate normals. This should fix the shading..


How can I subdivide a triangle so there is a vertex in the center of each triange? For example, I have an icosahedron and I want to put a vertex in the middle of each face so I can make a dodecahedron later. However when i try to subdivide it it does the reasonable thing, to divide each into 4 equilateral triangles. Is there a way to do what I explained above?

Thanks.


Pressing 'Tab' will move certain bones slightly I know that pressing Tab does not change the position of the skeleton in edit mode and pose mode.

When I press Tab, the skeleton of hand are moves a little strangely.Other bones do not move.

What causes this problem?

Here's a video that shows the problem: https://youtu.be/BGQlwQkXdns

Here's the .blend file: https://www.dropbox.com/s/ji4xjti2umhoxcd/2b_08_middle%20of%20additory%20bones.blend?dl=0

You have a IK-solver applied on some bones. This constrain does not work in edit mode, so when you go to object/pose mode, constrain starts to affect and moves bones a little.

Other thing that you show in video - it is bone in the head, it is hidden in edit mode, so you need to press Alt+H to show it.

And by the way, do you know that rigify addon, that you use, has a Rig generator, witch builds all logic for you and you need not to add constraints and additional bones manually?


How do I create a vertex group from selected vertices in edit Mode with Python (Blender 2.8)? I want to create a small Script that works with any object, but I need to create a new Vertex group of the selected vertices with Python

import bpy

# Modeling
bpy.ops.object.mode_set(mode='EDIT')
bpy.ops.mesh.select_mode(use_extend=False, use_expand=False, type='VERT')
bpy.ops.mesh.select_all(action='SELECT')
bpy.ops.mesh.extrude_region_move(MESH_OT_extrude_region
{"use_normal_flip":False, "mirror":False}, TRANSFORM_OT_translate={"value":
(0, 0, 0.5), "orient_type":'GLOBAL', "orient_matrix":((1, 0, 0), (0, 1, 0),
(0, 0, 1)), "orient_matrix_type":'GLOBAL', "constraint_axis":(False, False,
True), "mirror":False, "use_proportional_edit":False,
"proportional_edit_falloff":'SMOOTH', "proportional_size":1,
"use_proportional_connected":False, "use_proportional_projected":False,
"snap":False, "snap_target":'CLOSEST', "snap_point":(0, 0, 0),
"snap_align":False, "snap_normal":(0, 0, 0), "gpencil_strokes":False,
"cursor_transform":False, "texture_space":False, "remove_on_cancel":False,
"release_confirm":False, "use_accurate":False})
bpy.ops.transform.edge_bevelweight(value=1)

# New Vertex group from selected vertex

bpy.ops.object.vertex_group_add()

This is the better and simplified solution that I could do:
import bpy

bpy.ops.object.mode_set(mode='EDIT')
bpy.ops.mesh.select_mode(use_extend=False, use_expand=False, type='VERT')
bpy.ops.mesh.select_all(action='SELECT')
bpy.ops.mesh.extrude_region_move(MESH_OT_extrude_region={"use_normal_flip":False,
"mirror":False}, TRANSFORM_OT_translate={"value":(0, 0, 0.5), "orient_type":'GLOBAL',
"orient_matrix":((1, 0, 0), (0, 1, 0), (0, 0, 1)), "orient_matrix_type":'GLOBAL',
"constraint_axis":(False, False, True), "mirror":False, "use_proportional_edit":False,
"proportional_edit_falloff":'SMOOTH', "proportional_size":1,
"use_proportional_connected":False, "use_proportional_projected":False, "snap":False,
"snap_target":'CLOSEST', "snap_point":(0, 0, 0), "snap_align":False, "snap_normal":(0,
0, 0), "gpencil_strokes":False, "cursor_transform":False, "texture_space":False,
"remove_on_cancel":False, "release_confirm":False, "use_accurate":False})
bpy.ops.transform.edge_bevelweight(value=1)

# New Vertex group from selected vertices

bpy.context.object.vertex_groups.new(name='New_Vertex.000')
bpy.ops.object.vertex_group_assign()


How to export an animation from Blender and load it in Unity? My FBX file from Blender (as well as the .blend file) comes into Unity with no animation - none of the other forum posts have helped. The animation is very simple - made with keyframes in the dopesheet. What could I be doing wrong?

You should bake your animations before exporting to FBX using bake option:

this option includes all constraints and even any rig which is done in Animation Nodes addon.


How to make a 5-point perspective camera view? Look at this painting, The Courtyard by Irvine Peacock:

As you can see, there is a sort of fish-eye effect here so that the lines curve, so that you can see more of the image. How can I recreate this effect?

You may achieve it using Fisheye Equisolid type of the Panoramic camera (with some manual vertices tweaking).

Add a camera and position it verticaly as pictured below. Add a plane and place it in front of it. Add a background image (display axis type: Camera), decrease its opacity and push the Front button.

Set the render resolution so it is the same as image's resolution.

Enter the camera view (Ctrl+Num 0) and rotate it along the Z axis to fit the plane to the reference. Extrude the plane until you you build the rough representation of the object from the picture.

Select the extruded object in Object Mode and give it a material (Emission e.g.). Also give it a Wireframe Modifier with some thickness.

In Cycles go to Camera Data header--> Lens panel and set the camera type to Panoramic (Fisheye Equisolid). Experiment with Lens and Field of View values. In this case I found Lens=14 and FoV=180 optimal.

Divide the 3d view into two windows. Set the Solid viewport shading mode for the first and Rendered for the second one.

Snap the cursor to the origin point of the plane. Grab the camera and translate it along the Z axis. Next rotate it along the local Y axis (press R, then double tap Y) to fit the image as precisely as you can.

Controling two views at the same time you can now easily make the subdivisions to the mesh and model the details.

To make the model exactly fit the reference's perspective you may tweak some vertices.

Here's the comparision between original and tweaked perspectives.


How do rigs relate to weights? I'm practicing rigging a finger. Why is the tip getting smaller when I rotate it? And hopefully someone has tips on rigging a hand/fingers.

Some tips:

a good topology is very important for smooth joints transformations (try to model your finger as pictured below and you'll see how smooth it bends)

a proper mesh weights assigment is crucial for realistic bend movement (I suggest you using the With Automatic Weights parenting option. Select your mesh, then the bones and press Ctrl+P-->With Automatic Weights. This'll automatically aassign the proper, blended weights for all bones)


How can I get rid of the link (thick horizontal line) between two keyframes? Each time I hit 'I' to insert a keyframe in the Action Editor, if the previous keyframe on that channel is linked, the new one will be linked too (with a thick horizontal line). I can't find a way on the menu to disable or get rid of that #$%@^ link which affects the next and previous keyframes in an undesirable way. I'm sure there must be a way (although very well hidden). So what is the magic spell for this purpose?

If I change the position on the upper channel shown at the current frame, all previous (linked) frames on that channel take that new position -I don't want that. In the lower channel though, if I change the value no horizontal line appears.

UPDATE:
I uploaded this Blender screencast for proof of this unjustified behavior - and for a clearer explanation.

https://www.youtube.com/watch?v=pCs95EJDkZ8&feature=youtu.be

The yellow lines do not represent "links" but selected keyframes with the same value.

Form the Blender Manual

  One of the key feature of this window is that it allows you to visualize immediately which channel (i.e. Ipo curve) is really affected. When the value of a given channel does not change at all between two neighboring keyframes, a gray (unselected) or yellow (selected) line is drawn between them."

If what's bothering you is the way the interpolation works between keyframes , you should edit those not the dope sheet but on the Graph editor window.

In this example you can see the same key frames for the location of the X channel represented on the dope sheet and the graph editor, Notice how the Yellow lines between keyframes coincide with the flat regions of the graph, and how the line disappears where there is some transformation on the value in the graph.

EDIT
A note on the Hierarchical system and the Dope Sheet

Everytime you add keyframes using the I key you are presented with an option to choose what channels you want to use for the keyframe, for example Loc,Rot_Scale or Loc_Scale, Rotation only, all channels, only selected channels. The channels you choose are what is called a Keying Set.

The idea behind keying sets is to keep things organized, for example if you don't want to have a location keyframe when you just need to rotate.

In the DopeSheet you have access both to the keying sets and individual channels and they are organized in a hierarchical structure. You can move, delete or add keyframes with ease.

Here's an example:
At the top of the Hierarchy you'll find the dopesheet summary that encompasses every keyframe on the scene.
On the second level there are the individual objects with their own keyframes.

Click on the trianlges on the left to reveal the next levels down.

The lines rows in green are the Keying Sets

And further down are the individual channels.

Depending on where in the hierarchy you move (or add, or delete) the keyframes, you might affect everything, just the keying set or individual channels.

As for the Yelllow line... Sorry Still no magic nothing there... It doesn't hold anything inside it: It doesn't have any other purpose than to show information in unchanging values between keyframes.


Triangulate modifier doesn't work properly after combining faces After I combine two faces into one and then apply the triangulate modifier, it treats the newly created face as two faces instead of one, so it divides the face into two triangles. Is there a way to fix this and make it two combined faces as one?

Triangulate modifier applied to two separate faces:

Triangulate modifier applied to a combined face

It might be because you still have one or two vertices that make that face triangulate twice?


White Noise after saving image i was trying to make a simple setup in compositor, when rendered the image is perfect:

But after saving it, some white noise appears near the transparent part of the image:

here is the simple node setup, in theory, the image should be exaclty the same, right?

Output settings:

Here is the blend file

Hmm .... blender uses your PNG's alpha channel in a very strange way on output. Even PNG has black&white alpha it is displayed as partially transparent ... almost without transparency. So I would expect your question should be - Why PNG's alpha channel is ignored in my render?

Anyway...
What you can see as "white noise" around alpha edge looks the same as what I can get with Straight alpha

When switched to Premultiplied alpha it looks like your render ... the residue of brighter pixels is something that I can see on your original image too so I guess it is not an issue here.

But your original PNG is already set with straight and looks normal ... switch to premultiply in image properties make things even whorse ... probably wait for some better answer :) I'm confused now ...

Anyway ... reassigning Alpha channel with Set Alpha node solved issue for me. Also when I append rendered image back into blender (that is what you did, I guess, right?).

If you want to clear edge you can try Dilate/Erode node for Alpha channel ...

If you need this pixel cut from mask in final use InPaint node after Set Alpha.


How can I find an specific F-Curve given an action name? Given action name, a data path and an array index, how can I find the F-Curve associated to that action?

You need to use the fcurves.find(data_path, array_index) function. For example, we want to retrieve the F-Curve for the location’s Z channel, for an action named ActionName.

# Configuration
action_name = 'ActionName'
data_path = 'location'
array_index = 2

action = bpy.data.actions.get(action_name)
if not action:
    print('Action {} not found.'.format(action_name))
else:
    # Retrieve the specific F-Curve
    fc = action.fcurves.find(data_path, array_index)
    if fc:
        for kfp in fc.keyframe_points:
            print(kfp.handle_left)
            print(kfp.handle_right)
            print(kfp.interpolation)
            print('Frame = {:04}; Value = {}'.format(kfp.co[0], kfp.co[1]))


Is there a way to flip a UV without flipping the normals? I have a UV unwrapped object that I want one part of to show its texture flipped horizontally, but I can't seem to find a way to do this other than flipping the normals, but I'd prefer not to do that as it seems to mess up other things. Any ideas?

Select all in UV Edit window and type SX-1 and enter


How can a parameter be passed from one operator to another? I used a python template to create a menu which is populated by the names of files from the text editor:

class AnimMenu(bpy.types.Menu):
    bl_label = "Anim Menu"
    bl_idname = "OBJECT_MT_anim_menu"

    def draw(self, context):
        layout = self.layout
        for txt in bpy.data.texts:
            if txt.name[-4:] =='.txt':
                layout.operator("object.anim_operator", text=txt.name).text_name = txt.name # from here

Another operator should receive the filename as a parameter

class AnimOperator(bpy.types.Operator):
    bl_idname = "object.anim_operator"
    bl_label = "Pose Anim Operator"

    text_name = bpy.props.StringProperty(name="anim_text_name") # to there

    @classmethod
    def poll(cls, context):
        return context.active_object is not None

    def execute(self, context):
        txt = bpy.data.texts[ text ].as_string()
        main(context, text_name)
        return {'FINISHED'}

I wasn't able to use this technique:
How to set multiple custom attributes to operator class when called in UI layout?

props = layout.operator("object.anim_operator", text=txt.name)
props.text_name = txt.name

leads to:

AttributeError: 'OBJECT_OT_anim_operator' object has no attribute 'text_name'

I had to add the self keyword to access the variable in the invoked operator (basic python, ouch!)

class AnimOperator(bpy.types.Operator):
    bl_idname = "object.anim_operator"
    bl_label = "Pose Anim Operator"

    text_name = bpy.props.StringProperty(name="anim_text_name")
    @classmethod
    def poll(cls, context):
        return context.active_object is not None

    def execute(self, context):
        print("invoked script name=%s" % self.text_name ) # <<- self.


Modify nodes in compositing nodetree using Python I want to setup basic node tree using Python operator and I cannot use compositor context. Hint over node values pointed to this data path:

bpy.data.node_groups["Compositing Nodetree"].nodes["Alpha Over"].premul

but this collection: bpy.data.node_groups includes only custom node groups.

This bug report: https://developer.blender.org/T35720 pointed me to right right data path. When you want to modify node tree in compositor, then you have to use following path:

bpy.data.scenes['Scene'].node_tree.nodes['Alpha Over'].premul

or you can use following syntax to avoid hard-coded name of scene (current scene will be used):

bpy.context.scene.node_tree.nodes.['Alpha Over'].premul

and it just works. :-)


How can I use the compositor on the result of the sequencer? I recently ran a renderfarm on a file with some compositing setup, but I forgot to set the composite output back to the Composite node instead of the Viewer I was temporarily using. Since the node setup didn't require anything besides the image data (i.e., no Z-buffer, object IDs, etc.) I figured that I could just run the compositor on each frame individually. However, this proved to be somewhwat difficult.

It seems that the sequencer is run after the compositor (despite their non-exclusivity in the Post Processing panel), so my idea to use an image strip in the sequencer for all the images that I already rendered didn't work—the render just copied the images into a new directory.

The Movie Clip node doesn't seem to accept an image strip as input, either, so that was not an option.

What I ended up doing was sequencing the animation to a movie file, then piping that into the Movie Clip node in the compositor. However, this required extra time, extra storage, and it rendered the default scene every frame before compositing, only to ignore the result.

Is there a way to use Blender's compositor either directly on an image sequence, or in conjunction with the video sequencer?

To use the rendered image sequence as input in the compositor, use the Image node. Select any file within the image sequence as input. Change the node's type from Single Image to Image Sequence, then set the sequence's length and first frame.