text:
How do you move multiple faces by equal increments?
I have a cog wheel and I want to make the spokes a bit longer than they are. I can select the tip of one and drag it out a bit, but how do I precisely measure how much I've moved something so that I can then move all the other tips the same distance?
I can't have uneven cog spokes.

Can you use array modifier for the cogs? that will be the best option for symmetrical objects

For symmetrical shapes the best method is to use array modifier.
Delete all the faces leaving only one cog then change to object mode and add an empty in the origin of the gear and rotate the empty 45 degrees.

Then add array modifier on the gear object, set count to 8, disable Relative Offset. Then enable Object Offset and select empty from the selection box and enable Merge and First and Last.

This way you can control the gear shape by modifying only on cog.

I have created an addon to do that a lot faster,you can use it in this condition.
https://github.com/emaema/procedural-dupli-spin
read the documentation if you dont know how to use it.

Does the 'merge' ensure that vertices are merged when they touch so that the resulting mesh isn't a bunch of overlapping but disconnected edges?

@leigero Yes it will merge the vertices that are within the specified distance from eachother

You can precisely define the value of any element's movement. After pressing G, S or R and selecting the desired transformation axis (press x,y or z) you may input the number from the numerical keyboard. As pictured below I selected the edge of the spoke, pressed G, then Y and then 0.2

Select all the spoke's edges and press Shift+S-->Snap-->Cursor to Selected. It will place the cursor in the center. Set the pivot point type to a 3D Cursor. Press S and input the desired transformation value. You may also enable the Snap Tool (click the magnet icon, and change the snapping type to Increment). It will allow you to increase the spoke's lenght very precisely while scaling (hold Shift while scaling and you'll be able to change the lenght's value in smaller increments).

Now change the pivot point type to Individual Origins.

Press S and input the desired value to make all the spokes scale the same way.

Blender can move more than one face at once by various means.

You can extrude more than one face at time.  Be in Face Select mode.  Depicted in the image below (vertex, edge, face enabled).  Select your faces.  Use shift + click.  Then E to extrude. Return Key. Selection is still there. Alt + S to move face on normals (See menu Mesh/Transfrom/Shrink Fatten).

If you want to casually work, you can place a cylinder around the cog as a circular guide.
The same circular guide can be used as target for shrink wrap modifier.  You must create a vertex group for the faces on the teeth of the cog.
Shrink Wrap  can be applied:

Wonderful keystroke editing by another author.


text:
View follows object when object moves? How do I turn this off?
I did something unbeknownst to me and have made my view constantly follow an object. If i move that object it remains constant in the center of my view while the rest of the scene moves around instead.
What is this setting? I've tried pressing . on the number pad and it did nothing.

That question addresses a different issue, @gandalf3.

@RossM. Er.. How so?

Correct me if I'm wrong, but that question you linked to dealt with orbiting about a certain point, while this question had to do with tracking an object (no orbiting involved.  just panning)

@gandalf3 because that question addresses bizarre rotation issues with the viewport not the view locking to an object.

Yes. On further review, it's related (the lock to object setting did fix the issue for that question too).  But this one is a different issue. It just happens to have a similar fix.

@RossM. I disagree. They are the exact same problem, just asked differently.

The exact same solution.  Not the exact same problem.

@RossM. I don't see where you are coming up with different problem.. Both users accidentally enabled lock to object, and were subsequently confused as to why their viewports where acting differently. Anyway, if you don't think it's a duplicate, that's fine :) That's why there is a voting system.

Well this is a matter of my opinion, but to me, the only thing that the two questions share is the source of the issue (and therefore the fix).  They don't, however, exhibit the same side effects.  Analogy: two people can have the flu (same source of the issue) but experience two different side effects (one experiences coughing, the other sneezing.)  They can both be fixed by the same means, and come from the same source, but are different issues.

Yes! :)  All good.

Press the N key to bring up the right tool bar, and delete your cog object from the Lock to Object field.

Thank you, it's always a simple fix, just finding it is troublesome.

No problem.  A lot of stuff to do with the viewport setup (visibility of grid, axes, clipping, AO, matcaps, etc) are found in the N panel, so if you run into something you need to change in your viewport setup, odds are, it'll be in there.

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

sort: votes


text:
Blender crashes on startup, why?
Trying to use blender on ubuntu 18.04 and I get the following error:
libGL error: No matching fbConfigs or visuals found
libGL error: failed to load driver: swrast

Followed by a sigsegv.  I have an Nvidia graphics card and the output of the crash file is:
# Blender 2.79 (sub 0), Unknown revision

# backtrace
blender(BLI_system_backtrace+0x33) [0x555bdc475e93]
blender(+0x1040453) [0x555bdb9ff453]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20) [0x7f5e92df9f20]
blender(GHOST_GetDPIHint+0) [0x555bdc493290]
blender(WM_window_set_dpi+0x12) [0x555bdba1f932]
blender(ED_screen_refresh+0xe9) [0x555bdbd171a9]
blender(ED_screens_initialize+0x2b) [0x555bdbd177eb]
blender(WM_check+0x68) [0x555bdb9fff58]
blender(wm_homefile_read+0x3c9) [0x555bdba0d5e9]
blender(WM_init+0x14b) [0x555bdba0fccb]
blender(main+0x241) [0x555bdb9bf0c1]
/lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xe7) [0x7f5e92ddcb97]
blender(_start+0x2a) [0x555bdb9fc09a]

How do you fix this.

I found a clue here: https://askubuntu.com/questions/834254/steam-libgl-error-no-matching-fbconfigs-or-visuals-found-libgl-error-failed-t but was not happy with their solution.
I ended up reinstalling the nvidia drivers which had been removed during an abortive cuda install/removal.
sudo apt-get install nvidia-340
The version you need will be based on your graphics card and you can figure out that version with this page https://www.nvidia.com/Download/index.aspx?lang=en-us on the nvidia site.

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
How to make a fixed texture/"End Portal Effect"?
I was wondering if this would first off, even be possible within Blender. I wanted to make a project where I have a characters eye textures follow where the camera goes.
I can't think of too many example except for Minecraft's End portal, and League of Legend's Cosmic Reaver Kassadin skin
I'm guessing these both are more for game engine side of things, but I was wondering if it can be done in Blender.
Also bonus points if anyone can tell me what the effect is called! (I tried looking up "fixed texture", but alas, nothing)

Are you after a portal effect or eyes to follow a camera - a character's gaze following you about?

I think you could use the camera vector in the node editor.... https://blender.stackexchange.com/questions/53648/vector-for-camera-direction or if it has to be fixed in space use the location of an non-moving empty in node editor

I want the portal effect but for a texture, not another scene. It's just going to be a star texture like in both the examples. Also I will try and experiment with that later today and update the post if I can figure it out.

its called the monalisa effect named after the effect that the painting has with the eyes following you around the room

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
How to create fire with mantaflow, I can only generate smoke not fire
Could somebody please explain the new mantaflow fire simulation setting. I was unable to generate fire both in Cycles and Eevee. I play with all the setting.

All you have to do is set the Type of the Flow Object to 'Fire' or 'Smoke and Fire' which basically adds a new volume (field) to the simulation (in addition to the temperature) for calculating the flames:

Thank you so much, it works


text:
Index material in 2.8 (Cryptomatte)
I have a lamp. Behind the glass is a source of light. I want to apply effects to the light source in the composer. Previously, this was done using a material index. In 2.8 this isn't possible, there is Cryptomatte. But the source of light is behind glass, so I can't pick it to get a number. What can I do?

This is not exactly how to do it, but you can try to reduce alpha transparency of your glass object and adjust your Alpha Threshold value on View Layer settings. Just after that you can use cryptomatte object to pick the light.


text:
How to python script "Scale B-Bone"?
I want script "Scale B-Bone" to be in proportion to Bone Length.
How do I access this property?
Note I am interested in Scale BBone and Scale please refer to bellow image

The pose bones can be found at bpy.data.objects['Armature'].pose.bones with each bone having a length property bones['Bone'].length which represents the visible length in pose mode.
The bbone size that you change when using "Scale BBone" is two properties of the armatures bones which can be accessed through bones['Bone'].bone.bbone_x and bones['Bone'].bone.bbone_z
import bpy

ratio = 0.3
pose_bones = bpy.date.objects['Armature'].pose.bones
b = pose_bones['Bone']

b.bone.bbone_x = 1 / b.length * ratio
b.bone.bbone_z = 1 / b.length * ratio

than you. But I want to Change "Scale BBone" and not Scale. How do i do that with script? pls see the screen shot i added

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
How to duplicate linked(external) rigged character and animate each instance independently?
I have linked cookie flex rig by browsing to the groups folder of the rig file and then linking the character group (standard method) and not appending.
And then i did a proxy of rig by pressing "Ctrl+Alt+P" and selecting "rig" from list.
After this i do some animation and it works.
My Problem
But if i create another instance of the same "linked group"(charecter) and then proxy the rig
then even the first instance gets the same pose as the second one. I am not able to independently animate the two instances.
Pls note that i am aware of creating different files of the source rig file and renaming the groups and then instancing them back into one file. But i am not happy with this method as its crude. It create many files using more storage space. I have been using this solution though.

http://blender.stackexchange.com/questions/1123/how-can-i-independently-pose-group-instances

@stacker i am aware of this work around. But it just makes the project bulky. But there should be more elegant way of doing it. I don't know how they do it in crowd simulation, but there they might be doing something that creates independent instance of same rigged character.

I wasn't able to find a better solution yet.

In the Animation Toolkit that the Flexrig was originally released with, Nathan explains this as a limit of how blender works. One external file per character is the way to make it work. Don't know if there is any plan to change this. Maybe with the new dependency graph work this can be changed?

