text:
What causes the wrong value read-out in a Pie menu value slider?
Below you can see that the Normal size value is 737cm while it is actually only 37cm.

Here is the code - any idea if this is a bug or a mistake I did?
def draw(self, context):
    layout = self.layout

    mesh = context.active_object.data
    scene = context.scene

    pie = layout.menu_pie()
    pie.prop(scene.tool_settings, "normal_size", text="Size")

Those numbers are really, unless i'm mistaken, the menu indices. The 7 isn't from the normal_size, but from the index of that pie-item. It's drawing the slider rather awkwardly close to the index. Leading me to believe pie menu's weren't intended to be used for drawing sliders, else it would be a common use case, and have a nice obvious solution. Maybe it does? someone will correct me if there is.
In any case it looks like the pie menus could be more thoroughly documented. I don't think it's a bug rather a misunderstanding of how to use it. It seems mostly geared towards toggling and executing operators.
The only way I know how to suppress the index is by making a row out of the slider.
def draw(self, context):
    layout = self.layout

    mesh = context.active_object.data
    scene = context.scene

    pie = layout.menu_pie()

    row = pie.row()
    row.prop(scene.tool_settings, "normal_size")
    pie.prop(mesh, "show_normal_face")
    pie.prop(mesh, "show_normal_loop")
    pie.prop(mesh, "show_normal_vertex")
    pie.prop(mesh, "show_faces")
    pie.prop(mesh, "show_edges")

All kinds of crazy things can be done with piemenus
Columns
def draw(self, context):
    layout = self.layout

    mesh = context.active_object.data
    scene = context.scene

    pie = layout.menu_pie()
    col = pie.column()
    col.prop(scene.tool_settings, "normal_size")
    col.prop(mesh, "show_normal_face")

Rows
def draw(self, context):
    layout = self.layout

    mesh = context.active_object.data
    scene = context.scene

    pie = layout.menu_pie()
    row = pie.row()
    row.prop(scene.tool_settings, "normal_size")
    row = pie.row()
    row.prop(mesh, "show_normal_face")

box
def draw(self, context):
    layout = self.layout

    mesh = context.active_object.data
    scene = context.scene

    pie = layout.menu_pie()

    # option 1
    box = pie.box()
    col = box.column()
    col.prop(scene.tool_settings, "normal_size")
    col.prop(mesh, "show_normal_face")
    col.prop(mesh, "show_normal_loop")
    col.prop(mesh, "show_normal_vertex")

    # option 2
    box = pie.box()
    col = box.column()
    col.prop(mesh, "show_faces")
    col.prop(mesh, "show_edges")

I feel ashamed ... Thank you so much for you help. I got the feeling as well that the Pie menu concept is not yet fully refined to work with the general interface elements! I agree that the however the Pie Menu idea is pretty nice and what you can display in it so you do not have to use the main menu.


text:
Mesh / object mode with Pie menu?
The following command in edit or object mode is the same to create a new mesh cube:
bpy.ops.mesh.primitive_cube_add

I structured my pie this way but nothing happens - only when I am in edit mode.
I assume because mesh.primitive_cube_add is a mesh object? But it is the same readout in the console, when in object mode I press shift A and select the cube.
import bpy
from bpy.types import Menu

class NewPie(Menu):
    bl_label = "Select Mode"
    bl_idname = "mypie"
    def draw(self, context):
        layout = self.layout

        pie = layout.menu_pie()
        pie.operator("mesh.primitive_cube_add")

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

    wm = bpy.context.window_manager
    km = wm.keyconfigs.addon.keymaps.new(name="Mesh")
    kmi = km.keymap_items.new("wm.call_menu_pie", "E", "PRESS", shift=True, ctrl=True).properties.name="mypie"

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

if __name__ == "__main__":
    register()

    bpy.ops.wm.call_menu_pie(name="NewPie")

You have to add the shortcut to the Object Mode shortcuts so it would be captured when you are in object mode, so the register function would be like this :
def register():
    bpy.utils.register_class(NewPie)
    #Add shortcuts
    wm = bpy.context.window_manager
    #Edit Mode
    km = wm.keyconfigs.addon.keymaps.new(name="Mesh")
    kmi = km.keymap_items.new("wm.call_menu_pie", "E", "PRESS",shift=True, ctrl=True).properties.name="mypie"
    #Object Mode
    km = wm.keyconfigs.addon.keymaps.new(name="Object Mode")
    kmi = km.keymap_items.new("wm.call_menu_pie", "E", "PRESS", shift=True, ctrl=True).properties.name="mypie"

Aha - I was not aware of that Mesh is in deed referring to the edit mode. I understood it as the mesh area in the keymaps for sorting purpose in the preferences UI.

I just want some clarification here: the hotkey is determined by the section of the keymap it's in, not the viewport context? I was under the impression blender is based almost entirely on context. Maybe I'm misunderstanding the term.

Nope, it's a little different. How you call keymaps.new will determine which context will trigger the menu. Currently you add the shortcut to Mesh, which is EDIT_MODE, therefore the menu only appears when you are in edit mode.
Instead of adding it to Mesh and Object Mode separately you might consider adding it the generic 3D View keymappings, this will then trigger the menu whenever the mouse is in 3d view and you press the key-combo.
km = kc.keymaps.new('3D View', space_type='VIEW_3D', region_type='WINDOW')

Then inside your Menu layout you add logic which determines what kind of things to show depending on the mode of the Object.

import bpy
from bpy.types import Menu

class NewPie(Menu):
    bl_label = "Select Mode"
    bl_idname = 'kwanza'

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

        pie = layout.menu_pie()
        pie.operator("mesh.primitive_cube_add")

        # if context.mode == 'OBJECT':
        #     something with object mode
        # else:
        #     something with edit mode

addon_keymaps = []

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

    wm = bpy.context.window_manager
    kc = wm.keyconfigs.addon
    km = kc.keymaps.new('3D View', space_type='VIEW_3D', region_type='WINDOW')
    keymaps = km.keymap_items

    new_shortcut = keymaps.new("wm.call_menu_pie", "SEMI_COLON", "PRESS", shift=True)
    new_shortcut.properties.name = 'kwanza'
    addon_keymaps.append((km, new_shortcut))

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

    for km, shortcut in addon_keymaps:
        km.keymap_items.remove(shortcut)
    addon_keymaps.clear()

if __name__ == "__main__":
    register()

A small note about the code you pasted in your Question.
The last line should be bpy.ops.wm.call_menu_pie(name="mypie").
When you don't add a bl_idname to the Menu definition then you can call operators directly using the class name, otherwise if bl_idname is specified then you must use that instead.

A useful way to get a handle on how keymaps work is by setting them manually first, then using the keymap export feature to generate a .py file, and in this file do a search for your operator name or menu name
When I added kwanza to 3D View (Global) it added this to the keymaps export
# Map 3D View
km = kc.keymaps.new('3D View', space_type='VIEW_3D', region_type='WINDOW', modal=False)

... (snipped)

kmi = km.keymap_items.new('wm.call_menu_pie', 'SEMI_COLON', 'PRESS', shift=True)
kmi_props_setattr(kmi.properties, 'name', 'kwanza')

Thank you for all the extra information - trying to understand the mode switch you talk about. I was curious already about how to define commands based on the mode you are in.

have a look at space_view3d.py lines like if context.mode != 'OBJECT':

I see it makes a function available if the mode is right or shades it inactive if the mode is wrong. I think I need to write the code for drawing the buttons with a condition of what mode the user is in. Let me try to figure this out - but might fail hahahaha.

The inactive shading is done explicitely:  see http://blender.stackexchange.com/questions/41387/how-to-deactivate-a-ui-element-in-an-add-on

or through an if context mode is edit mesh like in the official pie menu as I just learned

sometimes the language needed to convey these concepts is much less transparent than the eventual code you end up reading / writing.

yes this is very true - what confuses me on top is also all the different ways how to do it.

source: Stack Exchange

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

sort: votes


text:
Syntax for operator Make Single User using the mesh data block
so imagine you have two objects but they are linked so it is one mesh data block
The following command should make the cubes single users so that the mesh data blocks are not shared but it doesnt do it.
row.operator("object.make_single_user")

So I am curious how one has to add the value for the object + data:
bpy.ops.object.make_single_user(type='SELECTED_OBJECTS',
                                object=True,
                                obdata=True,
                                material=False,
                                texture=False,
                                animation=False)

or how one could call this menu:

The default options for bpy.ops.object.make_single_user() are all false so you need to specify at least one True option when you call the operator. When calling an operator directly you can just include the optional values in the call -
bpy.ops.object.make_single_user(type='SELECTED_OBJECTS', object=True, obdata=True)

When using layout.operator() in a panel or menu,  you can't pass options this way but there are two methods you can use. When you only have one option to set you can add the property to the operator line -
layout.operator("object.make_single_user", text="Object").object = True

When you need to define multiple options you need to keep the operator item that is created and then adjust it's properties. As shown from the make single user menu -
props = layout.operator("object.make_single_user", text="Object")
props.object = True
props.obdata = props.material = props.texture = props.animation = False

props = layout.operator("object.make_single_user", text="Object & Data")
props.object = props.obdata = True
props.material = props.texture = props.animation = False

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


text:
Ghost button for Pie menu
Pie menus work sorting / placing the buttons as it seems via
82467913
but this is not idea specifically when you have less buttons than 8.
Is there a way to create invisible place holder buttons so for example slot 1 and 3 are not used but only 4 7 8 9 6  and 2
In the image below I split show and hide mesh up into two sections.
I would prefer Show Mesh to be just empty.

The pie menu items are filled in a specific order - first the left item then the right, the bottom item then the top, then the top diagonals and the bottom diagonals are filled last. If the numbers used for each position seems odd for this layout compare them to your numeric keypad.
The primary design of the pie menus is to place one menu item at each location. As we have found this can be abused to show many items at each location.
While items are added in order to specific locations, we can effectively 'skip' an item by having a label with no text taking the position we want blank, it will need to be followed by a call to menu_pie() to make the next item to go to the next position otherwise it will be positioned with the label.
pie = pie.row()
pie.label('')
pie = layout.menu_pie()

