Rigify doesn't work that way. In order to use it correctly, here are the steps :

Add Rigify rig from the add menu, which creates a "metarig". The "metarig" is a simplified rig without any interesting feature, his goal is only to be a temporary rig used for placing correctly the full-featured rig. He should not be used as a deforming rig.
In edit mode, place the metarig's bones correctly on your model. (You can find a bone positioning guide here) Do not delete nor add bones in the metarig.
When it's done, go in the Metarig's Armature Tab and click the "Generate Rig" button under the "Rigify buttons" Pannel.

This will generate a full featured rig according to how you placed the metarig's bones.

Now if you want, you can delete all the unwanted parts (and the "metarig").
It's time to bind your rig to your object. First, in the Armature Tab, you need to switch to the layer containing the deform bones, which should be that one :

All the bones in that layer should have a "DEF" prefix, meaning they are "DEForming" bones. If not, try the other two next layers.
Then you select your objects to bind, then your armature, and you hit Ctrl P → Set Parent to Armature With Automatic Weights.

This should be enough to get your face rigged and skinned. It may not be perfect tho, so I encourage you to do some deforming tests, as well as some facial expressions in order to quickly identify deforming issues and being able to fix them via weight paint mode.

I hope I helped.


Is there a way to do this "splitscreen" partially-rendered effect?

You may easily achieve this effect using Compositing Nodes. I'll show you how to do it both for a still image and animation.

STILL IMAGE

First select the Slot 1 in the UV Editor window and render your scene using a Full render (F12).

Then change the slot to Slot 2, but this time render the active viewport using the Open GL render. Remove all the materials from your model. Check the Only Render checkbox, located in a Display panel of the Properties Shelf (N) and click the camera icon located at the bottom bar of the 3D window.

Save both images to your computer.

Now go to the Node Editor, press the Compositing nodes button and check the Use Nodes and Backdrop checkboxes. Then set up the nodes as pictured below. First add two Image nodes (Shift+A-->Input-->Image) and open both images you've rendered. Next create a simple b&w texture in gimp (with the same resolution as rendered images).

Use it as a Factor for mixing two renders (add a Color node [Shift+A-->Color-->Mix] and plug the image to its Fac socket. Add a Viewer node (Shift+A-->Output-->Viewer) to see the compositing result.

ANIMATION

You may do it in similar way. Go to Render header and set up things as you like in Dimensions panel. In the Output panel choose the path to the folder you want your rendered frames to be saved (in my case I created a new folder and named it 'full render'). Change the file format to JPEG.

Now choose the Render Animation (Ctrl+F12).

When finished with rendering, change the path to another folder (I created a second one and called it 'openGL').

Press the OpenGL render animation button (the one next to OpenGL render button).

You have now two rendered image sequences in two folders. Set up the nodes as pictured below. Instead of adding Image nodes, add two Image Sequence ones (Shift+A-->Input-->Image Sequence). Load the rendered pictures for each of them.

With setup like this go once again to the Output panel, click on the file directory browser and create a new folder for the final animation. Change the file format to for example AVI Raw. Render your scene once again using F12 button.


Fog in Blender: Through World node or Object Node?

There are many ways to do fog in blender, and each one has different outcomes, the question is not what is better, but which one works for the desired outcome and or the computing power you have access to.

Using volumetrics (volume scattering) will yield the most realistic looking fog.

There are two ways to do it:

1- Adding volume scatter to the world  volume will mean that the whole scene is surrounded by suspended particles (like smoke or haze).

2- Creating a mesh that is used as a Volumetric Domain, instead of surrounding the scene but just the areas that you need the volume scattering. Again, this is done by adding a volume scatter node to the volume of the mesh.

The main difference is that when you add volume scattering to the world you will never see the end of the fog (well, the end will be the clipping distance of the camera), whereas using a volumetric domain the fog is contained within a certain shape and sometimes the end is noticeable and unrealistic.

The problems with of using the world are that you cannot combine volumes and textures. Once you add volume to the world it occludes any color or sky or HDR imagery. Also it requires more computing time and resources. Another limitation is that it won't work when using a "sun" lamp, but will work wiht point, spot or area lights.

Having a volumetric domain requires less resources, since the area to calculate can be smaller, and will allow you to use textures in the world. If you want to use HDR or sky textures, this is the only way to do volumetrics. WIth a volumetric domain you can use a "sun" lamp.

It is important to understand that whenever you add volume scatter in any form, there will be more noise in the scene, a clean image will require more samples to render. Using volume scatter will also result in more "fireflies" (bright pixels), to minimize that please read through the many posts on the subject that exist in this site.

The lights in the scene, will also seem darker, so the energy values will need to increase. Another thing to keep in mind, is that every light on the scene will show in the atmosphere affecting the overall contrast of the image. Hiding light sources will require extra effort.

A different way to do fog is by faking it with a Mist pass. A mist pass doesn't require much computing power and can be combined over the rendered image in the compositor.

The mist pass works by making objects in the distance seem brighter and less defined. The mist pass has control for start, end and density.

The mist pass is useful to create more realistic scenes without much effort by recreating the atmospheric haze that we experience in the real world, where objects far away seem to have less contrast.

The downside of the mist pass is that there is no interaction with the mist and the lights, so it will not create volumetric shadows or "god rays".


How to draw a PostGIS Polygon with holes into Blender using Python

Polygons can't have holes without a pathway between the hole and the perimeter. ( see: BMesh polygons with holes )

It is perhaps more convenient to use a 2D Curve. They can represent a face with holes easily using a Spline type called 'POLY'. For Example:

Then later Convert to a Polygon based Mesh and let Blender take care of how it arranges the tessellation.

here a script you could use:

import bpy

# weight
w = 1

def MakeFilledPolyLine(objname, curvename, cLists):
    curvedata = bpy.data.curves.new(name=curvename, type='CURVE')
    curvedata.dimensions = '2D'

    odata = bpy.data.objects.new(objname, curvedata)
    odata.location = (0,0,0) # object origin
    bpy.context.scene.objects.link(odata)

    for cList in cLists:
        polyline = curvedata.splines.new('POLY')
        polyline.points.add(len(cList)-1)
        for num in range(len(cList)):
            polyline.points[num].co = cList[num][0], cList[num][1], 0, w

        polyline.order_u = len(polyline.points)-1
        polyline.use_endpoint_u = True
        polyline.use_cyclic_u = True

# using the cyclic switch auto closes the loops, notice i've
# dropped the last coordinates.
vectors = [
    [[0,0], [10,0], [10,10], [0,10]],
    [[1,1], [1,2], [2,2], [2,1]]
]
MakeFilledPolyLine("NameOfMyCurveObject", "NameOfMyCurve", vectors)

The upside of this is it would handle polygons with no holes, or with any number of holes using the same code.

If you've come this far, I expect it will be a trivial matter to convert the strings of that PostGIS file into the appropriately formatted nested lists for the MakeFilledPolyLine function.


Can You Convert Hair Made From a Mesh Into a Particle System

I would imagine if you bake maps from the solid hair, you can use those same masks for effects. I haven't done this before but that's where I'd start, especially baking a world position map.


At first I thought "well, one way would be to use something like a "texture.jpg" name for that texture, and simply change the file that is named like that... that would do the trick, somehow. Other than that, you could probably need to script the change, for all the nodes to load the same texture. I can't think of other ways, atm"...

but then it came to my mind another trick, that could work better for you... here it is: use node groups!

you can set up a simple "image texture node" as a group, by itself.

It sounds absurd, to make a group of just one node, but it isn't: because you can reuse groups on every material you choose, and link it differently to other nodes.

Just select it as Add => Group => "yourGroupName" in the node composition area, and by default it has the same inputs/outputs as the base Texture Image node...

And, when you edit the group (on any node where it's used) you can change the texture, in a single node that's reused:

and, thus, reach your goal:


Perfectly matching concentric shell walls?

You can join the two meshes in object mode.  Then in edit mode you you can select the two edge and perform a Bridge Edge Loop.  That will also serve as a check to make sure you have the same number of vertices.

If you want two separate objects. You could start with one hemisphere, [solidify modifier], apply the modifier,  The select the inner portion and menu [separate] to form two separate meshes.


Update parameter on bpy.context.active_pose_bone changed

Getter (Setter) on a property

Small example, added active_pose_bone_length property to the scene.  Reports the length of the active pose bone or zero if none.  (AFAIK Blender bones cannot have zero length)

This way you are computing your property based on the selection, rather than checking selection change.

import bpy
from bpy.props import FloatProperty
from bpy.types import Scene

def get(self):
    pb = bpy.context.active_pose_bone
    return pb.length if pb else 0

Scene.active_pose_bone_length = FloatProperty(get=get)

alternatively could make this a context property

import bpy

def get(self):
    pb = self.active_pose_bone
    return pb.length if pb else 0

bpy.types.Context.active_pose_bone_length = property(get)


Particle systems with lamps as the object emitted

It is nothing about particle system actually.

As you see, there are some non-mesh type of objects cannot be rendered, such as lamps/bones/cameras/lattices/empties, etc, since they don't have any solid face to render. However, you can still see their effects around the scene as ususal.

Anyway, other options here would be:

For BI:

Instead of lamp, use mesh object with Emit shading enabled;
Group lamp with mesh object, set mesh material type to Halo, emit the whole group as particle unit.

For Cycles:

Use mesh object as particle unit, use Emission shader for material setting. (recommended)


Can you add a spine bone to an existing (deformed and animated) character rig without repainting weights and having to redo old animations

Does this work for adding bones along the chain such as adding a new
spine bone or can you only add to the end of the chain such as adding
fingers at the end of an arm?

What makes bones into a chain is parenting.  So you can make a bone and then change the parenting of other bones so that, now, that new bone is sandwiched in.
An alternative is to use the subdivide operation on a bone, which splits an existing bone in two, and leaves any children parented to the new bone created (which is parented to the original bone that was subdivided.)
There are a lot of different ways to make bones, and a lot of different ways to edit them.  Anything you can make in an armature, you can edit in-- after all, editing a single bone armature is how you make complicated ones!

And once done do you have to repaint the skinning and redo all old
animations?

In general, yes.  Any new bones you make won't deform any mesh until they have weights.  Any new bones you make won't be animated until you animate them.
There are plenty of exceptions.  A bone that changes parenting can affect the mesh indirectly, even without weights.  A bone that is part of an IK chain will be animated by the IK target, even if it doesn't have any animation data itself.

If this is not possible by default is there a plugin that makes it
possible?

What you're asking about is extraordinarily general.  Are there plugins that weight bones?  Sure-- so does out-of-the-box autoweights!  Are there plugins that generate animation?  Sure-- so does out-of-the-box rigid body physics!  But you probably have some particular kind of animation and weighting in mind.  There is no single way to animate or weight new bones, so there is no single, press-one-button plugin to animate and weight new bones.


How to add bumpiness to a car/roller coaster motion?

You could do this by adding the noise modifier to you animation.

1) Open the property’s tab in the graph editor and select the animation you want to add the bumpiness to
2) Go the modifiers tab and select noise