@sambler i had missed Nathan's explanation, thanks for that. But there should some work around. How one would generate crowd ? one cant create new file for each crowd character


text:
How to toggle Object visibility driven by armature layer visibility using python?
@Jerryno
I want to hide or show mesh object depending on the visibility of the layer
I adapted your code. It's not working why ?

On visibility of armature layer[0] the object ie Cube should be
  visible and on hiding of armature layer[0] Cube should hide

the test file
import bpy

class Watcher:
    def __init__(self, object, property, function):
        #if the property object needs deep copy
        try :
            self.oldValue = getattr(object, property).copy()
            self.newValue = getattr(object, property).copy()
            print(">>>>>>>>>>>> try  self.oldValue  >>>>>>>",self.oldValue)
        #if the property object doesn't need it (and don't have a copy method)
        except AttributeError:
            self.oldValue = getattr(object, property)
            self.newValue = getattr(object, property)
            print(">>>>>>>>>>>>AttributeError  self.newValue >>>>>",self.newValue[0],self.oldValue[0])

        self.object = object
        self.property = property
        self.function = function

    #Call the function if the object property changed
    def update(self):
        if (self.oldValue[0] != self.newValue[0]):
            print(self.oldValue[0] , self.newValue[0])
            self.function(object=self.object, new=self.newValue, old=self.oldValue)

# this holds all the watchers
watchers = []
def add_watcher(object, property, function):
    watchers.append(Watcher(object,property,function))

#
def visibility_change(object, new, old):
    print(object)
    print("old value: " , old[0])
    print("new value: " , new[0])
    if (new == True):
        bpy.data.objects["Cube"].hide = False
        return
    else :
        bpy.data.objects["Cube"].hide = True
        return

# Watch layer visibility
add_watcher(bpy.data.armatures["Armature"], "layers", visibility_change)

def watcher(scene):
    """This function will be run everytime after scene updates"""
    global watchers
    for watcher in watchers:
        watcher.update()
    return

# add handler if not in app.handlers
if watcher not in bpy.app.handlers.scene_update_post:
    bpy.app.handlers.scene_update_post.append(watcher)

do you mean the object should be visible only when the armature object is visible ? also there's nothing in your code that is setting the visibility or you are doing is printing variables

To achieve the goal you don't need script, you can drive the object visibility with classic driver.

In outliner right-click the object eye (or render) icon and select Add Driver:

Setup the driver like this ('layers' is an array and 0 point to the first layer, the values are 0 (hidden) or 1(visible)):

Now your object visibility is driven by the armature layer visibility. The driver will not update on it's own, you need to change the frame to see it in action.

@ Jerryno thanks. this worked.
If it's not too time-consuming can you tell me what's wrong in the script?

@ashwin The problem with the code is in update(self) function. The values old and new are always the same, the if statement is never executed. The reason for that is you deleted the try-except part from that function that handles updating the old and new variables. Also probably this deleted part would need to be updated to handle arrays, but not sure about it.


text:
What is the most efficient way to make instance real and joined

I have a setup, a very complex instancing, I simply want to Voxel Remesh this (sculpt) but if I use Make Real for instances, it will create bazillions instances, and I don't want that. I simply need a joined mesh based on the parented dupli instances, regardles how complex, and from that single mesh, then I can use Voxel Remesh or other processing.
Any idea?

Make real and join*
Could make the mesh by making the dupliobject active and running make duplicates real, and then joining them.  Sorry haven't fixed the location properly
import bpy

context = bpy.context
scene = context.scene
vl = context.view_layer

obs = set(scene.objects)
bpy.ops.object.duplicates_make_real()
new_obs = list(set(scene.objects) - obs)
bpy.ops.object.select_all(action='DESELECT')
o = new_obs[0]
vl.objects.active = o
for o in new_obs:
    o.select_set(True)

bpy.ops.object.join()

Using depsgraph in 2.8

Result in edit mode above, default torus duplivert default and scaled down icosphere.  May be cuppa time while it runs
Instances can be obtained from the depsgraph. https://docs.blender.org/api/master/bpy.types.DepsgraphObjectInstance.html#module-bpy.types
There is a section in
https://wiki.blender.org/wiki/Reference/Release_Notes/2.80/Python_API/Scene_and_Object_API
re getting the instances of an object via the python API.
Using the method prescribed for getting instances of a particular object, here is a test script to create a bmesh from all object instances of the context object,
The bmesh is written to  new single mesh object from the instances.  The mesh equivalent of make real and join.  (Without the original)
I have only tested this on a very simple example, without materials.
import bpy
import bmesh

context = bpy.context
ob = context.object
mwi = ob.matrix_world.inverted()
dg = context.evaluated_depsgraph_get()

bm = bmesh.new()
for ob_inst in dg.object_instances:
    if ob_inst.parent and ob_inst.parent.original == ob:
        me = ob_inst.instance_object.data
        bm.from_mesh(me)
        # transform to match instance
        bmesh.ops.transform(bm,
                matrix=mwi @ ob_inst.matrix_world,
                verts=bm.verts[-len(me.vertices):]
                )

# link an object with the instanced mesh

me = bpy.data.meshes.new(f"{ob.data.name}_InstanceMesh")
bm.to_mesh(me)
ob_ev = bpy.data.objects.new(f"{ob.name}_InstancedObject", me)
ob_ev.matrix_world = ob.matrix_world

context.collection.objects.link(ob_ev)

Interesting, appreciate the post. Works like a charm but still takes a few seconds for ~500 spheres on my machine though.

Thankyou. Could try without the bmesh by generating using from_pydata, with some numpy trickery  Hence prob not most efficient,   Added the operator approach with make real then join.

Thanks so much!!! This works well and faster than "making copy real" and joining it back.

I just discovered that
bpy.ops.object.convert(target='MESH')
will apply the visual mesh and remove all the modifiers, linked or not.  handy for cleaning up linked modifiers after making all instances real.
you can find it on ctrl+a as "apply visual mesh"


text:
Python: Up-Vector math for Curve
I've been working on python Curve Deformation tool. I need some help with the math. Possibly someone can help here. I cannot find correct UpVec for my custom curve.
Here are the screens which explain the problem:

Here is my tool in action:
https://youtu.be/Nxu6-0xm3Io
Here is the code I did but it's buggy in some angles. It inverts to 180 degrees on some angles:
https://github.com/mifth/mifthtools/blob/96e73eb3a2613b3f1396ddd7c4bdd9d0419ca5e3/blender/addons/mira_tools/mi_curve_guide.py#L515-L537
All I do is just cross direction of the point to global X and Y axis. Any help will be appreciated to get the quality of upVec as in Blender Curves.
And you can get the tool here:
https://github.com/mifth/mifthtools
http://blenderartists.org/forum/showthread.php?366107-MiraTools
Thanks.

perhaps an intereting read: rollercoasters-and-normals by freek hoekstra. (a blog post about exactly this problem)

Do you want to find the tilt as shown in the viewport? or calculate it from your own bezier data?

ideasman42 - i need the same tilt for my custom python curve. Here is "deform_lines" array of all points of the curve and all their directions. https://github.com/mifth/mifthtools/blob/96e73eb3a2613b3f1396ddd7c4bdd9d0419ca5e3/blender/addons/mira_tools/mi_curve_guide.py#L449

There are 3 ways for upVec to be found:
2 and 3 versions were suggested by mano-wii from here http://blenderartists.org/forum/showthread.php?361154-Coordinates-of-resolution-points-of-a-Bezier-Curve
1) Cross vec. https://github.com/mifth/mifthtools/blob/6b0469faea18d3375c3f3257963d7c85f327c44c/blender/addons/mira_tools/mi_curve_guide.py#L486-L488
2) Project vec.
http://blenderartists.org/forum/showthread.php?361154-Coordinates-of-resolution-points-of-a-Bezier-Curve&p=2866256&viewfull=1#post2866256
https://github.com/mifth/mifthtools/blob/6b0469faea18d3375c3f3257963d7c85f327c44c/blender/addons/mira_tools/mi_curve_guide.py#L490-L492
3) Dot vec.
http://blenderartists.org/forum/showthread.php?361154-Coordinates-of-resolution-points-of-a-Bezier-Curve&p=2866427&viewfull=1#post2866427
https://github.com/mifth/mifthtools/blob/6b0469faea18d3375c3f3257963d7c85f327c44c/blender/addons/mira_tools/mi_curve_guide.py#L494-L497
I choosed Cross vec for my approach for the upVec searching.
You can comment/uncomment any of approaches and try testing.
Also,I found another issue:
One direction can has different upVecs.
https://i.sstatic.net/WBhG3.png
To fix this issue I have to pick first point upVec and then check all points after. If a current upVecAngle is more than 90 degrees - we need to invert upVec.
Here is the code to fix this issue:
https://github.com/mifth/mifthtools/blob/6b0469faea18d3375c3f3257963d7c85f327c44c/blender/addons/mira_tools/mi_curve_guide.py#L504-L509
And you can see the result of my custom curve in editmode here:
https://www.youtube.com/watch?v=VXWSUwOul-s

Please avoid link-only answers.  All main information in your answer should be available without having to link anywhere else.  Besides being a nice format, if a link goes down then so does your answer.


text:
How to get rid of hair root location artifact
I have a small sphere on which I place a couple hair particles in the particle editor.
When the hair particles have simple children, the sphere is so small that the appear to be emitted from above the surface:

Is there a way to fix this artifact?
A reasonable fix would be to emit the hair from a smaller sphere inside my actual sphere, but I'm wondering if there is a way to avoid having the extra emission object.