I tried this out but this does not work. I pasted at the empty positions your code examples.

Sorry I missed that I had a row() or column() before the label when I was experimenting.

Could we get this in the official pie menu docs? This is absurdly helpful.


text:
Correct code for: set Snap to Pixel = True/False as Pie menu in UVEditor
I try to figure out how via a pie command one could set the "Snap to Pixel" = true or false inside the UV editor and struggle with finding the right way to write this as a code instruction. For the pie menu I would like to have a button to press and each press can trigger either the true or false based on the current state which I think one could check via an if step. Right?

As it seems the console reads this out:

But unfortunately this is the same when selecting "Constraint to Image Bounds".
The command I think is:
spaceUVEditor.use_snap_to_pixels

And this being boolean so true or false.

You can use wm.context_set_boolean or wm.context_toggle to achieve this.
The code should look like this:
op_props = pie.operator("wm.context_set_boolean", text="Snap to pixels")
op_props.data_path = "space_data.uv_editor.use_snap_to_pixels"
op_props.value = True

#or

pie.operator("wm.context_toggle", text="Snap to Pixels").data_path = (
    "space_data.uv_editor.use_snap_to_pixels")

do you have an idea how to render this as a checkbox? Or since it is a 0 1 flag that is set how to check if it is activated so in case it is on it will be set to off and in case it is off it will be set to on?

you have to find the UV editor area to access this property, add the following inside the pie menu :
    for area in bpy.context.screen.areas: #loop through areas
        if area.type == 'IMAGE_EDITOR':   #find the image editor
            space_data = area.spaces.active
            pie.prop(space_data.uv_editor,"use_snap_to_pixels") #the uv editor is part of the image editor


text:
Animation not working after appending node group
I have a question concerning node groups and animation.
I have a project in two files, both containing node animations. But, how can I merge the two node configurations together?. Of course I can re-create the node circuit manually in blend2; So I did. But then I thought there had to be a better way to do this, and the words Group and Append came to mind.
The appending process worked; but to my surprise, when I connect the appended group to the node circuit of blend2, everything works except for the animation.
Is there any specific step or configuration required to append the actual animation together with the rest of the imported node configuration?
Even though my question is generic, the two blends are available (if required).
Thanks in advance for all your help.
Sept

Yes, please post the blends.

Also, are these material or composting nodes?

The animation data is getting ported with the node group, just not applied. You can import a whole scene and it will work fine.
No solution has been found to re-link the animation data.

Yes, the two actions can be found in the Outliner>Datablocks>Actions section. They are just not linked to the right "user". Thanks for taking the time.

@Sangreelah It works if the whole scene is imported... if that is any use to you.

Yeah I have just tested it and it works. The only problem I see with the work around is that it involves importing a bunch of elements not-needed(like the cube and lights and so on); my project is nodes only, ignoring any render layer. I wonder if there is any way to link the imported action back to the right user.

That's what I'm trying to do... Not easy though.

Sorry I missed your question above; they are  composite nodes but no render layer, only a image and texture input.

@Sangreelah Okay!

@Sangreelah if GiantCowFilms has solved your problem you can accept the answer: http://blender.stackexchange.com/help/someone-answers


text:
Creating borders for flat models
I'm building a puzzle game and this is the method i'm using to create the puzzle pieces.

Create designs in illustrator.
Save the design as SVG. Import SVG to blender.
Save the model as fbx.

This is working well, but i need to have outlines around my puzzle pieces. For example, i need a piece to be black with white outline:

Please help me with this.

You could texture the model with a raster image of the outline (in blender), or you could try rendering an outline around them realtime in your game.

Texturing with raster image sounds simple enough!!

You could try adding a raster image to your model as a texture:
Probably the easiest way to add a texture to your model is by dragging and dropping an image from a file manager onto your object in the 3D view:

Note that you'll also need to UV unwrap your object.
For simple 2D objects extruded along the Z (like the one in the above gif), you can probably get away with looking at your object from the top (Numpad 7) in edit mode (↹ Tab), and with everything selected (A), pressing U> Project from view.
For more detail, see

The wiki on UV unwrapping
The wiki on texturing
How to properly unwrap my mesh?


text:
How could I model a realistic broken pillar (concrete)?
Something like this:

Of course I'm not pretending to achieve that level of detail, but is there any other way of obtaining similar results without having to spend so much time sculpting?
Basically, how do you model broken concrete? I tried with displacement modifier, but the results were too noisy and sharp, probably because I chose a bad texture but still I don't think I can achieve good results that way.

@cegatron ? that's the point of the question, I tried with displace modifier but it didn't work well. I'm not asking for the whole process or even to describe it, I only wanted to know the most adequate tools for the task within blender. Isn't that the point of the site?

If you plan to texture this, read through all the steps once before beginning. There is a UV mapping tip at the end that requires planning in advance.
Now let's get on with it...
Start with a cube, make it tall

Add a plane and fractal subdivide it

Fractal subdivide it again
This time a little more "fractally".
(If by any chance this is going to be a game asset go with a lower number of subdivisions.)

Extrude your subdivided plane to give it thickness

Set up a boolean (Optional: Subdivide the column too)
For the boolean, set the Operation to "Difference" because you're carving out of your column.
Subdivide the column (non-fractal) if you want the two meshes to be of similar density. Having a denser mesh would be better if you plan to do something like mutires sculpting on this. Having a less dense mesh would be better if this will be used as a game asset.

Apply the boolean, delete any leftover unneeded geometry
Apply the Boolean Modifier from Object Mode.
Then you can move your plane object to another layer or even delete it. After moving it you can see the subtractive boolean result.
To clean up stray geometry you don't need, select any part of those pieces in Edit Mode, press CtrlL to Select Linked geometry, then Delete (X) it.

Note that this is just a start. You can further sculpt this of course.
Bonus Tip: UV Mapping
Since your reference image has textures I will mention a texturing tip. If you plan ahead you can UV map this whole thing neatly. Booleans respect and will combine UV data.

UV unwrap your plane before you subdivide it. From the top, "Project from view (Bounds)".
UV unwrap your column before subdividing and before applying the boolean. "Smart UV Project" with an Island Margin of 0.1.
To place the fractal-subdivided UV island: Select the five flat faces of the column (may need to Select Similar (ShiftG) > "Co-Planar" if you've subdivided the column too). Invert the selection (CtrlI). In the UV/Image Editor Box Select (B) the rest of the visible vertices and scale/grab to position as desired.

An example of the sort of UV layout you can create:

Note: In the screen shot above the column was not subdivided before doing the boolean. It is a different .blend file from that of the preceding screen shots.

Wow, that's much more than I was asking for, simply saying "fractal + boolean" would have been enough. Needless to say, thanks for the tips.

This is a little tutorial man :) Thanks so much for this simple and powerfull method

@Ant Glad you found it helpful. :-) At first I thought this question would be too niche to be useful to a broad audience because like, how many people on here will be searching "concrete pillar"? But on second thought I realized maybe the principles of the modeling process could be relevant to people looking to create all sorts of similar structures... so I went into detail. Happy blending!

You can use the Blender Port of Zbrush ORB Brushes, they are very very good for such cases. You can get them here.

just great tutorial!!

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


text:
What is the shortcut to close up / zoom to face / vertex / edge while modelling?
What is the shortcut to close up / zoom to face / vertex / edge while modelling?
I mean, the button or shortcut to see the part of the model that you are selecting on detail, maybe for big models?

View selected is Numpad . (the full-stop/period/decimal point on the numpad)
It is also available from 3D view > View > Align View > View Selected.

You can also use "." period in edit mode it helps a lot in modelling also if you select multiple vertices same thing happens yet different perspective.

I will mention 3 shortcut which can zoom.

As mention above Numpad. to selected mesh (If you have many mesh and want to zoom selected mesh)

Press Ctrl++ on Numpad that will zoom and Press Ctrl+- on Numpad unzoom

If you want to zoom some selected area. Shift+B. As soon as you press it you will get white horizontal and vertical dot line drag on the area where you need to zoom.


text:
Can I delete geometry by rendering?
I know it could be weird, but can I for example take all the objects in the scene (static objects) and then render them with low polygons? like transforming them or something like that?

Try the decimate modifier

Where's that option?

Modifiers panel

remesh modifier can help too, depending on what you need.

@someonewithpc, going to post an answer?

You can use the Decimate modifier.
Select your object, and in the Properties panel, click the Modifiers tab; there, click Add Modifier and select Decimate. There are a few modes to select from, which give you a slightly different result, but you'll probably want to use Collapse. This mode as a Ratio slide, which you can use to control how much to decimate your object.


text:
How can I make a Bézier curve have sharp and curved points?
How can I make a Bézier curve have sharp and curved points? Like a zig-zag. And also being able to make more 'circular' parts too.
(I want to make fig 2, but I can only get to 1 by creating curves added with the E button.)

Being in Edit Mode you can select the desired curve point, press V and change the Handle Type to Vector

To have even more control you can set the Handle Type to Free

You can do this by going into edit mode, selecting a vertex and pressing S 0. This will make the vertex scaled to one single point, and it will cease to have an effect on the curvature of those segments.
Like this:
Before:

After:

The vertices are still selectable, moveable, etc.

You can change the Handle type of the selected control vertices to Vector by pressing V > Vector:

This will make the segments between those vertices into straight lines.

You duplicated Gonzou . . . his isn't as fancy though XD

@NoviceInDisguise Oops your right (though I started writing this when there were no answers :P).. Should I delete this? Or keep it for the answer ratio?

Keep it for sure!

This seems to have no effect in Blender 2.8 :-/

Is it possible to make the vertex with both handles zero length?
I scaled all to 0 and it seems to work but I'm wondering if it's possible to just remove the handles at all.


text:
Preview viewport animation at 60fps?
I made an animation with bones/rig and I'm trying to preview it at 60fps, but it is only is shown at 40-30fps.
Is it possible to fix this somehow?

Is it trying to go faster (is the fps indicator red?)?

Yes, and now that i see it dropped to 24fps :/

That means that the frames can't be calculated fast enough to keep up with the set frame-rate.

@beavoru You can try cutting down on Modifiers, especially the subsurf ones, as this will exponentially increase the speed.