You can read more about the noise modifier and other fcurve modifiers here

Note: Don’t add the modifier to the f-curve that controls the direction your object is going. For this particular problem add keyframes to your Y and Z locations of the car (assuming that car is moving along the X direction of the path) and then add noise to f-curves for Y and Z locations.


You define bl_label inside the operator's code as a variable so after that you can reference it as any other variable inside the operator. It would be self.bl_label:

import bpy

class SimpleOperator(bpy.types.Operator):
    """Tooltip"""
    bl_idname = "object.simple_operator"
    bl_label = "Simple Object Operator"

    @classmethod
    def poll(cls, context):
        return True

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

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

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

if __name__ == "__main__":
    register()

    # test call
    bpy.ops.object.simple_operator()


Mesh not showing in game engine after lattice deform

Lattice is not supported By the BGE.

Unsupported objects (curve, particle ,lattice ....) will not be converted to game objects when starting the game session. This means they will not present within the game.

Be aware children of unsupported objects will not appear as the parent is not present in the scene. I think this is your current situation.

I suggest to remove the lattice completely. At least unparent the cube from it.


Rotating Around 3D Cursor (Object vs Edit Mode confusion)

If the subdivision modifier is working, and you toggle the editing view in the modifier panel, the mesh displayed in 3D view will not be the one you actually manipulate.


Convert mouse movement into rotation value (not in bge)

Woo hoo! Figured it out. I was almost there. The problem was that I was simply using event.mouse_x and event.mouse_y (which returned x and y values for the entire screen, not just whatever 3D View I happened to be in). Change this to event.mouse_region_x and event.mouse_region_y and the angle data will be generated based on the size of the 3D View window you happen to be in and rotation responds perfectly! There's a bunch of other little calculations required to make it prettier (object angle offset, inverting values etc...), but those are pretty straight forward. The hardest stuff is done.


Blender 2.8, API, select_set( action = "SELECT") TypeError

The answer is:

bpy.context.object.select_set( state = True, view_layer = None)

That's the right syntax in Blender 2.8 Beta to the date, apparently the WIKI is not updated


How to make glass reflect illuminated objects but glass itself doesn't reflect light source?

Try going into ray visibility and fiddling with the settings


Is it possible to make the default scene fill two monitors at startup?

You can use the menu Window -> Duplicate Window(Ctrl-Alt-W) - to add a second Blender window, then put one one each monitor. The windows will by "synchronized" as in that changes will be reflected in real time. Ctrl-U will now work to save the setup.


More than 5 mix/principled shaders turns material pink in material preview but not in rendered preview? No missing textures

So I changed all the Principled BSDF shaders to simple Diffuse BSDF shaders, like Craig suggested and it worked! Don't know the exact reason why it worked but I guess the Principled BSDF is too complex for putting a bunch of them in a single material. Anyway thanks for the help again.


How to do support loops to combine smooth, curved surface with hard edge

This topology works:

Same with 3 edge loops:

if you need a sharp horizontal edge:


Import a csv animation path using animation nodes

Here are three solutions, with similar concept but a bit different on handling animation loop:

NOTE: Here, I read the raw CSV file located at the same filepath to the blend file by using Text File Reader node. You can also copy and paste the CSV content to the internal Text Editor, then read it by Text Block Reader node.


How do i get an array of objects with increasing rotations to stay on a specific axis?

I dont think you can do this with the array modifier or a different modifier. So I made this code:

import bpy
import math

Count = 10
distance  = [0, 2, 0]

rotationX = 10                              # in degrees
radiansX = rotationX *(math.pi / 180)       # in radians

rotationY = 0
radiansY = rotationY *(math.pi / 180)

rotationZ = 0
radiansZ = rotationZ *(math.pi / 180)

startRotationX = 0
startRotationY = 0
startRotationZ = 0

for x in range (0, Count - 1):
    bpy.ops.object.duplicate_move(OBJECT_OT_duplicate={"linked":False, "mode":'TRANSLATION'}, TRANSFORM_OT_translate={"value":(distance[0], distance[1], distance[2]), "constraint_axis":(False, False, False), "constraint_orientation":'GLOBAL', "mirror":False, "proportional":'DISABLED', "proportional_edit_falloff":'SMOOTH', "proportional_size":1, "snap":False, "snap_target":'CLOSEST', "snap_point":(0, 0, 0), "snap_align":False, "snap_normal":(0, 0, 0), "gpencil_strokes":False, "texture_space":False, "remove_on_cancel":False, "release_confirm":False})

    if x == 0:
        startRotationX = bpy.context.object.rotation_euler[0]
        startRotationY = bpy.context.object.rotation_euler[1]
        startRotationZ = bpy.context.object.rotation_euler[2]

    bpy.context.object.rotation_euler[0] = startRotationX + (radiansX * (x + 1))
    bpy.context.object.rotation_euler[1] = startRotationY + (radiansY * (x + 1))
    bpy.context.object.rotation_euler[2] = startRotationZ + (radiansZ * (x + 1))

I hope this works!


Error while trying to use Curve Modifier - Cannot apply modifier for this object type

You need to convert the text to a Mesh object.

Object -> Convert to -> Mesh from Curve/Meta/Surf/Text


Use filmic and output mask with absolute color values

Ok I found a way to do it. Instead of doing an alpha over with the ID Mask between black and white, I use black and a value node. The value node is set to a high value, high enough for the filmic color space transformation to map it to the maximum value 255/#FFFFFF in the output.

This has two problems though, 1) it depends on the "alpha over"-node to accept higher values than usually available (this should be ok, since internal representation is floating point), 2) I just took some high value instead of basing it on what value is mapped to white.


interrupted by signal 11: SIGSEGV when running bpy module from Flask app

Haven't done much with flask, will offer this up as a suggested workaround.

Try loading the mainfile outside of @route decorated methods.

Putting the load operator in any route method also caused a segfault for me (Ubuntu 18, blender 2.90, python 3.82)  Suspect a threading issue.

The following works as expected,

# batTOOLS...........

from flask import Flask
import bpy

app = Flask(__name__)
bpy.ops.wm.open_mainfile(filepath="/home/batfinger/Documents/blender/tests/BISECTO.blend")

@app.route('/')
def hello_world():
    lines = []
    for o in bpy.data.objects:
        lines.append(f"{o.name}</br>")

    return "\n".join(lines)


Blender displays the wrong X-relosution for JPEGs,

OK, found a solution.
Basically, blender is missing an EXIF reader. Luckily, python has the modules. We just need to install it.
Below is a basic method to install a module
https://b3d.interplanety.org/en/how-to-install-required-packages-to-the-blender-python-with-pip/
But did not work for me. Perhaps, its because of the office firewall or network....
So I installed the module using the wheel file, .whl, with the function below with blender (Not a powershell)
import subprocess
import sys
import os

# path to python.exe
python_exe = os.path.join(sys.prefix, 'bin', 'python.exe')

# install required packages
subprocess.call([python_exe, "-m", "pip", "install", "C:/LOCATION AND FILENAME.whl"])

Don't need to install pip because since 2.8 its already installed.
I am using the ExifRead module. Arbitrary selection. The code below gets me the dpi I want.
import exifread

# Open image file for reading (binary mode)
f = open('C:/Users/csemeon/Desktop/Fabric/RED 1200dpi.jpg', 'rb')

# Return Exif tags
tags = exifread.process_file(f)

for tag in tags.keys():
    if tag in ('Image XResolution'):
        #print ('Key: %s, value %s' % (tag, tags[tag]))
        dpitest =  str(tags['Image XResolution'])
        dpi = float(dpitest)

Had to use a two steps to convert the value to float (or int). Because the Dpi is a tag and doesn't convert directly to float.
Hope it helps someone.


Importing external python module into bge

Use pip to install it! In the blender polder you can navigate to 2.78/bin/python(.exe)
Run that and you have a typical python shell from which you can install pip the usual way (ie getpip.py). Then you can install whatever modules you like.
I have used this method to intall lxml for bge use. And I have used PIL inside blender (installed with a different method though)

When exporting, all python libraries are automatically copied.

But as monster said, first investigate the bge.texture module. You can merge images, set individual pixels etc. The only thing you can't do is resize them (as fas as I know)


One way to get this would be:

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

This should look like:

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

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

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


I use B to select 2 vertices but on 2 different sides, and i right click to drag and it only moves one

You can use C in edit mode to select vertices in a circular way or use B to select in a box way. Once you select the vertices you want then you can hit G to grab/translate the vertices you want as shown below:


Why does the object move when clearing its parent?

As stated in my comment, I'm pretty sure you can fix this by using Alt+P and selecting "Clear and keep transformation". This way it should clear the parent and keep its location.

What happens in your example is that when you remove the parent like that, your object jumps back to the original location/rotation it was in before it was parented to something.


How to overcome flat look in Texture painting in 2.8

I figured It out all you need to do is to make sure that image is plugged into color input of material and then just turn down opacity for texture paint (image) Or just turn off all overlays.

And Voila!


Continuous and coherent texture mapping on deforming objects

If you want the texture to deform with the surface, you will have to use UV mapping. Every polygon corner gets assigned a location in UV (2D) space and textures use this information to map to surface. This mapping is not hard to create (see UV textures/ing tutorials), but it can be unique for every mesh, so the key is ensuring this UV mapping is the same in all your meshes.

There is a way to have only 1 mesh and to use all the others for creating mesh shape keys. You need Absolute shape keys that animate in a sequence. You do this by joining 2 meshes with Join as Shapes option. This way you can convert multiple meshes with the same vertex order into a single mesh with deformation animation.

In python with both selected and the target for animation active:

bpy.ops.object.join_shapes()

You might need to override the context.


Rigify finger controls rotation not moving correctly

When rigging with rigify, most of the time bone roll will be correct, however on occasion if you have to adjust the metarig a lot, the rolls can get distorted. This is particularly common on the fingers as they have many segments and often require a bit of adjustment depending on the exact position that the hand is modeled. I find is always worth checking bone rolls in the hand when using rigify.