Enter the Particle Edit Mode.

Change the Particle select and display mode to Point select mode.

Uncheck the Lenghts and Root boxes in Options panel, then select all the hair particles with border select tool (B) and move them closer to the sphere (G).

Here is the result.


text:
Can I export multiple objects with individual animations to FBX?
I have a simple scene with two objects. Each object has scaling keyframes and the animations are different for each object. No modifiers, no armatures, nothing fancy. Just two cubes with some keyframes. When I export to FBX, then re-import the FBX file into Blender, both objects show up, but they both have the keyframes from the first object.
Is there any way to export both objects and have each of them keep their individual keyframes?
If there's some fundamental concept of the FBX format that I don't understand, please let me know.

I think that you have encountered a bug. Please report on https://developer.blender.org

@Jackdaw Reported a bug: https://developer.blender.org/T65768

According to Bastien Montagne (https://developer.blender.org/T65768):

No bug here, to achieve what you want you need to disable All Actions and NLA Strips options, then you'll get current scene's animation exported properly. Those two options are used to export several animations (usually for a single object), e.g. to export a character and all its animations to a game engine.

So, to export multiple objects with individual animations, do the following:

Click File > Export > FBX (.fbx)
In the Export FBX options, click the Animation button to view animation options
Make sure NLA Strips and All Actions are unchecked

Great answer. I have been frustrated all day by this one. Unchecking the all actions box in animation exports was what i was missing.
Thankyou
Next thing is to work out how to save different animations as options in the file.


text:
Why isn't 'bpy.context.object.name' printing out the name of my newly created object?
I have a simple operator which creates an empty object and immediately prints out the object's name:
import bpy

class createEmpty(bpy.types.Operator):
    """Create an empty object"""
    bl_idname = 'make.empty'
    bl_label = 'Create an empty object'

    def execute(self, context):
        bpy.ops.object.empty_add(type='PLAIN_AXES')
        print(bpy.context.object.name)
        return {'FINISHED'}

class createEmptyPanel(bpy.types.Panel):
    bl_idname = 'create_empty_panel'
    bl_label = 'create empty object'
    bl_space_type = 'PROPERTIES'
    bl_region_type = 'WINDOW'
    bl_context = 'object'

    def draw(self, context):
        layout = self.layout
        row = layout.row()
        row.operator('make.empty')

bpy.utils.register_class(createEmpty)
bpy.utils.register_class(createEmptyPanel)

When I run this from the console, it creates an empty object and prints its name, 'Empty'. However, when I click the button in the UI, it creates an empty object, but prints the name of the object that was selected, in my case 'Cube'.
Why is this? Is there a better way to select the object I just created, other than bpy.context.object?

related: http://blender.stackexchange.com/questions/45101/adding-named-objects-in-blender-with-python-api

The simplest solution is to use active_object instead:
def execute(self, context):
    bpy.ops.object.empty_add(type='PLAIN_AXES')
    print(bpy.context.active_object.name)
    return {'FINISHED'}

Blender doesn't switch the bpy.context.object until after the createEmpty operator has completed, hence the Cube's name was being printed. Your operator is invoked from the createEmptyPanel which has bl_context = 'object', I suspect this has built in blocking of bpy.context.object changes.
Avoid this behaviour by using the lower level bpy.data.objects.new to make the empty. Change the execute function to avoid using bpy.ops.object.empty_add(), like:
import bpy

class createEmpty(bpy.types.Operator):
    """Create an empty object"""
    bl_idname = 'make.empty'
    bl_label = 'Create an empty object'

    def execute(self, context):
        # bpy.ops.object.empty_add(type='PLAIN_AXES')
        scene = context.scene
        objects = bpy.data.objects
        mt = objects.new("empty_name", None)
        mt.location = (0, 2, 1)
        mt.empty_draw_size = 2
        mt.empty_draw_type = 'PLAIN_AXES'
        scene.objects.link(mt)
        scene.update()
        print(mt.name)
        return {'FINISHED'}

class createEmptyPanel(bpy.types.Panel):
    bl_idname = 'create_empty_panel'
    bl_label = 'create empty object'
    bl_space_type = 'PROPERTIES'
    bl_region_type = 'WINDOW'
    bl_context = 'object'

    def draw(self, context):
        layout = self.layout
        row = layout.row()
        row.operator('make.empty')

bpy.utils.register_class(createEmpty)
bpy.utils.register_class(createEmptyPanel)

It's a bit more verbose, but it does immediately give you a reference to the new empty.

authors: Матвей Громов


text:
Applying shrinkwrap modifier corrupts the shape
I've added lots of circles around a mesh in an effort to retopologize it with BSurfaces later. But I never get so far.
I've applied shrinkwrap on them all with the object as the target, and linked the modifier.
This works well so far:

But then I want to join the objects into one object. This creates problems because it now has only one origin and shrinkwraps all circles towards the new origin:

So, I thought, to fix this I should apply the modifier to the objects first, so that they retain their shape when they are joined. But if I try to apply the modifier, this happens:

I have no idea what's going on here.
Why does it get this shape when I apply the modifier, and how can I fix it?
And a side-question: How could I apply the modifier to all of the selected rings, instead of one by one?

See http://blender.stackexchange.com/q/3488/599

Could you post a .blend?

@gandalf3 here: https://dl.dropboxusercontent.com/u/1706324/test%20retopo.blend

Just discovered there's duplicate circles on top of each other in that file, so beware...

This is because the objects are Curve objects. Note the warning in the Info panel that appears when the modifier is applied:

When the modifier is active (not applied) it affects the polygon geometry generated by the curve object. When you apply the modifier it will only affect the Control Vertices (CV points) of the curve, giving a different result:

As you can see, the CV points are shrink-wrapped to the edges of the mesh, redefining the geometry defined by the curve.
To retain the shape, you must convert the object to a Mesh. This can be done with AltC> Convert > Mesh. This will take the geometry generated by the curve object and turn it into a mesh object:

Note that this will apply all modifiers as well. (See this post)

What are "CV points"?

@DavidS Control Vertices. They are the points that you use to define the shape of the curve.

So when I apply the modifier, it basically shrinkwraps the control vertices only? In that case, wouldn't they go to the edge of the shrinkwrap target, instead of the weird positions that they do in this case?

@DavidS. They do go to the edges of the mesh. See my edit

ahh ok I see now, just didn't look like they did in wireframe view.


text:
Blender's "smoothing groups" solution (Edge Split) destroys topology. Is there an alternative solution?
I was searching for how to create smoothing groups in Blender, and everybody seems to say I should use Edge Split. But this will actually create new edges, destroying the topology of the object! Is the situation really so that I cannot create 'smoothing groups' without modifying the actual topology of the object? It will be very difficult creating models for game engines or exporting to other 3d software without smoothing groups, and I don't want to destroy the topology to achieve it either..
Here, I start with a smoothed sphere:

I then apply edge split on a face, as is recommended as blender's method of doing smoothing groups:

This is the result. Looking good so far...:

Then I try to select an edge loop here, but it stops on the affected area!

When I try to move one of the edges, the reason becomes clear: Two edges have been created, completely destroying the object's topology:

I suggest you use the modifier Edge Split instead.
In Edit mode, select your edges desired to be sharp. Hit Ctrl+E to bring up the Edges menu. Select Mark Sharp. Now add the Edge Split modifier.

Edges are split by the modifier. In Edit mode they are marked cyan. Topology is still fine:

Would be good if you elaborated on why modifiers are different/better.

Modifiers alter the mesh when it comes time to draw or render, leaving your mesh unaltered when you go into edit mode. Makes things a lot easier to undo or adjust.

Since this question is old, I figured this probably relates to an older version of blender. So here's an updated answer.
The Autosmooth functionality was added a couple of blender versions ago (current 2.79), it enables you to specify whether edges are smooth or not without using any kind of modifier, editing, or splitting.

Steps to use the autosmooth functionality

Step 1. Set the object to use smooth shading
Step 2. Go to edit mode and select the edges you want to retain their sharpness
Step 3. Press CTRL+E to bring up the Edges menu. Click on Mark sharp.
Step 4. Now go to the Mesh data tab under the properties panel and enable Autosmooth under Normals. You can set the angle of smoothing to your liking, but I like to keep it at 180°.

The blendfile:-

This is the ideal solution and should be the top answer. Marking smoothing seams without splitting the topology actually makes this method superior to smoothing groups IMO

This is the best solution currently available in Blender, so this is the best answer to this question.
However, this is not the ideal solution, as the setting is limited to angles between faces, so you can't make custom smoothing groups that are more specific. Ideally blender should have a smoothing groups functionality as most other 3D softwares have so you can set exactly the faces you want to the smoothing groups you need.


text:
Sculpting brush tool only makes fancy triangles, no depth
So I want to sculpt on that object I have made, and when I do so, practicaly nothing happens. And then I try with a new project, with the original cube, and the factory settings but still nothing happens. I have dynamic topology enabled, and so when I get into wireframe mode, I can see the fancy triangle, but no depth to them, the brush tool only ads triangle... so if you have any idea of what's going on feel free
sculpt tool http://imageshack.com/a/img600/3905/by1v.jpg

Hmm.. That is very strange. Do you think you could upload a .blend where this occurs? Then we can determine if it's a setting or a bug.

Do you have any modifiers on your cube? I was just doing some sculpting and I created a cube, then put a subsurf modifier on it, and then tried to start sculpting. Nothing moved. I had to apply the subsurf before I could sculpt. I hope this is relevant info.

@AdamMasters This is because the geometry generated by the subserf modifier is not used when sculpting, you must either apply it or use the Multiresolution modifier instead. You will note that if you sculpt on the corners of the cube they will move a little bit. This does not apply to dynamic topology because modifiers will not affect the object in sculpt mode when dyntopo is enabled.

Now it works fine, I didn't change anything, I guess it was some sort of bug. I've had to close the program since the bug occured obviously so I can't provide any sort of example file, if it happens again I'll save it and send it back to you. Anyway thanks for the support!

It sounds like the Strength is set very low.
Try setting it to a higher value:

I'm sorry, the link was broken.


text:
How can i disconnect the teeth of muy 3d model from the rest of the rigged body
I'm trying to move muy model's arm but the structure inside his head  is still following that move, i also tried to chance the body's rig to sepárate it but it simply doesnt work.

Your problem is the wheights are wrong in your model. Select all verts of the teeth and remove them from all vertex groups (you can do it, if you click on the little triangle near the vertex groups), then reassign them to the correct bones. https://docs.blender.org/manual/en/latest/modeling/meshes/properties/vertex_groups/assigning_vertex_group.html

How do i select them?

i just checked the vertex groups after rigging it again and i saw that all bones i created were each one at a vertex group but i still cant find the group were the teeth are

You don't have to find the vertex group, just select all the teeth's verts then click on the little triangle, and select "Remove from All Groups"

how can i select them if i cant see them? i mean i cant see them because i have the rest of the  head around it, do i have to make the rest transparent or something? (sorry for asking somuch butim a beginner)

No problem. Select a vert on the head and hit CTRL+L. This will select the whole linked mesh, then hit H. This will hide the selected verts, so you will what is inside. You can unhide everything by hittng ALT+H.

thank you so much for the help but now i have a last issue that is driving me mad.you see


text:
Unexpected result with soft shadows when rendering a beveled cube in Cycles (3.0)
This seems like it should be pretty simple, but I must be missing or misunderstanding something.
I have a cube with a bevel modifier on it, and I want it to have pretty soft shadows.
But the result is that you can pretty much see where the beveled geometry transitions to the cubes sides...the shadows are much sharper than I expected - compared to the sphere next to it which has very soft shadows.

Thinking that it is a lack of geometry that causes this, I tried adding a subdivision surface modifier, but that made the problem even worse:

Adding more bevel segments does not seem to help either, nor does beveling manually.
I realize that comparing the shadows on the sphere with the shadows on the bevels might not be entirely fair, but it seems the transition between each individual bevel face is still softer than the transition to the flat cube face.
What am I missing?

Have you tried activating automatic normals in the object properties?

If you mean Normals/Auto Smooth then yes, it doesn't seem to make any difference in this case.

Try adding some inset faces so that the smoothing isn’t trying to make the whole side of the cube appear round.

@TheLabCat Insets doesn’t seem to make any difference either…I was thinking along the same lines that it is the size difference of the faces that causes the issue. I’ll experiment some more…


text:
Is it possible to make a curve visible through bevel geometry?
I have a curve with a round bevel, like so:

In the Viewport Display option, I have checked "In Front".
I do get the normals in front, but what I expected was to see the actual curve spline as well.
I.e. something like this (I have faked the result here by adding a second bevel-less curve on top of the other.)

This might be a bug, or is there a reason the normal handles would be drawn in front but not the curve itself?
Thanks,
/S

Adding a bevel to a curve converts it (dynamically, non-destructively) to a mesh. The actual curve is no longer there - you can test it by loading the object to a geometry nodes setup and investigating the spreadsheet: there will be no splines.

Ah, ok. Makes sense, thanks.


text:
How to optimize a mesh by merging objects and/or reducing faces
I've got a highly-detailed mesh of curtains, similar to what you'd find on a stage. The mesh currently has eight objects/materials (1 material per object), but in reality it only needs two - the large middle curtain and the gathered curtains on each side. The two side curtains use the same texture, and the four objects comprising the middle curtain all use the same texture.
What I'd like to do is merge the two side curtains into a single object (each side is currently 2 separate objects), then merge the middle curtain objects into a single object. After several google searches, I've found how to join objects but they're still appearing as separate objects.
Is there a way to combine multiple objects into a single one?
Also, is there a way to reduce the overall number of vertices and/or faces? The entire mesh currently has around 700k faces, and so far decimate can only get it down to around 350k before the mesh starts deforming.
BTW: Losing UVs isn't a big deal for me. Since we're only talking eight materials here, I can easily remap everything if I have to. My primary concern is that the exported mesh is as simple/optimized as possible while still looking good.
EDIT: If it will help, here's a link to the 3DS file I started with: Curtain Mesh
LINK: Here's a link to my blend file.

Could you upload your .blend?

Sure - I can upload it this evening when I get home then post a link. 'Course, I'd also like to learn how to do it myself if possible.

Yeah once I see what your talking about i can instruct better. as it is, it's a bit cumbersome to try to recreate your scene.

Related: http://blender.stackexchange.com/q/5136/599, http://blender.stackexchange.com/q/5542/599 and http://blender.stackexchange.com/q/474/599

I noticed that your file was made in 2.49. This is a very old version of blender, and I very highly recommend that you update to a new version if possible.

Using some rather aggressive decimate modifiers, I got it down to 75k while still looking fairly reasonable:

There are a few dark spots where there seems to be some weirdly positioned vertices messing with the normals, but these should be pretty easy to fix with a touch of the smooth brush or the simplify brush.
What I did:

Joined the two side curtains into one object.
To join objects, select them and press ⎈ CtrlJ. The selected objects will be joined to the active object (yellow outline):

Applied the scale by selecting the objects and pressing ⎈ CtrlA> Scale.
It's usually a good idea to apply object transforms as a rule of thumb.
The objects have a scale of .001. The object scale defines an offset which can be confusing and even cause precision problems in some cases.
Merged double vertices on each of the objects to close the small gap in the middle of the main curtain and the side curtains.
To remove doubles, enter edit mode (↹ Tab), select the part which should be operated on (selecting everything with A should be fine), and press W> Remove doubles:

I found that a threshold of about .003 worked pretty well in this case.
Added decimate modifiers to each object.
Note that you can copy modifiers between objects with ⎈ CtrlL> Modifiers.

Here is the resulting .blend. I've applied the modifiers, so it should open in 2.49 just fine.

Great answer! I love the GIFs instead of static screenshots - nice touch. I normally use 2.7 but in this case needed to export the mesh to a NIF using NIFScripts (which only works with 2.49 or lower). I'll play with this file and practice the techniques above.

Ah, okay (just checking ;) Blender is pretty compatible between versions, so it should work to edit the mesh in 2.7, then open the .blend in 2.4 for exporting.


text:
OBJ imported into Nifskope has no texture
I'm a bit of a noob when it comes to Blender, so bear with me here if this question doesn't include all pertinent information at first.
I'm working with an existing mesh for Fallout3. The mesh has three (3) nodes, one of which I want to modify slightly. Using Nifskope 1.1.3, I exported the node to an OBJ file, then opened that OBJ file in Blender 2.71. In Blender, I trimmed away vertices until I had what I wanted, then I exported the object as an OBJ file.
Back in Nifskope again, I imported the OBJ file as a new NiTriShape. So far, all has worked as expected. However, the imported node will not show the texture applied to it, despite showing the correct texture path/file in both Nifskope AND Blender.
Obviously, I'm doing something wrong here - probably in Blender before the export - but I haven't had any success finding out what so far.
Any tips in the right direction are greatly appreciated.
EDIT: I've tried pointing to other DDS textures, in case the problem was my custom texture. Same thing - just a flat gray with no texture applied. I also tried adding a BSShaderPPLighting node (incl. BSShaderTexture) to the NiTriShape, and pointing that to various textures as well. Same issue. I'm starting to think the problem is with the UV mapping in Blender, but I could be wrong.

Not sure what the issue was exactly, but apparently it was with my export. After downgrading to Blender 2.49 and installing the Blender NIF scripts, I was able to export the mesh directly as a NIF (instead of OBJ, then NIF) and now the textures work properly.
By having both versions of Blender installed, I can work in 2.71 with its much-improved interface, then open the *.blend file in 2.49 to export it as a NIF.

authors: Αλέξανδρος Ματσουλιάδης


text:
How to unset multiple values from Bezier objects?
I'm creating poly hair using Bezier Curves. I set the bevel Object to create a solid object but right now I want to unset that value from multiple objects curves. Why? because some curves really looks strange so I have to fix this manually
I mean how to set and unset this from multiple bezier object curves, it's really a lot of work clicking multiple times for do this repeating work.
I also check this.
Add the Same Modifier to Multiple Objects at Once?
It doesn't work on Curves.

There is.
Set it for the active object, then right-click the property and select the option Copy to Selected


text:
How to insert keyframe only "Available" in blender 2.78?
There used to be a feature in insert keyframes pop up menu (press i).
Where is it now or how to achieve that in new blender 2.78?

This image is from internet i dont know which version of blender is this screen shot from. But this clears what i am looking for

It's not very clear what you are asking, could you please clarify? Please edit your question and provide some more context

What's the "Insert keyframes only used for @ashwin?  Give us an example.


text:
how to create vertex groups from materials using python?
I have assigned different materials to a single mesh. I want to create vertex groups from the materials assigned. Is it possible to create vertex groups from materials using python?

i see that you tagged "scripting".. do you mean that you wanna do It by code? or by 3D view?

Yes how to do it through python code

This script adds the verts assigned to the face assigned to a material to a vert group with the materials name.
import bpy
context = bpy.context
obj = context.active_object

for index, slot in enumerate(obj.material_slots):
    #select the verts from faces with material index
    if not slot.material:
        # empty slot
        continue
    verts = [v for f in obj.data.polygons
           if f.material_index == index for v in f.vertices]
    if len(verts):
        vg = obj.vertex_groups.get(slot.material.name)
        if vg is None:
            vg = obj.vertex_groups.new(name=slot.material.name)
        vg.add(verts, 1.0, 'ADD')

You can do it manually. Just hover over a vertex and click "l" and then f6 and choose material instead of seam or sharp.
After that assign the selected vertices to a vertex group.

I am aware of this method thanks. I wanted to do it through script.


text:
Exporting Object .obj with texture/ color
I have made an object with color in shader editor and now need to export that. So that I have a png file with my textures and a obj file for my mesh. but i cant figure out how

File > Export > Wavefront (.obj). Make sure that write material is checked, this will generate the .mtl file with reference to the texture.

Just for the keywords: You need to unwrap your model and bake the texture, if you want to get an image texture.

How can I do that? I colored a lot of objects with shader editor


text:
Active image of UV/Image Editor
After creating an image using:
bpy.data.images.new(name="NewImage2", width=512, height=512)

How would I set that image to the active image within the UV/Image Editor in Python?

You loop through area till you find the UV/Image editor and set the active image to you image
for area in bpy.context.screen.areas :
    if area.type == 'IMAGE_EDITOR' :
            area.spaces.active.image = my_img

Is there a way to do this if that space isn't open?

@user53145 try changing spaces.active to something like spaces["myspace"]

Here's the correct way to do it. This will work even if the UV Editor pane isn't open:
bpy.ops.image.new(name='Some Name')
image = bpy.data.images['Some Name']

bpy.data.screens['UV Editing'].areas[1].spaces[0].image = image

This would only work if you don't change your Blender screen layout at all. @Chebhou's answer is more robust.


text:
How do I get bookmarks to appear in 'fileselect' panel?
I'm a newbie to both Blender and Python so I'm not sure of the terms I use.
I have a number of button events that bring up the file select panel using
context.window_manager.fileselect_add(self)

when the panel is displayed on the right side I wish to see the
System (drives), Bookmarks and Recent files.
Is there a call I can make to have these displayed every time or
something else I need to make this happen?
Thanks

What do you mean 'have them displayed' they are always there, as far as I know, thought they may be in a collapsed panel. Not sure if there's a python API call to expand a specific panel.

Possible duplicate of Is it possible to expand/collapes all panels in a region with a keystroke or shortcut?


text:
How do I add a button to the 'fileselect' panel?
I have python code that displays the 'fileselect' panel to retrieve and image file. I would like to add a button and event code to this panel. Currently I initiate the 'fileselect' panel with the following after setting it up.
context.window_manager.fileselect_add(self)

Thanks

related: http://blender.stackexchange.com/a/6933/3710, http://blender.stackexchange.com/a/43828/3710, http://blender.stackexchange.com/a/26906/3710

Looking at your link helped and I got something to work, thanks


text:
Object doesn't show in edit mode

I just click tab to go to edit mode and the object disappears.
There aren't any armatures or anything else of that kind on the mesh. I'm using Blender 2.74 (latest one).

try pressing ALT->H in edit mode. It's possible that you accidentally pressed H when you where in edit mode and had everything selected.

When your in edit mode, press ALT H. This unhides objects. What happened in your case, was that you accidentally pressed H (hide) while you where in edit mode with everything selected.


text:
How to import multiple .obj files and keep the overall structure intact?
I am doing some research work on anatomy of human body, for which I want to use this project:  http://dbarchive.biosciencedbc.jp/en/bodyparts3d/download.html
This project is a 3D Model of human anatomy, containing hundreds of .obj files. Each .obj file is actually a model of a part of human body. I want to import all the .obj files in such a way that the overall anatomy of the figure is intact, i.e. all the structures are in their right place (so that I don't have to manually correct their position).
Edit:
Thanks @poor and @zeffii for your input. After a couple of hours of head-banging, everything seems to work now.
Here is what I did:

Used the script given in the post mentioned by @poor.
Modified the directory structure given in the script (which is for windows) to work with linux.
Imported the .obj files using the script

The script now looks like this:
#Script to import multiple .obj files into blender
import os
import bpy

# put the location to the folder where the objs are located here in this fashion
path_to_obj_dir = '/home/user/Desktop/brainstem/'

# 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)

Note:
There is something specific to this Human Anatomy project (link given above) that I want to share (hoping that it might help someone).
As mentioned by @zeffii, this project is huge. If yout try to import all the files at once, your system may crash.
The project contains some reference files, which have information about the file names and anatomical structures covered in them. This is very useful information because in this way you can divide the whole project into regions/systems and work with one region/system at a particular time.
The image given above is of "Brain Stem" which is made up of 11 .obj files.

Edit # 2:
@poor has written an add-on for blender in order to import multiple .obj files simultaneously in a more user friendly way. I am now using this addon and it works flawlessly.
Here is the link: How to batch import Wavefront OBJ files?
How to add this Addon:
Step # 1:
First of all copy the code of the plugin and create a file named io_import_multiple_objs.py

Step # 2:
In blender, goto "User Preferences" > "Addons" > "Install from file" and select the "io_import_multiple_objs.py" file you created in step # 1.

Step # 3:
Enable the addon

Now you can batch-import multiple .obj files. :D

Thanks @poor for this great addon :D

just tried. works flawlessly if you give it the correct Path.

I have no experience with python. But based on common sense, I need to edit this line: "path_to_obj_dir = os.path.join('C:\', 'objects')". What should be the syntax? I am on ubuntu linux and the files are on my desktop.

but.. it's a rather large folder, the import might take a while...or fail because it's too much geometry.

It works.. I have added all the details to the original question above. Thanks

@AhsanIqbal I've wrote a small addon: http://blender.stackexchange.com/a/31825/3710 to import multiple files. Hope this makes your life easier :)

@poor Thank you so much. The addon is really really great and works flawlessly... :D

Great! Glad I could help :) Maybe it is helpful for others to mention in your question that this addon is available, right? Could you edit your question?

Ofcourse. I should have thought about it earlier... :)