You can also render out a preview (opengl) render, to pre-draw the frames then display them at a proper framerate.

From your comment, I gather that the FPS text is red, and below the desired rate. This is perfectly normal sadly, and just means your computer can not calculate the frames fast enough to keep up.
The displayed frame-rate is the actual number of frames calculated per second, and is displayed in red to let you know that is not the actual rate of playback. Notice that if it is going at full speed it will display the FPS text in white.
Try cutting down on Modifiers, especially the subsurf ones, as this will exponentially increase the speed.

Aside from trying to increase viewport performance, you can also use an opengl render to pre-render each frame, then play them back at the proper frame rate.

Set the frame start and end, and the output format/path:

Any format works fine (even image sequences), but if you want sound you'll need to specify a format and codec which supports it (e.g. h.264).
Click the openGL render button either in the header of the 3D view, or in Info > Header > Render:

Note that you must be in camera view (Numpad 0) if you want to render from the camera, otherwise the current 3D view orientation will be used.
You can quickly display the rendered opengl animation (or any rendered animation for that matter) by pressing ⎈ CtrlF11. Do note that this quick player doesn't support sound.
If you need sound, you might want to use an external video player or the VSE.


text:
Create walls from a plane?
I have a plane, as you can see below, that I would like to be the floor of a building.
How would I quickly create walls from all of the edges?

In edge select mode (CtrlTab>Edge), select all the outer edges and press EZ to extrude along the Z axis:

In the above gif I used the new boundary edge selection tool, which is currently only available in the latest development builds (it will be in 2.71).
If you are using an older version, you can select the boundary edges like so:

Enter edit mode (Tab)

Select all (A)

Press 3D view > Header > Select > Select Boundary Loop:

How'd you do the boundary loop selection for new builds.  I can't tell what you did from the screencast

Just press Alt+RMB on the edge twice (see this post) The old method works fine on new builds too.

That works, thanks.  It's nice to see it there now.  It's a very appreciated addition to the selection tool.

Great approach and very helpful for newbies.


text:
Control of blender settings via script
Could someone please explain, line for line how this script works; in particular the dots in between the setting definitions s.proxy.build_50
import bpy

for s in bpy.context.scene.sequence_editor.sequences:
    if s.type != 'SOUND':
        s.use_proxy = True
        s.proxy.build_25 = True
        s.proxy.build_50 = False
        s.proxy.build_75 = False
        s.proxy.build_100 = False

I'm most interested in understanding how one finds out how to define other settings/switches.
I know you can right click on for online Python reference. Also hover over them to see a bit of code; but looking at these has just confused me.
Is there a list of other settings / code to define them?

bpy.context.scene.sequence_editor.sequences is a list like:
list = ["a", "b", "c"]
for element in list:
    print( element )

this would print:
a
b
c

the for loop assigns each element from the list to a variable executes the commands (print in this case) and advances to the next element.
The same applies to your snippet s gets on value after another from the defined sequences. Adding a print statement before the if statement would show something like that:
<bpy_struct, ImageSequence("main_chart.jpg")>
<bpy_struct, ImageSequence("main_chart.jpg")>
<bpy_struct, SoundSequence("sound.wav")>

Now you know the name of the classes (ImageSequence or whatever is printed) and you can lookup the API Documentation
The dot is a syntax element that separates the name of an object by its properties.
You could also examine the available properties by using dir
print( dir(s) )

Which would print for an ImageSequence:
['__doc__', '__module__', '__slots__', 'alpha_mode', 'animation_offset_end',
'animation_offset_start', 'bl_rna', 'blend_alpha', 'blend_type', 'channel',
'color_multiply', 'color_saturation', 'colorspace_settings', 'crop', 'directory', 'effect_fader', 'elements', 'frame_duration', 'frame_final_duration',
'frame_final_end', 'frame_final_start', 'frame_offset_end', 'frame_offset_start', 'frame_start', 'frame_still_end', 'frame_still_start', 'lock', 'modifiers', 'mute', 'name', 'proxy', 'rna_type', 'select', 'select_left_handle', 'select_right_handle',
'speed_factor', 'strip_elem_from_frame', 'strobe', 'swap', 'transform', 'type',
'update', 'use_crop', 'use_default_fade', 'use_deinterlace', 'use_flip_x',
'use_flip_y', 'use_float', 'use_linear_modifiers', 'use_proxy', 'use_proxy_custom_directory', 'use_proxy_custom_file', 'use_reverse_frames', 'use_translation']

Related:

Is it possible to dump an Objects Properties and Methods?
Where can the latest API documentation be found?

bpy.context.scene refers to the current scene, e.g. bpy.data.scenes["Scene"]
Sequence Editor data is stored in the Scene type, and .sequences contains the the top-level strips.
This iterates over all top-level sequences, whereas s refers to a sequence:
for s in bpy.context.scene.sequence_editor.sequences:

If the sequence is of type SOUND:
    if s.type != 'SOUND':

... the following code block is executed:
        s.use_proxy = True
        s.proxy.build_25 = True
        s.proxy.build_50 = False
        s.proxy.build_75 = False
        s.proxy.build_100 = False

A couple sequence properties are set.
Other sequence types:
>>> [item.identifier for item in bpy.types.Sequence.bl_rna.properties['type'].enum_items]

['IMAGE', 'META', 'SCENE', 'MOVIE', 'MOVIECLIP', 'MASK', 'SOUND', 'CROSS', 'ADD', 'SUBTRACT', 'ALPHA_OVER', 'ALPHA_UNDER', 'GAMMA_CROSS', 'MULTIPLY', 'OVER_DROP', 'WIPE', 'GLOW', 'TRANSFORM', 'COLOR', 'SPEED', 'MULTICAM', 'ADJUSTMENT']

You can pick a single sequence and get the type:
>>> type(bpy.context.scene.sequence_editor.sequences[0])
<class 'bpy.types.SceneSequence'>

Check the API docs to find out about the properties and methods:
bpy.types.SceneSequence
.proxy is a subtype, which has several own properties: bpy.types.SequenceProxy
Don't miss to read this:
Blender/Python API Reference Usage: examples of how to use the API reference docs


text:
Make buttons on main menu light up
I am trying to make it so when you hover the mouse over a button, the diffuse will change.

The buttons are made out of planes.
I want the white plane to change to an orange color. I cannot find a way to do it with logic bricks, but I have done it before and cannot find out how to again.  I have tried action and visible actuators.

Mouseover > and > F-curve Actuator?  You can animate the diffuse colour via an F-curve.

First of all, select the first button. Then, ensuring you are on frame 1, go to the material tab, and set the colour to it's normal state (the colour you want for when the mouse is not over the button) and press I.
Then, if you want the change in diffuse of the button to be instantaneous, move onto the next frame. If you want there to be a longer transition between the two different states, however, move to a later frame, eg 5. The later the frame you change to, the longer the transition between the two states of the button will be when the mouse is over the button.
Now you are on a different frame, change the colour of the button to what you want, and press I, with your mouse over the diffuse slider.
Now, when you scrub through the timeline with the mouse, in between the beginning and end of the animation you have just created, you should see the colour in the material tab changing (this will not work if watching the animation using AltA)
Now, you can open up the game logic window. Add a "mouseover" sensor, connect it to an "and" controller, and then connect that to an "action" actuator. Just under the button that is currently set to play, there is a box that allows you to chose the animation to run. Clicking on that box opens a drop down box that allows you to chose the animation to play - there should only be one as you have only created one animation thus far, so simply choose the only animation in the box (if you already have more than one animation in your scene, you will have to make sure you chose the animation that you just created for that button - you can see the names of animations in the top left window if switching to the "animation" view instead of "default" or "game logic" at the top of the blender window.)
Next, there is the action playback type. This is above the animation box, currently set to "play". Changing the animation type to "flipper" means that when the mouse moves over the button, the animation will run and the colour will change, but when the mouse is moved off the button, the colour will change back. If it were left on play, it would not change back when the mouse moves off the button.
Next there is the start frame and end frame. Set the start frame of the Action to 1, as this is the frame of the start of the animation you made earlier. Then, set the end frame to the frame when the diffuse animation ended.
Now, when the mouse is over that button in the game engine, the colour should change, and when the mouse is no longer over the button, it should change back.
Once you have tested that works, repeat the process for your other buttons. Make sure they all have different materials, as, otherwise, when one button changes, they may all change.
Note: this will not work if there is a texture on the button plane, that would require you to have an orange and a white button (one on top of the other) and to fade between them with a similar method to above, but changing the opacity instead of the colour of the slider.
Finally, something to be aware of is the animation you choose in the action actuator. Make sure you choose the animation for the button you want to change, because there will be more than one animation in the drop down box once you have created different animations for different buttons.


text:
Emulated Numpad Mapping - Numpad Period?
By trial and error I have found that in Blender v2.7 on a laptop with emulated numpad set, \ represents Numpad / (forward slash).
Which key represents Numpad . (period)?