Rolls can be adjusted with ctrl-R. For rigify fingers you should have the bone's Z axis pointing in the direction you want the finger to curl when you scale the control bone down. There is no automatic way of setting this as it depends on the mesh.

Re-running generate from the metarig will update the generated rig provided you have not renamed it.


I know I'm 6 months late for this but I would just like to share an answer since I was also currently doing Andrew's tutorial for the Anvil and I also encountered this problem. I think the issue here is that after deleting the half of the model, you basically declared to Blender that your particular model is open and empty inside and that is why whenever you apply the Mirror modifier, you end up with a hollow model since the base model was hollow in the first place.
The solution I found for this is after deleting the half of the anvil, select all the vertices that were left and press F to create a new face.

Then do the rest with the Boolean modifier and the model should be solid inside. And also make sure that the Boolean modifier is on top of the Mirror modifier to see the cut on both sides. Hope this helps :)


Scalp's hair is NOT affected by "wind" forcefield effector but cube primitive IS

Aha, very simple solution.

The forcefield must exist on the same layer as the particle system under the object data tab to be affected.

Use shift+left click to add multiple layers to the wind forcefield.
See picture attached.


Is it possible to select multiple edge-loops simultaneously?

There is another way,which is selection by similarity.

The loops you are trying to select are similar in length for instance.

Select the loop and press Shift + G , Length.

You may want to decrease the threshold if your want a more precise result.


Making a pill capsule filled with powder

Transparency is very difficult to get right, especially when there's something inside of the transparent object. https://blend-exchange.com/b/6V8odJJx Here is a link to my own recreation of your image. I used a Voronoi texture that's run through a colour ramp to get the right look of the inside of the pill. Doesn't need to be too detailed unless you zoom really close to the object. Then I duplicated the shape in object mode and extruded it to have a bit of thickness. I then added a new material and changed the transmission, alpha, roughness, and specular settings until I got something that looked decent. Make sure to change the IOR as well, it's automatically set to glass.
Here's an example of my attempt, it's by no means perfect but its a good jumping off point.


Cycles, animate the color on part of an object

Create a new material for the part that you want to change and assign it to the section of the mesh you want to affect.

(see : Add different materials to different parts of a mesh?)

Then the color change can be done in different ways.

Then over over the color of the material, add a keyframe. Change to a different frame, change the color and add another keyframe.

A different way would be to use an RGB mix node to contol the color of your object and animate the factor value:

Or Create two different shaders with the qualities you are after, add a mix shader node and animate the way they mix.


This is a common problem, the more complex is the mesh, the armature, the weights, the more the animation gets slow.

Youn can use various strategies to check your animations:
1 - hide (maybe using layers, even separating some vertices of the mesh) all vertices you can
2 - building a fake simpler mesh, which will be very fast if done using bone parents instead of weighted vertices: i.e. it's very common to build a characetr using the face as it is and using simple cubes or cyliders for torso, arms, legs, parenting each whole object to its corrispondent bone: in this way you avoid lots of calculations.
3 - making a superfast OpenGL render of the scene, which can be analyzed always running in perfect realtime.

Maybe others users know some more strategies.


"Dll load failed" error when trying to install Animation Nodes in 2.81b and 2.8

You need to install vc_redist.x64.exe which is a package for Microsoft Visual Studio that Animation Nodes requires to work.  Once you have installed this, you will need to restart your computer and then attempt to enable the add-on again.


Is this for an animation or game?

For an animation you can use compositing to transition between several different versions of your model, each with different scales of detail.

For a game you'll probably need to fetch higher resolution blocks of game data as needed, similarly to how Google Earth fetches higher res textures as you zoom in.

Either way it probably won't be easy, but the result could be impressive if executed well.


Is there a start deactivated for particles as well as rigidbodies?

Not that I would be aware of. What I would do would be to set the particle simulation's starting frame to the frame when your object gets hit.


How to remove artifacts from an ambient occlusion bake

Well the issue is in overlapping faces.

First, the solidify modifier. When you press bake witch face will project: internal or external? In the place on your screenshot - external.

But even worse, if you disable the solidify modifier you will get same problems, becouse you have overlapping faces in UV-layout also.

This gif shows the overlapping faces:


How do you save, or make check points using the blender game engine?

==> https://drive.google.com/open?id=1ErvI2CB8UUhBa_-L1dVRnI_3jPoX93rF   <==

above is simple system example of save 'n load system (saves to text in your computer).
it's pretty simple when near sensor is triggered it's automatically saving if you want it to be manual add keyboard sensor and if you want to make limited amount of saves, add an property sensor(which decrease with each save) and so on and so forth . logic is pretty basic . Feel free to study and use the example blend file.


Blender 2.8 - eevee Silver/Chrome material

Activate "Screen Space Reflections" in the render tab. And may be you want to use my chnages to your shader. "Specular"s value "0.5" is more physically correct. I also cranked up the IOR value to 1.8, which is the IOR of silver (you will find huge tables
with IOR values for all kinds of materials online).

But the main reason, why the ring is dull grey in the "final" render and shiny in the viewport is: Your world material has the same dull grey color...:)
Even the most shiny silver ring will reflect only the dark when there is no light.
See attachment (the screenshot still has the wrong IOR...sorry)


Python script that sets target vertex group for object constraint

It was not entirely clear how much of the data structures have already been constructed (vertex groups, constraints, etc).  You will find techniques for most of it in http://web.purplefrog.com/~thoth/blender/python-cookbook/copy-location-from-vertex-group.html which I include here.  Just discard the actions for work that you have already accomplished

import bpy

def index_of_closest_vertex(location, obj):

    verts = obj.data.vertices
    choice = 0
    wLoc = obj.matrix_world * verts[choice].co
    d = (location - wLoc).magnitude
    for i in range(1, len(verts)):
        vLoc = verts[i].co
        wLoc = obj.matrix_world * vLoc
        d2 = (location - wLoc).magnitude
        #print( [ location, wLoc, choice, d, d2])
        if d2<d:
            choice = i
            d = d2
    return choice

def create_per_vertex_vg(obj):

    nVerts = len(obj.data.vertices)
    for i in range(nVerts):
        vgname = "vg %d"%i
        vg = obj.vertex_groups.get(vgname)
        if vg is None:
            vg = obj.vertex_groups.new(vgname)
            vg.add([i], 1.0, 'REPLACE')
        else:

            vg.add([i], 1.0, 'REPLACE')
            vg.remove([ j for j in range(nVerts) if j!=i ] )
    #

def find_or_create_clc(obj):
    for cns in obj.constraints:
        if cns.type=="COPY_LOCATION":
            return cns
    return obj.constraints.new('COPY_LOCATION')

def vg_for_i(obj, vertIdx):
    for vg in obj.vertex_groups:
        try:
            if (vg.weight(vertIdx)>0):
                return vg
        except:
            pass
    return None

def set_constraint(src, tgt):
    """ put a copy_location constraint on tgt referencing the vertex group for the closest vertex"""

    i = index_of_closest_vertex(tgt.location, src)

    cns = find_or_create_clc(tgt)
    cns.target = src
    cns.subtarget = vg_for_i(src, i).name

#

def mission1():

    o1 = bpy.data.objects['Cube']
    create_per_vertex_vg(o1)

    knob = bpy.data.objects['Sphere']

    set_constraint(o1, knob)

#
#
#

mission1()


Error generate rig in (rigify) after removing tongue and bottom teeth bone

Found it!
So, you create "faces.super_face" in rigify buttons tab.
delete all the face bone except the one that you accidentally delete. In my case, those are tongue bones and bottom teeth bone. Then, you parent them back to face bone, reposition them and click "generate rig" in object mode. It successfully generate the rig.
Notes for others, never delete any bones from the face rig. if you don't want to use them just deactivate "deform" in bones properties. *credits goes to R-800 for the info!!
Shout out and thanks to R-800 for helping me!!


You can't.
Twixtor, and other apps that do slow motion, use a technology called Optical Flow that estimates motion vectors to create interpolation.
There is no way, that I'm aware of, to do optical flow in blender.
Blender has no temporal interpolation for video other than repeat or drop frames, or cross-fade (frame-blend) between two frames.
None of those will give you the smoothness of extreme slow motion.
For an open source alternative to do optical flow re-timing try
http://slowmovideo.granjow.net/
or
https://linuxhint.com/slowmovideo-slow-motion-video-marker/


Well thanks to brasshat answer, I played around a bit and found one way to achieve this, there may be a better way but this certainly gives decent results.

I used the bridge edge loops tool.


How to move only a vertex at a time of an empty object with an image sequence attached

If you want your reference image to align with the camera, setup the camera to use a background image.

In 2.80 Background Image options have been added to the camera, this allows you to keep the image aligned with the camera view even if you move the camera.

To ensure the image fills the camera view you need to set the render resultion to match the aspect ratio of the reference image.


Baked normal map partially inside out (Blender/Unity)

So apparently a thing that can happen is that the unwrap algorithm puts down some islands mirrored. A way to see this is to view the model with the grid texture and look for flipped letters/numbers.

Hope that helps someone out there!


Imported image as plane does not have accurate colors

I believe you are on the right track...

Switch from Filmic to standard but not on the image or material like you did.

I actually didn't realize you could do it image by image like that but I think you need to switch it on the actual world scene.

Look under the "Scene" tab where you switch from EEVEE to Cycles... at the bottom look for "Color Management" and "View Transform" then switch that from Filmic to Standard.


in python I want to select faces in edit mode by the index of for loop

import bpy
import bmesh

# Get the active mesh
obj = bpy.context.edit_object
me = obj.data

# Get a BMesh representation
bm = bmesh.from_edit_mesh(me)

print(len(bm.faces))

bm.faces[0].select=True

for f in bm.faces:
    print("face")

With the Default Cube that prints

6
face
face
face
face
face
face

to the system console.


Mirror modifier, but not quite. Is there a phantom modifier?

We'll start with this mesh (I extruded a face so it isn't symmetric):

Go to the object tab and add the object to a group:

Now, create an empty. Go to the object tab and set the duplication to the group you just created:

Now, to mirror the object, simply make the x-scale of the empty negative. It will become flipped. Since Blender is smart enough, the normals will be alright.

Now, you have a flipped copy of the object that will change if you change the original. You can repeat this if you need more copies, and you can position them as you wish:


It sounds like you have Manipulate origins (⎇ Alt,) enabled in 3D view > Header:

This setting makes it so transforms will only affect the origins of objects, rather than the objects themselves. This is only really very useful when you have multiple objects/bones selected.

Also see What does the button next to the Pivot Point button do?


Speed control works on small video, not on large

For whatever reason, the preview and the rendered short clips were played in realtime (1x), but when I ran the whole rendering, the result was sped up (10x) as I wanted -- so effectively, my problem was that I simply didn't commit to the full rendering job. I had hoped that a short render would confirm in minutes what the full, lengthy job would produce.

During my playing around with it, I tried @3pointedit's suggestion to break the clip into frames, which also worked. For other users new to Blender, what I did was first open the Properties window, ensure PNG was selected (at the bottom of this image), set my output path (I left it at the default of /tmp\), then clicked Render (top of the image):

Then from a new project, in the Video Sequence Editor, I clicked Add -> Image, browsed to my temp directory, and selected all images. As a new user, the Blender UI is very unintuitive, and with tens of thousands of frames, I can't drag to select them all -- you have to hit a (NOT CTRL+ a) to select all of them. Then they're loaded together as a single strip which can be manipulated like a video.


The clothing simply isn’t large enough to fit around your model. Either increase the garment’s size or decrease the ‘Outer’ in the collision mesh’s Collision settings.


You could use two scenes two render two cameras (see Different camera settings for different render layers?)

However, this is a feature that is currently being developed, so you could try one of the development versions.


Break end of cloth mesh into particles in an infinite looping animation

You can put a particle system after the cloth one and then use Explode modifier to break the mesh.

If you input a vertex weight map to protect some faces it will randomly break the unprotected ones and create effect like this:


Blender 2.79 finds modules, but 2.80 does not

Apparently there was an API change and should have Googled harder. The answer is here Blender 2.8 can no longer import module from Textblock


Using bos fbx Error: "no module named UMIO"

From the error message it seems that you are using the BOS FBX importer with Blender 2.77.

The newest version of this add-on (at the time of this post) relies on precompiled libraries for Python 3.4 (see scripts/addons/io_scene_bos_fbx/win64bit/python34/UMIO.pyd) but Blender 2.77 ships with Python 3.5, so it won't be able to find the UMIO module.

Name                          Version
--------------------------------------------------
Blender 2.76                  Python 3.4
Blender 2.77                  Python 3.5
Blender 2.78                  Python 3.5

BOS FBX Importer 2015-07-04   Python 3.4

You need to either keep around a copy of Blender 2.76 to use this add-on with or ask the author to provide a newer version for Python 3.5.


i found  that if you do a copy location and change the Head/Tail value and then add a track to the other side


map 2d coordinates to 1d index using blender drivers

I don't know if there is a solution to grease pencil related but in a shader node you could use a formular like
Index = Row * GridWith + Column
to get an index from a 2d Point.


I think that you first need to make some armature corrections :

Rotate your IK controller in Edit mode to make it more easy to handle.
Deactivate its Deform option as it is not supposed to influence the mesh.
Unparent it, it is not supposed to be child of the hand, it is supposed to be parented with offset to the root bone.
Select the hand and make it the child of the controller.
You may also need to move the Pole Target, and also deactivate Deform.

Now when you select the mesh in Weight Paint mode, you can see that the chest bone influences the arms while it is not supposed to, so use the brush to correct that.


Click and drag the handle in the upper right hand corner of the timeline down to split the view, then set the new timeline to a 3D view by clicking on the editor selection menu in the left side of the header:

See How to close view windows? and the wiki for more information.


AttributeError when adding keyframes in draw function

The draw function is for UI only (defining layout and visibility of properties, sliders etc). It's called multiple times per second, sometimes 20 or more times, as you move your mouse around

You can't change bpy.data (including keyframes) from inside draw, it is blocked by design. You probably don't want to repeatedly execute that code anyway. A standard approach is to Run it from Text Editor with or without an enclosing function.

If this represents the first and second line of the the dataset, and the next lines are all formatted like line 2.

dataset.txt

GYROSCOPE X (°/s);GYROSCOPE Y (°/s);GYROSCOPE Z (°/s);Time since start in ms ;YYYY-MO-DD HH-MI-SS_SSS
9.08;-1.04;-9.51;20;2015-07-03 14:17:34:206

code

import csv
import bpy

def some_function(fp):

    obj = bpy.data.objects['Camera']

    results = []
    with open(fp, newline='') as inputfile:
        row_gen = csv.reader(inputfile)
        next(row_gen) # skip first line.

        for row in row_gen:
            results.append(row[0].split(';'))

    # start making frames at frame 1
    for idx, frame_data in enumerate(results, 1):
        xRot, yRot, zRot = frame_data[:3]
        print(xRot, yRot, zRot)
        obj.rotation_euler[0] += float(xRot)
        obj.rotation_euler[1] += float(yRot)
        obj.rotation_euler[2] += float(zRot)
        obj.keyframe_insert(data_path="rotation_euler", frame=idx, index=-1)

some_function(fp='/home/zeffii/Desktop/zen/dataset.txt')

The -1 at the end indicates that the keyframe is to be added after the other existing keyframes.

For info about paths; whether to use back or forward slashes, see:

  https://blender.stackexchange.com/tags/path/info

Adding this for completeness, because it differs across Operating Systems.


Make object follow path and collide with other object

I explored two ways of constraining a physics object to a curve:
1: A physics constraint connected to your rigid body is set to only travel and orient in a straight line.  Animation Nodes and a python script moves and aligns that constraint to your curve every frame.
AN makes a mesh out of the curve then moves and aligns that physics constraint to the curve every frame.  A python script is needed to work around an apparent bug to get the physics object location.
It's a complicated setup.  It works ok on a roller coaster type track.  It may work better with tuning.  It may work on yours.  If you share your blend file, I'll share mine.
2: Simpler, no plugins: A hidden pipe track and ball(s) connected to your object by physics constraints.
Loft your curve with a bevel so that it's a tube mesh curve, with enough detail and room so that the ball travel in it smoothly.  (make a copy of the curve so you can go back to it if needed)
Convert to mesh and a physics object.  The track is passive, mesh collision. no friction, no bounciness.
Connect a constraint and fix it to your object, perhaps below the pipe track.  your object's location should be constrained to the track, If you want your object to turn with the track, make two balls stick them in the pipe and connect them with a fixed physics constraint and connect your physics object.  You can hide this pipe track and balls in your render.  It's more complicated to have the angle matched to the curve in 3 axis.  Perhaps have a rectangle block traveling down a square tube?  Tested briefly, may work for some cases and with tuning, but a ball works so much smoother.
I have not tested or explored this completely but it should give you some ideas.
Edit: Tested 4 connected spheres forming a flat rectangle car, sliding in a square track, seems to travel smoothly and keep orientation.
Edit2: Which is similar to giving a rectangle a collision margin, It makes the corners of the "Box" collision object smooth.  So that's easier to make and edit.


How to set camera horizontal and vertical FOV

I have found that the dimension along which the FOV applies depends on the image aspect ratio.
Let us define the aspect ratio as the ratio of width / height, such that an aspect ratio larger than 1 means that we are in a landscape configuration.

if aspect ratio > 1.0
  FOV is along width.
else
  FOV is along height.

You can verify this by setting your image dimensions to, for example, X:2000; Y:1000, and Camera lens FOV:90°. Switch to ortho views and check the representation of the camera against the grid.
See the following screenshots:

With that in mind, you can use specific FOV values.
Remember that values going into and out of trigonometric functions have to be converted to and from radians.
I use vfov to mean the required vertical FOV and hfov to mean horizontal FOV.

A. To specify the vertical FOV:

If your image is portrait or square:

just set the wanted value in the FOV field.

If your image is landscape:

Use FOV = 2 * atan((0.5 * width) / (0.5 * height / tan(vfov/2)))

B. To specify the horizontal FOV:

If your image is landscape or square :

just set the wanted value in the FOV field.

If your image is portrait:

Use FOV = 2 * atan((0.5 * height) / (0.5 * width / tan(hfov/2)))

(Note that you can simplify a bit if you compute the aspect ratio first)

Explanation:

We first find the focal length (in pixels) according to the required FOV, for example:

f = 0.5 * height / tan(vfov/2)
We use this to find the FOV along the other dimension.

hfov = 2 * atan((0.5 * width) / f)
thus,

hfov = 2 * atan((0.5 * width) / (0.5 * height / tan(vfov/2)))

Example:

We need a 90° vertical FOV on a landscape image of 2000×1000px.

vfov in radians = 90° * pi / 180° = 1.5707… rad.
hfov in radians = 2 * atan((0.5 * 2000) / (0.5 * 1000 / tan(1.5707/2))) = 2.2142… rad.
hfov in degrees = 2.2142 * 180° / pi = 126.87°.

Result:


1: In the UV/image Editor select the vertices/faces thet need to be moved and use the Keyboard shortcut key Y to separate them.

2: Move them to their new position.

3 To join them back to the UV's...... select each pair of vertices to be joined then open the Weld/Align menu with the W key and choose Weld.


Texture problem: model only renders in black and white

Found the issue.  In the material pane under preview one of the settings was wrong.  I changed "color" to  image texture and then was allowed to select the texture image.  That corrected the color rendering issue.


Using cycles textures with an image you can take advantage of the true displace feature available with the experimental feature set

What this does is using a musgrave as factor for mixing both color and displacement textures


Direct Path for Desktop without Usernames for Blender 2.79

The script below retrieves the home directory and generates the path to the desktop. If the project has been saved before, it adds the name as prefix.

import bpy
import os
from pathlib import Path
from sys import platform

home_dir = str(Path.home())

if platform == 'linux' or platform == 'win32' or platform == 'darwin':
    desktop_dir = os.path.join(home_dir, 'Desktop')
else:
    raise RuntimeError("OS not supported")

if bpy.data.is_saved:
    filename = os.path.splitext(bpy.path.basename(bpy.data.filepath))[0]
    output = os.path.join(desktop_dir, filename)
else:
    # Project file hasn't been saved before, therefore no filename is available
    output = desktop_dir

bpy.context.scene.render.filepath = output

If you want the prefix to be the same as the active object in the scene:

import bpy
import os
from pathlib import Path
from sys import platform

home_dir = str(Path.home())

if platform == 'linux' or platform == 'win32' or platform == 'darwin':
    desktop_dir = os.path.join(home_dir, 'Desktop')
else:
    raise RuntimeError("OS not supported")