text:
How to copy Modifiers
I must be doing something wrong, I select my object which has two modifiers, press space, search for "Copy Modifier", and select it. I get the error message
"The object the data pointer refers to is not a valid modifier"
I have also had no luck with copying stuff like Materials.

Searching the error message in the source code shows 3 occurances, it appears that the "Copy Modifiers" operator is only available for some freestyle settings.
blender-2.69\source\blender\editors\render\render_shading.c
            BKE_report(op->reports, RPT_ERROR, "The object the data pointer refers to is not a valid modifier");
            BKE_report(op->reports, RPT_ERROR, "The object the data pointer refers to is not a valid modifier");
            BKE_report(op->reports, RPT_ERROR, "The object the data pointer refers to is not a valid modifier");

As described here Add the Same Modifier to Multiple Objects at Once? you could link the modifiers using Ctrl-L (Make Links) and select Modifiers.
Python:
bpy.ops.object.make_links_data(type='MODIFIERS')

The easiest way I've found to copy all the modifiers for an object is to tab out to Object mode and duplicate the object. Then tab into edit, select all, and delete. Then add your mesh while inside edit mode. This will apply all the modifiers to the new object. Works for me, i just wish there was a shortcut.

Why not use Ctrl+L > Modifiers?

You need to run these copy operators in a proper context, or they won't know what to copy.

