Rotate around one point, with constrain on z-axis for other point, impossible?

There's actually a very quick way to do this. All you need is 3 bones with an IK constraint. Set the root of the first bone at the center of the cylinder in your diagram and the tip on the edge (where the lower stud would be). That way when the bone rotates the tip will follow the track. Now extrude a bone up to the top of the door (top stud). Finally extrude another bone horizontally (left in the case of your diagram) and clear the parent on it.

Then in pose mode, add an IK constraint to the second bone and select Armature in the Target box and the 3rd bone that we cleared the parent on in the Bone box. Now, when you move the 3rd bone (which will be the control bone) the other two bones will follow, the door will open, and the lower stud will always stay the same distance from the center of the track radius.

Optionally you can add a limit location constraint to the control bone (as I did in the gif below) to ensure that the control bone never moves where it shouldn't.

All you then have to do is parent the door to the second bone (the yellow one with the IK constraint) and everything should be good to go.


What is my mistake in creating the uv map of the lantern?

First , I see some Overlapped UV islands (may I wrong because of image size).
Second , you should use a checker map to check your UV

then in Substance painter for some materials and texture coordinate you should change Projection on UV or Tri-Planer


The fastest solution in this case may be using a knife tool. Press K and snap the knife to the vertices. After pressing the LMB press C to make the cut go straight and cut the longer piece horizontally. Repeat the process for the other vertex. Now you can use a bridge tool to connect pieces (and then dissolve the unnecessary edge). You may also use a snapping tool (vertex) to connect pieces and then remove doubles.


I would suggest that after creating your two paths, you convert each one to a mesh, then you Join Ctrl+J the two new meshes, then in Edit Mode you select segments of vertices on each side and make a new Face.

The reason you should select a small segment at the time is if you were to take the whole thing there is a risk that it creates one large face that can cover the hole in the middle. You can use the Circle select to grab a set of vertices.

Hope this works for you.


How is possible to create a tetrakaidecahedron? How can I keep only the edges?

Under the user preferences make sure you activate the default bundled addon Add Mesh Extra Objects.

Add a new mesh of the type Math Function > Regular Solid and from the presets at the bottom pick Truncated Octahedron.

Erase the edges dividing the large faces in half, then add a Wireframe modifier.

Adjust the thickness as desired and add two Subdivision modifiers below it. The top one must be set to Simple, and the second one to Catmull-Clark.

Adjust subdivisions as desired for a more organic or geometric look.


Accessing Point Data of an Animated Bezier Curve Through Python API

Could you perhaps solve your problem by using Hooks?

Edit the curve
select the endpoint you want controlled by the empty.
Ctrl-h and Hook to New Object

Now moving the freshly-created empty drags the curve control point around.

It is also possible to hook the control points to bones in an armature, or maybe just select the hand and the curve and hook the control point to the hand object.


Why do these shadow catcher planes seem to let light pass through making new direct shadows to appear?

Shadow catcher is most of the time used to blend CGI Objects into real world scenes, you could also use the shadow catcher to render an object with transparent but with the shadow below. These are not the only ways to use the shadow catcher, but some examples. Blender Manual


bmesh/python - list directly or indirectly connected verts

Assuming the following definitions are a correct interpretation of what you are asking...

directly: connected by a single edge
indirectly: connected through a continuous path of N edges

...then the following code will find all directly or indirectly connected vertices of a given vertex. findConnectedVerts() takes the vertex of interest plus a maximum depth as arguments. It will then recursively find the connected vertices. I've tested this on a cube to verify that depth 1 yields the directly connected vertices, depth 2 yields all but a single vertex (which is 3 away) and depth 3 yields all the vertices in the cube (well, not the vertex passed in).
Note: I wasn't considering performance only functionality
import bpy

def getEdgesForVertex(v_index, mesh, marked_edges):
    all_edges = [e for e in mesh.edges if v_index in e.vertices]
    unmarked_edges = [e for e in all_edges if e.index not in marked_edges]
    return unmarked_edges

def findConnectedVerts(v_index, mesh, connected_verts, marked_edges, maxdepth=1, level=0):
    if level >= maxdepth:
        return

    edges = getEdgesForVertex(v_index, mesh, marked_edges)

    for e in edges:
        othr_v_index = [idx for idx in mesh.edges[e.index].vertices if idx != v_index][0]
        connected_verts[othr_v_index] = True
        marked_edges.append(e.index)
        findConnectedVerts(othr_v_index, mesh, connected_verts, marked_edges, maxdepth=maxdepth, level=level+1)

def main():
    mesh = bpy.context.object.data

    connected_verts = {}
    marked_edges = []

    findConnectedVerts(0, mesh, connected_verts, marked_edges, maxdepth=1)
    print(",".join([str(v) for v in connected_verts.keys()]))

    connected_verts = {}
    marked_edges = []

    findConnectedVerts(0, mesh, connected_verts, marked_edges, maxdepth=2)
    print(",".join([str(v) for v in connected_verts.keys()]))

    connected_verts = {}
    marked_edges = []

    findConnectedVerts(0, mesh, connected_verts, marked_edges, maxdepth=3)
    print(",".join([str(v) for v in connected_verts.keys()]))

main()


How do I restrict scaling to a specific axis?

Yes there is a way to do it.

During the scale S :

Use either X or Y or Z to scale only along X, Y or Z
Use either Shift+X or Shift+Y or Shift+Z to respectively scale (Y and Z but not X), (X and Z but not Y) or (X and Y but not Z)

And after you have confirmed your scale, you still have the operator panel in the bottom left part of the view :


A sleepless night brought up the following question: How to add a Particle Texture?

The steps are finicky but work well:

Create the particle system, and create/paint a new texture; include it as the object texture if you want to see what you're doing (the object's texture/material won't affect the particle system).
In the Particle Properties tab there's a dropdown called Textures. Select your texture.
In the Texture Properties tab, go under the Image > Settings dropdown and select your image (again).
At the very top of the Texture Properties tab, set the dropdown to ParticleSettings - Texture.
Finally, under Influence (still in Texture Properties), check Density to let the image drive particle density.

Also, for the particles to appear at the right place on a non-square surface, it may be necessary to select the UV unwrap for the particle system to match the texture placement. That's under Texture Properties > Mapping > Coordinates, select UV.

Steps 3 and 4 are particularly strange at first, but work well after all. Tabbing in/out of edit mode will reflect the particle system changes. Then, to texture paint the hair, go to texture paint mode and paint more white on the texture, remembering to tab in/out of texture paint mode to update the particle system.


You first example line bpy.app.driver_namespace['<functionname>'] = <functionname> registers the function within the driver namespace and makes it available as <functionname> within any driver expressions.

From other areas of blender you can access it with it's full data path - bpy.app.driver_namespace['<functionname>'](3) calls that function passing a value of 3.

But that isn't the issue you have with the math object creation -

The XYZ math surface object allows you to enter an arbitrary string to define the surface of the object. As this also allows any python to be run it implements a security feature that prevents any functions not listed in it's safe_list from being run.

To get around this you need to do two steps, add your functions as a module and then import them into the addon and add the names to the safe list. Or you can adjust the usage of the safe list to allow any functions. You may want to duplicate the addon and adjust it so you have your own custom addon that suites your needs. You may also find it easier to define the calculations used and just input a few variables.

For a sign function in a on-line script you can use 1 if x>0 else 0

For a^b I don't see an issue -2**3.5 returns -11.31370849898476


Alright after some tinkering around I stumbled upon this page. Basically I had to pass the argument as a keyword:

bpy.ops.import_scene.ldraw(filepath="model.ldr")

And now everything works as expected.


How to make an object move on a Mobius strip?

Create a Bezier Curve. Open it (it shouldn't be closed). Tilt one end 180°. ⎈ CtrlT
The Curve should resemble the twist of the moebius strip.

Add a Follow Path Constraint to the object. Check Fixed Position and set a key with the offset at 0 and 1.

Select the created keyframes and make them linear. T > L
Then make the graph cyclic. ⇧ ShiftE > Make Cyclic
Set a key on the first frame of the rotation. I
Set a key after the second keyframe of the offset on the rotation with the object rotated 180°, making it ready for the second circulation.
Set the new keys to constant interpolation. T > C

Wheeee!


In many models, many objects have vanished and just appear as dots. Why?

I rebooted the system, and perhaps related, switched from Cinnamon's software rendering to hardware rendering in the reboot (but it's been set to software forever). The problem went away.


Installing module to blender's python (Mac)

For some reason using cd to blender's python bin folder and then executed command was not working, but ... path to blender's bin folder with python3.7m + command executed at once worked just fine.

Do I have a "pip"?
I don't know if 2.80 was distributed without a pip (as mentioned above), but 2.79 and also 2.83 Mac build containes a pip ... executing ensurepip was satisfied. You can check that by right click on Blender.app icon > Show Package Contents > Contents > Resources > 2.9x > python > bin, drag&drop bin folder into Terminal window, type python3.7m -m ensurepip and execute. In my case it looked like ...
/Users/Filip/Downloads/Blender\ 92.app/Contents/Resources/2.92/python/bin/python3.7m -m ensurepip

Upgrade "pip"
Terminal recommend update pip to latest version. So copy&paste directory of bin folder or drag&drop bin folder again  into Terminal window, type  python3.7m -m pip install --upgrade pip and execute. My example ...
/Users/Filip/Downloads/Blender\ 92.app/Contents/Resources/2.92/python/bin/python3.7m -m pip install --upgrade pip

Module installation
From what I tried, even without pip care I could just install module by command
python3.7m -m pip install + type your module name. In my case open3d module...
/Users/filip/Downloads/Blender\ 92.app/Contents/Resources/2.92/python/bin/python3.7m -m pip install open3d


Light Align tool ( LightPaint feature as in HDRI Light Studio )

The Add-on Blender Light Studio - https://leomoon.com/downloads/plugins/blender-light-studio/ - offers that functionality via a modal operator. Activate the Add-on and add a light profile in the Toolbar on the left. After that, add a light via the interface too. Now, when a light is active, you can enable the interactive placement mode, called 3D Edit, like this:

Basically, you click on a face of the model, and the Add-on calculates the light position for you. Once you're happy, hit the Esc key to exit the interactive placement mode.


How to apply textures without them mirroring?

If you've finished modelling can you just click apply to the mirror modifier which will then just give you a single mesh to work with?


How to imitate early CGI style animation?