if bpy.app.version < (2, 80, 0):
    filename_prefix = bpy.context.scene.objects.active.name
else:
    filename_prefix = bpy.context.view_layer.objects.active.name

output = os.path.join(desktop_dir, filename_prefix)
bpy.context.scene.render.filepath = output


Can python access control points of Hue modifier?

You can access the 'Control Points' via CurveMap attribute of the respective Hue Correct Modifier:

>>> h, s, v = bpy.context.scene.sequence_editor.active_strip.modifiers['Hue Correct'].curve_mapping.curves
>>> print (h.points, s.points, v.points)
>>> [p.location for p in s.points]  # print saturation vector control points
>>> s.points[3].location[1] = 0.001 # assignment (y location)

To update the representation of the Curve within the UI call CurveMapping.update() after any assignment. However this does not update the Viewer, so toggling the 'visibility'  of the modifier is probably the easiest and fastest way to update the Curve and refreshing the Viewer at once.

Desaturate blue(s)

import bpy

scn = bpy.context.scene
act_strip = scn.sequence_editor.active_strip
hue_modifier = act_strip.modifiers["Hue Correct"]

# get the mapping
# .../bpy.types.CurveMapping.html#bpy.types.CurveMapping
mapping = hue_modifier.curve_mapping

# get the curve maps
# .../bpy.types.CurveMap.html#bpy.types.CurveMap
hue, sat, val = mapping.curves

# iterate through saturation control points
for count, point in enumerate(sat.points):
    x, y = point.location

    # desaturate blue
    if 0.55 <= x <= 0.7: # check if x is within the blue range
        point.location.y = 0.01

    print (count, point.location)

# direct assignment via index operator
#sat.points[5].location[1] = 0 # desaturate blue

# update the curve
# ../bpy.types.CurveMapping.html#bpy.types.CurveMapping.update
mapping.update()

# force viewer update (optional)
hue_modifier.mute = True
hue_modifier.mute = False

Custom curves

To apply a custom Curve iterate through CurveMap.points and assign a Vector((x, y)) to each Point.location (0-1 float range). The following operator allows to reset the number of points as well as the point locations to the default values for demonstration purposes:

Click to enlarge

import bpy
from bpy.props import BoolProperty, EnumProperty
from bpy.types import Operator
from mathutils import Vector

def reset_curve(curvemap):

    default_points = [Vector((0.0, 0.5)), Vector((0.125, 0.5)), Vector((0.25, 0.5)),
                     Vector((0.375, 0.5)), Vector((0.5, 0.5)), Vector((0.625, 0.5)),
                     Vector((0.75, 0.5)), Vector((0.875, 0.5)), Vector((1.0, 0.5))]

    if len(curvemap.points) > len(default_points):  # remove waste
        n = 0
        while len(curvemap.points) > len(default_points):
            curvemap.points.remove(curvemap.points[n])
            n += 1

    if len(curvemap.points) < len(default_points): # generate missing points
        n = 0
        while len(curvemap.points) < len(default_points):
            curvemap.points.new(0.1, 0.5)
            n +=1

    # set values to default
    for c, point in enumerate(curvemap.points):
        point.location = default_points[c]

class ResetHueCorrectOperator(Operator):
    bl_idname="sequencer.reset_hue_correct"
    bl_label="Reset Hue Correct"
    bl_options = {'REGISTER', 'UNDO'}

    # properties
    def modifier_callback(self, context):
        sel_strip = context.scene.sequence_editor.active_strip
        hue_modifiers = [(str(c), item.name.title(), '') for
            c, item in enumerate(sel_strip.modifiers) if
            item.type == "HUE_CORRECT"]
        return hue_modifiers

    mod = EnumProperty(name="Modifier", items=modifier_callback)
    hue = BoolProperty(default=True, name="Hue")
    sat = BoolProperty(default=True, name="Saturation")
    val = BoolProperty(default=True, name="Value")

    @classmethod
    def poll(cls, context):
        spc = context.space_data
        act_clip = context.scene.sequence_editor.active_strip
        return (spc.type == 'SEQUENCE_EDITOR' and act_clip.select)

    def execute(self, context):

        # get the active strip
        sel_strip = context.scene.sequence_editor.active_strip

        # tagging the area for redraw to update the curve edits
        context.region.tag_redraw() #context.area.tag_redraw()

        #for m in sel_strip.modifiers:
        m = sel_strip.modifiers[int(self.mod)]

        # get the mapping
        # .../bpy.types.CurveMapping.html#bpy.types.CurveMapping
        mapping = m.curve_mapping

        # get the curve maps
        # .../bpy.types.CurveMap.html#bpy.types.CurveMap
        h, s, v = mapping.curves

        # reset hue
        if self.hue: reset_curve(h)

        # reset saturation
        if self.sat: reset_curve(s)

        # reset value
        if self.val: reset_curve(v)

        # update the curve
        m.curve_mapping.update()

        # toggle modifier visibility to update the viewer
        # -> way faster than sequencer.refresh_all()
        m.mute = not m.mute # respect the state
        m.mute = not m.mute

        self.report({'INFO'}, "Successfully reset {}".format(m.name))
        return {'FINISHED'}

    def invoke(self, context, event):
        wm = context.window_manager
        sel_strip = context.scene.sequence_editor.active_strip
        if bool([m for m in sel_strip.modifiers if m.type == "HUE_CORRECT"]):
            return wm.invoke_props_dialog(self)
        else:
            self.report({"INFO"}, "strip has no hue correct modifier")
            return {'FINISHED'}

    def draw(self, context):
        row = self.layout
        sel_strip = context.scene.sequence_editor.active_strip
        if len([m for m in sel_strip.modifiers if m.type == "HUE_CORRECT"]) > 1:
            row.prop(self, "mod")
        row.prop(self, "hue")
        row.prop(self, "sat")
        row.prop(self, "val")

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

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

if __name__ == "__main__":
    register()


Combining Video Editor Scenes in One Scene

The gooseberry project uses a development branch of blender that has some modifications that haven't been applied to the main blender development yet. This is one change that is currently only in the gooseberry branch.

You can compare the code for the relevant panel in gooseberry branch and the master branch to spot the change. There are also other supporting code changes elsewhere to get that to work, see this commit.

There are gooseberry builds available to download from blender daily builds or you can look at building your own version of blender.


How to avoid fluid appearing outside collision objects?

I can't comment, so:

Try to keep the size of the domain as small as possible, and as fit to the simulation as possible. That makes the simulation require less resolution. For example, if you pour liquid from a bottle into a glass, restrict the boundaries of the domain to the neck of the bottle on top, and on the bottom, to the table, if you wish to have drops fall on the table. The domain works like a third dimension matrix. The resolution allows for the cells that are inside it to be smaller (which gives more resolution) or larger, depending on the resolution. Which is why you must fit your domain to your scene as much as you can. Since the cells inside your domain are not small enough, they touch the glass and some of them leak out, since the cells are larger than the thin glass.