In Properties Editor, use the Copy button in the Modifiers tab to duplicate.
In Material tab, use the Material Specials menu button (red arrow) and chose Copy Material.Paste Material with Material.001 selected would copy the material settings over and make it purple as well. It does not create a new material or replace the slot by Material.

The copy button in the modifiers tab does duplicate the modifier for the current object can it also be pasted to another object?

No it can´t, it just duplicate the Modifier to the stack of the same object. Theres gotta be a way to Copy/Paste in 3D viewport Modifiers & Materials. That´s the context you would optimally perform such operations.


text:
Python command within script to abort without killing Blender
When using the Text Editor, what is the best command to include inside a script which will abort the script at that line?
quit() and sys.exit() stop the script, but also kill Blender.

raise RuntimeError("Stopping the script here")

Obviously, this is not pretty.  I'd like to hear other ideas.

Running the script with this gives the message, Python script fail, look in the console for now... even though the script ran as expected (but exited because certain conditions were met)

Can you move the content of your comments to the answer? The answer is getting flagged for low quality because it's so short.

I believe the answer to How to break out of multiple loops in python? applies here too:
Refactor your script!
Don't run all your code in the global scope, but organize everything in functions.
This is how your script might look at the moment:
def process(val):
    return val * 2

for i in range(5):
    print(process(i))

If you already use some def's and call them from a small portion of code, which resides in the global scope (no indentation), make this portion another function and only place the call to this function in the global scope. If no, wrap your entire code into a function main() (you may use any name here actually):
def process(val):
    return val * 2

def main():
    # This code used to be in the global scope...
    for i in range(5):
        print(process(i))

# ... but now, only the call to our 'main' function resides in global scope!
main()

What do we gain?
Now it's easy to raise an exception at any level of your script, and catch it at the highest level, so no error is printed or otherwise shown to the user:
class ExitOK(Exception):
    pass

def process(var):
    raise ExitOK # quit script immediately
    return val * 2

def main():
    for i in range(5):
        print(process(i))

try:
    main()
except ExitOK:
    print("OK")

I derived the class ExitOK from the Exception class to create a new exception, so we can raise and catch a distinct one. This means the script can still error out on other exceptions and show a traceback.
No need to code anything for our ExitOK exception for our purposes, we just use pass, 'cause every class needs a body.
You could also define another exception, e.g. ExitError, to stop your script at any level and print a different message (to inform about the error without the Blender popup thing):
class ExitError(Exception):
    pass