I think it's rather difficult to determine a specific "settings configuration" that accurately represents 90's CGI, more of a series of tweaks, mainly in the vein of "breaking the modern rules" of shading, I think is what's needed to get the effects you want.
To me, 90's era CGI is defined by several factors. The first, and most obvious being limited geometry (ie fewer subdivisions), however also high on the list are approximated light reflections (so eevee is good), with less than perfect roughness and transparency/translucency (because caustics were very expensive back then), but a focus on metallic looking surfaces, and pronounced specular dots in lieu of accurate reflections. I also seem to remember over-saturated colors, as well as confused color schemes/tone maps to compliment (or insult?) the other objects in the scene.
In the scene I made below, I didn't do anything really special. The most notable thing I did was to use the back-facing output of a geometry node as the Mix Factor between a Transparent BSDF and the rest of the components on the Gem to make it give that "hollowed out" look, like in the image. I also used the Parametric output to control the Mix Factor with an Emission Shader. I don't know if it's "right".... it certainly is "wrong" according to the conventions I learned, but it seems that the idea is to "break the rules" somewhat, in order to "degrade" the look of things, so to speak. I also left a Layer Weight Node next to the roughness input of the Principled BSDF that makes up the gold material. I left it unconnected because I couldn't decide if it looked "better" or "worse" without it. Connecting either the "Facing" or the "Fresnel" output to the roughness both give some interesting results (so long as the metallic is sufficiently high).  Everything else, I mainly achieved just by keeping the roughness above 0 and playing with the specular values. I added a couple of extra lights to the scene, but I did not change any of their settings, and for the sky, I "cheated" the ambient lighting generated by the texture by using the "Is Camera Ray" output of a Light Path Node, to give a grey-orange ambient light instead.

The last step was just trying to make sure I wasn't (noticibly) using any advanced (compared to the 90's) features such as screen space reflections. I did cheat and use some bump information for the water, but that was just to save me the trouble of baking.
I'll include the .blend file so you can play around. I'll also keep working on examples of the other two images you posted, though I'm rather busy so it might take some time. Feel free to experiment in the meantime. I think the idea is to make the scene look "wrong" but in the "right" kind of way, if that makes any sense.
NOTE - I used a face-builder add-on to get the heads for the scene, but I'm not sure if they'll transfer with the file correctly. I'm hoping they do. If not, you'll have to use your own mesh, or Suzanne or something.
File is here -


I have this weird effect after I apply shade smooth

Did you select autosmooth check box?
It is right here, it should most probably solve your problem:

If it doesn't fix it here's is another possible solution:

Click on the arrow next to viewport overlay
Select 2nd option from the bottom called face orientation.
If all the faces are blue, you are good to go, if any face is red you might have to recalculate the normals.
to recalculate normals, go too edit mode, select all the face by pressing A, press Alt + N, From the list that opens select recalculate outside.


The problem lies on the eyes socket.

I could automatically weight the mesh with this procedure: i selected all eyes socket (the vertices not selected in the picture), pressed P for separate vertices into a new object, then automatically weighted the body. After doing this you can rejoin the two meshes, remove doubles, select the eyes socket and manually weight them.

Make sure you are working in the "basis" shape key!


Starting an animation on the birth of a particle or using animation nodes?

Solution

This can easily be achieved by subtracting the birth time of each particle form the time input of the required animation.

Lets assume that your animation is a simple 180 turn around the z axis, then I can just generate the rotations as follows:

What happens is when you subtract the birth time of the particle, the time of the animation becomes zero at the time of its birth and it linearly and continuously increases. Other complex and advances animations and scenarios can be achieved on the bases of the previously described concept.

Appendix

In case you don't know how to make a group like particle system, here is a simple a node tree that does exactly that:


Welcome to Blender Stack Exchange!

The reason you see what you do is because of the size of the shape that you are extruding along the path and the radius of the curve in the path.

When you extrude something around a curve, there is a maximum size shape you can extrude before nasty intersections occur. The maximum size shape you can use will have a radius that is the same size as the radius of the curve in the path.

What I'm trying to say is that you can't get a nice, smooth curve when using an object that big and a curve in the path that tight.

You have a few options though. You can change the curve in the path to make it less sharp, or make the profile you are extruding smaller, but I'm guessing that's not what you want. You can try selecting some of the nasty faces and using the Smooth Tool (can be found by pressing W) or using the smooth brush in sculpt mode.

My suggestion would be to use a lot less extrusions along your path, then use the subdivision surface modifier to smooth it all out. That way you have a lot less vertices to get bunched up in the corners and you can easily edit them all manually to make it look better (by moving them individually in edit mode or smoothing them with one of the options above). Also since you are going to be using this for a game you want to use as few vertices as possible to make it run faster.


Keyframed animations only happen at a specific time that we have set, using the NLA it is possible to duplicate an action so that the same animation can be repeated at different times. While we can copy and paste the same thing into different places, it is a manual process.

To automate animations we can use constraints and drivers. Constraints use a simple interface to configure a range of preset conditions, drivers expand on this to allow values to be calculated using python expressions or scripts.

If you have multiple objects that you want to move in unison, constraints can allow one object to be the master control with the others moving in relation to the master. This means you only keyframe the one object at the time you want them all to move.

It is possible to input a distance between two objects into a driver, this would allow an object to move if another is within five units of it and have it move back when it is farther than five units away. While we can get great control over an item, it requires the use of python, even if only a short expression to define the calculation to use.


Something wrong with my tracking markers?

This seems your solve error is fine.
Did you set the scale? if not ...
Under Solve Panel
their si Orientation Panel
Scene orientation tools can be used for orienting object to bundles.
Floor
Use selected three markers to define a floor. Camera will be transformed in a way which makes the selected markers to be flat (have Z = 0).
Wall
Similar to the floor orientation, but defines a wall (selected tracks are placed onto OXZ plane).
Set Origin
Transform camera in a way which makes active track to be moved to a scene origin. Only translation is applied to the camera.
Set X, Y Axis
Transform camera in a way which makes active track to become on X or Y axis. No translation is applied, meaning scene origin which was specified before will be preserved.
Set Scale
Scale camera or tracking object in a way which makes distance between two selected tracks match the given value in Distance.
Apply Scale
Similar to Set Scale, but actually modifies the tracking data.
Distance
Distance in active scene units which is used by Set/Apply scale.
...  I hope this will fix the scale..


If you want to use it, GIMP is a great alternative to Photoshop with a lot of the same tools and features for free. From there you could probably follow a Photoshop tutorial relatively well like this one.

I don't do it as much any more, but when I did texture painting, it worked really well for me to have a texture paint window open on one side of my display and an image editor on the other (see this post). Doing this, you can get some really good detail as long as you have a good set of UVs. I never even had to use GIMP or Photoshop.


Blender is not rendering in the viewport

Your render is paused .
Click on the top right icon shown in the image to switch it back on.
Don't mind the clipping... (The one in the second circle)
This function is normally used to prevent a view port render from updating even if we make any changes to any thing or try to mave in the viewport.


Before coding your own custom version of blender, start with what blender already offers -

Maximise Area makes the current editor (usually the 3D view) take up the entire window area while leaving the Info Bar at the top and viewport headers visible. In 2.7x press ⎈ Ctrl↑ Up arrow, in 2.80 press ⎈ CtrlSpace
Fullscreen Area makes the current editor take up the entire window without the info bar or headers being visible. In 2.7x press ⎇ AltF10, in 2.80 press ⎈ Ctrl⎇ AltSpace
Screens are preset window layouts that we can easily switch between, in 2.80 these are replaced with workspaces. If any of the included screens do not suit your requirements you can create your own or adjust the included screens. By setting up screens and saving them in your startup blend file, you can have them each time you use blender. This means you can manually setup a layout the way you want and always have it available and active when you first start blender. Note that you may want to disable the Load UI option to prevent other peoples screens being loaded when you open a blend file.

By making the 3D view full screen you still have the tool shelf and properties regions. You can use python to define your own custom panel to make specific things/actions easily available to you and by putting it in an addon it can always be there. You may also want to get creative and misuse the ability to alter header contents with an addon, say you never use the VSE, then you can setup a screen that has a small VSE area available that shows buttons or menus that you define.


It is a setting of the added cloth modifier.

context.object.modifiers['Cloth'].point_cache.frame_end

(where the cloth modifiers name is "Cloth" and the object has context)

The tooltip is spot on in later versions of blender.

Note may have to mouse over properties area to redraw and see new value.


How to use Blender in a way that allows easy modifications

Try the same thing again. However this time don't apply the boolean modifier on your original object set, just keep them active. You can take your original objects by duplication and hide them on a different layer. This way if you need to make a modification, you can duplicate them back to your working layer, make the desired changes, and on the working layer only apply the modifier(s).

So that you have a bit more visual context to what this means, here is the break-down:

Here are the ways that I split up the layers:

Layer 1 (Homerow 1) = The Active Layer

Layer 2 (Homerow 2) = The Stored Object Being Subtracted From

Layer 11 (Shift + Homerow 1) = The Stored Object Being Subtracted.

Here are the screen shots in the order listed:

Here is the modification workflow after you find the need to change something:


Is there a way to disable curve normals by default?

You're right: saving to startup scene doesn't make the change permanent. A workaround I use is changing the Normal Sizes on the same display tab to something smaller and less intrusive.
Then I go to object mode, delete the curve and save as startup file using CtrlU. The next time I open blender,  the normal size for displaying curves is how I set it.


How to import .py file from another directory in animationnodes2.1?

Th import statement should be:

from .. bvh_tree.construct import ConstructBVHTreeNode

Because the from import takes the form from module import something.


Move the object your are using as particle a bit upwards in Edit mode so that the bottom of the ball is at the object's local origin.


Hook to Empty Object on a Bezier Curve doesn't work

First unhook the hooks, keep the empty's Subdivide the curve. Go to Object mode to select the empty and the curve you want to hook it to. Then go to Edit mode, select the middle vertex of the curve and press Ctrl + H to hook it.


Better way for stopping simulations on timeline?

If you keep the mouse over the pause button in the timeline until the next frame is updated, it should register your click eventually. AFAIK the problem is that during a frame update, all of Blender's UI is locked (including all hotkeys), so consequently, nothing will be able to stop it while updating an individual frame.

This is universal for anything in Blender (and I think any app) that locks up the interface for a while. It doesn't log the position of the mouse until it has time to handle the click event. Sort of unfortunate, but that's just the way it works.


How to import morph targets into Blender?

One possible way is to import 1 mesh. Create a shape key as a base shape key. Import a second compatible mesh. Select the second mesh, and then shift+select the original base mesh, and on shape keys panel, click "Join as Shapes". Repeat to join all shape keys to 1 base mesh.