I also suggest that you try to use "volume initialization" set to "shell" on the obstacle fluid properties, which will change a lot of things (although it won't work miracles).

As you already know, the trick about precise liquids is the resolution of the domain. It's the only thing.

One example (Only 102 of resolution and domain subsurf):


How do you access the camera besides using CTRL+ALT+0?

Either Select it from the 3D scene or outliner and make it active, or set it as active directly from the Scene tab in the Properties Window


How to combine smooth and non-smooth faces?

In many cases it's better not to use different shading types, rather than set whole mesh as smooth.

For the rest of the mesh which is intended to be flat you either add Edge Split modifier or check Auto Smooth in Data tab > Normals and set the andgle you need. Then parts of the mesh will be smooth, others - flat:

When joining several meshes with different split angles used

In this case it may be easier to use Edge Split modifier and apply it. It will create double vertices that will make shading look depending on angle you've selected and after joining meshes even with different angle of splitting normals they all will continue look like they did before.

In other cases

You may want to use Auto Smooth as there will be no extra modifier in stack and no double vertices so the mesh will be easy to edit.


Holy smoke! You need to slow down the jump a lot! If you make the cape a more solid material, and slow down the jump a lot (Maybe to 5 frames). Also, what would make a better simulation would be to make the cape facing the opposite direction of the jump. AKA, if you jump -5 on the x axis, set the cape to be pointing towards the positive side.


Missing faces after adding Boolean modifier

You should remove the faces and edges in the middle before using the screw modifier. Because or else there will be interior faces in the mesh and it messes up the boolean modifier.


Error trying to set only active object's origin with others selected

Override the context.
There is no origin_set belonging to an Object.
There are a couple of ways to do this, either deselect all other objects before calling the origin set operator, or override the context to make the selection only the single (or chosen) object(s)
Am using the python console, which is a great place to nut things out.
With  "Cube" active, and the "Cone" and "IcoSphere" selected...
>>> C.object
bpy.data.objects['Cube']

>>> C.selected_objects
[bpy.data.objects['Cube'], bpy.data.objects['Icosphere'], bpy.data.objects['Cone']]

Make an override dictionary, telling blender the only object to re-origin-ate is the "Cube" by making it the only member of context.selected_editable_objects <- The selected objects that the operator uses.  Why cannot I override the context for bpy.ops.object.origin_set()
>>> c = {}
>>> c['active_object'] = None
>>> c['selected_editable_objects'] = [C.object]
>>> c
{'active_object': None, 'selected_editable_objects': [bpy.data.objects['Cube']]}

Run the operator with that context dictionary c as the first argument.
>>> bpy.ops.object.origin_set(c, type='ORIGIN_CURSOR')
{'FINISHED'}

and only the origin of the active object is set.
The error in your question relates to the Object
not having an origin_set property.
>>> C.object.origin_set
Traceback (most recent call last):
  File "<blender_console>", line 1, in <module>
AttributeError: 'Object' object has no attribute 'origin_set'


How to attach objects to ends of bezier curves?

With the add-on Animation Nodes you can create copys of objects and automatically place them at specific locations.

The node setup shown below loops over all objects in a group with the cables in it.

The first loop “Get Splines” returns a list of all splines in the objects.
For every spline an instance of the desired object is created.
The second loop “Place Objects” evaluates each spline at the end (Parameter 1.00) and calculates location, tangent and normal. Parameter 0.0 would evaluate the spline at the start but then you will also have to mirror the tangent vector.
The tangent and normal are used to calculate the rotation angle for the object. You might want to replace the Guide with a random vector instead of using the spline's normal so that the terminals' orientation is more realistic.


I Used Shift + L to select all objects in common.. how do I apply a material to all of those now?

You select all the objects that you want to apply material to, with the one that you already applied material to as the last selected one, then hit CTRL+L (make links) and choose Materials from drop down list.


I turned off the Pro Lighting add-on. I suppose because the uni machine I'm using doesn't allow to use or something... though it looked installed. Thank you for the help!


Parenting an object does not parent but has broken or dashed lines

OK, so it was because the logo objects were not part of the collection that the parent object belonged to.


How to remap my UV without messing with textures already applied to a mesh?

You can have multiple UV maps on an object*.
With multiple UV maps you can keep your "old" UV map for the texturing you already did. Then add a second UV map and properly unwrap your object.

In the Object Data tab of the Properties window under the UV Maps heading, you will see something much like this:

Click on the + button, that will add another UV map slot to your object.

You really should name both your UVmaps now, just double click or CtrlLMB  on the name in the list to rename it.

Note: Be careful which UVmap is selected (highlighted in blue in the list), simply clicking on a UVmap will change what UVmap is selected or active. When you are unwrapping your object you will be changing the active UVmap.

Last step, go to everywhere you used the "old" UVmap: cycles nodes, BI material textures, modifiers, and dynamic paint, and make sure it is using the correct UVmap.

Now you can safely, in the new UVmap, unwrap your object however you like and it will not affect your previous texturing at all.

* In reality it is not added to the object, but the object data. However for brevity I will refer to it simply as the object.


Is there a way to extrude in a smart way?

As far as I know there's no magic button (like E) to extrude the way you want.

The simplest/fastest way I know is using Loop Cut and Slide in Face/Edge-edit mode (see picture).

It can become a very fast operation, if you get into the habit (see GIFs below).
Basically you use loop cut and slide to create faces where you need them and then you just move your face (instead of extruding it).

In this first situation I'm just hitting CTRL+R to start the "Loop Cut and Slide" command, I create one edge in the face and I slide it to the border, do the same in the other direction (to the other edge), then I select the face and I move it on the Z axis.

And here I'm doing the same but I do just one cut and slide it to the lower edge.


Reparent object with transformations of new parent

The best solution I have found thus far:

Select the child and its parent.
Press Alt+D to duplicate linked.
Manually copy the transform, rotation, and scale from the destination empty to the new empty.
Select the new child.
Press Alt+P > Clear [Parent] and Keep Transformation
Parent it to the destination empty.
Delete the duplicated empty.


Is the Network Render addon able to render with openGL?

AFAIK netrender doesn't support this, as there is no opengl "render engine" defined in blender (as you noted). There is an opengl render operator, but it is not defined as a formal render engine.

However there is a simple alternative approach you might be able to use. See the following questions:

Render on more than one computer?
Cycles Netrender Returning Black
How to use baked fluid with network render?


Another procedual way is to simply enable the Add Curve: Extra Objects addon. It is used to generate many kinds of curves with various parameters, including spirals.

To enable it, CtrlAltU to open User Preferences window, then find and enable it under the Addons tab.

Then you can tweak feature like Bevel or Extrude in the curve's Object Data tab to bring depth for it.


Checker-like Glitch on Cycles and Snow-like Glitch on Eevee Render

Solved by Jachym Michal, there's a backup collection hidden from viewport, but it was set to appear on render


Try those two things:

Check if your pivot point is set properly. It has to be in the middle of your x-achis. To set your pivot hit SHIFT+CTRL+ALT+C (or hit SPACE and type "set origin"). Then choose "Origin to Geometry" or "Origin to Center of Mass".

Now your mirror selection should work correctly. If not, also do point 2:

Delete one half of your mesh. add a mirror modifier. mark your seems. Apply your mirror.


From this answer, I've changed or set the following:

1- Keyed object
2- Particle
3- Surrounding sphere (viewed as bounds)
4- Bunny (viewed as bounds)

On the right the setting for keyed object (the 2nd PS has 10 for the time parameter).

Above the setting for the surrounding sphere (250 for the 'end' parameter).

And below the setting for the bunny:


make sure everything is deselected (alt + a) in edit mode. Press the number 3 for face selection and make sure you have the selection tool enabled. Click on the centre of the face.


There are three core ideas to recreate the portal VFX from Dr. Strange:

Motion blur
Rotating the particle emitter
Asymmetry in the particle emission

The look of flying sparks can be achieved by using motion blur in combination with an emissive material for the particles. The particle emitter should be a circular mesh. It's also important how the particles are emitted, since in the movie they fly away from the circle in a tangential direction while seemingly unaffected by gravity. This can be achieved by spinning the emitter, setting the normal velocity to zero, setting the tangential velocity of the particles to a suitable value and deactivating gravity. A more subtle effect in the movie is that even when the portal is fully open the emission intensity and particle distribution wobbles slightly. This can be achieved by removing segments from the circular particle emitter. The amount of wobble depends on the speed of the emitter's rotation, lower speed results in more wobble.

You can download the project by clicking on the link below:

A quick breakdown of how a scene with the portal was filmed for the movie and the result with the added VFX can be seen in this video.


Can you curve 1 edge without adding more edges to it?

Just move some of your vertices/edges around like this, if possible for your design. (Select vertice and press G) Then you keep the same number of faces and your vertices end up on the curve.  And your faces are distributed more evenly making cloth simulation more realistic.


Text cursor turned into horizontal cursor, how to undo this?

Press the Insert key.  The horizontal cursor means you're in "overwrite" mode, which can be toggled on and off with this key.


Why the addon installation succeeds but the API is not accessible through the bpy module?

I think I could find a way around this but I don't think this will work for all addons that require restarting Blender, but it works for Armory.

Here are the steps:

# Install the addon
bpy.ops.wm.addon_install(filepath=os.getcwd() + '/armsdk/armory/blender/addon/armory.py')
bpy.ops.wm.addon_enable(module='armory')

# Set the SDK path (Armory-specific)
user_prefs = bpy.context.user_preferences
addon_prefs = user_prefs.addons['armory'].preferences
addon_prefs.sdk_path = os.getcwd() + '/armsdk'

# Use the `start()` function of `bpy.ops.arm_addon` to enable it.
bpy.ops.arm_addon.start()

Now arm shows up in bpy.ops. I don't think all addons have a function like start() that Armory has.


How do I made this screw tube not have an invisible wall?

The reason your simulation isn't working as expected is because the tube has a screw modifier on it that hasn't been applied.

Apply the modifier to make the geometry real, and it will work just fine. You also should apply tranforms with Ctrl+A rotation and scale (in object mode) on  all objects involved in the simulation. Otherwise the simulation can become unstable and have unexpected results.


How can I merge or join Grease Pencil objects in collection?

Select all your objects -> go to Object menu -> Join. (Or use the shortcut Ctrl + J)


Does blender have useful skinning tools?

The skinning in blender leaves a bit to be deserved in my opinion but there are some options. In blender this is called weight painting and it uses vertex groups.

For every mesh there is a weight painting mode, where you can manually paint skin weights by painting. There are several tools here to help you out, with extra brush settings in the right settings panel.

In there is also a menu with some extra features.

Or you can manually add/remove/adjust the vertex weights in the edit mode by selecting vertices and adjusting in the right vertex group tab.

There is a paid add-on with extra tools for blender (also 2.8) available here: https://gumroad.com/l/weight_paint_tools


Weird normals after applying baked normal map

Well, now it works. The only thing I did differently from the other times was to disconnect the Image Texture Node and changing the Color Space to Non-Color before the baking. I can't change the Color Space afterwards, this is new in Blender 2.8.


You can do this with Free & Open Source software, using Eclipse and PyDev.

Download & install Eclipse from https://eclipse.org/downloads/
Follow PyDev installation manual http://www.pydev.org/manual_101_install.html
Install my remote debugging add-on from Github
Configure it in the addon preferences for /home/sybren/.p2/pool/plugins/org.python.pydev_5.3.0.201610121612/pysrc/pydevd.py (adjust for your system)
Start a debug server in PyDev
Press Space in the 3D view and search for "pydev", then choose the operator to connect to the PyDev debugger.

You can see me explaining the steps in my Blender Conference 2016 talk Develop add-ons like a pro.


How can I make a partially transparent texture?

if you're using cycles you can use a configuration like that..

image texture -> diffuse shader ->
                                     mix shader ->  output
             transparent shader ->

in the node material editor.


What is the difference between a UV Sphere and an Icosphere?

The major fundamental difference is how each sphere is modeled. The UV sphere, somewhat like latitude and longitude lines of the earth, uses rings and segments. Near the poles(both on the Z-axis with the default orientation) the vertical segments converge on the poles. This sphere is useful for projecting terrain onto planets and/or complex modeling as it is readily subdivided even after being created, and maps onto equirectangular projections (plate carrée) readily.
The icosphere uses a different approach. A polyhedron is made with triangles which are placed(at various subdivision levels) as an icosahedron (thus the name) and more finely-subdivided solids. All faces have the same area, which may be useful for certain types of UV mapping containing non-organic textures. An example that comes to mind is an isocahedral die or billiard balls where stretch must be minimized near the point where the number is printed onto the ball.

A conparison of UV and icospheres. UV spheres are on the left. Going downward, the subdivision levels are increased. 10 rings, 3 segments; 16/8, and 32/32 for UV spheres, and subdivision levels 1,2, and 3 for the icosphere. Default BI material is used, and light is directly behind camera.
Source: manual page and experimentation with UV mapping.


I also encountered that problem while modeling my aircrafts. There are two possible solutions:

The first option is to duplicate the surface where you will put the
logo then separate it into a different object. After that, move or
scale it just above you main object to remove intersections of
meshes. you can now put the logo (make sure it has a transparent
background) and reverse since it is now an individual object and it
will not affect other textures.

The last option is to apply the Mirror modifier then create a new
material just the same as on the other side but the logo that you
will now input into your image texture is reversed. This will be the
texture that you will put apply in the mirrored side of you
aircraft.


Question about the pamameters of Arcto in sverchok's "Profile Parametric Node"

This node was intended to closely resemble the SVG style of specifying paths, and you should really look at what SVG specs say about ArcTo

;; straight from the svg specs
(rx ry x-axis-rotation large-arc-flag sweep-flag x y)

For a deeper description see this github issue tracker post:
https://github.com/nortikin/sverchok/issues/350#issuecomment-51353886


Joining 2 Armatures and keeping the weights

Weight is a property of a Vertex Group, it's not about rigs but about meshes.

Every single vertex will be moved by a bone if the bone has exactly the same name of a vertex group to which the vertex has some weight, and the whole mesh must have an armature modifier pointing to the rig.

When you merge two meshes, all vertices retain their weights, but if some vertex groups have the same name, some will be renamed with the ".001" suffix, and they will stop to be influenced by the bone.

The same can happen if you join two armatures which have some bones with the same name.

So you have to check the right correspondence between bone names and vertex groups names, and eventually rename some bones to avoid overlapping (if you rename a bone in a working model, its vertex group will be automatically renamed in the correct way).

If every datablock has different names, everything will work well after joining.

Don't forget to apply rotations and scale (Ctrl + A) to all objects before joining.


Particle render: first frame has huge motion blur, other frames are fine

Start to render from frame 2 and you are ok
(I can't find the "starts on frame" setting)
"Start on frame" means that the shutter opens at the start of the frame and closes after the % of 1 specified in the "shutter" attribute.
The problem is that there are no particles at Frame 1.. first emission particles show up at 1,00000001 frame.
that's why you have blur on first video frame.
Don't know why the first static render is ok.


Influence Geometry Node "Point Distribute" density based on distance to empty

Answering my own question after figuring something out on my own.
If you add a vertex group (named whatever you want, but in my case "proximity", and set the vert weight for all verts in the object to 1.0, you can add a "Vertex Weight Proximity" modifier BEFORE the "Geometry Nodes" modifier to use as a weight influence.
By setting the Proximity mode to Geometry, and setting the high value to 0 and your low value to whatever you want, you can influence the range of the effect.
You can edit the falloff by going into weight paint mode, and adjusting the minimum value of the Weight Proximity modifier and seeing the weight change on your object (it might have to be subdivided first a few times).
Controlling the density is as easy as adding the name of your vertex group to the "Density Attribute" section of the "Point Distribute" node in the Geometry Nodes, since Vertex Groups apply as attributes.


Select the face where you want to add the groove. Press I to inset a new face. Then scale it with S and constrain to a axis (for me it was the X axis), press E to extrude the groove.

Or if you want the groove running all the way across the side, add two loop cuts with CtrlR. Then push them closer, by scaling same as above. After you have it the size you want, select the two outside faces and E extrude them out.


Define properties as annotations for dynamic property group

Hi your post is the closest to the issue that I'm having, and it seems like you've resolved your problem, I'm just not sure how the structure of your class can relate to the structure of the class in my problem that's throwing the error
I keep getting these annotation-type warnings which I understand are common but not breaking for addons that have compatibility 2.8 and 2.7, however, when trying to run blender in the background it becomes breaking.
Warning: class WM_OT_import_modal contains a property that should be an annotation!
c:\Users\Willard\Desktop\blender\2.82\scripts\addons\sketchfab_init_.py:1648
assign as a type annotation: WM_OT_import_modal.gltf_path
assign as a type annotation: WM_OT_import_modal.uid
You are using the latest version(1.3.1)
ERROR (wm.operator): c:\b\win64_cmake_vs2017\win64_cmake_vs2017\blender.git\source\blender\windowmanager\intern\wm_event_system.c:1486 wm_operator_invoke: invalid operator call ‘WM_OT_import_modal’

Below is the class in the addon throwing the error.
class ImportModalOperator(bpy.types.Operator):
    bl_idname = "wm.import_modal"
    bl_label = "Import glTF model into Sketchfab"ltf)
    bl_options = {'INTERNAL'}

    gltf_path = StringProperty()
    uid = StringProperty()

It would seem I just need to assign the properties: “gltf_path” and “uid” as type annotation to fix my error. But I can not conceive how to do this


Set Focal length to the same value as your actual camera.

5000 sounds way off.  Maybe you missed a decimal and it was 50.00?
Most point-and-shoot cameras are between 35 to 50.
Wide angle is lower, 18 - 30.  Zoom is 80 - 200.
Just looking at it, I would guess 50.

Scoot your Blender camera to the same distance
from your object as it was in the real world.

After looking at the scene...

File > User Preferences:

Add-ons tab > Import-Export tab

enable Import Images as Planes

N to bring up right-panel

right-click on the 3D Cursor Location
and Reset All to Default Values

Add > Mesh > Images as Planes

select the image you are trying to replicate

then scale it up on the X and Y by 5

go down to the Viewport Shading button
(bottom-center)  click Material
so you can see the image.

Be sure to click the Photo-icon
in the top-right panel
so it won't render in your final image.

Click on the Render tab, and under Dimensions,
Resolution:
X:    1800 px
Y:    1000 px

this should give you the proper aspect-ratio
use the Percentage Scale for test renders

select camera, press 0 on your numpad
to go into camera view

set Focal Length to 50

reset camera X rotation to 0
and set Z location to 14

select human.001

Location:
X:   1.0
Y:  -0.3
Z:   9.0

Rotation:
X:     0
Y:   180
Z:   180

Material > Add
Surface:   Toon BSDF
Size:      1
Smooth:    1

Add > Lamp > Sun
Strength 3

Location:
X:     5
Y:     5

Rotation:
X:    -5
Y:     5

Add > Lamp > Sun
Strength 5

Location:
X:    -5
Y:     5

Rotation:
X:    -5
Y:    -5

Click on the light properties

Size:          5
Samples:       8
Max Bounces:  12

Render tab >
Sampling:
Branched Path Tracing    - uncheck square
Clamp Direct:     10
Clamp Indirect:   10
Light Sampling:  0.5

AA Samples:
Render:       25
Preview:       0

Samples:
Glossy:       50
rest of 'em:   1

x  Sample All Direct
x  Sample All Indirect

Pattern:        Correlated Multi Jitter


How do I stop Blender 2.8 from quitting when I close a project?

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


Workflow for animating object inside of object? (Organic shapes...)

Use an armature with two bones, one for the heart and one for the wrap. Make the heart bone the parent of the wrap bone. Now when you scale the heart bone, the wrap will also scale.

You don't need to use weight painting, a simple parent object to bone will work. Parent the heart to the heart bone and the wrap to the wrap bone.

Now animate the scale of the bones -

You could also use shapekeys to give more detail during the pulsing.

Example here


This is less flexible than compositing, but if you're in Cycles, and lazy, you can, for example:

Split your world material into a mix between 2 colors, one to light the scene, and one to be visible to the camera. Here the scene is lit only by an environment HDRI, with its color tweaked though a Hue Saturation Value node.
Sit your object on a plane masked in its 'Object' tab > 'Visibility' panel to be a shadow catcher:

For this kind of result..

There are quite a few possible approaches .. maybe 'Shadow Catcher' would be a fruitful search term.


How to read all ‘recent reports’ from info window

Recent Reports

Modifying code from https://blender.stackexchange.com/a/62620/15543

The code in answer prints the textblock.

This one removes all other recent reports from blend file, creates a new one via operator,  and writes it to filepath

import bpy

#remove other Recent Reports
reports = [bpy.data.texts.remove(t, do_unlink=True)
           for t in bpy.data.texts
           if t.name.startswith("Recent Reports")]
# make a report
bpy.ops.ui.reports_to_textblock()
# save the report to file

filepath = "recent_reports.txt"
with open(filepath, "a") as f:
    f.write(bpy.data.texts["Recent Reports"].as_string())

Alternatively, if you don't want to clean up others, the new text added by operator can be found using sets.

import bpy

texts = set(bpy.data.texts)
bpy.ops.ui.reports_to_textblock()
new_text = (set(bpy.data.texts) - texts).pop()
filepath = "recent_reports.txt"
with open(filepath, "a") as f:
    f.write(new_text.as_string())

both write to a file "recent_reports.txt" in the same folder blender was opened


Change in shape after adding mirror modifier

The reason for the changed shaped is the Merge option.
The vertices of the blade are directly on the merge plane XY but they are connect to vertices on the handle, which don't get merged. This result in some different connections.
A solution could be to turn off the merge option on the mirror modifier.

BUT...
... your topology is horrible. Here are some steps to fix it.

Grab the faces of the blade and move them down, of the XY merge plane. ⇧ Shift RMB > GZ

Don't use triangles, remove the upper edge of the triangle at the transition. ⎈ Ctrl↹ Tab > E,  LMB > XECreate a new vertice by extruding.  LMB, E > [drag] >  RMB

Turn on the mirror modifier again (not subsurf though), select the edges along the ridge and extrude them upwards so the mirrored parts are joined.

Your topology should be a clear flow of quads. If you wish you can counteract the smoothing of the subsurf by marking certain edges as sharp. ⇧ Shift LMB select them and mark sharp ⇧ ShiftE.


how do I make an object bend or break if hit with sufficient force?

Unfortunately, dynamic fracturing/destruction is not truly possible yet. Though there are some interesting experiments:

Blender Demolition - Proxy Mesh Utilization (Demo 6)
Real-time Shattering Demolition physics in the BGE
BA thread with a patch developed by the author of the above videos

However, you can fake fracturing with the Cell Fracture addon (which is bundled with blender, you can enable it in CtrlAltU> Preferences > Addons > Cell Fracture) and rigid-body contraints:

It's not necessary, but you can get finer control over how an object is fractured by using the Grease Pencil:

Fracture the object into separate objects by pressing Cell Fracture in 3D view > Tool Shelf:

Make them rigid-body objects and constraint them using another addon called Bullet Constraints Tools:

Use the Calculate Mass tool to calculate and set the mass of all selected objects based on volume. I used the Glass (Broken) preset for the shards and the Bronze preset for the monkey:

Manually animate the render visibility of the original and fractured objects in the Outliner (camera icon), so that the original is used until it is fractured by an impact, or use post processing. (see related post)

You can simulate bending with soft-bodies, however tearing is not possible. (though again there are some tests)


Why isn't the shine/gloss showing on the character when I render?

The problem is just what I expected,
There are no lights.
You are rendering a closed space with no lights. Of course, it's not gonna be visible in the render.
As you can see in the image below adding just four point lights set to about 400watts power helped so much. There is nothing wrong with your material you just don't have any lights for the material to reflect.
Also, the table cloths and some other things are pink because you didn't pack the image textures in the blend file you shared.


You'll probably want to use an extra empty object that you rotate the moon around. That way you can rotate the earth and the moon independently from each other. Before starting, reset the origins of your objects (ShiftCtrlAltC).

To do so:

Start by adding an empty object in the same location as your earth object (you can snap your cursor to the earth by using ShiftS > Cursor to Selected)
Select your moon object, then select your empty and parent it (CtrlP). You will notice that you can now rotate the moon with the empty, but the earth rotates separately.
Rotate the earth at the speed you want.
Rotate the moon.
To make the moon orbit around the earth, rotate the empty.

If you want to make the moon orbit copy the speed of the earth, you can use a copy rotation constraint on the empty (you can also set the percentage of the speed by adjusting the influence).


Why does 24fps on blender appear slower than elsewhere?

Blender is counting frames instead of seconds so it is probably that the frames do get a different time value.
The other thing is that it is two standards in the FPS, 24 and 23.976. That might be the problem also.

It is possible that the FPS in the preview is different from the final also.


Python 2.8 - how to assign a material in shading versus layout workspace

The following script allows you to create a material with the colors you'd like and assign it to a specific object. The material is only created once, if another material with the same name already exists that one is used. If it finds the expected shader node it sets the desired color. The first argument is the object you want the material assigned to, which can be retrieved e.g. through bpy.data.objects['NameOfYourObjectHere'].

def add_material(obj, material_name, r, g, b):
    material = bpy.data.materials.get(material_name)

    if material is None:
        material = bpy.data.materials.new(material_name)

    material.use_nodes = True
    principled_bsdf = material.node_tree.nodes.get('Principled BSDF')

    if principled_bsdf is not None:
        principled_bsdf.inputs[0].default_value = (r, g, b, 1)

    obj.active_material = material


Set a projector at UVProjection modifier (script)

Similar to How to add modifiers using python script and set parameters?, the recommended way is to add a new modifier to an object using ObjectModifiers.new() which returns the reference to the modifier and allows to assign whatever you like:
import bpy

# Get the object in context
obj = bpy.context.object

# Add the modifier to the object in context
modifier = obj.modifiers.new(name="project", type='UV_PROJECT')

# Properties
modifier.uv_layer = "UVMap"
modifier.projector_count = 10

for p in modifier.projectors:
    p.object = bpy.context.scene.camera

projectors property is of type bpy_prop_collection, which is essentially a list of object references. In order to assign an object to each Object property of the modifier, you would have to assign an object reference like bpy.context.scene.camera.


Exception Access Violation when trying to add face to new Facemap

Perhaps the cause of the crash was accessing an invalid reference.
>>> import bmesh
>>> obj = bpy.context.edit_object
>>> me = obj.data
>>> bmsh = bmesh.from_edit_mesh(me)
>>> bmsh.faces
<BMFaceSeq object at 0x000002686604A600>

>>> bpy.ops.object.editmode_toggle()
{'FINISHED'}

>>> bpy.ops.object.editmode_toggle()
{'FINISHED'}

>>> bmsh.faces
Traceback (most recent call last):
  File "<blender_console>", line 1, in <module>
ReferenceError: BMesh data of type BMesh has been removed

The following script is based on the examples in API documents.
def execute(self, context):
    obj = bpy.context.edit_object
    me = obj.data
    bmsh = bmesh.from_edit_mesh(me)
    fm_lay = bmsh.faces.layers.face_map.active

    for f in bmsh.faces:

        fm = obj.face_maps.new( name=str(f.inded+1) )
        f[fm_lay] = fm.index


Translucency for shell material using the Principled Shader

Ok, the trick here is to have a mask control the vertical falloff of your shader.

I dont have much time to work on this, but this should get you going in the right direction. I will also tell you what I would change.

Getting the top translucent part : Your 1st shader should have the transmission all the way to 1 (for glass), then put a slight roughness on it.
Have that mix in with another shader for the base of the shell, (we will get back to this)
Have those two shaders mix with the "Gradient Top" node* (You will have to create this, I attached a pic how to do it.)
The base of the shell will have 2 Principled SSS shaders, I believe I put the SSS radius to .1 for all of them, the higher the number the more transparent it becomes.
I found a wood texture that I used for the grooves that I plugged into the principled shader. (I should of plugged it into both, I messed up. )
I used a noise texture to have the yellow and orange broken up a little.
Then for the bands I just used a wave texture in the displacement socket. I would rather model this instead and not even use the displacement.

**** maybe instead of a glass Princepled shader I would try a translucent/glossy shader and see how that looks.

*** Dont copy my settings exactly I did them real quick. Play around with the gradient top settings.

*** I probably wouldn't go with a noise texture to mix the two princepled shaders. It would be better to paint those by hand, so you can follow the curves.

Hope this helps a little.


Reproducing the "From Instancer" example from the Blender documentation

1 - This is for Cycles only
2 - You need to be in Rendered mode (not Material Preview)


Can I change Info bar colour on scene change

Cool idea, I wrote this addon for me just now and I triggered the Header draw event. You can copy it from below or from here: scene_colored_header.py

EDIT: Updated to the newer Version. Don't use the old version, it generates a continuous redraw of the Header, wich I don' noticed. leads to cpu inceasement

the updated Version:

    #scene_colored_header.py
bl_info = {
           "name": "Colored Header for each scene",
           "author": "Leon95, Idea: 3pointedit",
           "version": (1, 1),
           "blender": (2, 68, 0),
           "location": "Properties > Scene Tab > Scene Panel > Display Color",
           "description": "Define a Header Color for every scene and display it in the Header",
           "category": "Scene"
           }

import bpy

def_color = bpy.props.FloatVectorProperty(size = 3,min = 0.0,max = 1.0,
    default=bpy.context.user_preferences.themes[0].info.space.header.copy())
def_color = bpy.context.user_preferences.themes[0].info.space.header.copy()

def ui_properties_costum_header_color(self, context):
    row = self.layout.row()
    row.prop(context.scene, "headerColor")

def ui_info_header_refresh(self, context):
    #assign the property to the header theme every time it is redrawn
    l_co=context.window_manager.lastHeaderColor
    ch = context.user_preferences.themes[0].info.space.header
    cs = context.scene.headerColor
    #check, if reassignment is needed, since  assigning a color leads to redraw
    #(which the causes some kind of stack overflow)
    if not (round(l_co[0],3) == round(cs[0],3) and round(l_co[1],3) == round(cs[1],3) and round(l_co[2],3) == round(cs[2],3)):
        bpy.context.user_preferences.themes[0].info.space.header = bpy.context.scene.headerColor
    context.window_manager.lastHeaderColor=[cs[0],cs[1],cs[2]]

def register():
    co = bpy.context.user_preferences.themes[0].info.space.header.copy()
    bpy.types.WindowManager.lastHeaderColor=bpy.props.FloatVectorProperty(size = 3,min = 0.0,max = 1.0)
    bpy.types.Scene.headerColor = bpy.props.FloatVectorProperty(
                                     name = "Display Color",
                                     subtype = "COLOR",
                                     size = 3,
                                     min = 0.0,
                                     max = 1.0,
                                     update = ui_info_header_refresh,
                                     default = co)

    bpy.types.SCENE_PT_scene.append(ui_properties_costum_header_color)
    bpy.types.INFO_HT_header.append(ui_info_header_refresh)
    #bpy.app.handlers.frame_change_post.append(ui_info_header_refresh)

    #reassigment forces redraw
    bpy.context.user_preferences.themes[0].info.space.header = bpy.context.user_preferences.themes[0].info.space.header

def unregister():
    bpy.types.SCENE_PT_scene.remove(ui_properties_costum_header_color)
    bpy.types.INFO_HT_header.remove(ui_info_header_refresh)
    #bpy.app.handlers.frame_change_post.remove(ui_info_header_refresh)
    bpy.context.user_preferences.themes[0].info.space.header = [def_color[0],def_color[1],def_color[2]]
    bpy.context.window_manager.lastHeaderColor=[0,0,0]
    del bpy.types.WindowManager.lastHeaderColor

if __name__ == "__main__":
    register()


not sure if you found a solution, but here is python script, that reads and writes  bphys data

https://blenderartists.org/forum/showthread.php?318831-Point-Cache-Doctor-script

via phonybone
and here is nice solution via kram1032

Can I access the particle system through Python to build custom simulations?


How do I animate a right-angle triangle inside a circle (hypotenuse of the triangle is the radius of the circle)

Start by adding a single vertex (ShiftA then S then A or Add -> Single Vert -> Add Single Vert). You should be in edit mode by default after doing this, but if not Tab into edit mode.

Extrude by 1 along the X axis (E then X then Numpad 1), then extrude by 1 along the Y axis (E then Y then Numpad 1). Select everything, by hitting A twice. Press F to make a face.

If you want only the outline of the triangle, press I followed by some sufficiently small number then press Enter, then X followed by F. Tab out of edit mode.

Go to the object properties and add the following into the Scale boxes:

If you prefer degrees:
X: #cos(radians(360*(frame-1)/100))
Y: #sin(radians(360*(frame-1)/100))

If you prefer radians:
X: #cos(2*pi360*(frame-1)/100)
Y: #sin(2*pi*(frame-1)/100)

The hash signs are mandatory. They tell Blender that you're entering a driver rather than a static value. If you edit the driver later, the hash signs won't show up, and you shouldn't re-add them. Once the driver is created, Blender knows it's a driver without being told again.

frame is the current frame number, and the reason I subtract 1 is that Blender starts at frame 1, while the parametric equations for a circle start at 0. 360 or 2*pi is the angle of a full circle, and 100 is the number of frames it will take to complete a full circle.

The result:

As you can see, the triangle's outline gets scaled as well, and there's certainly room for improvement there, however, here's the .blend.


All you need to do is replace the Layer Weight node with a Normal Map node.
I played around with the normal color and strength to get a result I liked.
(The image texture I'm using is just an image of a gradient)


Is there a Simplify Curves addon for Blender 2.80?

Select your keyframes on graph editor.
Press "o" Select SMOOTH KEYS. That should "simplify" a little bit better your curves.
I remember the function "simplify curve" is available for grease pencil, but I don´t remember seeing it elsewhere. Please paste a screen capture.

I hope this works for you. If it does, please vote me up and mark me on the checkbox to the left side of this answer.
Thank you.


You can easily achieve this with the animation nodes add-on for blender (it's basically like coding but with nodes)
There's even a tutorial on YouTube for exactly what you are looking for!
:)


How can I make only the selected object change to wireframe view?

On viewing objects in "wireframe" mode ,all objects go to wireframe by default.
In order to view ,wireframe for a selected object in "other modes" , check "wire" under the objects panel.


Make sure you are undoing in the edit mode. Undoing in the edit mode will undo individual steps you made while editing your object (eg. moving vertices, extruding faces...). Undoing in object mode will undo every change made to that object while you were in edit mode.