# ...

try:
    main()
except ExitOK:
    print("OK")
except ExitError:
    print("Failed")

You could also give more detailed information about the exit reason like so:
def process(val):
    raise ExitError("quit process() with value %i" % val)

# ...

try:
    main()
except ExitError as e:
    print("Failed:", e)

If it is meant to be temporary while drafting the script, raising an exception is probably the easiest solution.
raise Exception()

If it is not meant to be temporary you may consider reorganizing your code using additional functions or logic/control flow. Python actually runs faster if the code is wrapped in functions. (see this post on stackoverflow)
The equivalent to running the code from the text editor is (see api docs)
filename = "/full/path/to/myscript.py"
exec(compile(open(filename).read(), filename, 'exec'))

Calling sys.exit() raises an exception which is allowed to propagate and thus exits blender. (see
SystemExit,
exit(),
exec()
)
You may run your script manually with exec and catch an exception, i.e. SystemExit, with try ... except.

Open the python console before running the script.  If you want to stop the script click on the python console and press control-C.

how will this work, ctrl C is "copy to Clipboard"?

Think he means system console, rather than python console.

Another way is by using pdb:
import pdb
print("Before")
pdb.set_trace()
print("After")

When the pdb.set_trace() executed you can choose (type in the console) if you wish to 'continue' or 'exit()' continue will print the "After" while the 'exit()' will exit the script but will keep blender alive.
Hope it help someone.


text:
Rotate object around cursor with Python
What Python command rotates an object around the 3D Cursor?

Assume you already have the Pivot Point set to 3D Cursor (although this could be done in Python also)

You can use the operator bpy.ops.transform.rotate(), but you need to override the context or else it will only rotate around the object's median point.
import bpy

def get_override(area_type, region_type):
    for area in bpy.context.screen.areas:
        if area.type == area_type:
            for region in area.regions:
                if region.type == region_type:
                    override = {'area': area, 'region': region}
                    return override
    #error message if the area or region wasn't found
    raise RuntimeError("Wasn't able to find", region_type," in area ", area_type,
                        "\n Make sure it's open while executing script.")

#we need to override the context of our operator
override = get_override( 'VIEW_3D', 'WINDOW' )
#rotate about the X-axis by 45 degrees
bpy.ops.transform.rotate(override, value=6.283/8, axis=(1,0,0))


text:
Control what properties displayed in F-Curve Editor
Using Python, I would like to control what is displayed in the F-Curve Editor (in the Graph Editor window).
For example, say I want to display bpy.context.scene.gravity.

How to display this property if it's already been keyframed?
How to display it if it hasn't been keyframed?
How can I undisplay any other F-curves? (e.g., say a keyframed object also happens to be selected)

From the wiki manual:

Header Tools
Show Selected Only

By default, the Graph Editor shows the channels for the active object only. Toggle this button off to show channels for all objects.

Show Hidden

Enable this to show channels from objects/bones that are hidden.

Show only matching F-Curves

Use this to only include F-Curves that contain the specified text.

Filters

Show options for whether channels related to certain types of data are included.

If you want to change these settings you should have a look at

bpy.types.SpaceGraphEditor
bpy.types.DopeSheet
bpy.types.FCurve

If you are using an operator which will be called from the graph editor, the space data is available from
space = context.space_data
dopesheet = space.dopesheet

I.e.:
dopesheet.show_only_selected = True
#select the objects you want to show
obj.select = True

Another example:
#show only objects from the group named 'Group'
dopesheet.filter_group = bpy.data.groups['Group']
dopesheet.show_only_group_objects = True

#don't show object transformations and scene properties
dopesheet.show_transforms = False
dopesheet.show_scenes = False

Hide a fcurve:
#only accessible by index
fcurve = obj.animation_data.action.fcurves[0].hide = True
#fcurve's attributes data_path, array_index provide more information about it

or select it:
fcurve = obj.animation_data.action.fcurves[0].select = True

If the object has not been animated:
The minimum requirement to show up in the graph curve is existent animation data with an action assigned to it which possesses at least one fcurve.
So if the object has not been animated yet:
if not obj.animation_data:
    obj.animation_data_create()
    obj.animation_data.action = bpy.data.actions.new('myAction')
    #create an fcurve for the x coordinate
    obj.animation_data.action.fcurves.new("location, 0)


text:
Is it safe to delete the cache?
Does deleting the cache files in the USER directory hurt anything?
The user directory where the cache in question is:
{username}\AppData\Roaming\Blender Foundation\Blender\2.70\cache

Also is cycles what is generating this cache?

Related: http://blender.stackexchange.com/q/9291/599

Yes, cycles caches BVH (Bounding Volume Hierarchy) files in there when Cache BVH is enabled in Render settings > Performance:

Deleting them shouldn't do anything bad. Cycles will just regenerate these files (though it won't cache them if you disable Cache BVH), which might cause an increase in render times, depending on the complexity of your scene.

Thanks for the hint, the name of the caches should have helped me guess what it is though :p


text:
Is there a way to have one material for cycles and the BI
Is there any way to make a material work in cycles and the blender internal?
I'm looking for a way to have only one material in the material slot, but a different material for cycles and blender internal.

If you don't use material nodes in your BI material, then yes, kind of. By enabling and disabling material nodes you can switch between the BI material and the Cycles material.

Without material nodes
You can sort of do this by enabling and disabling material nodes. (note that you cannot use material nodes in your BI material with this approach)
For example:

Create a BI material:

Switch to cycles and enable material nodes:

Create a cycles material:

Switch to BI and disable nodes:

Your original BI material will appear unchanged.
With material nodes:
If you do need material nodes for your BI material, then you will have to create both the cycles material nodes and the BI material nodes in the same node tree:

Note that you can only add nodes for the render engine that is selected (though I think you can add any node regardless if you add them from python), so you will have to switch the selected render engine back and forth.

Just checked myself yes having both material setups in the nodes works with out any changes to the material properties. Thanks for the great idea.


text:
How to pause the BGE and then resume
With the logic setup below I'm trying to pause the game, then on any key stroke resume where it was paused. Trouble is when the BGE is Paused it seemingly can't listen for any input.
click image for full size

It does appear that a suspended scene does not respond to any events, which sounds right when you think about it.
A solution is to use a second scene to control the play. When starting game play connect a scene actuator that sets a second scene as a scene overlay. This second scene only needs one object, which can be an empty, and contains the pause/resume pieces as you have shown, just with the pause/resume scene set to the first scene not the second that has the pause controls.
If you have setup a scene as an overlay to display scores etc then you can just use one of these objects.


text:
Cloth sim makes hole in my cloth
When I bake my cloth sim so the cloth will fall on the chair,instead of covering it like it is supposed to,the back of the chair rips a hole in the cloth. How do I stop this?

Try increasing the collision quality in Physics > Cloth Collision.

You could try a couple of things:

Increase the "Distance" value under Physics > Cloth Collision
Increase the Structural Stiffness of the Cloth
Increase the Repulsion Force
Increase the Repulsion Distance
Increase the Collision Quality under Physics > Cloth Collision

in physics turn "Off" collision for the cloth.  Collision just needs to be on the object it collides.


text:
How do I get my layers back?
My layers are gone and I'm in global view. How do I get them back? I've tried the numbers, shift + numbers, I'm in global view and nothing works. Please help!

Could you upload a bigger screenshot or a .blend?

@cegaton The OP says they are in global view (which was the issue in the question you linked).

yes, it worked!!! thank you! I had pressed the / button.


text:
How do I fix the pivot point of my vertex
The pivot point of every vertex in the mesh of my object is out of position for some reason how do I put it back to where the geometry of my vertex actually is. I tried origin to cursor but it will say you could not do apply this in edit mode.

As illustrated in the picture above the pivot point is far from where the vertex is located.

Yes the 3d Manupalor's origin is what I am talking about. here is the copy of my .blend file. link

This is because the armature modifier is not taken into account (this is intended behavior), so the pivot point is at the non modified location of the selection.
This becomes obvious when toggling Modified edit cage (the triangle icon on the modifier):

To make things more manageable, try disabling the modifier in edit mode:

Also see Why is vertex snapping with auto merge enabled not merging vertices?

Switch out of edit mode back to object mode and try the "Origin to 3D Cursor" operation again.  It should work.

yes it works but that is not what I wanted to do. I want to fix each vertex so that the pivot of every vertex is in its center. Not the pivot of the whole 3d object itself.

You can assign  every vertex of a mesh to be a pivot point, but only one at a time. You do this by setting the pivot point to "active element", and selecting the vertices as you want to change the pivot point. Just as you cannot have more than one active element at a time, you cannot have more than one pivot point at a time.

well the problem is when I snap using the magnetic too from vertex to vertex. It does not snap correctly, it snaps to the point where the pivot seems to be located. This is happening in all vertices

@user4956 Do you have any modifiers?

Sounds to me like you have scaled, rotated, or translated the vertices, without applying the translation, scale or rotation. To do this, go to object mode, and press SHIFT-Akey, or from the operation search function, type "apply".

@brasshat The scale and rotations shouldn't affect snapping. Also Shift A is Add, did you mean Ctrl A?

Yes, gandalf3, I did mean "CTRL-Akey". And while I wouldn't expect rotation to affect snapping, i'm not as sure as you are that translation would not. Also, this would not be the first time I found Blender behaving in a way I didn't expect. Of course, most of the time the fault lies with my expectations, but still.......

@brasshat I did what you said and it still does not solve the problem. Here is the copy of my .blend file link

Post a ~.blend file.

@brasshat I posted the link to the file above