In emulated numpad mode there isn't a non-numpad key that's mapped to the same functions as numpad period.  The way to get a key to do what numpad period does is to map your own choice of key to do the same things as numpad period does.  Numpad period is mapped to "View Selected" in eight or more windows (you can find them by searching for key-bindings for 'numpad' and scanning through the results but searching for 'numpad .' doesn't work).  The window in which I use numpad period most often is the 3D view.  Below is an explanation of how to remap the numpad period key in that window. A similar process would work for any other window type you want to remap.
I used this explanation to change the key binding in user preferences (Ctrl+Alt+U) for the View selected command under 3D View> 3D View (Global)> View Selected (see below, I have mapped it to semicolon ;).

Before you pick the key to map it to, you might like to make sure that your new binding isn't used for some other command. You can search by key by changing Name in the top search bar to Key-Binding and enter the key you'd like to check.  If nothing shows up (see screenshot) then you're safe; if some bindings show up you might still be ok if none are applicable to the 3D view.

Rather annoyingly, searching for 'period' . doesn't find the bindings to numpad period - not even if you type the period with a numpad - but you can get close by searching for the key-bindings for 'numpad' (type in the word as though it was a key).
If you feel adventurous, you might prefer to add an additional binding rather than removing the numpad binding (maybe you'll buy a numpad one day). To do that, take a look at the command you would have remapped by clicking the little white triangle:

That shows the command is view3d.view_selected.  Scroll way down to the end of the list of bindings and find the Add New button. Press it and you'll get a new binding called none just above the button you clicked:

Expand the key binding, enter the command and set the key you want bound to it:
.
Finally, don't forget to save your user preferences!

Remapping key binding for the action in Outliner won't ever work in viewport since this is entirely different context - 3D viewport and Outliner, as well as different shortcuts. Answer above as well as question never mention about View Selected command for the viewport (it could be for clarity). View Selected command can be found in Key-Binding mode by searching for "numpad" in 3D View context (maybe a limitation or a bug since some shortcuts seem to be available for search).

Thank you.  I have updated my answer to explain how it is an answer to the original question and to explain how to search (as far as is possible) for bindings to numpad period.

Nice and detailed answer!! Thanks a lot!!

I was also bothered by this a lot. The only way I found is to change the binding to a laptop key that is recognised by Blender.
Go to the user prefs, Input and in the search field, write . and you will find the binding called Outliner Show Active. Change it to something that works on your laptop.


text:
Displaying faces in edit mode
Blender is not displaying faces with a dot as usual in Edit Mode, Face Select mode.

This is Mavericks OSX, Blender 2.72b

curious, the only dot I can think of is drawn in wireframe mode.

Does it show for the default theme?

Yes, it is showed for the default theme.

Face dots are not displayed if Textured Solid is enabled in 3D View > N-panel > Shading.
Odd theme colors could make it hard to see the face dots, but that's not the reason in your case. Unselected faces use the wire color for both, the edges and the face dot, which is light purple in your screenshot (so clearly distinguishable from the surroundings).
As last resort, submit a bug report to the tracker.

That was the reason in my case. OK


text:
Animation on keyframe and timeline

How do you loop an animation inserted between, for example, keyframe 1 and 20, through out the whole 250 frames on the timeline?
How do you animate a torus on repeat?

When you add keyframes they are stored in an Action to let them repeat add the action as an Action Strip to the NLA Editor and set the repeat property (in the property panel N) to the number of repetitions. Note that the Action Editor is mode of the Dopesheet Editor.

Where can I view the repeat property? Sorry I am very new to Blender. I am using Blender 2.71.

Nevermind. I have found the repeat property. Thank you for your help.


text:
How to create and export multiple animation/actions in blender?
I understand how to create animations, but can't seem to find a good tutorial on how to create, name, and export multiple animations into Wavefront OBJ. Do you know of any or can you please explain?
This going to be exported and loaded using jMonkeyEngine3 and Wavefront OBJ as file type.
I tried using the DopeSheet in Action Editor mode, but it doesn't seem to export even though I had two actions and used the Action.use_fake_user.
I am trying to create an Idle, Walk, and Wave_Arm animations just for testing and learning.
Also, is there a way in Blender to check if animations were exported?

Wavefront OBJ is a widely supported file format for 3D models. It can store vertex coordinates, UVs, vertex normals, face definitions and texture vertices (plus additional, but not standard-compliant data in some softwares).
Animations are not supported. The export option Animation in the OBj exporter does not really export an animation, but an OBJ for every frame in your scene. So it's really a series of OBJ models. Some engines may support this for animations.
As said, the addon uses the scene, so the current timeline. Every object can reference not more than a single action. Therefore, only that one action is exported. Batch export of all actions is not supported.
It would be trivial to do code-wise, but we lack an essential information: which action belongs to which object? All actions are stored globally (bpy.data.actions in python). For which objects an action works, is not stored. You can "run" an action on any object, e.g. matching bones in another, different armature will be animated too.
Thus, you need to switch actions on your animated object, change start and end frame on your timeline and export them one by one. Or adapt the export addon to batch-export all actions for the active object (you may use Action.frame_range to determine the keyframed boundaries).
You can check the export by either inspecting the output folder, or by checking the system console (on Windows, it's as easy as Window > Toggle System Console):
OBJ Export path: 'C:\\Users\\CoDEmanX\\Desktop\\untitled_000249.obj'
OBJ Export time: 0.00
OBJ Export path: 'C:\\Users\\CoDEmanX\\Desktop\\untitled_000250.obj'
OBJ Export time: 0.00

That makes a lot of sense. Well I guess I will have to make  the OGRE exporter work... - On a side note, so then how am I suppose to have multiple actions exporter? (OGRE of course) With the way you say it... it seems like one would have to multiple copies of the same model in order to access different actions.

An export script could change the active object's action (Object.animation_data.action = ...), basically iterating over all actions and export every frame in the keyframed boundary (either exporting single OBJs and Scene.frame_set(), or change Scene.frame_start and Scene.frame_end and use Animation options ot export the entire timeline with a single call to bpy.ops.export_scene.obj()). An additional function could check the actions' data_path properties and try to figure out, if an action works for the object you want to export.

I am not talking about OBJs... I am talking about OGRE... .mesh.xml. W/e ill accept since you basically pointed me in right direction.

My bad. Exporting single models using frame_set() to advance should work with all exporters, just change the bpy.ops call.


text:
bpy.context.selected_objects: Context object has no attribute "selected_objects"
If creating a basic operator and reading the list of selected objects upon execute I get the correct response:
class foo(bpy.types.Operator):
    bl_label  = "foo"
    bl_idname = "foo"

    def execute(self, context):
        print(context.selected_objects)
        return {'FINISHED'}

However I need to read the list of selected objects elsewhere, outside of the Operator, from within a subclass of threading.Thread.
Calling bpy.context.selected_objects anywhere else results in an error, as it doesn't exist.. which is both puzzling and irritating.
Has anyone else dealt with situation before, not being able to access the list of selected objects. Is there by chance another method?
I have thought about creating an operator that would return the list of selected objects if invoked through python code... but I do not understand operators fully (yet) and thus do not know if that is possible.

Why threading? bpy is not thread-safe, so that might be the root cause.

The context is dependent on quite a number of things, and not every context holds the scene's set of selected_objects. A safer and more consistent way to get the selected objects is this:
selected_objects = [ o for o in bpy.context.scene.objects if o.select ]

I wonder if there is a performance difference between
bpy.context.selected_objects

and

o for o in bpy.context.scene.objects if o.select

Given a  scene may have thousands of objects an only two possibly selected (or any arbitrary number).

List comprehensions are fast, much faster than loops and among the fastest operations python offers. I doubt it will add much to the runtime even if context.selected_objects is faster.

The biggest catch with bpy.context is usually with operators that work in the 3dview but fail when trying to run them from the python console or when running a script in the text editor.
To overcome these issues you can override the context, which is described on the bpy.ops page, you may also want to look at several examples in answers here. While ways to override the context are designed as a way to pass on the adjusted context to an operator, the concept should translate to your use of threads, maybe you will need to pass a starting context for the thread to use when you first start it.

I'm having the exact same problem but I'm struggling with overriding context. I want to apply "Smart UV Project" and no matter what/how I make context its always wrong. Can you ping any hints how to handle it ?


text:
How can I attribute a parameter to multiple objects?
I would like to apply a custom parameter to a selection of objects with the following setup:
class MyPanel(bpy.types.Panel):
    bl_label = "Tool"
    bl_space_type = "VIEW_3D"
    bl_region_type = "TOOLS"

    @classmethod
    def poll(cls, context):
        return len(context.selected_objects) > 0

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

        myprop = context.active_object.myprop
        row = layout.row()
        row.prop(myprop, 'subdivs')

For now it works with the active_object, but how do I have to change my panel so it can pass on multiple variables to my update function?

"how do I have to change my panel so it can pass on multiple variables to my update function ?" What is the update function supposed to be. This question is unclear.

bpy.props allows you to define your own get/set/update methods for a property.
import bpy

def update(self, context):
    #self ~ owner of the property
    for obj in context.selected_objects:
        #assigning a value to obj.property would cause a recursion!!!
        obj["custom_property"] = self.custom_property

bpy.types.Object.custom_property = bpy.props.IntProperty(update=update)

If you change the attribute custom_property for an object the change will be applied to all selected objects.
You can also use drivers to synchronize properties.


text:
Bones are not right when importing fbx
I have a bought rigged model in 3ds max file format that I want to use in Blender. So I selected the mesh and bip rig and exported to fbx. When I imported the fbx to blender 2.8, the bones were out of place. The ends of the bones are facing different directions.

I'm a beginner in Blender and I'm enjoying learning it now especially with the changes in 2.8. Most of my files are in max or fbx and I really want to practice blender especially using the fast rendering of eevee.
I would appreciate some tips or advice in solving this issue.
Thanks in advance!! ^_^

Thank you for the advice! I already tried doing rigging in blender and it was a good study. I know that 2.8 is in the beta version now and I can't wait for it to release officially. I was just asking around if it's possible now even in beta. Hopefully, the official 2.8 release would solve it.
I did try using 7.9 but I was having a bit of difficulty with the interface before that's why I love the 2.8 beta because it's an easier transition for me.

Related to https://blender.stackexchange.com/questions/128273/how-do-you-make-your-model-skeleton-to-look-like-this/128274#128274 . Fbx has many small variations depending on which versions of software you are exporting from. In this case it has mis-interpreted the bone orientations during import, rather than the scale. You could try playing with some of the importer settings, but other than that I'm not really sure.

@Sazerac I hear you with playing with the importer settings. Some did solve some bone placements but the sizes changed. Hmmm I'm also at a loss here. I could do the rigging and skinning again but what's the point of buying the rig asset. I wanted to save time not gain more. I hope the next blender update can solve this.

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


text:
How to organize different animations when you didn't finish your scene yet?
I want to have different scenes to create different movements of my objects. When I create or change an object, I want it to be created or changed in all these scenes. Only the animations shall not be linked.
Is there a way to link all objects without their animations between scenes?

are you talking about the Blender "scenes" within the same file, or are you talking about creating a brand new Blender file.

@moonboots I don't want to create different files because I would have to update everything I change in every file. I'd like to have different scenes in which everything but the allocation of the actions is updated :)

the File > Link function precisely allows you to make all the animations you want with an object, but its mesh is only editable in the original file, so if you change the original mesh it will be replicated on all its linked instances

On the opposite, if you create a new Scene in a file, all the instances of the same object will have the same animation. So I may miss something but I don't think you can do that with Scenes. What you could do, though, is make a Linked Copy Scene, then make Linked Duplications of your object (alt D instead of shift D): the instances are independent, but if you change the mesh of one instance it will change the mesh of all the others.

https://blender.stackexchange.com/questions/93043/linking-the-mesh-and-location-of-objects-with-different-materials-in-different-s/93055#93055

So I may be wrong but here is what I think you should do from what I understand:
As you don't want to use the File > Link function and as you absolutely want to use Scenes, I think the best way to do it is to create a New Scene > Linked Copy mode, so that the objects stay linked from a scene to another, then you need to make linked duplications of your object (altD instead of shiftD), so that if you make any edit on one instance of this object, it will be replicated on all the other instances on all linked copy scene.
Why linked duplications? Because if you simply reuse the same object from a scene to another you won't be able to change the animation of one instance without changing the animation of all the other instances.

Thank you a lot! That works very well for armature actions and would be what I look for! But it doesn't seem to work for shape key actions with the exaclty same process. Very strange. They get updated in their linked duplications.
Am I doing anything wrong? Do shape key actions work completely different?

yes you're right, it looks like the limitation of this method  :/  I didn't know shapekeys were replicated on the linked duplications by the way

Do you know a way to summerize actions?
It would be helpful to activate a group of actions on different objects by one klick :)

I'm not sure to understand, could you give an example? You can copy an action (Animation Data) of an object with ctrl L but I'm not sure that's you want

I mean: I klick an "action folder" or something and every object in the scene gets the right action that belongs to each other.
Very specific - I know :D

on the NLA, you can select a group of strips and duplicate it, maybe it's the closest thing to what you need?

You're right! I could just order my actions and objects on the NLA in the timeline!
Thank you so much! That's better than the scene idea.


text:
Pie menu and limited viewport shading options (show subset of an enum)
So most code exmaples I find are using the option to list all shading options
pie.prop(context.space_data, "viewport_shade", expand=True)

But I would like to only show 3 and have the feeling that I have to create a new
class operator to execute the code like:
bpy.context.space_data.viewport_shade = 'SOLID'

Am right with that assumption?

nope, to display a subset of an enum you can use wm.context_set_enum
        f = pie.operator("wm.context_set_enum", icon='SOLID', text='Solid')
        f.data_path='space_data.viewport_shade'
        f.value = 'SOLID'

        f = pie.operator("wm.context_set_enum", icon='WIRE', text='Wires')
        f.data_path='space_data.viewport_shade'
        f.value = 'WIREFRAME'

You might use a loop to reuse some code:
        modes = [
            ["SOLID", "SOLID", "Solid"],
            ["WIRE", "WIREFRAME", "Wires"],
            ["BBOX", "BOUNDBOX", "Bounds"]
        ]

        for ICON, VALUE, TEXT in modes:
            f = pie.operator("wm.context_set_enum", icon=ICON, text=TEXT)
            f.data_path='space_data.viewport_shade'
            f.value = VALUE

Grrrr Just text is what you can use for the type - I would not have guessed that.

Do you have a paypal account?

oh wow - RENDERED does not have an icon you can select?!?!

Yeah that's what I imagined and I use that icon as well already. Are you in Russia? Any other service? You help me so much.

LOL - the icon the RENDERED mode uses is called "SMOOTH"


text:
Correct syntax for "mirror" pie operator in UV Editor as one operator
What is the correct way to in the UV editor perform an X or Y mirror as one command for a pie operator?
pie.operator("transform.mirror()", text="Mirror").constraint_axis='True, False, False'

Based on what I saw in the console:
bpy.ops.transform.mirror(constraint_axis=(True, False, False), constraint_orientation='GLOBAL', proportional='DISABLED', proportional_edit_falloff='SPHERE', proportional_size=0.0323492)

I struggle to understand the logic because I was able to successfully do this with a different snapping command
bpy.ops.uv.snap_cursor(target='SELECTED')

has to be written as
pie.operator("uv.snap_cursor", text="Snap Cursor to Selected").target='SELECTED'

Alternatively I could just define an operator and call the name via a pie button but I feel this makes the script longer than needed

lose the parentheses and add ones at the end pie.operator("transform.mirror", text="Mirror").constraint_axis=(True, False, False)

Actually I tried this. What happens is that you start the mirror command and have to press x or y for the direction. the constraint definition will be ignored.

try clicking the leftMouse without specifying the axis and read the executed command in blender you'll see it is not ignored

My eyes fool me. True without the constraint it goes into asking you. With the data it executes what you define and still enables you to overwrite it via X or Y or press LMB.

The description of the operator can be found here.
bpy.types.UILayout.operator returns an bpy.types.OperatorProperties object.
So if you need to assign multiple presets, assign it to a local variable first
op_props = pie.operator("transform.mirror", text="Mirror")
op_props.constraint_axis = True, False, True
#...

When the operator's invoke method is called the operator may use user input to set its properties or run modal, before finally running its execute method.
To skip the invocation you might try:
#...
pie.operator_context = "EXEC_DEFAULT"
pie.operator("transform.mirror").constraint_axis = True, False, True

pie.operator_context = "INVOKE_DEFAULT"
#...

See UILayout.operator_context for the available options


text:
Possible to combine a pie.operator and box.operator together?
Would it be possible to have pie operators along all 8 pie positions and below pie 2 have a column of box operators?

No, you cannot have all 8 pie positions and another extra box.
You can have boxes instead some pie positions though. So you can have 7 pie positions and the bottom 8th one being a box:
def draw(self, context):
    layout = self.layout
    pie = layout.menu_pie()
    #4 - LEFT
    pie.operator("mesh.primitive_cube_add", text="LEFT", icon='MESH_CUBE')
    #6 - RIGHT
    pie.operator("mesh.primitive_cube_add", text="RIGHT", icon='MESH_CUBE')
    #2 - BOTTOM
    box = pie.box().column()
    box.operator("mesh.primitive_cube_add", text="BOTTOM 1", icon='MESH_CUBE')
    box.operator("mesh.primitive_cube_add", text="BOTTOM 2", icon='MESH_CUBE')
    box.operator("mesh.primitive_cube_add", text="BOTTOM 3", icon='MESH_CUBE')
    box.operator("mesh.primitive_cube_add", text="BOTTOM 4", icon='MESH_CUBE')
    #8 - TOP
    pie.operator("mesh.primitive_cube_add", text="TOP", icon='MESH_CUBE')
    #7 - TOP - LEFT
    pie.operator("mesh.primitive_cube_add", text="TOP - LEFT", icon='MESH_CUBE')
    #9 - TOP - RIGHT
    pie.operator("mesh.primitive_cube_add", text="TOP - RIGHT", icon='MESH_CUBE')
    #1 - BOTTOM - LEFT
    pie.operator("mesh.primitive_cube_add", text="BOTTOM - LEFT", icon='MESH_CUBE')
    #3 - BOTTOM - RIGHT
    pie.operator("mesh.primitive_cube_add", text="BOTTOM - RIGHT", icon='MESH_CUBE')

You can split rows, create multiple columns, etc. Normal formatting methods of Blender UI applies. If you omit the .box() you don't have that ugly border and only grouped entries which looks better imho.


text:
How to load a video in a MovieClip node
How to create a "CompositorNodeMovieClip" node and load a video using the python api in the node editor.
My progress so far...
bpy.context.scene.use_nodes = True
nodes = bpy.data.scenes['Scene'].node_tree.nodes
links = bpy.data.scenes['Scene'].node_tree.links # create the movieclip node
movieClipNode = nodes.new("CompositorNodeMovieClip") # get the video clip
videoClip = bpy.data.movieclips.get( videoPath );

but videoClip is returned as null..

My progress so far...bpy.context.scene.use_nodes = True
nodes = bpy.data.scenes['Scene'].node_tree.nodes
links = bpy.data.scenes['Scene'].node_tree.links
create the movieclip node
movieClipNode = nodes.new("CompositorNodeMovieClip")
get the video clip
videoClip = bpy.data.movieclips.get( videoPath ); but videoClip is returned as null..

In future, please add any extra info into your question and not the comments.

Thought of keeping the question succinct. Will keep that in mind for the later questions. Thanks for modifying.

you are using incorrect key , the key is the name of the movie clip
#load new movie clip
bpy.data.movieclips.load(clip_path)
#get the new movie clip
movie_clip = bpy.data.movieclips.get(clip_name)
#assign movie clip to the node
bpy.context.scene.node_tree.nodes['Movie Clip'].clip = movie_clip

ah.. thanks for pointing out. That fixed it.


text:
How to pass a property from popup to execute
I'm writing a Curve Outline Addon which works quite nice as a script, but I'm getting confused with the UI integration: I would like a simple popup asking for the Outline amount which interactively shows on my Curve. Instead I have a popup which forwards my property to the execute and then applies to my Curve.
Somewhere I didn't completely grasp the concept of modal/pass_through and invoke/execute...
class CurveOutline(bpy.types.Operator):
    """Curve Outliner"""
    bl_idname = "object._curve_outline"
    bl_label = "Create Outline"
    bl_options = {'REGISTER', 'UNDO'}

    outline = bpy.props.FloatProperty(name="Outline", default=0.1, min=-10, max=10)

    @classmethod
    def poll(cls, context):
        return context.object.type == 'CURVE'

    def execute(self, context):
        createOutline(context.selected_objects[0], self.outline)
        return {'FINISHED'}

    def invoke(self, context, event):
        return context.window_manager.invoke_props_dialog(self)

invoke_props_dialog() opens a "blocking" popup, it won't call execute() with the updated values until user confirm with OK button.
Use invoke_props_popup() instead, if you want to immediately re-run the operation:
import bpy

class CurveOutline(bpy.types.Operator):
    """Curve Outliner"""
    bl_idname = "object._curve_outline"
    bl_label = "Create Outline"
    bl_options = {'REGISTER', 'UNDO'}

    outline = bpy.props.FloatProperty(name="Outline", default=0.1, min=-10, max=10)

    @classmethod
    def poll(cls, context):
        return (context.object is not None and
                context.object.type == 'CURVE')

    def execute(self, context):
        createOutline(context.object, self.outline)
        return {'FINISHED'}

    def invoke(self, context, event):
        return context.window_manager.invoke_props_popup(self, event)

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

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

if __name__ == "__main__":
    register()

Added a check for context.object is not None to ensure the operator isn't run with no active object and replace selected_objects[0] by object, as it's not the same. If you intended to work on multiple selected objects, get all selected objects and remove the active one from list to separate them.

Thanks a lot, a bit frustrating being so close though... Now I have a working Curve Outliner which I'm happy to share btw!

You can set an update callback on the FloatProperty. I'm not sure it is actually safe to use it with invoke_props_dialog() but I tried and it works.
Replace the line outline = bpy.props... by:
def update_outline(self, context):
    createOutline(context.selected_objects[0], self.outline)

outline = bpy.props.FloatProperty(name="Outline", default=0.1,
        min=-10, max=10, update=update_outline)


text:
Why doesn't "bpy.ops.wm.save_as_mainfile()" work in UI panel?
Why doesn't
bpy.ops.wm.save_as_mainfile(filepath="D:/ddd/test_v1.blend")"

work in UI panel?
I need to add a new button in the render panel which sends the current file to a network location.

Is the " after the ) a typo?

Use backslashes (\) instead of forward slashes (/). Also you need to either escape special characters, or use (') instead of (").
The following code should work:
bpy.ops.wm.save_as_mainfile(filepath='D:\ddd\test_v1.blend')

or escaping characters
bpy.ops.wm.save_as_mainfile(filepath="D:\\ddd\\test_v1.blend")


text:
Toggle button to occlude geometry missing
I cannot see this button anymore, even though I am in edit mode.
Is it possible to hide or delete it accidentally? I need this button back pretty badly, since I dont want to select nearby geometry that would normally be hidden.

Do you mean this button?

It only shows up when you are in Solid View or higher. If you are in wireframe mode, it will not show up because it cannot compute the occlusion.

If you still can't see it, try middle-click draging the 3d view header bar to pan its contents.

yeah thats the one. didnt realize that about wireframe mode. will make selecting vertices trickier.


text:
Selecting a face in a script so that you can edit eg resize it?
I was trying to write a script to generate an object from primitives but came across a problem I couldn't solve.  The code generates a cylinder and finds the face as well as putting it into edit mode.  However when I try and select it in edit mode the whole object is still selected.
How do I script the selection of just that face?
When I do it by hand the selection of the face which I can do generates nothing in the info window.
import bpy

bpy.ops.mesh.primitive_cylinder_add(radius=1, depth=2)
ob = bpy.data.objects['Cylinder']
ob.name = 'NewCylinder'
mesh = ob.data

bpy.ops.object.mode_set(mode = 'EDIT')
n = 0
for face in mesh.polygons:
    face.select = False
    if len(face.vertices) > 4:
        print(' end face {}'.format(n))
        n += 1
        if n == 2:
            face.select = True
bpy.ops.transform.resize(value=(0.33, 0.33, 0.33))

It might seem counter-intuitive, but you need to be in Object mode to change the selection when using .mesh.  I changed a few more things, like you can use the 'DESELECT' action in mesh.select_all else edges are still selected when you try to un-select faces
import bpy

bpy.ops.mesh.primitive_cylinder_add(radius=1, depth=2, enter_editmode=True)
ob = bpy.context.object  # gets a reference to the newly created object
ob.name = 'NewCylinder'
mesh = ob.data

bpy.ops.mesh.select_all(action='DESELECT')

bpy.ops.object.mode_set(mode = 'OBJECT')
n = 0
for face in mesh.polygons:
    if len(face.vertices) > 4:
        n += 1
        if n == 2:
            face.select = True

bpy.ops.object.mode_set(mode = 'EDIT')
bpy.ops.transform.resize(value=(0.33, 0.33, 0.33))

Noteworthy: bpy.context.object should be used after calling a mesh primitive operator to refer to the newly created object (like zeffii did). You might pick the wrong object otherwise if the name already existed.

@CoDEmanX i'll add that as a comment into the code too

(Sorry for the comment but @zeffi I am delighted with the solution and stackexchange.  I racked my head about this for 1 day)

@hum3, as you can see by the other answer there's a variety of approaches to this. My preference is the bmesh method shown by CoDEmanX, but I wanted to provide an answer that shared more with your original question - to keep the point of reference.

@zeffi  I know that I  ought to learn the bmesh route but I am just starting and this matched using the info window like a macro recorder.

When editing faces you should select face mode bpy.context.tool_settings.mesh_select_mode = (False, False, True) otherwise you will be selecting faces via vertexes, which can lead to problems. In this example, if you remove if n == 2: you would simply be selecting all the faces.

You could also do this with Bmesh module, which does not require mode switches:
import bpy
import bmesh
from mathutils import Matrix

scene = bpy.context.scene

bm = bmesh.new()
bmesh.ops.create_cone(bm, cap_ends=True, segments=32, diameter1=1, diameter2=1, depth=2)

caps = [f for f in bm.faces if len(f.verts) > 4]
bottom_cap = min(caps, key=lambda f: f.verts[0].co.z)

mat = Matrix.Identity(4)
mat[0][0] = 1/3
mat[1][1] = 1/3
mat[2][2] = 1
bmesh.ops.transform(bm, matrix=mat, verts=bottom_cap.verts)

me = bpy.data.meshes.new("Cylinder")
bm.to_mesh(me)
me.update()

ob = bpy.data.objects.new("NewCylinder", me)
ob.location = scene.cursor_location
scene.objects.link(ob)
scene.update()

BTW: The same result (with bottom face scaled down by 1/3) can also be achieved with a single call to create_cone():
# diameter1 controls the size of the bottom cap
bmesh.ops.create_cone(bm, cap_ends=True, segments=32, diameter1=1/3, diameter2=1, depth=2)


text:
Poly / Bezier curve from a list of coordinates
I'm trying to create curves from a list of points, I have the xyz coordinates in text files.
I could make it manually via the python console for a single curve, but I have to do it many times and I don't know how to correctly implement a loop.
How can I do that?

This should work:
import bpy

# sample data
coords = [(1,1,1), (2,2,2), (1,2,1)]

# create the Curve Datablock
curveData = bpy.data.curves.new('myCurve', type='CURVE')
curveData.dimensions = '3D'
curveData.resolution_u = 2

# map coords to spline
polyline = curveData.splines.new('NURBS')
polyline.points.add(len(coords))
for i, coord in enumerate(coords):
    x,y,z = coord
    polyline.points[i].co = (x, y, z, 1)

# create Object
curveOB = bpy.data.objects.new('myCurve', curveData)

# attach to scene and validate context
scn = bpy.context.scene
scn.objects.link(curveOB)
scn.objects.active = curveOB
curveOB.select = True

It creates a NURBS curve. The type for curveData.splines.new(type) can be chosen from ('POLY', 'BEZIER', 'BSPLINE', 'CARDINAL', 'NURBS').

Thanks, but I already did something similar actually. Is there a way to make it a function that reads the coords from a text file passed as an argument? Something like CreatePolyLine('coords_file_name.txt')...

If you install NumPy (which comes bundled with the Linux version), you could replace the fourth line with coords=np.loadtxt('filename.txt'), and add import numpy at the top... otherwise there's certainly other ways to read in a text file in Python.

Note for anyone who finds this later, if you choose 'BEZIER' for the curveData.spline type you'll need to use .bezier_points.add() and .bezier_points[i].co instead of .points.add() and points[i].co.

For Bezier, the default (0,0,0) handles won't be adequate, you may want to set them to the points as well: .bezier_points[i].handle_left = .bezier_points[i].handle_right = .bezier_points[i].co

I like to set my handles to the adjacent nodes in the list.  That way, if I use the curve as a bezel of something, the end caps and joints will be aligned properly.

If you get AttributeError: 'bpy_prop_collection' object has no attribute 'link' in Blender 2.8 or newer, then check this answer https://blender.stackexchange.com/a/162417/131771


text:
How to manage Handlers in an add-on?
What is the best way to manage handlers in an add-on?
I am making an add-on that uses the scene_update_pre handler. In the register() function, I have added this line:
bpy.app.handlers.scene_update_pre.append(my_handler)

The issue is how do I setup the unregister() function to remove the handler if the add-on is disabled? I can't use pop because it might mess up another add-on, correct?
Whats the best practice when making an Add-on?

It is simple:
def unregister():
    bpy.app.handlers.scene_update_pre.remove(my_handler)

Blender will call unregister() in the moment you untick the addon in the User Preferences.
my_handler is a function in the global scope of your script, and you append it to the scene update handlers. You can remove it in the same way, by giving a function reference to remove(). It doesn't work if you try to remove a handler callback from outside, because another script hasn't the same function.

With a draw_handler, you pass the "handle" to be removed.  For app handlers, you remove the function, no handle is returned with bpy.app_handlers.scene_update_pre.append(my_function)


text:
Rotation around an edge (A newbie question)
Is it possible in Blender 2.8 to rotate an object (or a vertex group) around an edge? The edge then serving as an axis of rotation. If so, how is it done?

Could you add an image to demonstrate the effect you want?

Thanks, I will look into it!


text:
Key Render through Node Editor adding a border / shrinking video
Both imput videos are 1080x1920, yet the render comes out as footage 1/2 the size of the resolution, after keying with the node editor.

Can you add a screenshot of your render settings?

Yes, the resolution is set to 100%. Here are my settings https://imgur.com/a/07qVzfb


text:
Curve modifier doesn't wrap plane around bezier circle
I'd like to wrap a plane around a circle. My plane has the solidify modifier which gives it a little bit of depth.
Based on what I can find online the curve modifier should be able to warp my plane in such a way that it wraps around the cylinder. But when I do it in my blender I get strange results. Here's one example. In this example it just puts the origin of the plane on the circle and then as you move x it rotates around the circle. But I want it to wrap around the circle as though it were made of clay and I pressed it against the outside of the cylinder. Ultimately I'm trying to do this with an svg so I can cut a hole in the cylinder with the image that I want.
Anyways, here's what I'm looking at.

Here's the file.

Have you tried another axis?

Yeah, with how I've got it set up that will either make the plane really tall, like a column, or it disappears for some reason.

Apply the scales with Ctrl+A. Put the curve and the plane to the same place (the origins). The most important: subdivide the plane, because the modifier only can bend between verts. https://drive.google.com/open?id=1ts4Y1mbZ2LvhI80Nd0Edjn5qR0s8TQuX

The only way to connect two vertices is with  a straight edge. Have you subdivided your plane?

Thanks for the file! I followed your guyses instructions on my file and yes, subdividing worked. At first I tried the subdivision modifier but that deformed the plane so I subdivided in manually by adding edge loops. Was me doing that consistent with what you meant when you said to subdivide it?

Did you place the subdivision surface modifier above the curve modifier?

It gives slightly different and undesirable results either way. subdiv first I get a horizontal oval. subdiv second I get a vertical oval. In either case it doesn't keep the rectangle shape which is what I want. It seems like one of those things where people use the word subdivide synonymously with "add edge loops"

Yes and no. Set the Subsurf Modifier to "simple" not to "Catmull".

I see it now. Neat.


text:
How do you know what will make the boolean modifier work?
The green mesh and the blue mesh are identical except the green one started out as a 3mm diameter cylinder and the blue one started out as a 6.5mm diameter cylinder.
I hate to say it this way because I've been making a lot of changes as I go along so it's not 100% true but basically use of the boolean modifier has been pretty much hit and miss. Every time I use it I have no idea if it will work or not.
Once I get the blue mesh to carve into any spot on the red mesh I have to get it to carve over where the green mesh has already carved and I'm certain that will be more difficult.
Here's what I'm having trouble with:

and this is the general idea of how the blue and green meshes fit into the red mesh:

It's from an earlier model before I was as good with blender as I am now, lol. It basically forms one of those interlocking tracks that are used to hold parts together.
Finally, here is a stripped down version of the file that contains only the three meshes in question. Thanks in advance.

Well, for what it's worth I got it. I just recreated the blue mesh and tried again (https://i.imgur.com/x4i07Sq.png). If I had to guess I'd say maybe I added a solidify to the blue mesh and forgot about it and that messed things up somehow. I really don't know why the blue mesh doesn't work but recreating it worked.


text:
Solidify thickness doesn't make sense
I'm using a cylinder with cap fill type set to nothing. I usually add solidify to get the cylinder wall depth. I've been calculating it by knowing that a value of 1 completely fills in the cylinder.
However now, for no reason that I am aware of, it has started working in two different ways. If I open a new blender file it at least gives a predictable result. The value for thickness is the "radius" of the cylinder wall.

But on the file that I've been trying to work on it's pretty much just totally random or I'm too tired to figure out what's going on. 9.6cm=4.9mm or about 1/20th. I had set Display > scale to 20 but I've used solidify many times in this same way and it worked as expected (where a value of 1 fills in the cylinder). As you can see I set the scale to .05 to try and compensate but that didn't do it and I'm out of guesses.

What happens when you apply scale to the cylinder? Can you share a copy of the blend file that has the problem with https://blend-exchange.giantcowfilms.com/? maybe someone can find a setting that you have missed.

Changing the cylinder's scale works as expected but the thickness stays the same relative size. Here's the file (thanks for anyone willing to take a look).


text:
How can I copy one side of a rig to the other?
I need to mirror the half part of the rigging of my character, I remember it was something with the scale or rotation.. does anyone know which was the right solution step-to-step?

possible duplicate of How to mirror a bone?

Sorry but isnt working :/ that's not what i need, i need to select the bones (all the half part of the rig) and then just duplicate it on a mirrored way.

Keep in mind, just mirroring isn't complete, you might need to adjust the roll of the bones and you also will want to update the names since Blender will append some numeric constant to the duplicates.

In order to mirror a rig down the very middle, you'll need the 3d cursor reset (ShiftC) and used as your 'Pivot Point' (.). That'll determine the mirror center, so long as the rig itself is placed correctly in the center (0,0,0). Now Select any half of the armature (excluding the spine/middle) and duplicate it with ShiftD, next press CtrlM + (the axis you are working along, usually  X) to mirror it over to the other side. With the selection still instact, press W > Flip Names to update the names so something like upper-arm.L becomes upper-arm.R.
After doing this, the mirrored bones might have a different roll from the other side. To fix, select the original bones (can just invert selection with CtrlI if you still have the mirrored side selected), enable X-Axis mirror under Armature Options in the toolshelf and press CtrlR to fix the roll.

also the Pivot point needs to be set to 3D Cursor

I just tried to name the bones correctly on one side (ending with .L in my case) then while the pivot center was at (0,0,0) as recommended here I pressed W and choose Symmetrize. BEST THING EVER! It automatically makes a duplicate with the right names, not adding the .001 at the end making them more complicated and best of all the X axis mirror option works! This means I can even copy the keyframes of one bone and paste mirror at the other if the pose is symmetrical!

Name the bones correctly and ending with either an (.L) or (.R.
Set the 3D cursor to (0,0,0) and assign the pivot point to it.
Select the bones you want to duplicate (all ending with their Left/Right convention.
Press W and select the option Symmetrize.

It helps to have X-ray and Names enabled in the viewport so you see them all.
Then, having a left and light side ready, in edit mode you can activate the X-Axis mirror and it works. In Pose mode you can copy the bone properties (rotation and position) with Ctrl+C

Here are your steps :

Press Shift+C on keyboard to center pivot.
Press .(Period) to select pivot as scale point
Press Shift+D to duplicate bones.
Hit S then the axis you are working on (For ex:-x) and -1.
This should do it.

should be shift + D but it worked thank you

I would recommend to use the x-mirror(makes work easier down the road). See the duplicate that NoviceInDisguise linked.
Manually, you can do this:
Set 3D-cursor to center. Then select rotation around 3D cursor.
Choose the bones you want to mirror, duplicate them(shift + d), press S for scale, then x and then press -1. Duplicate bones will mirror over z-axis.

I just remembered, to mirror a half part of the bones/skeleton you have to take all the bones on the half (left or right) part of the mirror, then press S (Scale) and -1, then rotate it with R (Rotation) on 180°, plus pressing X, then you will have the half part like a mirror.
Also, the pivot should stay at median point pivot.


text:
How to make a game autosave and autoload
I need my game to always save all settings and scores, also always load them when running game. And... I want to also save theese objects, which has disappeared from scenes(collected points, boost ups, etc.) Who can help me, please?

There's probably a much easier way, but you could have variables which change depending on what level your in ect, along with others that toggle the use of boost ups and collected points etc. Then you can save these variables to different .txt files so that they're the same when you start up the game next time.
For Python Variables:
Connect this script to a keyboard sensor, with a status of All Keys, followed by an always sensor. The pytho controller is in module mode. You need a folder next to the .blend called "SaveLoad". And finally add two game properties to you object just so that you can see that the script really works.
S Key to save, L Key to Load and A Key to change the variables, but obviously you can easily modify the code to you needs of automatic execution.
import bge
from bge import logic
path = logic.expandPath("//SaveLoad/")

cont = logic.getCurrentController()
own = cont.owner
keys = cont.sensors["Keyboard"]

var1 = 20
var2 = 60

def save():
    global var1
    global var2
    for key,status in keys.events:
        if status == logic.KX_INPUT_JUST_ACTIVATED:
            string = bge.events.EventToString(key)

            if string == "SKEY":
                info = str(var1)+","+str(var2)
                file = open(path+str(own)+".txt", "w")
                file.write(str(info))

            if string == "LKEY":
                file = open(path+str(own)+".txt", "r")
                line = file.readline().replace("\n","").split(",")
                var1 = int(line[0])
                var2 = int(line[1])

            if string == "AKEY":
                var1 += 1
                var2 += 2

    own["prop"] = var1
    own["prop0"] = var2

For Game Properties
This script needs to be set up the same way as the variable script, but yet again you do have the option to change it to your needs.
from bge import logic
path = logic.expandPath("//SaveLoad/")

cont = logic.getCurrentController()
own = cont.owner
keys = cont.sensors["Keyboard"]

### Use keyboard
for key,status in keys.events:
    if status == logic.KX_INPUT_JUST_ACTIVATED:
        string = bge.events.EventToString(key)

        ### Save "prop" and "prop0" to file
        if string == "SKEY":
            info = str(own["prop"])+","+str(own["prop0"])
            file = open(path+str(own)+".txt", "w")
            file.write(str(info))

        ### Load "prop" and "prop0" from file
        if string == "LKEY":
            file = open(path+str(own)+".txt", "r")
            line = file.readline().replace("\n","").split(",")
            own["prop"] = int(line[0])
            own["prop0"] = int(line[1])

        ### Change values
        if string == "AKEY":
            own["prop"] += 1
            own["prop0"] += 1.3

Will it save in the same folder as .exe when I make game runtime? Will it use .exe file's directory/SaveLoad/?

It worked, thank's! Now I will just have to figure out the principals on gamesave.

Is it possible to do it infinite like this: info = str(own[])+","+str(own[])+","+str(own[])?

file = open(path+str(own)+".txt", "w")- does it save the game as object_on_which_is_added_python_controller_name.txt?

Hi! This is important! How do I replace LKEY with always? What should I place in "LKEY" place for always actuator?

Please, tell me how do I make it always save and load, not only then, when I use buttons. I need my game to always save and load settings(best way, evry second frame)

I tried to change properties in game, I changed some data. Than I tried it out. It saved my data, but I could not load. I checked the directory I use, .txt file was there with all contents. Why it does not work? I used 1 integer and 3 floaters, but I changed own["prop"] = int(line[1]) to own["prop"] = float(line[1])

About the always thing - instead of buttons - add an always sensor and add it as well to the python controller. Then, underneath the keys variable, add__   always = own.sensors["Always"]    __and replace the LKEY, etc - which ever buttons you plan to make always - if statements into always.positive      so   if string == "LKEY":    becomes    if always.positive == True:


text:
Is there any option to select all objects in scene and then apply all the modifiers together for every single object?
I got a lot of objects, with different modifiers, can i apply the modifiers together but with individual values for each single object? (in order to save time?)

Make the object which has the modifiers the active one, and then press Ctrl + L>Modifiers

But what if some objects have already some different modifiers that aren't applied? doesnt they mix or something?

Yes, it will over-write the set modifiers, not what you are looking for

@someonewithpc that links them not applies them..

@Jerryno Exactly, Beavoru, why do you want to apply them? Whenever you export or render it will act the same.

@Jerryno If he wants individual values, the OP will have to copy the modifiers, modify the values and then apply - no other way.

I added a lot of differente modifiers, but i didnt applied them, now i want to add a single modifier (wireframe) for everything, but then if i copy that specific modifier for everything, i think the other parameters (the other modifiers) will copy as well, and thats something i dont want :/

Related - http://blender.stackexchange.com/questions/3488/is-it-possible-to-apply-modifiers-to-multiple-objects-at-once

Select all the objects with modifiers that should be applied and then press Alt + C. In the dialog appeared select the second variant, i.e Mesh from Curve/etc. That will apply all the modifiers respectively.
In Blender 2.8 and above, the hotkey for this operation was dropped so you have to call it from viewport menu > Object > Convert To. You can assign a shortcut to it yourself or in viewport press Ctrl+A —> Visual Geometry to Mesh which essentially will call the same Convert To > Mesh operator.
Probably you will need to create backups of the meshes to have possibility to redo something with modifiers if needed.
Be careful applying modifiers to objects that share mesh data, as it can lead to unexpected results due to instancing; only one mesh will be used for all instances which means that modifiers will be copied from the very first instance and modifiers on other instances won't be taken into account as well as still-active modifiers on unselected object instances can cause severe performance impacts.

This will do what you want: Applies modifiers for all selected objects:
import bpy
import bmesh

for ob in [ob for ob in bpy.context.selected_objects if ob.type == 'MESH']:
    b_me = bmesh.new()
    b_me.from_object(ob, bpy.context.scene)
    b_me.to_mesh(ob.data)
    b_me.free()

    for mod in ob.modifiers:
        ob.modifiers.remove(mod)

To add modifier (wireframe) for all selected objects:
import bpy

for ob in [ob for ob in bpy.context.selected_objects if ob.type == 'MESH']:
    mod = ob.modifiers.new(name='Wire', type='WIREFRAME')
    mod.thickness = 0.02 # SET THIS


text:
How to curve an already made curve?
I created a curve, but now i need to take all the object and curve it again, like this:

does the Curve modifier work? Use a NURBS Circle.

how can i put it/link it to my actual curve?

yes, how can i connect my curve to the other one? sorry if my english is bad, isnt my main language :/

You can use the powerful Curve modifier to do this. Make a curve to use as the factor, name it something you can remember, and then select the curve you want to bend and go to modifiers and add a Curve modifier. You then will need to select the name of the curve you want to use as the factor, like this:

Now your curve should conform to the shape of the circle, however it may look a little odd:

What you need to do is select the circle and scale it to the desired size, you should end up with something like this:


text:
How can i hide the references lines on a bezier curve?
I want to hide all those lines, only keeping the main curve while working, how can i do that?

You can hide the path normal markings by pressing N and then finding the Curve Display section. Under that un-tick Normals. If you were referring to the handles (the red line), then that option is the next checkbox.

In 2.8+ the settings seem to be at the bottom of the "overlays" pan.

@AnthonyBobenrieth Thanks - I've been searching every panel for about a day and a half looking for that.

@AnthonyBobenrieth okay and so where IS the "overlays" pan…?

@Tim Two balls icon in top right of a viewport. This should help: https://i.imgur.com/5xUDBut.png


text:
How to duplicate an object with rig and animation?
How can I duplicate a geometry with rigging and animation?
I have an animated character with bones, but I need to duplicate it just like a mirror, without messing up or ruining the model.

How about using a mirror for the mesh, and then mirror the rig(http://blender.stackexchange.com/questions/24026/how-can-i-copy-one-side-of-a-rig-to-the-other)?

Will i need to re-skin the character?

I don't know. I've never skinned a half-finished mesh before.

But if that's your issue, I doubt it's difficult if you copy the vertex groups as well =) But that's out of my field.

@X-27 wanna put that as an answer so we can get this off our unanswered list? Thanks!

In Blender 2.8a, put everything that belongs to the character into a collection. In object mode, right-click on the collection -> "Duplicate Collection".

You can use Blender's group linking system:

select both your mesh and its armature
hit CTRL + G to put them in a group (and eventually hit F6 to name that group)
If you need a clean scene, you can create a new empty scene (in the "info" toolbar (at the top of the default UI layout), the + button)
hit SHIFT + A and select "Group instance", then choose the group you just created
repeat the last step as many of time you need duplicates
play the animation, all the groups should be animated the same.

If you need one group instance to play the animation mirrored, you can scale it on X and Y axis with value -1 (S > SHIFT+Z > -1)

I was just looking at this for duplicating a rigged character without duplicating key frames... but... it did duplicate the key frames. Here's how I figured it out and here's how it went (Blender 2.74) after some trial and error...
I made sure I was in object mode, shift selected the armature and character mesh. Duplicated (shift+D) the selected items and dragged them out (pressing Y in my case to constrain the transform to the Y axis). This created a copy with all key frames in place but displaced from the original along the Y axis.
I wanted the copy facing the original but rotating the entire selection 180 around the Z axis caused some really weird problems. The solution was to select the armature only, skip into pose mode, select the root of the armature (the one bone that the whole thing will transform around) and then rotate (R Key, Z key, 180).
I'd set up the armature with some IK control bones (hands and feet), pole targets (knees and elbows) and the hip bone being the root parent for the rest. All of these were children of the main "root" bone that would move the whole armature. This was the root bone that I had to rotate.
Another stumbling point was when I tried to delete the existing key frames from the copy (because they had been copied faithfully) and managed to delete the keys from both characters. Stupid mistake (because all the keys were on the dope sheet) but something to watch out for. The cursor icon in the header (next to the ghost thing) isolates the selected items and might help in this respect.
I'm not sure if this will help you directly but this thread did get me there in the end.


text:
Strange shadows on mesh following curve
I'm currently modeling a scene that features a highway overpass at night with light streaks.
I have constructed the main piece of the overpass, and made it follow along a bezier curve with little to no problem with an array and curve modifier.
The only problem, is after I render, I get some strange shadows on the road that do not make much sense as to what the reason is.

I thought at first it was the road lines causing a problem (they are on a separate mesh for ease of use), but even after rendering without them, the shadows still appear on the road.
I've tried recalculating normals and other fixes, but it hasn't worked. It might be the mesh, but I tried to keep it as low poly as possible.

I'm not entirely sure what is causing the problem, so any help would be great.
Thanks in advance.
EDIT
Here's the modifiers on the highway

Are you using a seamless texture? or textures at all?

Are you using Cycles or BI?

No textures, just flat color, and I'm using blender's internal renderer.

If you know you are done with the curve , merge the vertices and remove doubles.

That didnt really do anything. Even after recalculating normals.

Array modifier? If so tick the Merge checkbox.

I have the array merged as well, I've just posted the highway's modifiers on the description. I'm going to try a different method, and see if that fixes the problem.

Relative offset -1 shouldn't do anything funky . . . how does it display without the Curve modifier?

Okay, so I've narrowed it down to what is causing the problem. The actual mesh isn't at fault. Apparently it's my light trails causing the shadows. The way I have them, is a single plane (each), duplicated along the path. The planes dont have a texture, but they do emit light.

It seems like wherever there's an edge on the light trail's mesh, it causes a dark spot. I think I have an idea on how to fix it though.

Nevermind, it's still acting up.

Pasteall isn't working for me, but here's a dropbox link if anyone wants to take a crack at it. https://www.dropbox.com/s/wke2gbgvvg6jt5j/Overpass.blend?dl=0

I've personally never had very predictable results from BI's indirect lighting.. Wouldn't be surprised if it's just a side effect of the way it works.

Delete the faces on the beginning and the end (left and right seen from image 2) of the parts. It needs to be open at the ends for the parts to merge. Play with the merge distance, make it larger until it snaps. I can see from image 2 that the parts did not merge causing shadows in between. You need an equal amount of  vertices on begin and end to make it snap.

good call, I over-looked that.  Those in between faces will certainly cause a mess, which brings up a good point.  When you have visual errors; it's a good idea to start hiding faces around the affected area so you can see if there's anything going on underneath.

Thanks guys, I had the same realization as well a bit ago. Since the BI renderer was causing me problems though, I switched over to cycles, and things are working perfectly, if not better. The noise is a bit much, but I can be patient when it comes to the final render. Thanks a lot guys!


text:
Is there a function to fix edge length in Blender?
I hope this question is clear enough. I am trying to create a 3D model of a tesselated origami model. What I want to do is translate a vertex and have the surrounding vertices translate such that edges connecting them to the translated vertex keep their original length.
Here is an image of the origami model:

Here is an image of the 3D model of the flat tesselated pattern:

I hope you can see here that I would like to translate the centre points of the concave hexagons (the vertices currently selected) and have the connected edges keep their length as if it was made of a rigid material.

I'm confused as to what you're trying to do.

I think is is the same as this question (http://blender.stackexchange.com/q/18601/822) except for edges instead of faces.

Currerntly, I don't think there is any easy-and-accurate way to do so. For the specific case, manual adjustment can be acceptable, and almost unnoticable.

Don't have too much time to experiment on it, but have you tried with bones, inverse kinematics and such ?

For the specific case, You may consider using cloth simulation to preserve the edge length:
Step 1 to 3: Create Unit; mirror + arrays; Apply modifiers + coloring for convenience. (For existing model, you can ignore above)
Step 4: Select all poked vertices, CtrlG to add to a new vertex group, then CtrlH) to add a hook.
Step 5: Add Cloth simulator. use the vertex group as pins.
Step 6: Scale the hook while simulating (playing animation). Then AltC - 2 to convert the result. Finally, delete all unwanted faces.

Example file

Thank you for your detailed answer. Trying to get my head around this now.

OK. I understand the principle here. I'll continue to see if I can get the result I want and post back here.