Try using THREE js to shift to one of the morph targets, then export multiple OBJ files and join them all in blender.


Create your cage, I have used a box
Select your box and enable Edit Mode (Tab)
Keep the box selected and go to Mesh > Normals > Flip Normals
Then go to the Physics tab, and enable the Collision modifier

Now your boids should interact with the cage. Hope it helps.


Name the text datablock something.py and tick the 'register' checkbox. It'll run whenever you load the file, just like you want.

You do need to enable autorunning Python scripts in your user preferences (this is disabled by default for security reasons).


The First way to do this...

( This will work independent of the axis you created your curve object.)

Select your curve.
Hit spacebar and search for "convert to" Shortcut (ALT + C)
Select "Mesh from curve"
If you have not turned on "Mesh : F2" addon do so in the user preference.
Enter edit mode with the converted curve selected.
Select all the edges and hit F to fill.

-

The second way to go.

(For this method your curve needs to be created in the top view OR in another
words the XY axis)

Select your curve.
Go to Properity panel > Bezier Tab > Shape > turn on 2D shape Button.
Make sure "cyclic" is turn on.
Select "front" on the fill option.

Cheers let me know if it helps.


Without watching the video tutorial, a high and low resolution model cannot share the same UV-map therefore geometric details from the higher resolved mesh are baked into a normal- (or other type) map which is unwrapped from the low res model.

The generated map is used to create details (fake geometry) for lower rendering time which is very common in games.

The workflow in this normal map example :

Unwrap the low res model
add a matrial and texture
select high res and then low res model
bake from selected to active


How to resolve these artifact looking after apply normal map?

The problem has been resolved. It is caused by the missing info from the normal map.
To fix the normal map, I used Photoshop to clean those spots, and it works just fine without baking another one.


You can adjust the Mirror Texture Settings by checking U or V, or both

The texture won't be mirrored, and when you apply the mirror modifier you will be able to see all the parts clearly ( in the UV editor )


execution time for a program in python blender

import bpy
from itertools import product

mesh = bpy.data.meshes['Cube']
objects_scene = bpy.context.scene.objects
objects_data  = bpy.data.objects
actions_data  = bpy.data.actions

def create_cube(name, location):
    obj = objects_data.new(name, mesh)
    objects_scene.link(obj)
    obj.location = location
    return obj

def create_animation(obj, time):
    obj.animation_data_create()
    obj.animation_data.action = action = actions_data.new("Action")
    fcurves = [action.fcurves.new(data_path) for data_path in ("hide", "hide_render")]
    for fcu in fcurves:
        fcu.keyframe_points.insert(   0, 1, {'FAST'}).interpolation = "CONSTANT"
        fcu.keyframe_points.insert(time, 0, {'FAST'}).interpolation = "CONSTANT"
        fcu.extrapolation = "CONSTANT"

n = 6
time = 1
for i in range(n):
    for indices in product(range(-i, i+1), repeat=3):
        if sum(abs(j) for j in indices) == i:
            cube = create_cube("Cube", indices)
            create_animation(cube, time)
            time += 1

The result rendered using the OpenGL Viewport Renderer:

Note

I scaled down the default cube manually and deleted it afterwards before i ran the script.


Is there a Unity coordinate system export option?

Most file export formats allow you to configure some kind of world orientation in the export settings. As you can see in the images below. .FBX, .DAE, .OBJ, and .PLY allow you to specify a "forward" and an "up" axis, and others like .GLTF have a checkbox to specify Y-UP. See below (examples are from .fbx and .dae):


Lofting: can I copy a Shape-Keyed mesh for each frame of its animation?

Bmesh script

Select the profile mesh, run script. Creates a copy for each frame from scene frame start to scene frame end.

A simple edge loop animated with follow path constraint, scale, and a mix of two shape keys.  BMesh.from_object gives a mesh snapshot at that frame (Apologies for low quality gif)

import bpy
import bmesh
from mathutils import Vector, Matrix
from math import radians, degrees
context = bpy.context
scene = context.scene
ob = context.object
me = ob.data
bm = bmesh.new()
f = scene.frame_start
step = 1
while f <= scene.frame_end:
    scene.frame_set(f)
    bm.from_object(ob, scene)
    rme = bpy.data.meshes.new("Rib")
    bm.to_mesh(rme)

    copy = bpy.data.objects.new("Rib", rme)
    copy.matrix_world = ob.matrix_world
    scene.objects.link(copy)
    bm.clear()  # interesting without.
    f += step

Skinning the thing.

Rather than having an object per rib, could also make one object.  Taking advantage of the order each rib ring is added, can bridge these edgeloops with bmesh.ops.bridge_loops  Could be done on a lower level by creating faces.

import bpy
import bmesh
from mathutils import Vector, Matrix
from math import radians, degrees
context = bpy.context
scene = context.scene
ob = context.object
mw = ob.matrix_world.copy()
me = ob.data
nverts = len(me.vertices)
nedges = len(me.edges)
bm = bmesh.new()
f = scene.frame_start
step = 1
rings = []
while f <= scene.frame_end:
    scene.frame_set(f)
    bm.from_object(ob, scene)
    bmesh.ops.transform(bm, verts=bm.verts[-nverts:], matrix=ob.matrix_world)

    rings.append(bm.edges[-nedges:])
    f += step

# build from rings
next = rings.pop()
while rings:
    ring = rings.pop()
    bmesh.ops.bridge_loops(bm, edges=ring + next)
    next = ring

rme = bpy.data.meshes.new("Rib")
bm.to_mesh(rme)
copy = bpy.data.objects.new("Rib", rme)
#copy.matrix_world = mw
scene.objects.link(copy)


Assigning texture and colour to object groups

Your Problem seems to be linked Object Data. You need to make your Objects Local first and regroup them. First to make them local press U > "Object and Data", while all objects are selected. Then select your group that should always have the same color and press Ctrl+L > "Object Data" to group them.


Remove black lines rendered using Cycles

Solution: select the object, and then select the option:

Object -> Transform -> Origin to Geometry.

This solution is similar to the @Bithur's comment.

I don't know why it happens, but it seems Blender could have a little bug about handling textures when the objects are too far from the workspace center. For sure it's not a feature.


Without seeing your node tree this is my best guess. Under the texture image node change the projection from flat to box. You can also change the blend value but if your stairs are perpendicular it probably won't change anything

Edit: sorry picture is sideways i am on my phone.


No, freestyle is not yet supported in Cycles (and I'm not sure it ever will be directly supported). You could work around the issue by using render layers and grabbing only the freestyle pass from BI:

Then mixing it with the Cycles pass in the compositor.


Keyframing angular velocity (linear acceleration of orbiting bodies)

The angular frequency is the gradient of the curve in the Graph Editor View. For example
$$
\frac{43200-14400}{1801-1201}=48.0 \ \  [deg/frame] \ \ \   at \  1801 frame \ .
$$


From what i have searched, u might have to try changing the source code....
Look in content in the below posted link:
Hope you find your answer.
https://developer.blender.org/T42194


How can I seal/close a head model at the bottom so no light will get in but only from the eyes?

Firstly, you are not only selecting the vertices around the hole—only select the vertices that are actually "touching the hole" (if that makes sense). If it's still not working, it's likely you're having some sort of issue with the mirror modifier. Try applying the modifier, select all, and then W-->remove doubles. Select all of the vertices surrounding the hole, and then press "F." This should fill it up nicely.


Extending ridge around part of an object

If you can live with the awful topology of the mesh here are the rough steps to accomplish modeling that ridge:

Lets start by sanitizing the mesh first

Select these vertex and move your 3D cursor there with Shift + S Cursor to selected

Exit edit mode and move the center of the object to the cursor with Shift + Ctrl + Alt + S > Origin to 3D cursor
Now that your Arm object has a sane center move it to the scene's origin (coordinate 0,0,0)

Now lets make the object symmetrical

Add a vertical plane at the object/scene origin

Scale it so it reaches the whole object
With both selected enter edit mode on the arm object, and in top view use the operator Knife Project to cut your whole geometry in half. Use the option cut through for best results
Now delete half of the mesh, making sure you delete all the small faces along the symetry axis

Now you can add a mirror modifier to the object so you only have to deal with half of the mesh and model part of it. Blender will take care of the symmetry

Modeling the ridge

Now delete this part of the mesh

Select the border of the round part an duplicate it with Shift + D

Scale in inwards towards the cursor by pressing . then S to scale and Shift + Z to keep it from scaling in Z direction
Separate the scaled edges into a new object with P
Now use the Knife Project as described above with the plane to cut it into the mesh
Enter edit mode again and you can select these faces

Extrude them until they reach the desired height

Exit edit mode and add a new plane at exactly the height of the top of the round part

Scale it so it covers the whole object and use knife project again to cur a new loop on the mesh

You can now bridge these edges with F and start closing your geometry

Extrude the sides up. Make sure the surrounding vertex are vertically aligned with the remaining ones so they lign up

Done


My Textured object isn't showing up in the rendered view :S

Select your object,click Shift+Ctrl+A or ctrl+A and then select make duplicates real.

And then it will show up in renders:


Here are some solutions:

1:

  1) export your drawing in Python (numpy) as SVG file (say using MatPlotLib)
  2) import SVG file into Blender
  3) apply bevel to that

2:
In the following however we did it in a different way.

  1) We traced your image in Inkscape
  2) and exported as SVG file.
  3) In blender we just made it mesh and applied extrude.


Delta transforms are used when you have some incorrect location in your animation, like if your animated object is at wrong place you can just adjust the location in Delta Transform.
If you don't use Delta transform for such repairing, you have to edit a particular keyframe by overwriting them.
For example, if you have a plane on which a cube is floating from one place to another, you will obviously make a Location keyframe by pressing I. But the problem arises when you want the same animation for another. Dupicate the animated cube at another place, and play the animation, you can't see the another cube in animation, you can see only one cube. Did it disappear?
No, it is just on the location where the original cube is lying during the animation.It has the same Location path which the original cube has, as it is been duplicated!
To fix this, you should use Delta Transform, assume that you duplicated the cube on X axis, now the path should move parallel to the original cube i.e on Y axis, but not on same X axis, so change the location of X axis in Delta Transform, and you'll get the parallel movement of both cubes i.e without affecting your animation movement.
What you will do in absence of Delta Transform?
As I mentioned above, you have to overwrite each keyframe by changing its location again and again by pressing I and selecting Location keyframe, depending upon the number of keyframes you have created. But this makes it easy if you want to change the initial location of any axis and make it permanent till the last keyframe. It will have the same animation but on different axis, which you have changed in Delta Transform.