text:
Know when edit-mode is entered by script? (python)
How would I know through a script when the switch to edit mode happens? I need it for modal operator.
I was thinking on listening for 'TAB' event and checking obj.mode, but I hope there is a better way, for reasons like changed edit-mode shortcut or switching to edit-mode by script.

In your modal operator you can test object.mode for which mode the object is in - example:
import bpy

bpy.context.active_object.mode   # = 'OBJECT'

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

bpy.context.active_object.mode   # = 'EDIT'

There is no callback, you will need to test this on 'tab' event or always to be sure..

Alternatively, you can check bpy.context.mode which will be EDIT_MESH if in edit mode

In 2.8, you can use message bus to do that:
The principle is to obtain the path using a path name through the object.
Then declare a subscription to message bus.
import bpy

#The callback when then change occurs
def a_callback(object, data):
    print( object, data, "changed" )

def subscribe_to(object,data_path,callback):

    #Get a rna subscription link from the object
    subscribe_to = object.path_resolve(data_path, False)

    #Effectively subscribe to the rna path from the object
    bpy.msgbus.subscribe_rna(
        key=subscribe_to,
        owner=object,
        args=(object,data_path,),
        notify=callback,
    )

subscribe_to(bpy.context.object,"mode", a_callback)

Note: bpy.msgbus is not documented for now. But it contains few functions that we can find using the Python console:

Or via context.mode?

@batFINGER, is it supported?

There is no way to "trigger" your script when the user enters edit mode. The only way for you to run your own code on entering edit mode is to set the keyboard shortcuts to run your script instead of changing to edit mode.
As it sounds like you are referring to switching to edit mode while your modal operator is running, you will need to check the event and enter edit mode when the tab key is pressed, other operators will not be run while your modal operator is running.
def modal(self, context, event):
    if event.type == 'TAB':
        if context.active_object.mode == 'EDIT':
            bpy.ops.object.mode_set(mode='OBJECT', toggle=False)
        else:
            bpy.ops.object.mode_set(mode='EDIT', toggle=False)

other operators will be run if the modal returns {'PASS_THROUGH'}


text:
Consistent triangulation when exporting shape keys
I am attempting to export objects from blender into .obj format for use in an opengl program I am writing.  Currently, I am attempting to create shape keys in blender, then export them, then interpolate between them as my program runs.
Below is the python command that I use to export the .obj file.
bpy.ops.export_scene.obj(
    filepath = temp.name,
    use_selection = True,
    use_edges = False,
    use_normals = True,
    use_uvs = True,
    use_materials = False,
    use_triangles = True,
    keep_vertex_order = True)

Both the initial and final steps of the animation look as expected, with the shape key either applied entirely, or not applied at all.  However, in the interpolation between the two shape keys, there are graphical issues as shown below.

This seems to be caused by inconsistent triangulation between the two different shape keys, since the diagonal between the corners of the rectangles goes in the opposite direction at the two ends of the animation.  I would not have expected this, since I had passed the keep_vertex_order flag to the exporter.  Am I understanding the issue correctly, and is there a way to keep consistent triangulation?


text:
Active collision bounds in the BGE?
How can I have collision bounds that are exact, even during animations. If I have a character with a simple rectangular prism, it won't be realistic. I could have an exact copy in shape but the animations will play and it will be ruined. I could have animations on the collision bounds, but then being stable to the ground won't happen. I could just have simple bounds then another set of perfect bounds, but dynamic object will hit only the simple one. There is obviously another technique for the next step in this topic. How can I have collision bounds that work with dynamic objects, and are perfect in shape to the original character that are also stable to the ground?
I would prefer solutions that do not include python.

What do you mean?

Ok, I ignored the "no Python" requirement because the absolute simplest way of doing this requires very few lines of code.  Doing it brick-only would be loads of work and very dirty.
Attach this to your animated mesh and run it every frame.  It will update the physics to match the mesh.
import bge

def update(cont):
    own = cont.owner
    own.reinstancePhysicsMesh()

if __name__ == '__main__':
    update(bge.logic.getCurrentController())

Example blend
Of course, being parented to the armature means it wont be affected by gravity.  So you'll need the armature parented to another object for controlling movement.  Make use of Collision Group / Collision Mask to prevent unwanted interference.
EDIT - Example with collision masks

Tell me this, when an object collides, i've seen, it hits what the object looks like. When will it register its collision?

The collision registers right when it hits.  You can add a Collision sensor -> And controller -> End Object to the falling object and confirm this.  Er, and it looks like a rogue property (dyn) found its way into the file.  It does nothing and I have deleted it.

Honestly, you did well. I had 2 of 3 of my biggest bge problems solved today. Let me implement it into my game files, and if it works i'll have you as correct answer. Otherwise, i'll update you on it, I will try to have it done soon.

How do I add the green/red borders?

That would be the physics visualization debug mode.  Toggle with Game -> Show Physics Visualization near the top of the window.

And one more thing, the bullet would collide with the parent of the armature, and you said to "Make use of Collision Group / Collision Mask to prevent unwanted interference." How would I use that to make the bullet not interfere with the controller?

Each object needs to be part of one or more collision groups.  Then you'll check a collision mask box for each group that the object should collide with.  It will take some thinking to narrow down which objects should belong to what group.  Basically the movement mesh should be in a group that isn't detected by the bullets.  Set in the physics panel.

Thanks. I have done instructions, and I placed a sphere with an animation where it just moves forward through the player. The white lines, the ones that stay the same all the time, seem to be the ones the ball hits. When the player is in his animation, the collision bounds don't seem to change.

Let us continue this discussion in chat.

pq can you talk in chat pls?

This example should have everything you need.  The animated mesh updates the physics shape every frame, and the bullet (sphere) ignores the player parent object (cube).  If you are unable to replicate this in your own file, there is likely another object getting in the way.  If it works I'll update the answer.  https://dl.dropboxusercontent.com/u/19279604/static/misc/physics_shape_with_mask.zip

I replicated it to the exact, and my controller along with character keep colliding! I tried everything, and i'm starting to get really frustrated!

I can replicate it with 3 cubes, but not my situation! I have bounds, a character, and a rig. The rig is set to no collision, my character to static, and my controller to dynamic. Character is child of rig, and rig is child of controller. To be more specific, I want the character to not collide with bounds, but collide with bullets. I want bounds to not collide with character or bullets, but collide with map. I tried everything, and nothing works.

What you're looking for is Rigid Body Collisions Shape. This option lets you select how the collision bounds of the object collide with other objects. this can be found under the Physics tab.

Obviously, you don't want a man with cube collisions. Triangle Mesh is the BEST option!
This makes the collision surface a triangulated copy of your object and will move with your object even in animations.
Of course there are other options that the computer can calculate faster, so don't use Triangle mesh unless you need it. If Box will do, use it.
Here's an example.

You can see what's happening in the physics visualization under game options.

I have already posted that answer, and the OP said it didn't work.

@BlenderDev what doesn't work about this answer?

With triangle mesh, it doesn't update with animations.

The exact issue with any standard RigidBody collisions.

May you post the .blend?

I actually don't want anyone to see it, it may seem weird to hear, but it is a long story. For the most part,  I have a character, a rig, and a controller. The rig is parent of character, so it cannot be affected by gravity. Therefore, I made a controller for movement and to be parent of rig. I want it to collide with some things, but not all. I want the character to collide with all. Sorry, I just realized I didn't mention this in question. However, I just want to know how to have the controller not interfere and collide with bullets.

Does the mask question answer this?


text:
How to use playAction() on libloaded objects in BGE?
I'm loading the file like this:
logic.LibLoad(logic.expandPath('//car.blend'), 'Scene', verbose=True, load_actions=True)

And I get my object (without using addObject() BTW, is it how it's done?) fine, I can basically do what I want with it. But I cannot seem to use its actions.
And at loading time I can see the action being loaded in the console output:

SceneName: Scene
  ActionName: Car.flipOver

This is how I start the action:
    name = "Car.flipOver"
    start = 1.0
    end = 10.0
    layer = 0
    priority = 1
    blendin = 1.0
    mode = logic.KX_ACTION_MODE_PLAY
    layerWeight = 0.0
    ipoFlags = 1
    speed = 1.0

    # (tests to see if the car is stuck)

    self.playAction(name, start, end, layer, priority, blendin, mode, layerWeight, ipoFlags, speed)

Not only the action does not play, I get no warning or error message of any kind! (at least when you omit the load_action parameter you get a fair "failed to load action").
Can somebody explain to me how one can access actions in externally loaded .blend files.

the problem seems to be in the playAction arguments exactly in ipoFlags = 1 it should be ipoFlags = 0
I have no idea why but this is what got it working at least in my test file


text:
Remove Unused Keyframes?
I would like to be able to clean unused keyframes from my dope sheet, ones that aren't doing anything.
I read online that you press 'O' in the dope sheet to do this, but I tried it and it didn't work. So, I looked for the hotkey and preferences, and it isn't there!
Is there a way to do this?

I do believe pressing O used to run this tool in the Dope Sheet, but for consistency with the other editors O now seems to enable proportional editing. Now the 'Clean Keyframes' option resides in the Key> Clean Keyframes menu.

WARNING This will reset ALL interpolation back to the F-Curve default Interpolation.

I found that right away and tried it, but it doesn't delete the keyframes :P Apparently it just removes closely spaced keyframes to simplify the curves.

Hey I found it! Just press delete and select "Clean Channels"

I couldn't find a 'Clean Channels' option in 2.75, I only found that the same 'Clean keyframes' tool I mentioned is also displayed in the 'delete' menu.

'Clean keyframes' is designed to do this task for you. However, it will destroy work you put into applying and editing interpolation settings.
The safest way to remove unused keyframes is to open up the F-Curve editor, zoom in with the ctrl and middle mouse button and select keyframes that are zeroed those are the ones that are zeroed. You may want to leave some if you animation requires it.
Unfortunately, this method won't help you if you have posed a character and keyed the same pose multiple times.


text:
3-bone IK chain not rotating properly, why?
I ran into a weird bug where my 3-bone IK chain isn't behaving as expected. I've made other quadrupeds in the past and had no problem like this. As far as I can tell, the IK constraint is also exactly the same as all others I've made. Here are some GIF examples.
This is what I would expect from a good 3-bone IK leg: https://gyazo.com/98754f4cdb2f08d87d9ce5734c5b367e
This is what I'm getting now, the upper bones are barely rotating:
https://gyazo.com/0ea27bb19a79a998cf1cfe44400b36c5

Did you check the stiffness values of every bone of the chain in the Inverse Kinematics tab of the armature properties panel?

As it turns out, the severity of the rotation in the chain directly effects how well the IK will work. A subtle rotation isn't enough, but as soon as I bend the chain a bit more in edit mode, the IK picks up quite a bit of rotation.


text:
How to bake ambient occlusion into vertex colors?
This is frustrating for me. The UV-textures to vertex cols add-on doesn't seem to work despite the specific instructions. Any other tutorials I can find are either very old or very poor.
I'd like to know how to do this in Blender 2.79. I need vertex colors in my ambient occlusion for use in Shader Forge.

Quick overview of the bake process & preview in Blender Render

How to bake the ambient occlusion into vertex colors

Select the object and make sure the object has a vertex color layer assigned in Object Data > Vertex Colors. If not, create one by clicking the plus button.

Navigate to the Render tab > Bake. Select Bake Mode: Ambient Occlusion and Bake to Vertex Color

Select the object and hit Bake

Blender Render material setup to see the vertex colors

Select the object's material and enable these:

Shading > Shadeless

Options > Vertex Color Paint

Switch to viewport shading to Material
Optionally, if you want to see your texture blended with vertex colors, you can go to Texture tab > Influence and set the Blend: Multiply

Cycles material setup to see the vertex colors

To add vertex colors into node tree, use Attribute node with the name corresponding to the object's vertex color layer name (it is named Col by default).
In the example below, you can see a simple shadeless material where vertex colors and an image texture are combined:

Nice answer. Could please add a short textual description of the process describing the steps so it is searchable and indexable?

Awesome!! Thank you so much Jan! :D I was losing hair over this. So simple too.

Duarte Farrajota Ramos: updated the answer to include written steps

Is there a way to get this working in Blender 2.90?

@unfa The feature is now back with 2.92


text:
How can I erase part of a mesh using another mesh?
I need a way to erase accurately a part of a mesh, using another mesh.

I need the big mesh to have a gap where the smaller mesh is.
I don't need the smaller mesh, so it doesn't matter if it gets destroyed in the process/

use a boolean Mod

I realised that might help, but I have no idea how to do so, when I tried, nothing happened

answered.....read below

This can be accomplished with a boolean modifier.
Add it on the large mesh and set the type to difference, then set the smaller mesh as it's target.

once you apply the modifier, you will have a hole in the large mesh, you may delete the small mesh

Thanks, I already tried it but it didn't work, turns out I had a copy of the mesh visible, so I didn't see the gap

if this solves your problem, accept it so we can mark this as solved.


text:
How to repair the deformation made by armature
I am trying to rig the back legs of an animal, but the armature deforms it's knees and upper legs weirdly. This is the position in which it was modeled:

When I wanted to rotate the lower or upper leg, it turned out like this:

How can I fix it? (I have already tried reassigning, but maybe the wrong way)
Thanks for help.

First off, and I can't tell if you did, you should always have the limbs fully extended when weight painting the rest pose. Secondly, you need to make sure you are using less than full weights on overlapping vertices. It looks like you have no transition space. You can do this by changing the strength of your weigh paint brush in the T menu. Let me know if you think this is your issue so I can add a detailed answer.

I didn't yuse weight painting at all, although i knew that it's usualy used. This is my first rig, so I assigned vertex groups only in edit mode by selcting all the faces I wanted to deform and assignign them to the bone.

Well at least we know what the problem s now. :P

@aky-her That is what your issue is then, when you use vertex groups, all the vertices have a value of one or zero. You need to paint the fading parts in between that are affected by both bones

When adding items to a vertex group, the default weight is 1.0. The weight value is a floating point number that's clamped between 0.0 and 1.0. There's a slider for adjust it to the value you want. Besides, even paint mode is going to use vertex groups.


text:
Creating A Thatched/Rattan Material?
Trying to make a thatched material (for my lamp shade). Like a rattan type look. Can't figure this one out for the life of me. Here's an example: http://thumbs.dreamstime.com/t/rattan-texture-5839027.jpg
How would you make something similar?
Thanks!

Do you need a close up?

@someonewithpc Yes sir. I mean, not really close, but it's for game art so potentially it could be.

One way to get this would be:

Add a plane, in Edit Mode subdivide W
Poke Alt-P

This should look like:

In top view Numpad-7 rotate 45° R 4 5
Scale along X-Axis S X
Select one of the new (poked) vertices and select Amount of connecting edges from the Shift-G popup
Move the selected vertices upward G Z

In Object Mode add a Subdivision Surface* modifier with subdivisions set to 3:

Bake the normals of the resulting mesh to an unwraped plane and use the image as normal map.


text:
Is there a quick way to override the UI widget for a single property in an addon?
I'm experimenting with an addon that has multiple properties.  I want one of them to be a drop-down that lets you pick from the list of armatures.
I have found example code where you can override the draw() method of the operator:
class ParentGearsToActive(bpy.types.Operator):
    """connect selected gears to active gear and ensure that they mesh correctly"""
    bl_idname = "mesh.parent_gears_to_active"
    bl_label = "Parent Selected Gears To Active Gear"
    bl_options = {'REGISTER', 'UNDO'}
    bl_region_type = 'UI'

    phase_degrees = bpy.props.FloatProperty(name="phase", default=0, min=0, max=1)
    offset = bpy.props.FloatProperty(name="axial offset", default=0)
    master_rotor = bpy.props.StringProperty(name="Master rotor", default="")
    armature = bpy.props.StringProperty(name="Armature", default="")

    def draw(self, ctx):
        layout = self.layout
        row = layout.row()
        row.label(text="Phase:")
        row = layout.row()
        row.prop(self, "phase_degrees", text="")

        layout.label("Axial offset:")
        layout.prop(self, "offset", text="")

        # armatures = { "objects" : [ o for o in ctx.scene.objects if hasattr(o.data, "bones")]}
        # that bit doesn't work how I want, continue stupidly
        armatures = ctx.scene

        layout.label("Armature:")
        layout.prop_search(self, "armature", armatures, "objects", text="")
        layout.label("Master rotor:")
        layout.prop_search(self, "master_rotor", armatures, "objects", text="")

However, when I consider applying this to another operator which has around 12 properties, I begin to cringe.  Am I overlooking a better way to define the property that would let me avoid overriding the draw() method?


text:
Change background color in Image Editor for transparent image
I'm rendering an image with a transparent background, which will eventually be included in a figure with a white background. In the Image Editor, blender displays the transparent regions as a grey/black checkerboard pattern. This is helpful, but I would like to get an idea how my image looks on a white background whenever I re-render.
Is there anyway to temporarily set the background color of the Image Editor?
Here's what it looks like, and as you can see, it's a little hard to tell if the render would look pretty on a white background:

Use the Compositor, with this node setup:

It just takes the areas with an Alpha value, and replaces them with the color specified in the Alpha Over node.

@DanHickstein If this answer has satisfactorily answered your question, consider marking it as accepted by clicking the checkmark next to it :)

Oh yes, the most important part! :)


text:
Revert parts in a Multiresolution sculpt to their original position?
Is there a way to selectively "undo" sculpting deformations in a Multiresolution sculpt? Sort of a "bring back the base shape" brush or similar.

I have some thoughts on how this may be done but nothing that is really straight forward and one-click only.  You should be able to bake a height map and then use this height map to drive a Displace Modifier.  Since the Displace modifier can use Vertex groups, you can paint a mask that will determine which areas are displaced by the baked map and which stay the same as the base mesh.  The setup and learning curve may be more trouble to you than it's worth.  Let me know if you are interested and I will try and come up with a relatively simple walk-through.

That's fine, thank you. I understand your approach. Thanks for taking the time to write it down!


text:
Why do multiple keyboard inputs stop playing an action?
I have a simple character, who has simple animations. In the logic editor, I have a Keyboard sensor (W) > And controller > Action actuator set to Loop stop.
I did the same with another keyboard sensor (S). When I play the game and use W it's fine, and when I use S it is also fine. But when I press both of them (W+S) and let go of only one of them, the animation stops.
This only happens when I wait for a second after pressing one (W or S) and then press a second. In other words, the game is fine until I press 2 of the functions at once.
How can I let both W and S work fluently with Loop Stop enabled?

Please don't close question, like always, I tried to make it as clear as possible, I am in danger of being blocked!

I'm not entirely sure what you are asking, but here's a guess anyway.. Does it work if you use an or controller instead of and?

THANK YOU SO MUCH! MAKE THIS AN ANSWER AND ILL PICK YOU!

This is because an and controller requires all connected sensors to be true to pass a signal to the actuator. An or controller requires that at least one of the inputs is true.
Think of it this way:

An and controller requires both sensor 1 and sensor 2 to be true.
An or controller requires either sensor 1 or sensor 2 to be true.

This is just boolean logic, see the wiki for more details.