Also Refer this.


I can't make my material transparent in Blender 2.80

If you want to make the object transparent, their are 2 ways to do that:

Use transparent material (as you have already used), Add it to a mix shader whith the respective shader you want it to mix with and change the blend mode for the object to "Alpha blend".

Now, you use this method when you want to create an object with just transparency, that means without any reflection (that doesn't quite exists in real world). Every transparent material has refraction and if you want your material reflect like glass you can use the second method.

Using a glass shader. It won't directly reflect the changes right away, you need to enable "Screen space Refraction" for both the scene and the material you. Then you need to change the refractive index of the material to the one you wish for, or just keep it anything else than 0.

Scene settings to enable refraction


Is it possible to stay in Face Mode when making loop cuts?

You can in a way.. In the 3d view header, hold Shift and click on the Edge and Face icons.  The only drawback to this is that you will be in both Edge and Face selection mode.

Also, the quickest way to switch selection modes in Blender is to use CtrlTab, (you can also hold Shift while selecting here too to get multiple selection modes, to leave a mode, do the same thing).


moving camera with HDRI environment texture image

The issue is that the background HDRi is infinitely far away. Moving the camera parallel to a moving object will not create the illusion of movement, since the background will always be the same: there is no shift in perspective or elements that transform somehow.

A camera move like this

Will result in:

The HDRi is generated at a single point in space and is valid for only that point. So the only possible motion that would be realistic is rotation with no camera displacement. Any displacement would require different visual information for every position in the 3d world (like in Google Street view, where you have the 360 view for one point, translating the view will generate a completely new view)

In real life the motion in the background would be according to the distance from the camera to the object, objects that are close would appear to move at a faster speed than those very far away.

Possible solutions would be to use different layers of background planes that would move at different rates. In the far background the HDRi could even remain stationary without braking the illusion of movement.

As an alternative the moving element could move in a circular path around the camera and the camera just rotate following the moving object, the background would seem to move (when in reality the view is changing). This would create the illusion like it does in cartoons where the characters move in an ever looping background.

Alternatively the moving object could stay stationary and by animating the coordinates for the background, the background could rotate creating the illusion of movement.

In the World section of the Material nodes add a Texture Coordinate node and a Mapping node to control the placement of the Environment texture. By changing the rotation on the mapping node you can place the HDR where you need it.


Change orientation of object with respect to x-y rectilinear plane

You can rotate it.

then  apply rotation.

here is a tutorial on the basics of navigation


Render new stills and not the created video sequence

Sounds as though you have not set your render output back to still images.

If you already have multiple sequences you want to re-stitch, just be sure to re-adjust your start and end frames.


I think that the easiest solution would be to remove wireframe modifier from this mesh,duplicate and separate from it edges, that you want to be thicker and add the wireframe modifier to this new mesh.


How to check if an object has a uvmap with python?

In this case you'll need to check if the objects mesh data has any UV layers.
This works for vertex colors too.

import bpy
if bpy.context.object.data.uv_layers:
    print("We have UV's")
else:
    # if this runs from an operator, you may want to report an error instead.
    raise Exception("Missing UV's")

Where uv_layers can be replaced by vertex_colors, materials... or any other sequence you want to check is empty or not.

Note: In Python you could check: if len(bpy.context.object.data.uv_layers) > 0: however there is no need, since all sequences will evaluate to False when empty, infact, this is slower in some cases since counting all items can be avoided when we only need to check if its empty.


How to work with layers in 2.9x like in previous versions (2.7x)

The 2.7 Layers have been replaced by Collections, you should now use Collections. Basically one former Layer is now one Collection (and when you open an old Blender file Layers are automatically replaced by Collections).

You're confusing Layers with View Layers, which are completely different things, View Layers are useful for the Compositor (which is not the case in this tutorial).
With View Layers you're just changing the visibility settings of the current scene for later compositing purpose, so when you modify an object, it's the exact same object as the one of another View Layer.


without an blend file i have to guess, but it seems to me, that you missed some uv marks on one end of each of the objects. A cubic object needs to have 3 UV Marks on each of its ends. I made a picture to explain it futher:  If that does not solve the problem, please upload the blend file.
For getting the top and bottom face separated from the object, mark the howl face:


Is there a way to convert a constraint to a keyframe?

You could use Object > Animation > Bake action
(Or if you are in Pose mode, Pose > Animation > Bake action)

Bake action was added to the menu in Blender 2.62
(though it was previously available with Space> Search)
Unfortunately, there does not seem to be any documentation for this feature yet.


Unable to select the right frame on 2d Blender

from the Blender documentation:
Adjusting the View
The Timeline can be panned by holding MMB, then dragging the area left or right.
You can zoom the Timeline by using Ctrl-MMB, the mouse Wheel, or pressing NumpadMinus and NumpadPlus.
You can also use the scrollbars, located at the bottom or the right of the editor, to pan and zoom the view.
https://docs.blender.org/manual/en/latest/editors/timeline.html#:~:text=The%20Timeline%20can%20be%20panned,pan%20and%20zoom%20the%20view.


Add camera at random position through Python

You can spawn cameras in a circle around your object, at the altitude of your main camera. Then add a "Track to" constraint to make the camera face the target object. Finally, set the camera to active.

The constraint adds the benefit that it will follow the target object if it moves. If you dont have a target object you can create an empty in the scene.

How to randomly distribute points along a circle

import bpy
import math
import random
from mathutils import Vector

camera = bpy.data.objects['MainCamera']  # Make sure your first camera is named 'MainCamera'
target_object = bpy.data.objects['Cube']  # The camera will face this object. /!\ Naming

z = camera.location[2]
radius = Vector((camera.location[0], camera.location[1], 0)).length
angle = 2 * math.pi * random.random()

# Randomly place the camera on a circle around the object at the same height as the main camera
new_camera_pos = Vector((radius * math.cos(angle), radius * math.sin(angle), z))

bpy.ops.object.camera_add(enter_editmode=False, location=new_camera_pos)

# Add a new track to constraint and set it to track your object
track_to = bpy.context.object.constraints.new('TRACK_TO')
track_to.target = target_object
track_to.track_axis = 'TRACK_NEGATIVE_Z'
track_to.up_axis = 'UP_Y'

# Set the new camera as active
bpy.context.scene.camera = bpy.context.object

Result :


UI blocked until a mouse event when invoking modal operator from another operator

There are two fixes needed.

1. The modal() must return PASS_THROUGH instead of RUNNING_MODAL.
That allows Blender to process mouse events, however, fixes the problem only when invoked from property update function.

2. Using a timer instead of the counter.
I'm not clear why not just changing the counter limit to 3 does not work (that just requires another mouse event, i.e. need to move or click the mouse).
Nevertheless, the modal timer does fix the problem for invoking from other operator too.

Fixed code:

import bpy
from bpy.types import Operator

class TheModalOperator(Operator):
    bl_idname = "my.themodaloperator"
    bl_label = "TheModalOperator Operator"

    timer = None

    def invoke(self, context, event):
        print("TheModalOperator invoke")
        self.timer = context.window_manager.event_timer_add(0.1, context.window)
        context.window_manager.modal_handler_add(self)
        return {'RUNNING_MODAL'}

    def modal(self, context, event):
        print("TheModalOperator modal", event.type, event.value)
        if event.type == 'TIMER':
            print("---TheModalOperator modal finished")
            context.window_manager.event_timer_remove(self.timer)
            return {'FINISHED'}
        else:
            print("---TheModalOperator modal pass-through")
            return {'PASS_THROUGH'}

class MyOperator(Operator):
    """This is my operator"""
    bl_idname = "my.operator"
    bl_label = "My Operator"
    bl_options = {'REGISTER', 'UNDO'}

    def execute(self, context):
        print("MyOperator execute")
        self.report({'INFO'}, "MyOperator executed")
        bpy.ops.my.themodaloperator('INVOKE_DEFAULT')
        return {'FINISHED'}

# button on the toolshelf
class MyTestPanel(bpy.types.Panel):
    bl_idname = "mytestpanel"
    bl_category = "My Stuff"
    bl_label = "My Test Panel"
    bl_space_type = 'VIEW_3D'
    bl_region_type = 'TOOLS'
    bl_context = "objectmode"

    def draw(self, context):
        layout = self.layout
        col = layout.column(align=True)
        col.label(text="This blocks UI until a mouse event:")
        col.operator("my.operator", text="Run my operator")

def register():
    bpy.utils.register_module(__name__)

def unregister():
    bpy.utils.unregister_module(__name__)

if __name__ == "__main__":
    register()


Blender Bevel can not bevel a simple all-quad geometry!

I have found a solution. Turn out all I have to do is to flip normal of faces at the area with the problem.


Final result:

It's animated wind with changing strength.

Steps:

Create Cylinder with only 6 vertices and some small radius (for me it's 5cm).
Go to Edit Mode and add 3 Loop Cuts.
Select bottom Edge Loops and add them to Vertex Group.

Exit Edit Mode and add Soft Body physics to our cylinder.
First set the Goal Strength to 1 and as Vertex Group select the one we created before.
Add some wind to test it out.
Go to Soft Body Edges tab and Soft Body Self Collision and make changes accordingly to picture below.

That's it.

Final thoughts:

If you want it to look smooth, add Edge Creases 1 to top and bottom edge loop, select Shading Smooth, turn on Auto Smooth and add Subdivision Surface modifier.

Note. Settings may differ accordingly to edge loops count, pole length and such.
You will want to tweak then such values as Pull, Push and Bending.

Note 2. To control jiggling and bending strength change Soft Body Mass.

Blend file:


Do "no cached" simulations give the same result in multiple computers?

If all the properties of a physics item are the same, then yes. Physics will work the same way everytime, if there is no dynamic wind simulation in your scene or something. Its blender, not real life.


How to mix emission shaders to get gradient effect

Maybe try something like this. Since you're already using a globe (sphere), you can get a good gradient by mixing the Emission colors using a Fresnel as a mix factor:

If you want a "glassy" globe, you can mix the result with a Glass Shader, using the same Fresnel as a mix factor for that too:


Go to Dopesheet or Graph Editor, click on the little magnifier icon on the header bar, type in "Scale" in the input field, it will allow you to filter the channel by name. Then press A to select all channels (suppose you didn't have any customized name for other channel), X.

Even if you finally have some channels filtered that you do not want to delete, just try selecting or deselecting them with various selection tools, including single click. :)


Access Bone Coordinates using Python API

API docs:

  head - Location of head end of the bone relative to its parent

  head_local - Location of head end of the bone relative to armature

  tail - Location of tail end of the bone

  tail_local - Location of tail end of the bone relative to armature

Since Bone 1 has no parent, the vector between object origin and bone head is used.

Bone 2's head it at Bone 1's tail (Connected is ticked), thus Bone 2's head is at (0, 0, 0) because there is no distance between both.

Bone 2's tail is at (0, 1.732, 0) because it's given relative to its parent bone. Bone 1 and 2 face the very same direction, all it takes is the length of the bone to define its endpoint (Bone direction is on the Y-axis in Blender). Tail minus head is

(3, 3, 3) - (2, 2, 2) = (1, 1, 1)

and the length

sqrt(12 + 12 + 12) = ~1.732


You must have inner faces. Delete them, otherwise Blender doesn't know where to extend the loop cut.


Vertices movement keeping view perspective, but not actually moving the vertices

Disable the Snapping option (magnet icon).

Snapping makes your selection snap to the face.


Importing OBJ with MTL and Image not working properly

1. Check the obj file
In your case the obj is not exported correctly. Obj is a human readable file format it is easy to find the issue. You can check this by open up the file in a text editor of your choice (sublime, gedit...).
To check referenced materials go to these lines:

mtllib [external .mtl file name]
usemtl [material name]

In your case mtllib line is correct, but usemtl is missing.
# OBJ FILE
...
f 3103/18700/18700 3081/18701/18700 3119/18702/18700
f 279/18703/18703 3118/18704/18703 274/18705/18703
f 265/18706/18706 3101/18707/18706 278/18708/18706

# usemtl material name (reference to the .mtl file)
usemtl MyMaterialName

You can find the material name in the mtl file in this line: newmtl [material name]
# MTL FILE
newmtl MyMaterialName
Ka 1.000 1.000 1.000     # white
Kd 1.000 1.000 1.000     # white
Ks 0.000 0.000 0.000     # black (off)
map_Ka myMap.jpg         # ambient texture map
...

As last step check if the paths to the textures are correct:
map_Ka my-texture.jpg                           # points to texture in obj folder
map_Ka /home/user/images/my-texture.jpg         # absolute path on unix
map_Ka C:\\Users\\user\\images\\my-texture.jpg  # absolute path on windows

Make sure that the filenames of your textures are correct and there are no white spaces in the paths itself. Instead of pointing to the 'absolute path', you can also try Blenders Find Missing Files operator. For further information about all the possibilities of obj's read this wikipedia article.
2. Apply the material
If the material is not applied to the imported object you can select it here:

3. Enable textures in the viewport

If your textures are pink, see: Why are all the textures in my file pink?
To display the texture in the viewport see: How to show textures in the 3D View editor?


How to find all objects in the Camera's view with Python?

There are a few different ways to handle this, you could...

project into 2d space, then detect which objects are in the 2d frame.
calculate the camera bounds in 3d and detect which objects are inside it.

Here is some sample code that demonstrates the second method. It uses a set of planes (4 or 5 for orthographic cameras) and finds all objects that have any part of their bounding boxes within the planes:

Note, this isn't all that elegant, we could for example have a single function that intersects 2 sets of planes - one for the camera - another for the bound-box. However this is at least working and can give you some starting point - others may like to improve or post a method that uses projection.

def camera_as_planes(scene, obj):
    """
    Return planes in world-space which represent the camera view bounds.
    """
    from mathutils.geometry import normal

    camera = obj.data
    # normalize to ignore camera scale
    matrix = obj.matrix_world.normalized()
    frame = [matrix @ v for v in camera.view_frame(scene=scene)]
    origin = matrix.to_translation()

    planes = []
    from mathutils import Vector
    is_persp = (camera.type != 'ORTHO')
    for i in range(4):
        # find the 3rd point to define the planes direction
        if is_persp:
            frame_other = origin
        else:
            frame_other = frame[i] + matrix.col[2].xyz

        n = normal(frame_other, frame[i - 1], frame[i])
        d = -n.dot(frame_other)
        planes.append((n, d))

    if not is_persp:
        # add a 5th plane to ignore objects behind the view
        n = normal(frame[0], frame[1], frame[2])
        d = -n.dot(origin)
        planes.append((n, d))

    return planes

def side_of_plane(p, v):
    return p[0].dot(v) + p[1]

def is_segment_in_planes(p1, p2, planes):
    dp = p2 - p1

    p1_fac = 0.0
    p2_fac = 1.0

    for p in planes:
        div = dp.dot(p[0])
        if div != 0.0:
            t = -side_of_plane(p, p1)
            if div > 0.0:
                # clip p1 lower bounds
                if t >= div:
                    return False
                if t > 0.0:
                    fac = (t / div)
                    p1_fac = max(fac, p1_fac)
                    if p1_fac > p2_fac:
                        return False
            elif div < 0.0:
                # clip p2 upper bounds
                if t > 0.0:
                    return False
                if t > div:
                    fac = (t / div)
                    p2_fac = min(fac, p2_fac)
                    if p1_fac > p2_fac:
                        return False

    ## If we want the points
    # p1_clip = p1.lerp(p2, p1_fac)
    # p2_clip = p1.lerp(p2, p2_fac)
    return True

def point_in_object(obj, pt):
    xs = [v[0] for v in obj.bound_box]
    ys = [v[1] for v in obj.bound_box]
    zs = [v[2] for v in obj.bound_box]
    pt = obj.matrix_world.inverted() @ pt
    return (min(xs) <= pt.x <= max(xs) and
            min(ys) <= pt.y <= max(ys) and
            min(zs) <= pt.z <= max(zs))

def object_in_planes(obj, planes):
    from mathutils import Vector

    matrix = obj.matrix_world
    box = [matrix @ Vector(v) for v in obj.bound_box]
    for v in box:
        if all(side_of_plane(p, v) > 0.0 for p in planes):
            # one point was in all planes
            return True

    # possible one of our edges intersects
    edges = ((0, 1), (0, 3), (0, 4), (1, 2),
             (1, 5), (2, 3), (2, 6), (3, 7),
             (4, 5), (4, 7), (5, 6), (6, 7))
    if any(is_segment_in_planes(box[e[0]], box[e[1]], planes)
           for e in edges):
        return True

    return False

def objects_in_planes(objects, planes, origin):
    """
    Return all objects which are inside (even partially) all planes.
    """
    return [obj for obj in objects
            if point_in_object(obj, origin) or
               object_in_planes(obj, planes)]

def select_objects_in_camera():
    from bpy import context
    scene = context.scene
    origin = scene.camera.matrix_world.to_translation()
    planes = camera_as_planes(scene, scene.camera)
    objects_in_view = objects_in_planes(scene.objects, planes, origin)

    for obj in objects_in_view:
        obj.select_set(True)

if __name__ == "__main__":
    select_objects_in_camera()


How to apply material on an object that is under armature

To see your materials with proper texturing and shading change your viewport mode to either Texture or Material.


Since I figured out the answer, I'll answer my own question.

Blender's Video Sequence Editor is an awesome tool; however, it lacks some functionality like some effects the Compositor has.

For example, there is no Fast Gaussian Blur which is a lot faster than the normal Gaussian Blur with a minor margin of error (see this page for a comparison; it's not exactly the Blender's implementation, but it's pretty close). Furthermore, as far as my preferences go, I actually prefer the look of the Fast Gaussian to the normal Gaussian Blur.

So, since there's no direct way of using the compositing feature for the video strips, the question is, are there any workarounds?

Fortunately, I was able to find a working add-on for that, it's called Edit Strip With Compositor.

Note: There's another add-on mentioned in this thread called VSE to Compositor, but it doesn't work for Blender 2.76b.

So, let's get to it.

In order to install and enable it, follow these steps:

Firstly, download the latest version (it's the version 0.14 for Nov
20, 2015).
Next we need to extract the Python script from the archive.
Now, you can either install the script from the User Preferences or if you want to make it system-wide, you can copy it to the Blender's add-ons folder (in my system it's /usr/share/blender/2.76/scripts/addons). Note that this might require some administrative privileges.
Then you need to go to the User Preferences in Blender and activate the add-on.
If you want to enable it by default (on Blender's startup), don't forget to click the Save User Settings button.

After enabling it, you can start using the compositing functionality for the VSE. Here's a demo of it; however, he uses the other add-on mentioned above in the note, but they're not that different.

To apply the effects from the Compositor to the VSE strip, you need to follow these steps:

Select a video strip first (yes, unfortunately, you cannot apply the effects to the effects strips itself, but you can apply other effects on top of it).
Press N on your keyboard to open the Properties panel.
Scroll down in the Properties panel until you see the Edit strip with Compositor section.
Click the Set master scene button.
Check the Show options checkbox.
In the Compositing, choose the Compositing option from the drop-down list.
In the Editing Screen, choose the Video Editing option.
Optionally, you can enable the Add Viewer option.
Click the Create Comp from strip button on top of the section.
Click the Edit Composition button.
Now, this should look familiar. It should get you to the Blender's Compositor. Let's add the Blur effect. Open the Add menu by pressing Shift+A and select Filter → Blur from there.
Drag the Blur node over the connection path and once it becomes white, make a single click.
From the drop-down menu, select Fast Gaussian instead of Gaussian and choose your X and Y values for the blur size.

It should look something like this (except for the Backdrop which I have disabled):

Switch back to the Video Editor layout and voilà! You can notice that the blur effect is much more responsive now.
In order to animate the effects, you need to switch back to the Compositor and utilize the keyframing from there.

Related questions:

Can I add the output of the VSE as input to the node diagram? — Blender Stack Exchange
Blur video track in Video Editor? — Blender Stack Exchange


How to create this type of gradient background lighting?

To do this you can use a textured emission plane (you could simulate it with an out of focus mesh lamp too, but a plane will be less noisy).

Add a big plane behind your scene:

Give it a procedural gradient material:

The Object coordinates are centered around the object's Origin, so by default that's where the gradient will be centered.

To adjust the size and scale of the gradient, you can tweak the settings on the Mapping node

I've also made the plane brighter than it appears to the camera by using different emission shaders based on the Camera Ray output of the Light Path node, to avoid over exposing the background a lot.
Render

This way glossy floor plane will reflect the light from the plane, creating a neat effect.


How to properly project a pattern from a spotlight cone?

In the texture panel for the lamp, go to «Mapping», and change the coordinates from «Global», which seems to be the setting in your case, to «View». This should fix your problem. Works for both procedural and image textures.


Blender adds extra bones to ends of armature when I export as .fbx or .obj?

Okay, well actually the answer is really simple. I just found out that all you need to do is disable "Add leaf bones" in Export as .fbx > Armature.


Center array of objects in relation to another object

Press Space and write align objects into the search box that appears, then Enter

Then on the undo panel on the bottom left click on X and then Shift-click on Y

Finally to place exactly on top, enable snapping to vertex and move along the Z axis only (either by dragging the arrow or with G Z

The place where the mouse is when you hit G usually denotes the vertex you want to snap to the point the mouse is when you click to release. I say usually because depending on the camera angle blender might misunderstand your intentions.


Is it Possible to Dynamically Change Object Materals?

Dynamic paint is basically an automated painting system, you define a canvas and brush and together they generate an image (unless saved into vertex data such as vertex colour or group). This image can be used just like any other image within blender.

As shown in Miika's documentation you can use the generated image to adjust various texture settings within the blender internal materials. One example that appears to be omitted is the stencil setting (in the influence panel), this enables the texture layer to be a mask between higher and lower texture layers.

Within cycles you can use an image as input for the Fac value of a mix shader. As the final mix in a material you effectively choose between two different materials. You could also use it at any stage to mix any part of the node setup or input any specific value of a single node, like noise scale or emission strength.

Using nodes with the blender internal render you would input into a MixRGB node instead of a MixShader node to get a similar result.


When you say section, I assume you mean selection or group of objects (more than one object).
First you move your 3d Cursor from the origin (0,0,0) to where you want to center your transform.

Then select your objects, set "Transition Orientation" to be relative to "Cursor", than any rotation or scale or move will be relative to that cursor point.

(please if this is your answer, please mark it as ANSWER so I can build credits)


Unexpected result when using transform.resize API

So the operator seems to actually do what it is supposed to do, but the view lags behind.

Try the following call after transform.resize():

bpy.context.object.data.update()

That should trigger the update. I believe this update is incorrectly missing in the C-operator.


Everything rendered in black except sky background in cycles

Welcome!
In future questions, please try to provide as much detail as possible, optimally with screenshots to explain the question or issue.

Specifically here, it appears you added an overriding faulty material (Material.002) that replaces all other materials in your scene.

To fix the issue, remove it by going to the Scene Tab in the Properties Window, scrolling down to the Layer property group, then clicking the delete ("X") button in the Material box.


How to fill a hole between 2 circles quickly

Select the two circles and bridge them using  SPACE B R I


Is there a way to flat plane object affecting by proportional edit?

You can restrict the axis in which you scale to zero.

In this case, select all vertices. press:

S (to activate the scale tool)

Z (to restrict the scaling to the Z axis)

0 to bring all the vertices to the same plane)


You can use F3. This will list the commands, and even show you the shortcuts (if they exist)

The shortcut is Spacebar for older versions of blender (< 2.80).


This is because your timeline starts 885 and ends with 1500. The cloth sim starts at 1, which makes it jump.
Reset the beginning and end according to your timeline and then rewind once.
The rope will jump back where it started.


During Texture Paint, Shadows and Lights Create Distorted Colors

You can make changes to your viewport to create a flat color response in the same place you choose matcap or solid, etc.


How to use 2.8's default HDRi's in renders?

The default HDR images can be found in your installation folder:

[Windows] - C:\Program Files\Blender Foundation\Blender <version>\<version>\Datafiles\Studiolights\World\
[MacOS] - /Applications/Blender/Contents/Resources/<version>/Datafiles/Studiolights/World/
[Linux] - /opt/Blender <version>/<version>/Datafiles/Studiolights/World/

In the World section, set the surface type to Background and the Color to use Environment Texture. Then select the HDR image you would like to use:


EDIT: Selecting everything in edit mode and pressing Crtl-E then selecting Edge Split will do what you want.

If I understand the question correctly you want each triangle to be separate from the rest of the mesh (so no vertex is used by more than one triangle).

One way to do this is to select everything in edit mode (vertex select is easiest although not necessary), press Alt-E and choose individual faces. Immediately right click to cancel the operation and then press Ctrl-I to select everything but the extruded faces. Once you delete the selected vertices you should be left with a mesh made of individual triangles.


How to re-encode video without losing quality

The first option isn't a possibility. The second one, however, is. You should be able to de-multiplex the audio and video track and then re-package new audio with the video. FFMPEG is the program that I tend to use for this kind of task, but you'll need to be comfortable working from the command line. Depending on the OS you use, there may be easier tools for this.


Did you try using a wireframe node or modifier. You may be able to duplicate the torus and then apply the wireframe to the outer torus if you want it to look more 3D. But you can also try the wireframe node.


How to get a property value not in current frame?

You can evaluate fcurves for a property from python. Let's say you animated object Cube's location and want to get the Z value at frame 15:

# little utility function for searching fcurves
def find_fcurve(id_data, path, index=0):
    anim_data = id_data.animation_data
    for fcurve in anim_data.action.fcurves:
        if fcurve.data_path == path and fcurve.array_index == index:
            return fcurve

# index=2 for the Z curve. Just omit for single value properties.
fcurve = find_fcurve(bpy.data.objects["Cube"], "location", 2)

# Get the value at frame 15
print(fcurve.evaluate(15))

Note that evaluating fcurves may not be accurate in all circumstances, e.g. when you have additional constraints, physics simulation, etc. In that case the only real option may be to actually move to that frame, store the value and go back to the original frame.


How to assign a new material for each object using Python?

Run this with your objects selected:
import bpy

# I separated the creation of nodes to a function so it's easier
# to edit later if needed
def create_nodes(mat):
    mat.use_nodes = True
    nodes = mat.node_tree.nodes
    for every_node in nodes: # this removes all existing nodes
        nodes.remove(every_node)

    # creating Principled node and moving it:
    node = nodes.new('ShaderNodeBsdfPrincipled')
    node.location = (-190,100)

    # creating Output node and moving it:
    output_node = nodes.new('ShaderNodeOutputMaterial')
    output_node.location = (40,100)

    # creating the link between the two nodes:
    links = mat.node_tree.links
    link = links.new(node.outputs[0], output_node.inputs[0])

# this saves the currently active object so it can be restored later
active = bpy.context.object

# let's loop through all selected objects
for every_object in bpy.context.selected_objects:
    # I only want to work with objects capable of having a material
    if every_object.type in {'MESH','CURVE', 'SURFACE','META', 'FONT'}:
        if every_object.name not in bpy.data.materials:
        # if there is no material named after the object yet let's make one
            mat = bpy.data.materials.new(every_object.name)
            # and let's create the nodes for it
            create_nodes(mat)
        else:
            # if the material already exists let's just use it
            mat = bpy.data.materials.get(every_object.name)
        if len(every_object.material_slots) == 0: # if there are no material slots
            every_object.data.materials.append(mat)

        # The only thing left now is to assign the material to
        # all material slots. We probably do not want to loose the info
        # about how the object is divided into separate materials
        for every_slot in every_object.material_slots:
            every_slot.material = mat


What it looks like is happening is that both the label part of the bottle and  the “pink” part of the bottle are using the same material (node setup).

The label part has been unwrapped to map the test grid texture correctly but because the “pink” parts are also using the same material node set up but have not been UV mapped all the vertices of the pink part are at the X = 0, Y = 0 location (bottom left hand corner) of the UV square.

To check this, select the “pink” parts in the bottle then go to the UV editor, those vertices/faces will be selected, now hit the G key and move them around the UV square with the mouse and you should notice the “pink” parts change colour depending where they are on the colour grid.

To correct this you need to give the “pink” parts their own material and node setup.


How do you get a trace around your shadows?

You can pick out the edges of the shadows by using the compositor as follows :

The key is to enable the Shadow pass in the Render Layers (right-hand-side of the screenshot). In addition, enable the Object Index pass to give some control over which objects in the scene will have shadow edges highlighted - otherwise all objects will show highlights on all shadows, even where they are shadowing their own faces (presumably not desired).

This works by taking the Shadow pass (which just shows the shadows) and passes this through a Dilate/Erode filter to slightly shrink back the shadows, followed by a Subtract node to get the difference between the original shadows and the ‘shrunk’ shadows - this will pick out the edges. The ID Mask filters out only those objects with Object Index of '1' (which in this case is just the 'floor') and this is combined with the shadow edges using a Multiply maths node so as to only highlight shadows on the ‘floor’. The result is used to mix between the original render and a solid colour (red) which highlights the edges.

EDIT : To show all shadows (including 'self' shadows where an objects blocks its own light) you can use a simpler setup, not requiring the object ID :

Note that the 'background' also counts as a 'shadow' - hence the line on the outer edge of the floor plane.


Subdivision surface only works well with quads, and from the looks of it your model isn't constructed in the most clean way. There are a few things you can try short of remodelling the mesh:

Remove doubles
Recalculate Normals
Add a bevel modifier, which might be able to clean up the edges for you so you can apply a subsurface modifier.
Add 2 edge loops around the perimeter of the object so that subdivision works better.


Welcome to Blender Stack Exchange!

Cycles has a Bevel node (found in the add menu under Input>Bevel) that does exactly what you want. Simply plug the output of the Bevel node into the normal input on your shader/material and that's it. The example below shows a basic setup. The radius can be increased to make the corners look even more rounded.

Blender also has a Bevel modifier that will add the geometry very quickly as well. Depending on your model it may be an option too.


Is it possible for Blender to interface with other software and hardware?

There's quite a few ways to do this, depending on your hardware. If you're using an Arduino that has wireless communication with your sensors, you can plug the Arduino to a PC running blender via USB and send data over serial communication.

A blender python script can access the serial data and use it to do whatever you want it to do (for instance control a character rig). Here's some more sample code on how to use the python serial (pyserial) library.

That's just one way related to one type of controller. If you specify more about what you're aiming for and what tools you're going to use, people will be able to provide you with better, more specific answers.


Multiple Linked Objects with unique Materials / Group Materials override

(step 1 from gandalf3's answer)

Set the material datablock to Object, then right click on the drop down and select Copy to selected This is important, if you skip this step 2 will not work.

Select all the objects you want to have the same material, with the active object having the material to be copied to all the others selected. Press CtrlL, and select Materials. It will now link the materials to the Object and not the Data.


How to make glass clear at overlapping point

What you are seeing corresponds with the way light behaves in the real world.
When you are dealing with filters you are subtracting colors from the light that goes through the filter.
If you are using primary colors (Red, Green and Blue), any filter with one of the primary colors will effectively cancel the other two out.
In other words: a Red filter will only transmit Red light, and will absorb Green and Blue.
Likewise a Green filter will subtract the Red and Blue out of white light and the result will be just green.
A Blue filter will only let Blue through, and absorb the other two colors.

If you then add a second filter then you will have no light left to go through.
Red light has no green content to go through, green light has no blue content to go trough, and blue has no red.

If you must use filters (such as glass), use Yellow, Magenta and Cyan instead.

(image source: http://hyperphysics.phy-astr.gsu.edu/hbase/vision/subcol.html)
Suggested reading to learn about additive or subtractive color mixing:
https://en.wikipedia.org/wiki/Additive_color
http://www.physics.wisc.edu/ingersollmuseum/exhibits/optics&color/subcolormix


Parenting an object to a bone not working

The correct procedure to parent the empty to the bone is:

Select the empty

Shift select the armature

Go to pose mode

Select the bone you need as parent

Press Ctrl P and choose "bone" option.


Make object in glass material not look like its underwater?

If you're using a Glass Shader, try bringing the IOR closer to 1, but not all the way to 1 because that will cause you to loose the dome reflections.
Default IOR - 1.45 - Cube is bent

IOR at 1.0 - too low - Cube is normal but glass shape (reflections and refraction) is completely lost.

IOR at 1.10 - More realistic - Glass is still visible without bending the cube noticeably. However, notice the background is refracted differently as well - you will have to find an appropriate balance that works for your project.


Scripting the modeling of a plane world map

I think the easiest way to do what you want is to find a map in SVG format that has the elements you need.

Import it into Blender.

(If you don't have the Imprt as SGV menu available you need to enable the addon in the UserPreferences CtrlU)

The map will be a series of curves that you can then extrude at will

using the controls for extrusion on the curve tab.

The naming for the curves is inherited from the naming of the curves in the original SVG file. You might want to edit that in Inkscape or Illustrator before bringing those over to Blender, or maybe you are lucky enough to find a SVG map that has the naming already done!


Selecting a different object hides all keyframes in timeline?

This is a feature. You only see keyframes for the selected object in the timeline. If you want to see all your keyframes, I would use the Dope Sheet.

The arrow icon only shows the key frame from the selected object.
The ghost icon shows keyframes form hidden objects.
The life saver :P(I think that the official name?) shows broken drivers.


How can I print just the name of the camera and not the full structure?

import bpy
context = bpy.context
scene = context.scene
active_camera = scene.camera

if active_camera:
    print(active_camera.name)
else:
    print("No Active Camera Selected")


Can Python Operator Presets be shared between Operators?

Leveraging the preset system

A while back when doing some addon maintenance, changed the preset code for the add curve extra objects addon for 2.7x.  In particular add curve spirals.

Can leverage off the existing preset code to emulate the 'PRESET' option.  This way can choose what goes in the preset, what folder to save in, the menu and the operator to execute the preset.

Code snippets from /2.79/scripts/addons/add_curve_extra_objects/add_curve_spirals.py

Firstly there is an add preset base base class to inherit

from bl_operators.presets import AddPresetBase

The operator that creates the presets, notice can set the subdir here, defines in the script,  and what properties to save in the preset.  It is also associated with a menu.

class CURVE_EXTRAS_OT_spirals_presets(AddPresetBase, Operator):
    bl_idname = "curve_extras.spiral_presets"
    bl_label = "Spirals"
    bl_description = "Spirals Presets"
    preset_menu = "OBJECT_MT_spiral_curve_presets"
    preset_subdir = "curve_extras/curve.spirals"

    preset_defines = [
            "op = bpy.context.active_operator",
            ]
    preset_values = [
            "op.spiral_type",
            "op.curve_type",
            "op.spiral_direction",
            "op.turns",
            "op.steps",
            "op.radius",
            "op.dif_z",
            "op.dif_radius",
            "op.B_force",
            "op.inner_radius",
            "op.dif_inner_radius",
            "op.cycles",
            "op.curves_number",
            "op.touch",
            ]

its associated menu class. The bpy.types.Menu class has a 'draw_preset(..)` class method that draws the menu from the files in the presets folder. The default preset execute operator, which runs the code within the preset file setting the props is assigned as the operator of each menu item.

class OBJECT_MT_spiral_curve_presets(Menu):
    '''Presets for curve.spiral'''
    bl_label = "Spiral Curve Presets"
    bl_idname = "OBJECT_MT_spiral_curve_presets"
    preset_subdir = "curve_extras/curve.spirals"
    preset_operator = "script.execute_preset"

    draw = bpy.types.Menu.draw_preset

In the draw method of the operator that the presets are for

def draw(self, context):
    layout = self.layout
    col = layout.column_flow(align=True)

    col.label("Presets:")

    row = col.row(align=True)
    row.menu("OBJECT_MT_spiral_curve_presets",
             text=bpy.types.OBJECT_MT_spiral_curve_presets.bl_label)
    row.operator("curve_extras.spiral_presets", text="", icon='ZOOMIN')
    op = row.operator("curve_extras.spiral_presets", text="", icon='ZOOMOUT')
    op.remove_active = True

With this set up  presets are being saved to or loaded  from the defined folder. This way if your operators A and B have similar (same) structure can draw their presets from the same folder.

Also Look for code in addon prefs in __init__.py to convert from the old preset locations to new presets.


How would I go about making this fuselage?

Here is a topology proposition, I hope this helps:


Weird blown out colours in renders eevee

I've had this issue as well, and it seems like it's an issue with using bloom and volumetrics at the same time.
Try clamping the bloom with a value of 20, see if that fixes it. (of course, you'll only know when rendering large batches of frames again)


Batch Rename (add-on) - inverted sequential numbering

Regex is a powerful (albeit not Turing complete) language, in which it's hard to say what is possible and what isn't: Adding Numbers with Regex.
However, in this case I find it fair to say the task can't be done using regex alone: the way search & replace functionality in regex mode works, is it goes through objects one by one, and applies the regex formula to each name separately. Therefore the task can't be done, not because of limitations of regex, but the limitations of the context available to it. Imagine writing a Python function, which gets an old name and is supposed to return a new name:
def rename(old_name):
    new_name = "?"
    return new_name

If you can't access variables outside of this function (and regex can't), then even though you're using a Turing complete language (Python), you can't come up with a solution, because while you can extract a number from the old_name, you don't know a total number of names, so you're unable to do new_number = total_number - old_number. If you hard-coded the total_number to the function, assuming that there's always 100 objects for example, then it would work (as long as the assumption holds true). Likewise, if your object numbering, instead of integers, uses float numbers in range [0, 1], e.g. instead of Cube.001, Cube.002, Cube.003, Cube.004, Cube.005,  it uses Cube.0.0, Cube.0.25, Cube.0.50, Cube.0.75, Cube.1.0, then again, you can make a Python function, not knowing the total number of objects, that still flips their names. Think of a shader that takes a texture and flips it, and what kind of data or coordinate system that shader requires in order to work. Search & Replace just doesn't supply Regex with that (and if it did, it would still be very unpractical to create such complex regex formulas).
The Python script solution can be as simple as:
import bpy

cubes = [o for o in bpy.data.objects if o.name.startswith('Cube.')]
for i, c in enumerate(sorted(cubes, key = lambda c: int(c.name.split('.')[-1]), reverse = True)):
    newname = f'Cube.{i:03}'
    if newname in bpy.data.objects:
        bpy.data.objects[newname].name = f'Renaming...{newname}'
    c.name = newname

However, this script has some problems:

It doesn't touch an object without a number in its name. So if you start with a Cube, and then duplicate it 9 times, it will only rename duplicates (giving the last duplicate number 000), while the first duplicate will become the last (009). You need to manually rename the base Cube to Cube.000 in order to fix that.
It assumes every object with its name starting with Cube. is the object to be renamed. Even if it's name is Cube.Big without a number.
It will make the numbers have 3 digits, even if you rename more than a thousand objects. So the numbering will be: 001, 002, [...] 099, 100, 101, [...], 998, 999, 1000, 1001, [...].
It assumes there's a dot immediately before a number. If there's any object like Cube.Big005, the script will fail trying to convert Big005 to an integer, and nothing will be renamed.
It's case sensitive, so it will rename Cube.001 but not cube.001.

Here's a more general script, dealing with those issues:
import bpy

name = 'sphere'  # what you search for, exactly. Searching for 'cube' will *not* find 'cube2' or 'cubes' or 'mycube' objects
case_sensitive = False  # Don't ignore letter case
ignore_numberless = False  # Don't treat an object with proper name but without a number as first in sequence
new_first_numberless = False  # Keep the convention of not giving the number to the first object, after reversing
minimum_digits = 3  # use at least that many digits in object numbering (the script will use more if necessary)

# ------------------------------------

objs = bpy.data.objects

_name = name if case_sensitive else name.lower()

to_be_renamed = []
for o in objs:
    name2 = o.name if case_sensitive else o.name.lower()
    last_part = name2.split('.')[-1]
    if not last_part.isdigit():
        if not ignore_numberless and _name == name2:
            to_be_renamed.append((-1, o))
        continue

    if _name == name2[:-len(last_part)-1]:
        to_be_renamed.append((int(last_part), o))

to_be_renamed.sort(key = lambda x: x[0], reverse = True)

number_len = max(minimum_digits, len(str(len(to_be_renamed)-1)))
format_str = '{}.{:0' + str(number_len) + '}'

for i, (sortkey, object) in enumerate(to_be_renamed):
    if i == 0 and new_first_numberless:
        newname = name
    else:
        newname = format_str.format(name, i)
    if newname in objs:
        objs[newname].name = f'Renaming...{newname}'
    object.name = newname

There are settings in one place for easier script usage.
If an object's name is the name searched for, without a number, it's number is considered as -1 (so its order is before 000)
Every number has to be at the end, immediately after a dot. An object like Cube001 will be ignored (but the script will not fail)
If the last element is 35000, the first will be 00001 (consistent length of numbers)


Add new object mesh addon template

Quick little addon slapped together using text editor > templates > python > Addon Add Object template.

Adds two circles, bridges the edge loops.
If ngon fill is chosen, splits one fill edge, dissolves the rest.

Test addon.

bl_info = {
    "name": "New 2D Ring",
    "author": "batFINGER",
    "version": (1, 0),
    "blender": (2, 80, 0),
    "location": "View3D > Add > Mesh > New 2D Ring",
    "description": "Adds a 2D ring (circle with hole)",
    "warning": "",
    "wiki_url": "",
    "category": "Add Mesh",
}
import bpy
import bmesh

from bpy_extras.object_utils import AddObjectHelper, object_data_add

from bpy.props import (
        IntProperty,
        BoolProperty,
        FloatProperty,
)

class MESH_OT_primitive_ring_add(AddObjectHelper, bpy.types.Operator):
    """Add a 2D filled ring mesh"""
    bl_idname = "mesh.primitive_ring_add"
    bl_label = "Add 2D Filled Ring"
    bl_options = {'REGISTER', 'UNDO'}

    inner_radius: FloatProperty(
        name="Inner Radius",
        description="Inner Radius",
        min=0,
        default=1.0,
    )
    outer_radius: FloatProperty(
        name="Outer Radius",
        description="Outer Radius",
        min=0,
        default=2.0,
    )
    segments: IntProperty(
        name="Segments",
        description="Number of Segments",
        min=3,
        default=8,
    )
    ngon_fill: BoolProperty(
        name="Ngon Fill",
        description="Fill with ngon",
    )

    def draw(self, context):
        '''Generic Draw'''
        layout = self.layout
        # annnotated on this class
        for prop in self.__class__.__annotations__.keys():
            layout.prop(self, prop)
        # annotated on AddObjectHelper
        for prop in AddObjectHelper.__annotations__.keys():
            layout.prop(self, prop)

    def execute(self, context):

        me = bpy.data.meshes.new("CircleHole")

        bm = bmesh.new()
        bmesh.ops.create_circle(bm, radius=self.inner_radius, segments=self.segments)
        bmesh.ops.create_circle(bm, radius=self.outer_radius, segments=self.segments)

        ret = bmesh.ops.bridge_loops(bm, edges=bm.edges)
        if self.ngon_fill:
            edges = ret['edges']
            e = edges.pop()
            bmesh.ops.split_edges(bm, edges=[e])
            bmesh.ops.dissolve_edges(bm,
                                     edges=edges)
        bm.to_mesh(me)

        object_data_add(context, me, operator=self)

        return {'FINISHED'}

def menu_func(self, context):
    self.layout.operator(MESH_OT_primitive_ring_add.bl_idname, icon='MESH_CUBE')

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

    bpy.types.VIEW3D_MT_mesh_add.append(menu_func)

def unregister():
    bpy.utils.unregister_class(MESH_OT_primitive_ring_add)
    bpy.types.VIEW3D_MT_mesh_add.remove(menu_func)

if __name__ == "__main__":
    register()

    # test call
    #bpy.ops.mesh.primitive_ring_add()

Add Cone Primitive

Though I would add that the functionality is very similar to add cone primitive, with no fill and no height (can scale totally to zero in z and apply)


How to save an image in uv editor even when closing blender?

Setup your image(s) however you would like before modifying anything else in a new clean .blend file.
Press Ctrl+U to save the modified start-up file as the new default, and the images (along with any other changes, materials, objects, etc.) will be present going forward.
If you decide to go back to the default configuration, then you can Load Factory Settings
Documentation is here


Relation between Fresnel IOR and Layerweight blend?

By comparing visual results from both LayerWeight's Fresnel and Fresnel Node on a test sphere I concluded that these settings give similar results:

Blend:  0.00  0.10  0.50  0.70  0.80  0.90  0.95  0.98  1.00
  IOR:  1.00  1.10  1.70  3.30  5.10  10.0  20.0  50.0  1000

The Y scale is logarithmic

Confirmed by Brecht (thanks) the conversion formula is:

IOR = 1/(1 - Blend)
Blend = 1 - 1/IOR

Layer Weight node:

Layer Weight Facing output mixes the two shaders based of angle of incidence.
The Fresnel output mixes them based on fresnel formula (Dielectric fresnel weight), which is a function of angle of incidence. The exact math is here: Wiki
The Blend slider adds additional blending between the two shaders: at 0 it will be green and at 1 it will be red.

On the other hand the Fresnel node allows for proper IOR input:

I use Fresnel node when dealing with glass-like materials, where the light goes through - where it bends at the interface. I can set proper IOR for the interface this way.

I use Layer Weight node when dealing with reflectivity, it allows for better control over the transition on the surface (how smooth it is) and over how the materials are mixed (with that blend slider). This suits artistic approach better when you are eye-balling stuff.


Override print method.

Been investigating a number of ways to do this.  Possibly the simplest is to  override the print in your scripts.  Below is designed to from somewhere import print and writes all print non keyword arguments to open consoles in same screen.

import bpy
from bpy import context

import builtins as __builtin__

def console_print(*args, **kwargs):
    for a in context.screen.areas:
        if a.type == 'CONSOLE':
            c = {}
            c['area'] = a
            c['space_data'] = a.spaces.active
            c['region'] = a.regions[-1]
            c['window'] = context.window
            c['screen'] = context.screen
            s = " ".join([str(arg) for arg in args])
            for line in s.split("\n"):
                bpy.ops.console.scrollback_append(c, text=line)

def print(*args, **kwargs):
    """Console print() function."""

    console_print(*args, **kwargs) # to py consoles
    __builtin__.print(*args, **kwargs) # to system console

print("print me to console")
print("and me\n and me", "and me\nI'm:", print)

My attempts at redirecting stdio have failed and often lock up a console. Will get back to this later with better links, but there is a lot of console code to fiddle around with ...  console_python.py bl_operators/console.py and the mathviz addon code.

EDIT: See Dubplicate Question Answer on handling stdio redirecting.


Function to crop an image:

def crop_image(orig_img, cropped_min_x, cropped_max_x, cropped_min_y, cropped_max_y):
    '''Crops an image object of type <class 'bpy.types.Image'>.  For example, for a 10x10 image,
    if you put cropped_min_x = 2 and cropped_max_x = 6,
    you would get back a cropped image with width 4, and
    pixels ranging from the 2 to 5 in the x-coordinate

    Note: here y increasing as you down the image.  So,
    if cropped_min_x and cropped_min_y are both zero,
    you'll get the top-left of the image (as in GIMP).

    Returns: An image of type  <class 'bpy.types.Image'>
    '''

    num_channels=orig_img.channels
    #calculate cropped image size
    cropped_size_x = cropped_max_x - cropped_min_x
    cropped_size_y = cropped_max_y - cropped_min_y
    #original image size
    orig_size_x = orig_img.size[0]
    orig_size_y = orig_img.size[1]

    cropped_img = bpy.data.images.new(name="cropped_img", width=cropped_size_x, height=cropped_size_y)

    print("Exctracting image fragment, this could take a while...")

    #loop through each row of the cropped image grabbing the appropriate pixels from original
    #the reason for the strange limits is because of the
    #order that Blender puts pixels into a 1-D array.
    current_cropped_row = 0
    for yy in range(orig_size_y - cropped_max_y, orig_size_y - cropped_min_y):
        #the index we start at for copying this row of pixels from the original image
        orig_start_index = (cropped_min_x + yy*orig_size_x) * num_channels
        #and to know where to stop we add the amount of pixels we must copy
        orig_end_index = orig_start_index + (cropped_size_x * num_channels)
        #the index we start at for the cropped image
        cropped_start_index = (current_cropped_row * cropped_size_x) * num_channels
        cropped_end_index = cropped_start_index + (cropped_size_x * num_channels)

        #copy over pixels
        cropped_img.pixels[cropped_start_index : cropped_end_index] =
                                orig_img.pixels[orig_start_index : orig_end_index]

        #move to the next row before restarting loop
        current_cropped_row += 1

    return cropped_img

How this script works

The image class stores the pixel information as a one-dimensional array, and save 4 channels for RGBA (even if you load a .jpg).  For example, on this 2x2 image, I've labelled the order that the pixels appear:

and so if you have an image object named my_image, then my_image.pixels will be a 1-D array: [R value for pixel 0, G value for 0, B value for 0, A value for 0, R value for pixel 1, etc.].

Example usage

#crop image to 100x100 square
cropped_min_x = 300
cropped_max_x = 400
cropped_min_y = 300
cropped_max_y = 400
input_image_filepath='/home/garrett/Desktop/kjEh.jpg'

orig_img = bpy.data.images.load(input_image_filepath)

cropped_img = crop_image(orig_img, cropped_min_x, cropped_max_x, cropped_min_y, cropped_max_y)

print("Saving new image...")
cropped_img.filepath_raw = "/home/garrett/Desktop/myImage6.png"
cropped_img.file_format = 'PNG'
cropped_img.save()
print("Finished saving")


How to get elbow IK constraints to work properly?

If you set the bicept Ik chain to one, it works pretty well, but generally this kind of rig is constructed with only one IK: the forearm pointing to the arm IK, then you can use the elbow IK bone as the pole target of the single IK constraint.
Don't forget to set the right pole angle (in my example 180 degrees).


How to save a rendered image that I have added a vignette to in Compositing?

Actually there is a way to save the composited image without re-rendering:

select the viewer node
in the N panel (properties region) under "Node" there is a "Save This Image" button.


You can't control the smaller grid-spacing values, these use an alpha value which is automatically calculated based on zoom level and the lightness of the grid-color (in orthographic mode).

Blender is calculating the color automatically and isn't giving you control.


Are samples correlated to the output resolution?

Short answer: No.

Light is sampled per pixel. So if you render with i.e. 200 Samples, Blender takes 200 Samples of each pixel. It doesn't matter if there are 5 oder 219928 pixels.


Enabling extrusion sharpens selected object

The video shows the typical (and not incorrect) bulging that happens when you have a closed tubular object with subdivision surface enabled. To avoid that, delete the face at the end so that the mesh is open on the side where you extrude it. If you want to leave it closed, add a loopcut to sharpen / flatten the bulge. It also helps with the fixed direction so you don't have to hit Z to unlock it. The face normal indicates the direction of the extrude, without it it is not locked at the beginning of the extrusion.


Why isn't my smoke simulation interacting with other objects properly?

You have a normal collision above the Smoke collision, and it seems to be messing things up. I removed both and re-added just the smoke collision, and the simulation appeared to work flawlessly, no smoke came outside of the walls.

Before:

After:

I can replicate this issue by adding a standard collision to the object, then adding the smoke collision. If you reverse the order it works perfectly fine. This appears to be some sort of collision priority conflict or bug. As long as you add the Smoke Collision first it should work as expected.