You're looking for is the Affect Only > Origins option in the Options panel (top left of your 3D view), which allows you to move the object's origin and change its orientation:


Eevee render output is black. But it appears in cycles. What I did incorrectly during adjustment?

Having a bright, high contrast monitor and good vision, I'm able to see this picture is not completely black:

In future, you can try cranking up the Exposure in Render Properties tab  -> Color Management section (or use compositor to increase contrast etc.) to see what's happening better:

As you can see, your character is cut in half. This happens because the character is overlapped by an object, which also blocks light, putting everything left in a deep shadow.
Right away when you open the uploaded project, you can see the problematic object on the bottom workspace region:

It's not problematic in viewport preview, because it was set to only display as a bounding box in the viewport:

The solution you probably want is to disable rendering of this object by clicking on a camera icon next to the object's name in the Outliner:

Then the render becomes this:


Make sure, under your Render Properties in the Post Processing panel you have Compositing and Sequencer checked.

Also make sure to hit Animation CtrlF12 for your Rendering, not just Render F12.


To see all the bones influencing geometry:

Select the mesh.
Get into Edit Mode.
Select the vertices you're interested in.
Hover your cursor over the 3d Viewport, hit N.
Scroll down until you see Vertex Weights.

From there, select the Deform option and you should be able to see all the influences.  If there's an influence that you don't want there, hit the X next to the VG name.


to keep the Tie moving in front of the player you can add some random motion on the Y axis with a constraint to keep it in the view, and to keep the Tie moving in front of the object on the X-axis you add some motion on the x axis:

to make a bullet be fired at a position without traking an object you can add another object that will track the hitBox and fire the bullets, when the box move the bullets will not track it


Is there anyway to make particles have an influence area around them that will let them collide, without having to turn them into rigid bodies?

You can add a force to the particles to effectively repel each other as in this answer https://blender.stackexchange.com/a/84426/29586. It isn’t ideal as it relies on the particles being all the same size and it isn’t physically accurate (but is a quick and dirty method).

Another option is to use the Molecular Script add-on (http://pyroevil.com/molecular-script-docs/) which physically simulates the particle collisions.


Is there a way to make gradient shadows?

EDIT:

As L0Lock said, to smooth an object, you can simply click on Smooth Shading (in the Tools panel, on the right of your 3D View > Tools > Shading > Smooth) and enable the Auto Smooth option (Properties panel > Data > Normals > Auto Smooth and play with the Angle value).

My first answer was to use both Smooth Shading and Subdivision Surface. Why that? Because it won't only create a gradient shadow, it will also smooth your shape, which is generally what you want. In that case, no need for the Auto Smooth, but you will have to add some edge loops close to your angles to keep your angles sharp. That said you'll probably need to change your topology to make it work:


How do you crop a video in the current Blender Video Editor?

If you want to change the resolution of the project to fit your image, select the image strip, and select this:


How do I force a parent-child object hierarchy to follow armature *without* using armature modifier?

I'm assuming that you've already copied the object's starting rotation to match the rotation and roll of the bone. You might need to apply this rotation (Ctrl+A) in order for the constraints to start working properly.

Another possibility is that you might be experiencing Gimbal lock on your objects. Armatures don't exhibit this problem because their default rotation type uses quaternions, whereas objects default to Euler rotations. Fortunately, you can change the rotation type for objects (3D View > Properties region (N) > Transform panel > Rotation) from XYZ Euler to Quaternion (WXYZ).

Try that and see if you're still running into rotation issues.


It's 'easier' than it used to be, here's one way, using the 'View' Transform Orientation.

Find a reference rectangular face, preferably facing down your intended Z, select it in Edit Mode, and set the Transform Orientation to 'View'
Orthographic: ShiftNumpad 7 align your view to the face.
ShiftS > Cursor to Selected .. now the cursor should be centred on the face.
In Object Mode, with the Header > Options set to 'Origins', move the origin:  ShiftS > Selected to Cursor
Header > Object  > Transform menu.. Align to Transform Orientation. Now the Origin shoould be aligned with the view, and the face.

There may be some 90 degree swivels to do while in the view, to get your X,Y and Z on the right axes, and don't forget to switch the 'Origins' option off.


In user views, you can control the visibility of the axes and grid floor in the 'Display' panel of the properties region in the 3D View window.

I don't know why, but this doesn't work in the preset orthographic views (Top, Left, etc.). To hack out of that, convert the preset view to a user view from exactly the same angle, by tilting away and back again: Numpad46. It might be more convenient to align your view to a selected face, or an object's Z axis, using ShiftNumpad7.


Blender is subdividing the edges on the outer edge of the face, but it isn't filling in the grid tiles for you.

If you want to fill in the top face with a grid using the subdivided vertices, first delete the top face. Then select the top edge loop, and press Ctrl+F then select Grid Fill.


Game Engine lags when activating sound with keyboard

From what it seems to me, you have a Keyboard Sensor stringed to a And Controller stringed to a Sound Actuator.  When in this setup the game will always lag for this reason: when a keyboard key is held, it sends many pulses per second to the computer to act as input.  If you have something like a Motion Actuator, then this isn't a problem, as it just makes it move forward continuously.  However, with your Sound Actuator, what it's trying to do instead is to start playing the sound file every time it receives a pulse (which by default is 60 times per second).  So in effect every frame the key is held it tries to play the sound, which is more than the game engine can handle, and as such it slows down.

Now, a setup that doesn't have the sound playing 60 times at once is as follows

[WARNING: TECHNICAL JARGON AHEAD!]:

First delete the malfunctioning sound actuator part you set up.

Use a different Keyboard Sensor than the one controlling the movement of your character,  but assign it the same key (W).  Click the ''' icon on the sensor to darken it, then in the frequency box, enter in a number other than zero (the basis of this number is how many frames is in between pulses, for example if you put in 29, then there will be 29 pulse-lengths between every pulse sent to the computer, making the sensor do 2 per second at 60 frames per second.  The larger the number the more time in between pulses.)  See this page on Sensor Common Options for a little more of an in-depth look on this function.

Then add your And Controller and a Sound Actuator set to use your sound.  If everything goes correctly, you should have some evenly-spaced footstep sounds with no lag.

If this was good, consider upvoting! :)


Box Select Error: Active Object is Not a Selected Mesh

No, the message is right. And happens also selecting by hand, I just did it (blender 2.74 on this pc)

In blender, the "active object" is the last one selected.

But. suppose you have 3 objects and

You start selecting obj1: that is the active object, and is also selected
then you shift select obj2 and obj 3: now obj1,2,3 are all selected but obj3 is the active (last selected)
then you (eg: by mistake), click again on obj1: now obj2,3 are selected, obj1 is not BUT it is the last you selected (and then deselected) so, to blender obj1 is still the "active" object, but is not selected

exactly what the message says...

In your image, I see that in the outliner this is visible. the active object (not selected) is backpole.003 (its text is highlighted but the triangle icon has no circle background) while backpole.009 and backpole.019 are selected (the triangle icon has a circle purple background)

If you ask me, it could be a bug in the selection behaviour, but... this explains the message you get. It could be that box selection replicates this behaviour or something similar with the same effect


In order to move/rotate/scale the result of a baked soft body or cloth simulation you can export the data to a suitable format and either Import it (into a set of shape keys) or use the exported point data to drive a Mesh Cache modifier. This can be achieved via the MDD Importer/Exporter which is available as an addon (User Preferences/Add-ons).

Shape Keys

For the 'shape key' method, simply select your bakes soft body/cloth mesh and select File/Export/Lightwave Point Cache(.mdd) from the menu. This allows you to create an MDD file containing the data from each of the vertices in your mesh.

Now select File/Import/Lightwave Point Cache(.mdd) to re-import the point data and the add-on will automatically generate animated keyframes to animate your object between frames. At this point you can remove the Soft Body physics as the animation will be purely keyed.

You can now move/rotate/scale your mesh and the animation will still be applied.

See https://blender.stackexchange.com/a/106400/29586 for a further example of this.

Mesh Cache Modifier

Another option is to access the exported MDD data via a Mesh Cache Modifier. The modifier reads the exported MDD data and applies it directly to the mesh. This has the advantage of avoiding the complexity of keyframed shape keys and allows the animation to be more easily 'tuned'.

This can produce the following result :

Here the centre cloth falling on the cube is the original simulation. The point cache has been exported to an MDD file and the mesh duplicated (without the simulation) and Mesh Cache modifiers used to re-apply the simulation on each of the copies - at different start frames and orientations.

A further example of this can be found here https://blender.stackexchange.com/a/10661/29586


Is there a way to bulk move objects under a collection

I can't reproduce this in 2.83 .. I can select multiple, either in the 3D View, or the Outliner, and left-drag them into the collection by releasing the left mouse-button over the appropriate line.
It may be easier, with such a large selection, in Object Mode, in the 3D View or the Outliner, to hit M. You should then be offered a dropdown menu of collections to which you may move the selection, or the option to create a new collection to move it to.


Seams are visible around the link at the lines corresponding to the UV seams :

To correct that, you can paint (texture paint) this part using the clone brush, preferably using a strength of 1 (if not you will have more blurry painting).

To clone paint, Ctrl+LMB at the position you want to clone, then paint along the seam :

Note that will change your texture. So make a copy of it before you do that.

For adding more rusty parts, you can use the same principle, both in order to have more rust at the places you want and also to correct the seams :

The same part, before and after (no need to be an artist to do that !):

Edit : to have more rust in a more easy way (but that will not correct the seam problem) you can move the UV map parts to the center. In this particular case, that will not have any impact for the other texture :


Are you sure you did With Automatic Weights? It really looks like you parented the armature to the cube, with the cube as the parent. That's wrong. The cube must be the child.
Make sure you select the objects in the correct order. The so-called active object is displayed orange. The so-called selected objects are displayed red.
The cube must be the child (=red), selected first in the viewport. The armature must be the parent (=orange), selected last. After you parented them With Automatic Weights (Ctrl+P in Object mode) you will see the hierarchy in the outliner. The armature is in the collection, and when you expand the node you will see the cube.

In Pose mode you can deform the mesh.


You can use for this task Data Transform Modifier.

You will need to have both meshes in the exact same place.

To the mesh with holes add Data Transfer Modifier, select original mesh as a source, check Face Corner Data and Custom Normals and select Nearest Corner Of Nearest Face.

You will be also prompted to enable AutoSmooth, of course do this in mesh Data tab.


Problem with moving vertices in shape key edit mode

When in Edit mode, there is an Options tab in the Tool box (T).  In the tab you had X mirror and topology mirror turned on.  If you untick X mirror, the two vertices stop moving together.

(Also, you ought to Apply Rotation, (Control A/ Rotation) so that local axes agree with global axes, not that that was the cause of the problem. It can cause rigging problems if it's not applied. Also you should Apply scale (Control A/Scale) because if you ever animate a child object rotating around the bear it will inherit the Scale as it rotates, and become bigger on one axis, then shrink again as it goes further around)

Note that if you apply Rotation and Scale, but don't untick the X mirror box, the two vertices now move in a logical, mirrored direction at least. So your local rotation and scale values were interfering with the proper function of the X mirror tool.


You don't need conditional executions to achieve this effect, what you need is a constant seed for every nth interval. For instance, if I floor divide the time by 10, the result will be zero for the first 10 frames, 1 for the next 10 frames, 2 for the next 10 frames and so on. If I used the result of the floor division as seed, the random offset will be constants for every 10 frames.

If you want the length of the intervals to be random, we may use an approach as follows. We will initialize a variable with some integer--say zero, at each execution, we will replace that variable by another random integer if some boolean is true, that boolean has some probability $P$ of being true. The value of the variable is then constant for some interval that depends on $P$ and changes if the boolean is true. The implementation may be as follow:

AN.seed if hasattr(AN, "seed") else 0

The above expression checks if AN has a variable called seed, if it has, it returns its value, if not, it restuns zero.

AN.seed = (new if y else original)

This expression sets the variable to the frame number if the boolean y is true. The boolean is true if the value of a random variable $\in [0,1]$ of a uniform distribution is less than 0.1 (meaning the probability of being true is equal to 0.1). The probable length of the intervals is inversely proportional to the probability $P$.

Now all you have to do is to use the value of that variable as seed for the random generator and everything should work as you expect it to.


Can bones in IK chains be also moved independently?

If I get you correctly, sure.  You just add another bone:

In your particular case, you would:

Duplicate bone 3 and delete any constraints from this duplicate.
Parent this duplicate to bone 3.
Disable deform on bone 3, and rename any vertex groups on the mesh to follow the duplicate instead ("3.001" likely.)

That way, bone 3 still takes place in the IK chain, and you have a deforming bone that defaults to the orientation of 3, but is still independently manipulable.
Should be said, even though you can do that, it doesn't mean you should do that.  How most people would approach the situation in your picture is to make 2 the IK bone, move the rest pose of 4 to the rest pose tail of 2, decrement the chain length by 1, and then give 3 a world->world copy rotation constraint targeting 4.  (An alternative here is to enable rotation on the IK constraint, but that's less reliable-- the IK solver doesn't do well with rotation enabled.)


How to do continuous integration with gitlab when developing blender addons?

Introduction

Continuous integration requires a few things, namely tests, a CI server and tooling to run the test suite and read results automatically. Let's take them one by one.

Testing

There are various ways to write unit tests in python, but I decided to go with the classic unittest module because it is included with blender's python.

While I started off with tests in a different repository, I decided to move them alongside the addon in order to eliminate the need of keeping tests and addon in sync.

Let's say our addon is named toaster. I would advise naming the tests folder toaster_tests. You'll see why.

The test suite

The test suite is written in classic unittest manner.

class ToasterMeshTests(unittest.TestCase):
    def setUp(self):
        if bpy.data.objects.get('Cube') is not None:
            bpy.data.objects.remove(bpy.data.objects['Cube'], do_unlink=True)

    def tearDown(self):
        pass

    def test_addon_enabled(self):
        self.assertIsNotNone(toaster.bl_info)

Some caveats:

You need a way to override context because the tests are not always run in the same context as the actual operators. I have found this to mostly work but not always.. Some times you will have to rework your addon in a way that it is less context-sensitive, for example using bmesh instead of operators to manipulate meshes. You will also need to provide a path for context passing all the way down to the last operator call (which is a good idea anyway as you might find that things break due to context changes when you move your UI around). This context override function seems to work most of the time for me (unlike the one in the API reference)

def context_override(self):
    override = bpy.context.copy()
    for window in bpy.context.window_manager.windows:
        screen = window.screen
        for area in screen.areas:
            if area.type == 'VIEW_3D':
                override['window'] = window
                override['screen'] = screen
                override['area'] = area
                override['region'] = [region for region in area.regions if region.type == 'WINDOW'][0]
                override['selected_objects'] = [o for o in bpy.context.scene.objects if o.select]
                override['active_object'] = bpy.context.scene.objects.active
                return override

I found a weird bug when reloading the startup file (bpy.ops.wm.read_homefile()) in setUp so for now you need to manually start the suite in an empty file, and clean up after each test.

Graphical version

If your addon is graphical it might make sense to run some of the tests manually and eyeball the result instead of writing complex geometry-understanding scripts. For this reason, I made the tests folder an addon by itself, with a panel and an operator that calls each test separately. This is why I recommend naming the folder toaster-tests, in order to avoid name conflicts in the blender addons folder.

This is the operator

class TestsOperator(bpy.types.Operator):
    bl_idname = "toaster_tests.run"
    bl_label = "Toaster Tests"
    bl_options = {'REGISTER', 'UNDO'}
    testcase = bpy.props.StringProperty()

    def execute(self, context):
        if self.testcase == "all":
            suite = unittest.defaultTestLoader.loadTestsFromTestCase(ToasterMeshTests)
        else:
            suite = unittest.TestSuite()
            suite.addTest(ToasterMeshTests(self.testcase))
        unittest.TextTestRunner().run(suite)
        return {'FINISHED'}

And the UI panel

#A new panel in the tools section of the 3D view
class View3DPanel():
    bl_space_type = 'VIEW_3D'
    bl_region_type = 'TOOLS'

class ToasterTestsPanel(View3DPanel, Panel):
    bl_label = "Toaster Tests"
    bl_context = "objectmode"
    bl_category = "Toaster Tests"

    def draw(self, context):
        layout = self.layout
        col = layout.column(align=True)
        col.operator("toaster_tests.run").testcase = "all"
        col = layout.column(align=True)
        col.operator("toaster_tests.run", text="Test 1").testcase = "test_add_column"
        col.operator("toaster_tests.run", text="Test 2").testcase = "test_add_beam"

Running the test from the console

To enable continuous integration you need to be able to run the tests from the terminal. While this is trivial, it is not as trivial to make sure that the CI runner understands if the tests failed or passed. Blender has the --python-exit-code parameter but this returns non-zero only if an exception is thrown in the supplied python file, immediately before exit.

Thus we need to throw an exception if the tests fail, catch it and immediately exit. This is what this script does.

import unittest
from toaster_tests.suite_1 import ToasterMeshTests
import sys

def run():
    suite = unittest.defaultTestLoader.loadTestsFromTestCase(ToasterMeshTests)
    success = unittest.TextTestRunner().run(suite).wasSuccessful()
    if not success:
        raise Exception('Tests Failed')

try:
    run()
    sys.exit(0)
except Exception:
    sys.exit(1)

You can try to run it like this

blender --addons toaster,toaster_tests --python toaster_tests/run.py --python-exit-code 1

You will see blender momentarily launch and output like this:

Read new prefs: /path/to/userpref.blend
Toaster Loaded
Reloaded modules
...
----------------------------------------------------------------------
Ran 3 tests in 0.003s

OK

or if the tests failed

Read new prefs: /path/to/userpref.blend
Toaster Loaded
Reloaded modules

.F.
======================================================================
FAIL: test_add_column (toaster_tests.suite_1.ToasterMeshTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/qwazix/.config/blender/2.78/scripts/addons/toaster_tests/suite_1.py", line 45, in test_add_column
    self.assertEquals(bpy.data.objects['Cube'].location, Vector((0,0,-8)), "Column not at the correct position")
AssertionError: Vector((0.0, 0.0, 0.0)) != Vector((0.0, 0.0, -8.0)) : Column not at the correct position

----------------------------------------------------------------------
Ran 3 tests in 0.002s

FAILED (failures=1)

CI!

In the first reference link there's a nice writeup on how to make the CI server (in that case Travis) to download blender in the new VM the CI engine uses. While this allows you to use the shared runners in the case of GitLab (I assume something similar happens with Travis) however I find it wasteful and unnecessarily heavy on blender foundation's servers to download blender each time I push to my server, so I decided to spin up a virtual machine on my local computer.

So go install yourself a distro with your favorite blender version on a virtual machine and then install gitlab-ci-multi-runner.

  If you are wondering why a VM, it's because you might have done all sorts of weird things on your local blender installation (enabled multiple addons, installed python modules and other things) that a user might not have and thus the fact that the tests pass on your machine doesn't mean it will work on a clean environment.

Register your runner with gitlab

gitlab-runner register

It will ask you to provide a token from your gitlab repository and give a name to the runner. For the first time it might be useful to do it as user rather than as root, in order to run it manually and be able to observe what is going on. Afterwards, registering as root allows for unattended tests by just having the VM booted up, though you might run into issues with the X11 display. Choose a name and labels as you like and set executor as shell.

Now run it (except if you set up as root, where it automatically runs in the background)

gitlab-runner run

CI configuration

To trigger a CI build in GitLab you need to add a .gitlab-ci.yml in the root of your repository. The following file works for me

job1:

  script:
    - mkdir -p ~/.config/blender/2.78/scripts/addons/
    - rm -f ~/.config/blender/2.78/scripts/addons/toaster
    - rm -f ~/.config/blender/2.78/scripts/addons/toaster_tests
    - ln -s `pwd`/toaster/ ~/.config/blender/2.78/scripts/addons
    - ln -s `pwd`/toaster_tests/ ~/.config/blender/2.78/scripts/addons
    - blender --addons toaster,toaster_tests --python toaster_tests/run.py --python-exit-code 1

If you choose to run it as root you will need to append the following switches to the last line, as the runner runs under the gitlab-runner user which does not have a DISPLAY, nor access to alsa.

-b -noaudio

  Note that I suspect that running with -b might incur additional context issues with blender, since it's possible that context override won't work (no windows to loop through in context_override()). This theory is not tested.

Passed!

Now if all went well, your runner should show

Checking for builds... received                     build=6237996 repo_url=https://gitlab.com/d-e/blender-addon-boilerplate.git runner=78a379b6

Build succeeded

and the build page in gitlab should show the output from blender. After a while a nice green reassuring

badge should be besides your last commit.

Wrapped and ready to go

I've updated my boilerplate blender addon (now named Toaster) with CI configuration. There are two branches, one that launches the full blender gui in the runner and the nogui-testing branch which runs blender in the background. Go get it.

References

Automatic Blender Addon Testing with TravisCI
Terminate Blender with Exit Code “1” when run from command line
Blender Manual – Command Line Arguments
Gitlab runner documentation


Blender Cycles - How to make particle planes to face towards the camera?

It seems to fix this issue, when I enable "Rotation" under the duplicate object selection in the Particle System settings.


What does "Invalid clnors in this fan!" mean?

Clnors stands for Custom Loop Normals.

This happens when clnors are not equal to each other where they should (would have to see the geometry), this message is printed and they are all replaced with their average value to be equal.


You can use the Decimate modifier to optimize the mesh and it should preserve UVs.

Select your object in Object mode

Add Modifier Decimate

In the modifier settings, select Planar and set a low angle limit (1 degree is enough if your mesh is truly flat).

Apply the modifier when you're done. Check the face count to see how many polygons you have now.

Note: The Decimate modifier affects the whole object


The point here is simply a question of lamps . . . You added too many (5-6 lamps all around the mesh with a sun too) then the shadows overlap. Delete all the light point you created and let only one in front of the mesh.

Check the image:


The links in the comments are the answer but since I have made a picture, why not post it anyway:

Instead of deforming the object directly, deform a stack of tris. Then parent your target object (the cylinder in this example) to the deformed object and enable duplifaces for the tris in Properties >> Object >> Duplication.

Just make sure the object you want to duplicate has its scale applied or there will be deformations.


There is a gradient tool, if that's what your looking for.

Activate it with AltLMB or by pressing Weight Gradient in the 3D view > Tool shelf > Weight Tools:


The Properties Panel in your screenshot is simply retracted. I marked the arrow that expands it. Some of its previous options can also be found in the Tool Tab, also marked.

On top of the Outliner, top right of your image, there is also a dropdown menu that contains some of what before was in the tool panel.


Rigid body object animation won't preview or play?

Run the simulation Alt-A until all frames have been displayed, this causes a real time bake. After that it should work fine.


Blender Cycles quickly renders animation just black

Cycles Render uses a different node set-up for the materials then Blender Render. (You can check that for both Cycles Render and Blender Render by opening the Node Editor, with 'Use Nodes' enabled) After switching to Cycles Render,  it doesn't contain the materials you have set up in Blender Render. You must make the new materials in Cycles Render yourself.


.PDB Files are not capable of importing to blender 2.8

The issue is that your files have the wrong encoding. The byte 0xFF is not valid in UTF-8. You need to convert the file to UTF-8 then it should work properly. A good editor will be able to do this for you, for example Notepad++ offers a function to convert encodings.


Imported Scene is Very Slow – Deleted and Undoing Takes Forever

The .fbx file does seem rather resource hungry for such a simple scene. I've downloaded the .obj version for comparsion. Counterintuitively the .obj is both smaller in file size and loads much quicker despite being a ASCII text format. The reason seems to be that in the fbx import all objects are parented to empties and every object has 25 materials assigned. This increases the scene complexity and dependency graph that has to be constructed on import. The actual geometric complexity is identical, none the less the effect is quite profound since the fbx import requires 542.9 MB of memory compared to the 44.5 MB of the .obj import. The solution would be to use the .obj instead of the .fbx file.

Scene statistics .fbx

Scene statistics .obj

The light blue edges are marked as sharp.


Does Blender use Automatic Tweening/Animation?

The animation features of Blender relies heavily on keyframes and different kinds of interpolation between those. So yes, Blender does indeed use "Automatic Tweening" (but not always as cegaton mentions in the comments).

At least if "tweening" is defined as in this Wikipedia article.


You can click on the circle of the head of the inner bone.


Multiresolution subdivisions are creating curves down the middle of my model

Looks like you have internal faces down the middle (probably left over from a mirror modifier). Delete all the faces that are inside of your guy, they are on the center, right where the crease is.

You can easily remove any interior faces.

Tab into edit mode, make sure no part of your mesh is selected.
From the 3D view header Select > Interior Faces.
Switch to wireframe with Z and if you have any faces selected press X > Faces.


You need an HDRI texture for the proper reflections you are looking for. Go into the shading tab and switch from object shading to world shading (highlighted below). Add an environment texture, and assign an HDRI texture

(If you need HDRI images, one place that has  a good selection of free ones is here - https://hdrihaven.com/hdris/).

Alternatively, if you want the same ones that come with blender (used in lookdev), they are in the folder ../2.82/datafiles/studiolights/world. I think the one you used in the preview is forest.exr

Connect it up as shown below and enjoy.

For the other problem you are having, your (base) material node setup should look like this. Either add the nodes if they're not there, or if you want to just start again, hit the minus button next to the material, and add a new one.

EDIT: A SAMPLE PROJECT FOR YOU

Ok, I made a .blend project that SHOULD be pretty much the same as what you're working with. It works fine for me. Download it, and have a look, and see if it

a) it works for you, and

b) has any differences between it's settings and yours.

File is here -


What I did was use a bezier circle to curve the shape I used to cut into my sphere. A simple curve deform with Ctrl+P after selecting my imported .svg, then the circle.

As for the pattern cut into the sphere:

I first removed doubles on the imported curve after converting it to a mesh object with W>remove doubles and then used limited dissolve to clean it up a little more and recalculated normals with  Ctrl+N. Finally extruding the object to give it the thickness I wanted.

The last step for the cut itself, was joining the sphere and pattern objects as one, then going to edit mode, and selecting only the imported object and placing it where needed. Then finally, via the Spacebar menu, searched for Boolean, and the hole was cut.

Here's a little .gif showing that part of the process.

Edit in response to comment:

This will only address the first of the images and should get you in the direction of the desired result.

Add a UV sphere, in the operator panel, increase rings and segments as desired. I used 120 segments, and 60 rings. Scale along the Z axis to the appropriate shape.
Apply a decimate modifier set to unsubdivide with one iteration.

In edit mode select all face loops that will be kept.

Invert selection with Ctrl+I and then press X and delete the selected faces.

Select the face loops that should be raised with Shift+Alt+RMB and then press Alt+E>Region(vertex normals)

Tab back into object mode, add a solidify modifier, adjust to the desired thickness. Add subsurf if desired.

Using these steps you can go in a few directions and should be able to get the results you're after.


get position of object following a path via script

Use the matrix world.

An objects world matrix is calculated for every frame, to position all objects globally in the scene regardless of how it is done be it via constraints, parenting, drivers, yada yada.

To get the global location at frame f

context.scene.frame_set(f)
global_location = context.object.matrix_world.to_translation()


The number 'zero' is just a zero based enumerator (eg: 0th,1st,2nd...etc) for the material used on your polygon.
I think, that the enumerator order corresponds to it's position in the (Materials?) editor scroll box.
If you want to see '1'. Create a new material, select your object or a face of it and "Assign" (Button) the object to the second Material in the list. Re-run your script.
..oh, also "set" only contains unique values. So if all your polgons use material '0' there will only be one entry.


Well, finally, I I've found the way to "solve" it, if that could be called really an issue... It's true that Blender display badly meshes with alpha material if the map is low quality or small when I'm in the "Blender render" mode, well from what I've tested, that's what I've noticed...

However here, as I'm working with low poly assets and small maps, I just switched to "Blender Game engine" render, and by pressing "P" to have a preview of the "game", I don't have anymore those artefacts... There was as well the fact the shader was set in the shading tab to "shadeless" ! Unchecking this, is also important, even thought in this case I really want the shader to be shadeless...

Sorry for my ignorance... I guess you didn't think about that because that was too much simple...


How do I get a list of nodes in the currently active group?

There doesn't seem to be any obvious solution, so I've come up with a bit of a hack:

The trick is, context.active_node is always the actual active node in the tree the user is currently editing. context.space_data.node_tree.nodes.active (let's call it tree_active for short) is the active node for the base level (outside all groups). If the user is editing a group, tree_active will be a group node (because it was first selected+made active before the user hit Tab to edit it).

So if context.active_node is not the same as tree_active, then we know the user is inside a group. We don't know how deep they are though, so we need to recursively check if tree_active is the same as context.active_node - if it's not, then we use tree_active's node tree as the new base tree we're checking against.

If we are in a group, tree_active will always be a group node (unless it is the same as context.active_node).

Here's the code I eventually came up with:

tree = context.space_data.node_tree  # Base level tree
if tree.nodes.active:
    while tree.nodes.active != context.active_node:
        # We are in a group, check next level
        tree = tree.nodes.active.node_tree

tree will be whatever node tree the user is currently editing.


Long error message when try to extrude and input box is empty? (I can now no longer use blender)

I expect that the copy of flip fluids wasn't installed right and is causing this issue. The flip fluids addon found on github is not a simple python addon that can be copied into place, it needs to be compiled for the target system before installing.

As you have reinstalled blender, the issue would likely be in your user settings. Find the USER path for your system and move or rename the folder with the version number (2.79) to say 2.79-bad. This will prevent blender from loading anything in there.

Once blender starts without any user config files, you can try replacing some files to try and restore to where you were before the issue. In the config folder, try replacing the startup.blend, userpref.blend and bookmarks.txt. Inside the scripts, you could try replacing some other addons you may have installed if you know they belong to an addon that you can't find the original files for. If you do this a couple of files at a time you can identify any that cause the issue.


Blender Emission Without Blowing Out Texture (Eevee)

I think the usual Light Path/Is Camera Ray node would work for you. Basically, showing only the original non-emission color to the Camera and using Emission node for everything else. This allows you to increase the Emission Strength without affecting the color reaching the camera.


Your body mesh seems to have a lot of duplicate faces.  You can see this even by moving around the model in the viewport...those weird marks are the geometry fighting:

Another way to see is if you select a face on the torso and choose "Select->Select Similar->Material" and you'll get most, but not all, of the faces.

I would suggest selecting ALL of the vertices of the body model, then choosing Mesh->Vertices->Remove Doubles.  That will remove the extra geometry.

Unfortunately then you will have patches of the torso that are a different material (so they'll be purple) but you can select one of those, again do "Select->Select Similar->Material" and set them to the same material as the rest of the Torso.  Or vice versa, depending on what you want.

You might have to re-rig after removing the doubled geometry, but it will solve your rogue pieces sticking out.


I'd say the trick here is having to overlapping objects with different materials.

If you make an instance of eachoder they'll virtually be one and the same object, changes to the mesh will propagate to other clones seamlessly and each can have it's own material one with halo, other with wireframe.

Make sure you apply materials By Object instead of By Data otherwise you won't be able to have different materials per object.


How to fix the rig after weight painting

Every IK constraints has a "chain lenght" parameter, setting the amount of bones involved in the IK solution: 1 means that only the constrainted bone will try to reach the target, 2 means that the constrained bone and its first neighbour will act as an IK chain, and so on. 0 means that every connected bone will be part of the chain.

In your screenshot it looks like the Right forearm has a 0 chain, propagating the IK action until the neck-clavicle junction, while every IK should be set to 1 chain lenght.

Consider also that - generally - we use a single IK constraint to control forearm and upper arm bones, with an addictional bone named "pole" to control the elbow position: this is the "standard" method!


As written in the comments - I'm just getting old.

Gone is the purple reflection:

[edit]
Sorry for the missing details. I forgot that I wanted to use a world background image at the beginning. Therefore I changed the surface type to "image" without actually asigning one. That caused the reflections.


Using nodes would be only way to make additive blending for material.
Though If You're making a light ball in Blender Internal You don't need it. Just go to material, find Shading make Emit higher then 1, go to World, check Indirect Lighting switch Gather(right below Indirect Lighting) to Approximate and voila, You got ball, that emits light.


Rigify - what are tweak bones,and what do they do?

They allow you to deform your character with a lot of freedom.
This can be useful for cartoony animation... although if you don't go too extreme with them, you could possibly use them to create realistic motion.
I have a video where I explain a bit about them:
https://www.youtube.com/watch?v=vKgH5zXIYmM&feature=youtu.be&t=1171


How do I make those rhombic indents in this water bottle? Image in description

To make the shape, use the Mirror, Array and Simple Deform (Bend mode) modifiers:
Create a plane, rotate it, apply the rotation, subdivie, mirror:

Array it 6 times, make it bend with a Simple Deform modifier (Bend mode)

Change its shape, extrude inwards:

Give it a Subdivision Surface modifier, add edge loops to sharp the edges:

As the medium part is divided by 4 and not 6, you're going to make it apart. Draw the curve with some extrusion, delete the faces to only keep the edges:

Create another plane, subdivide it so that it has the same number of edge loops as the bottom part (18 faces), use the previous shape to cut it with the Knife Project tool:

Now again, mirror, array and bend with a Simple Deform modifier:

Extrude inwards, add edge loops:

Merge with the bottom:

Correct the shape etc:

You probably need half the edges, you can simplify whenever you want:


How to extract commands such as single dupliverts

The row of "dupli_type" options [None, Frame, Verts, Faces, Group] comes from what is called an EnumProperty. Blender uses this as a radio-box-like interface to give you a choice from a list. The item you select determines which elements of the UI become visible.

  Right-Click on the Verts button, pick Edit Source, go to the TextEditor and open
  properties_object.py it will show at the line where that UI element is  referenced.

The Duplication panel's draw is like this. Notice that the 5 possible states are covered by the if-elif-elif-elif. Notably the choice for NONE results in no drawing at all because it isn't in any of those tests. There's nothing to show in the case of 'NONE' so a 5th logic statement is redundant.

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

    ob = context.object

    layout.prop(ob, "dupli_type", expand=True)

    if ob.dupli_type == 'FRAMES':
        split = layout.split()

        col = split.column(align=True)
        col.prop(ob, "dupli_frames_start", text="Start")
        col.prop(ob, "dupli_frames_end", text="End")

        col = split.column(align=True)
        col.prop(ob, "dupli_frames_on", text="On")
        col.prop(ob, "dupli_frames_off", text="Off")

        layout.prop(ob, "use_dupli_frames_speed", text="Speed")

    elif ob.dupli_type == 'VERTS':
        layout.prop(ob, "use_dupli_vertices_rotation", text="Rotation")

    elif ob.dupli_type == 'FACES':
        row = layout.row()
        row.prop(ob, "use_dupli_faces_scale", text="Scale")
        sub = row.row()
        sub.active = ob.use_dupli_faces_scale
        sub.prop(ob, "dupli_faces_scale", text="Inherit Scale")

    elif ob.dupli_type == 'GROUP':
        layout.prop(ob, "dupli_group", text="Group")

To make a custom panel for this you need to make a custom (deputy) EnumProperty, which should include some code to update the real property.

import bpy

class HelloWorldPanel(bpy.types.Panel):
    """Creates a Panel in the Object properties window"""
    bl_label = "Hello World Panel"
    bl_idname = "OBJECT_PT_hello"
    bl_space_type = 'PROPERTIES'
    bl_region_type = 'WINDOW'
    bl_context = "object"

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

        layout.prop(ob, "deputy_dupli_type", expand=True)

        if ob.deputy_dupli_type == 'VERTS':
            layout.prop(ob, "use_dupli_vertices_rotation", text="Rotation")

        elif ob.deputy_dupli_type == 'FACES':
            row = layout.row()
            row.prop(ob, "use_dupli_faces_scale", text="Scale")
            sub = row.row()
            sub.active = ob.use_dupli_faces_scale
            sub.prop(ob, "dupli_faces_scale", text="Inherit Scale")

def register():
    # give all objects a new property (also known as an attribute)
    # called "deputy_duply_type".
    bpy.types.Object.deputy_dupli_type = bpy.props.EnumProperty(
        items=[
            ('NONE', 'NONE', "", 0),
            ('VERTS', 'VERTS', "", 1),
            ('FACES', 'FACES', "", 2)
        ],
        default='NONE',
        update=lambda s, c: setattr(s, 'dupli_type', s.deputy_dupli_type)
    )
    bpy.utils.register_class(HelloWorldPanel)

def unregister():
    bpy.utils.unregister_class(HelloWorldPanel)
    del bpy.types.Object.deputy_dupli_type

if __name__ == "__main__":
    register()

The downside in this case is that changes made back in the original Duplication Panel are not reflected in the state of your new deputy_dupli_type property. This may lead to some confusion, but if you aren't using the original panels then it isn't a problem.

Some code clarification:

update=lambda s, c: setattr(s, 'dupli_type', s.deputy_dupli_type)

The take-away from this line is (even if it looks like gibberish):

Once the user picks a different option from the object.deputy_dupli_type, this triggers the object's dupli_type attribute to be set to the same value as the newly selected option.


How do I get image handles and click&drag things around in Blender Compositor?

Do it in the 3d view?
import videos into emission shader planes and animate them.
I know it's stupid but I think it's the only way you can work graphically.

I wish that in 2.9 the Video editor thing will become Good!


Accessing image texture uv channel connected to Cycles material Image Texture

You need to use a UV Map node:

You use it like this:


Hey thanks to batfinger and cmomoney, here's the answer :

### Strips ###
for scene in bpy.data.scenes:

    if scene.sequence_editor is not None:

        strip = scene.sequence_editor.sequences_all

        if strip is not None:

works perfectly to get all the strip in the sequencer editor in any scene of your blend file ! hope it'll help for people in same situation !


Faces with more than four vertices for 3D printing

You shouldn't use ngons for printing. Not even quads. Send triangulated mesh to the printer.

Ngons (and quads) are very convenient to work with. You can use knife tool on them easily. Because of this I would recommend using F when making the model.

For export for printing, use the Triangulate modifier and the Wire and Use All Edges option for Object Display. This allows you to control how the model will exactly triangulate and how it will print. You have more control over the triangulation and you can set the same Beauty algorithm for triangulating ngons as the Alt F command does by default.

Most exporters will allow you to apply modifiers on export, so you don't have to triangulate you model in Blender which makes it easier to do changes on the model later.


Everything moves, not just the selected vertex

You're probably using Proportional Editing. This mode allows the user to make changes to vertices (or other selectables) within a given region, based on how close those vertices (or other selectables) are to the actual selection.
From the Manual:

Proportional Edit is a way of transforming selected elements (such as vertices) while having that transformation affect other nearby elements. For example, having the movement of a single vertex cause the movement of unselected vertices within a given range. Unselected vertices that are closer to the selected vertex will move more than those farther from it (i.e. they will move proportionally relative to the location of the selected element). Since proportional editing affects the nearby geometry, it is very useful when you need to smoothly deform the surface of a dense mesh.

This can be (accidentally) turned on by pressing O. It can be turned off the same way.
GUI controls in Blender 2.8x (proportional editing enabled):

GUI controls in Blender 2.7x:

(The highlighted button toggles the mode on and off)


Reduce sine wave f-curve modifier frequency?

Sorry about that, I found the answer (not for decreasing the speed of the graph editor animations as a whole (meaning f curve modifiers which can't be edited through keyframes since I've got only 1 key frame), but for sine wave functions.
The answer is reducing the Phase Multiplier below 1:


Insert new vertices into face using pyhton & bmesh

Subdivide an edge or edges.
Just as with using the UI to add another vertex to a face would require subdividing an edge.
The loop vertices that define a face, will also be a part of another faces loop verts, if connected via an edge.  Bmesh gives us a quick API into  all the loops and linked geometry of each element. In most cases these are read only.
To add a single vert to an existing faces verts, requires subdividing one edge.  Using the bmesh subdivide edges operator will ensure that the links and loops are  correctly maintained.
Simple example, using active face and subdividing the zeroth edge.
f = bmesh.faces.active # the active face
bmesh.ops.subdivide_edges(
        bm, # the bmesh
        edges=[f.edges[0]] if f else [], # zeroth edge  if face
        )

This will ofcourse add an edge also.  If another face shares the edge it will also share the newly created geometry.
How to subdivide mesh with Python and Blender 2.8?
How to use "bmesh.ops.subdivide_edges" on selected edges
import bpy
import bmesh

ob = bpy.context.object
me = ob.data
bm = bmesh.from_edit_mesh(me)

f = bm.faces.active
e = f.edges[0]

bmesh.ops.subdivide_edges(
    bm,
    edges=[e],
    cuts=1,
    edge_percents={e : 0.33},
    )

bmesh.update_edit_mesh(me)


Imported .obj just showing a black texture

You need to create a material. Blender has two different renderers, Blender internal (the old) and Cycles (the new and nowadays standard). Materials are different in these two. I suggest you pick cycles.

First, make sure you are using cycles. You find the menu in the top bar of blender.

Now, select the object and go to the Material tab. A material should be selected for the object. If it not, create it:

If the material was created for Blender Internal, you may have to press "use nodes". Now, your material is ready to accept a texture map. Press the little button with a dot to the far right of the "Color" field. In the menu that pops up, select "Image Texture".

Now hit open and browse to your texture. You have now created a material with a diffuse shader and an image texture. It should look like this:

If it doesn't show up on the model, it means your UV-mapping on the model is wrong (probably). Since the texture only works for a specific UV-mapping, you must get this right when you import.

The next step if you intend to render this is to work on the shader some more. You do this in the node editor. Your shader will look like this:


Is there a good reason to ever start modelling with something other than a subsurfed cube?

UV spheres are good. If you subsurf a cube until it is smooth, you will get a spheroid, but, not a perfect sphere. To get a perfect sphere you must start with a sphere.


Loop at intersection of two objects (script)

Bmesh bisect plane.

Here is a script that bisects one mesh with a plane and creates a new  mesh object with the intersecting edges.

In test example

Grid is a 100 x 100 grid displaced with a cloud texture via a
modifier (not applied).
Plane is a single face default plane, named "Plane".
Move plane to desired location and run script.
New object "Bisect" has the edges of the bisection only.

Still of result, since I hit stop on gif to quickly

2.8 version

import bpy
import bmesh

context = bpy.context
dg = context.evaluated_depsgraph_get()
scene = context.scene
ob = context.object
plane = scene.objects.get("Plane")

if plane and ob:
    pmw = plane.matrix_world
    face = plane.data.polygons[0]
    plane_co = pmw @ face.center
    plane_no = pmw @ (face.center + face.normal) - plane_co
    bm = bmesh.new()
    bm.from_object(ob, dg)
    bmesh.ops.transform(bm,
            verts=bm.verts,
            matrix=ob.matrix_world)

    x = bmesh.ops.bisect_plane(bm,
            geom=bm.faces[:] + bm.edges[:] + bm.verts[:],
            clear_inner=True,
            clear_outer=True,
            plane_co=plane_co,
            plane_no=plane_no,
            )
    # new object
    me = bpy.data.meshes.new("Bisect")
    bm.to_mesh(me)
    ob = bpy.data.objects.new("Bisect", me)
    context.collection.objects.link(ob)

2.7x version

Result of running in 2.79 on modified grid, using a one face plane object named "Plane"

import bpy
import bmesh

context = bpy.context

scene = context.scene
ob = context.object
plane = scene.objects.get("Plane")

if plane and ob:
    pmw = plane.matrix_world
    plane_co = pmw.translation
    face = plane.data.polygons[0]
    plane_no = pmw * (face.center + face.normal) - pmw * face.center
    bm = bmesh.new()
    bm.from_object(ob, scene)
    bmesh.ops.transform(bm, verts=bm.verts, matrix=ob.matrix_world)
    x = bmesh.ops.bisect_plane(bm,
            geom=bm.faces[:] + bm.edges[:] + bm.verts[:],
            clear_inner=True,
            clear_outer=True,
            plane_co=plane_co,
            plane_no=plane_no,
            )
    # new object
    me = bpy.data.meshes.new("Bisect")
    bm.to_mesh(me)
    ob = bpy.data.objects.new("Bisect", me)
    scene.objects.link(ob)


where is 'refresh sequencer' in the VSE of 2.8?


You can do this easily using Falloff Tracer node.
Falloff Tracer is available on Animation Nodes + Extra Nodes addon.


so, with Dupliverts:

Create your circle, create your petal, apply the rotations, parent the petal to a bone With Automatic Weight.
Select your circle, in the Properties panel > Object > Duplication, press the Verts button, enable Rotation.
Parent the armature to the circle. The petal should duplicate along the circle.
Animate the bone in Pose mode, it animates the other petals.


there are two settings viewport focal length (35, in your case) and camera focal length (30.72 in your case), 35 would be default.
on your picture i cant really see a problem, you just have zoomed out while being inside the camera so you se the fisheye-distortion of your camera around the real sensor area. if thats the problem just zoom in.
Your render should look good with 30.72 focal length. If you want ist exactly as in Viewport put it to 35 in Camera-Lens menu.
but maybe i'm missing something?
Greetings AM


Blender 2.75b fails to start on Windows 10

So the real answer here seems to be in Windows and the drivers.  The only solution I've found is that I can re-install the Operating System to get it to work.


Blender crashes when enabling "true" displacement

This doesn't explain the crash but does offer a way to work around the issue.

I noticed that your OSL script is generating a Color to pass into the Displacement. The Displacement is a Scalar value (at the moment - I believe the future incarnation of True Displacement will offer a Vector - much more versatile) and so there is no benefit in generating your displacement as a Color - it will be converted to and interpreted as a scalar value anyway.

By amending the OSL code to generate a float rather than Color, Blender no longer seems to crash :

Further to this, it appears to be specific to the type of noise used. For example, changing using 'usimplex' instead of 'uperlin' does not trigger the issue - also fine for 'cell', 'simplex', 'perlin' (without the 'u'), 'gabor', etc. all seem to work fine but for some reason 'uperlin' causes the crash - but only if you actually try to 'use' one of the elements of the color (eg, color c = noise('uperlin’, P*Scale, Time); Displacement = c[0]; causes it to crash).


How to select vertices which are overlapping?

You need to enter wire frame mode Z or turn of limit selection to visible:

 When in one of these two modes, you simple select the vertex, if you got the wrong one, select again, without doing anything.


Set origin to 3d cursor(3d cursor became the origin)

Oh, I got the answer It's really easy you just should change it to active element or individual origins.


Cycles Normal Bake does'nt bake indents that are not tapered

You're not doing anything wrong, what you want to do is just not possible to achieve with normal maps. If you look at it from the top, you can't see the sidewalls, therefore no normal information can be baked to the normalmap (the normal-information for the sides is infinitely small). normal maps can't represent height differences – only differences in the orientation of the faces.


Tilting a specific section of non-uniform curve

The easiest way to do this is just by selecting the entire top section, moving your camera to the side view using 1, 3, or 7 on the number pad, and rotating with r and transforming with g. Other than that the only thing I can think of is rigging, which might be more trouble than it's worth in t his case.


To iterate over all RNA properties you can access:

self.rna_type.properties.keys(),

In most cases you'll want to skip rna_type, which is added automatically.

Example operator which prints its properties in order.

import bpy
from bpy.props import StringProperty

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

    foo = StringProperty()
    bar = StringProperty()
    baz = StringProperty()
    spam = StringProperty()

    def execute(self, context):
        for k in self.rna_type.properties.keys():
            if k == "rna_type":
                continue
            print(k)
        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()


How can I calculate a 28.5 mm hole for a hyperboloid center opening when it's Z=0

If you want to input the radius here:

You can change your code by:
for i in range (0, num_x):
    for j in range(0,num_y):
        # nomalize range

        u = 8*(i/num_x-1/2)
        v = 2*math.pi*(j/(num_y-1)-1/2)

        x = math.sqrt(1+u*u)*math.cos(v)*uval_a/2
        y = math.sqrt(1+u*u)*math.sin(v)*uval_a/2
        z = uval_b*u

        vert = (x,y,z)
        verts.append(vert)

As explained here
The base equation is:
$$
\frac{x^2}{a^2} - \frac{y^2}{b^2} = 1
$$
Which gives:
$$
y = \pm \frac{b}{a} \sqrt{x^2 - a^2}
$$
When a and b are defined by:


This has happened to at least 3 times but seems like I don't remember it at all!
it took me a little while to figure it out.
The issue with the teddy bear is that, You have not enabled show emitter in the particle's section.
Hence the render shows just the hairs but not the bear which is emitting those hair particles!

As per the ice flakes I see a collection called sprinkles in particle selection but it seems to be deleted.
the name in the particles seems like just the cached name!


Focal length is the distance between the lens and the focal point:

At focal point the image is sharp and it's the place where the camera sensor is located (or camera film). The Field of View of each lens depends on the sensor size:

The conversion formula is this:

FOV = 2 * arctan(half_the_diagonal_of_sensor / focal_length)

Blender allows you to enter the "zoom" of camera in either Focal length (mm) or in Field of View (°):


Issue with Collada export on Mac OS Catalina

Quick update on the front - I talked with the designer working previously in the project I was struggling with. It looks like it's freezing for quite a long time (around an hour) as there are tons of animations in the file and take this long to handle them in export. I think the outcome of this is missing progress on the export process - what is surprising progress is shown when exporting to eg. .obj.


If calling key_frame_insert directly from a bone, the easy way, and it always writes to an existing action unless it needs to create it, then the answer is to just manipulate the facts on the ground.

In the simple 2nd example, you can simply assign the armature's current action to None, ob.animation_data.action = None.  These examples only have just one bone & frame though.  When I place that in the real code, there is also an empty my name.001 created. If I try adding ob.animation_data.action = actionto the first example, the same empty action is also created in real code.

Though that empty action would get removed on save / reload, it looks half-assed.  With some help from here, if you un-link the action, and rename after the new keyframes are added, you get one action every time.

import bpy
from mathutils import Vector

ob = bpy.context.object
if ob.animation_data and ob.animation_data.action:
    # save last action, so it does not get removed without user doing something
    ob.animation_data.action.use_fake_user = True

    priorAreaType = bpy.context.area.type
    bpy.context.area.type = 'DOPESHEET_EDITOR'
    bpy.context.space_data.mode = 'ACTION'
    bpy.ops.action.unlink()
    bpy.context.area.type = priorAreaType

bone = ob.pose.bones['K2-Root']
value = Vector((1, 1, 2))
bone.location = value
bone.keyframe_insert('location', frame = 1)

ob.animation_data.action.name = 'my name'


Can I have a custom "bounding box" for the near sensor?

A near sensor detects objects within a radius from the object's origin. This naturally means that it detects objects within a sphere, the size of which is determined by the "distance" field on the near sensor. You can, however, work around this spherical limitation fairly easily. Add a cube and modify it to whatever special shaped detection region that you want. (you don't have to start with a cube, you can use any method you want to get the mesh). Parent your special bounding shape to your player, and set the physics type to sensor, make it invisible, and set the collision bounds to triangle mesh.

Then, you can use two collision sensors to activate whatever your near sensors would normally do. (To connect logic across multiple objects, simply select them both). Just make sure that the property you're looking to detect is on all the objects you want to be detected. (No the property doesn't have to be filled in as "WhateverYourDetecting."


It looks like bad normals and some geometry errors in you model.
Have you tried the classic Select all > Remove Doubles > Recalculate Normals?
(A to select all > W > Remove Doubles then Ctrl + N)

You could then try to use the operator Select Non Manifold Shift + Ctrl + Alt + M to select said faces, although if they are attached to the rest of the model mesh, deleteing then will most likely create more problems for 3D printing, like wholes and discontinuities.

You could then use the Select Non Manifold operator again to detect new problems that might arise and try solve them one by one. Maybe remove doubles and recalculate normals again.


Not perfect (but imperfections are like the one we have bevelling or insetting, etc. too far), and that can also be the case with a curve and bevel object.

The principle:

Start with the first two vertices of the curve, a segment S0 = (V0, V1)
Get the location of the starting position of the // curve P0
Calculate the displacement D0 = (V0, P0)
Calculate the normal N0 = D0 cross (V0, V1)

Now iterate for 1 to n:

Get the new normal by D(i-1) cross S(i)
Get the new D(i) = S(i) cross N(i)
The location is Pi = Vi + Di

Result with imperfection (the active curve with 4 empties as starting points):

Main part of the code is the following (complete code is in the blend file below, so this snippet won't work alone).

To use it from the blend file: the curve is the active object, starting points are selected object.

def create_parallel(curve_object, from_object):
    #Get the poly spline
    poly = curve_object.data.splines[0]

    #Create the target poly spline
    target_object = create_curve(curve_object, bpy.context.scene.collection)
    target_poly = target_object.data.splines[0]

    #Get the starting location in curve coordinates
    starting_location = curve_object.matrix_world.inverted() @ from_object.location

    #Delta from the first point
    delta = starting_location - poly.points[0].co.xyz
    #Its length
    distance = delta.length
    #Keep it normalized
    delta.normalize()
    #Orthogonal direction
    ortho = delta.cross( poly.points[1].co.xyz - poly.points[0].co.xyz ).normalized()

    #First vertex
    target_poly.points[0].co = (*starting_location, poly.points[0].co.w)

    for i in range(len(poly.points)-1):
        prev = poly.points[i].co
        co = poly.points[i+1].co

        axis = (co.xyz - prev.xyz)

        #Orthogonal direction is recalculated to be orthogonal to this delta and the next curve segment
        ortho = delta.cross(axis).normalized()

        #New delta is calculated as being orthogonal to the curve orientation and the current orthogonal direction
        delta = (axis).cross( ortho ).normalized()

        #Calculate the location of the current vertex
        location = co.xyz + delta * distance
        #Assign it to the curve
        target_poly.points[i+1].co = (*location, co.w)

Improving it, should need to relax (or remove) vertices comparing the curvatures of the curves... another story...


Blender 2.90.1|Where's the UV Layout Export function?

Make sure "Import-Export: UV Layout" is enabled in the addons section of user preferences:


When I try to render, the camera renders from the wrong position

Check in the outliner to see if you have another camera in the scene.  The one that is shown in the Gif, doesn't have its triangle completely coloured in - it's just the outline of a triangle. If it's completely coloured in, it's the ACTIVE camera. With the visible camera you want to render from still selected, press Control and Number Pad 0.
That will throw you into the camera view of that camera and make it the active one.


Animation of the fabric stops and "freezes" earlier than I need to

Problem solved! :) looks like it is just a bug. Apparently it happened not only to me. To solve it you need to enter and then exit  the Edit Mode and Bake again.


Making particles grow while sticking to an object

Use Hair type instead of Emitter in Particle settings (suits all kinds of mesh deformations including armatures), it also provides object instancing.

Or stay with Newtone option, but use Lattice + Hook combo (for simple scale/rotate/locate animation).

Prepare Lattice

Add Lattice object, scale it in object mode a bit bigger than your mesh Cube. Change interpolation to Linear.

Hooking

Go into Lattice edit mode, select all vertices and press Ctrl H, select Hook to new object (Empty will be added)

Setting emitter object

Add Lattice modifier after Particle system and select your lattice object.

Animating

Now if you try to move Empty, it will engage movement for Lattice and also emitter as it is cotrolled by lattice object. So instead of animating emitter object, animate Empty.


In BGE, how do I move an object up with a motion actuator for a few seconds then bring the object back to its original area

I suggest to play an action that lifts the object.

A simple logic would be to have one sensor that measures when to block (e.g. keyboad sensor on E).

Activate an action actuator that plays the action in flipper mode. This means when the blocking request ends -> the action will be played reverse.


As a first you need to know what is your priority: time or quality? You can't have both.

This is very complex "problem" and need a lot of study. What is good in one situation may not be good in another.
Generally:

In "Sampling":

set Clamp to higher value
use "Branched Path Tracing" - check noise in every pass in compositor and adjust Samples by render pass.

In "Light Paths":

turn off caustic.
reduce light bounces.

In "Performance":

set Tilles according to your hardware (usually 64x64 for CPU, 256x256 for GPU).
tick "Persistent images" if your textures does not change in full length of animation
try using "Spatial Splits".

In Material node editor:
Use "Light path" for determine rays you don't need. For example disable shadow ray in glass can speed up render quite a lot.

I mentioned only most used features. There is not a general "golden rule" that work always and in every case. All settings depend of your scene and your preferences.

BTW: render animation about 30 hours is not unusual.


My cycle render result is far different from my viewport how can I solve it

It's something strange. On my end, the image renders properly.
On the other hand, when I render an animation this error comes.
Edit: I think the change of colours is because you rendered the animation in eevee before and then are viewing it in cycles in the viewport.


Noob Question - Why does my screen look like this?

Try each of these 4 viewport shadings, and the drop down menu will change according to the mode. From left to right: Wireframe, Solid, Material preview, and Rendered (means the scene will look close to what it will look like when you render them).


From the point where each vertical edge was at Arrow 1, in edit mode you can shift-select each of those inset vertical edges, and then hit s to scale each edge and push them inwards.  That will move just those edges and their vertices all inwards (or outwards) symmetrically.

If you're already at Arrow 2 and can't go back, from edit mode you can select each horizontal edge at Arrow 1, hit "x" to bring up the delete sub-menu, and select Dissolve Edges to eliminate them.  You can then scale the vertical edges at Arrow 2 using the process above to move them without creating any new edges.

Does this accomplish what you were trying to do?


Manuel Bastioni LAB characters are rendered pink/purple on different machines

From here I found that the missing textures should be assigned again. So selected

Blender-> File -> External Data -> Find missing files

and then went to the folder

/Applications/Blender.app/Contents/Resources/2.79/scripts/addons/manuelbastionilab/data/textures/

The issue was solved. Now to avoid this happening again you select select the Blender-> File -> External Data -> Pack all into .blend so the textures will be integrated into the .bled file and don't have to be loaded from original texture folder every time.


Python code, copy dimension from one object to another

Swap A and B

For the most part, blender works the other way. The last selected object is the active object,aka  the context.object or context.active_object used by operators. An attribute of the context object can be assinged to all the other selected objects, in the list context.selected_objects

Hence select B [C, D, E, F...] then A, A has context. The x dimension of A is set as the X dimension of B and other non active selected objects.  (and lazily A too not that it matters in this case as it is same)

import bpy
context = bpy.context
x = context.object.dimensions.x
for o in context.selected_objects:
    o.dimensions.x = x

Note: if an objects data has a zero dimension, for instance default plane in Z. there is no way of scaling to make its z dimension non zero.


Why an object looks darker after Applying Scale and how to fix it?

Blender does not fix surface normals(vectors defining surface direction) automatically when you invert the geometry so they are pointing the wrong way - to the inside of the object. The best thing to do would be to flip the normals:

Note that you need to be in edit mode and have the geometry selected. You can also reach this function from Faces menu that can be called with ctrl+f, you can just hit f once the menu is called - that's a very quick way to reach the function.

You could also use Recalculate Outside(ctrl+n) or Recalculate Inside(ctrl+shift+n) functions, however this might lead to undesired result if you have a mesh that has normals already set up in some particular way or if you are working with geometry that the automatic algorithm may not be suitable for (for example simple planes might confuse it since it cannot determine where the outside should be and if you have a few disconnected planes in one object that might be a problem). Most people will advise to recalculate normals in this situation, however it is a lot more logical to just flip them instead if you know that the problem is caused by inverting the geometry(scaling with a negative value).


How to make a clothing mesh follow an arm mesh?

To solve this:

Select your mesh and switch to edit mode
Select all using A
Hit P then choose By loose parts
Now there will be two meshes, the arm and the cloth. Select the cloth mesh and hit Alt+P then clear Parent
Select your cloth mesh then select the armature as well using Shift+ Right Click
Hit Ctrl+P and select with Automatic weighting

and this will be the result:


Subtitles or how can a text object be edited before a frame is rendered?

An application handler could be used to read subtitle data and display it by editing the text object.

import bpy
from bpy.app.handlers import persistent

@persistent
def frame_change(arg):
    print("Load Handler:", bpy.data.filepath)
    t = bpy.data.objects["Text"]
    label = ("Frame # %d" % bpy.context.scene.frame_current)
    t.data.body = label

bpy.app.handlers.frame_change_pre.append(frame_change)


Okay, I was trying to do things the hard way. I can just keyframe the Sphere itselft and move it around as I need to, withouth having to make it follow the armature.

So it's solved.


Enabling an addon calls register
The issue in new code posted is the lack of
if __name__ == "__main__":
     register()

(pretty much ubiquitous in all blender addons and UI code etc etc, or for python command line scripts) Without this conditional register() will be run on import (Worth noting on import __name__ is the module name, ie not matching "__main__").
When an addon is enabled it is imported and calls its module.register() Henceforth your code is registering a second time and throws the error on the first class registered in register method.
The conditional code is there so scripts can be tested in the text editor.
Note: another thing to look for:  for registered classes the bl_idname property is how they are known to blender.


You can use a Displace Modifier and an Empty to move the coordinates of the Texture doing the displacing. This produces the "swimming through" effect. Use the Strength slider to adjust how subtle or pronounced you want the effect to be. Keyframe the Empty as needed to get the speed you want.

You can also change your Texture Type and Size to best fit your mesh density:

Rotating and Scaling the Empty produce interesting variations on this effect. Play with it. :-)

One more thing: Here's another way to do it with the Empty coordinates using a driver, so you don't even need to keyframe. If you type #frame into an input field then the value will move with the frame. Then you can change it to frame/20, frame/30, etc. for finer increments (slower change). This method uses Python, so you can "Reload Trusted" or enable "Auto Run Python Scripts" in Preferences.


Crash when selecting GPU or clicking System in settings with RX5700XT

In the event that it helps someone else out, I think the issue was an incompatibility with a kernel update. It's unfortunate but it appears that AMDGPU lags behind Ubuntu in kernel compatibility.

The machine recently updated to Kernel version 5.3. reverted it to 5.0 which was the previous version, reinstalled amdgpu and everything is fine again.
I installed amdgpu (pro version this time) 19.50, which is the latest version as of Jan 2020.


There's a status property: aud.Handle.status

You could check it in regular intervals until the status changes to AUD_STATUS_STOPPED or AUD_STATUS_INVALID, see the API docs.


Without knowing your system specs, this answer will be a bit of a shot in the dark however, generally speaking, given a decent system with a modern architecture, your best bang for the buck will come with a "more better" graphics card. GPU rendering is an order of magnitude faster than CPU.

On my particular system, GPU rendering is 4 times faster than CPU rendering.

Think of it this way, a \$200 graphics card will likely get you better performance than \$200 in combined CPU and RAM upgrades.

There are also a dozen things you can do in Blender, not the least of which is play with the tile size (Render > Performance > Tile Size). This is just trial and error--so pick a frame, change tiles to 32x32, render, check the render time in the upper left corner. Change tiles to 256x256, repeat. Pick the faster one and try a couple values on either side -- if 32x32 was faster, compare 16x16 and 64x64. Values should be increments of base 2 (so; 2, 4, 8, 16, 32, 64, 128, 256, 512...).


The example in your Blender will help you, see.
Text Editor > Templates > Python > Operator Mesh Uv


EDITED:

A slightly more sophisticated version of the previous script, that now finds all the vertex groups of all the vertices of each polygon, isolates the most frequent vertex group and uses it to choose the correct material from the list. Also uses the method to find the material name that matches the vertex group name, as suggested by @batFINGER.

Try this (with the selected object):

import bpy

o = bpy.context.object

for p in o.data.polygons:
    # Get all the vertex groups of all the vertices of this polygon
    verts_vertexGroups = [ g.group for v in p.vertices for g in o.data.vertices[ v ].groups ]

    # Find the most frequent (mode) of all vertex groups
    counts    = [ verts_vertexGroups.count( idx ) for idx in verts_vertexGroups ]
    modeIndex = counts.index( max( counts ) )
    mode      = verts_vertexGroups[ modeIndex ]

    groupName = o.vertex_groups[ mode ].name

    # Now find the material slot with the same VG's name
    ms_index = o.material_slots.find( groupName )

    # Set material to polygon
    if ms_index != -1: # material found
        p.material_index = ms_index


Is there a way to check a blend file's integrity, and/or see a crash log?

As far as I know there is no blend "file auditing" tools, but I may be wrong.

There are however debugging options in Blender. You can launch blender using command line options to activate it's debugging tools and see if any useful output can help you pinpoint your problem. You can see all debug options at the Blender Manual

If you are on Windows you should probably also set up a batch script or a specific shortcut to automatically launch Blender with the correct arguments without having to write them manually each time.

A batch script is also useful to prevent the command prompt from closing automatically in the event of a crash, so that you can actually see what happened and read the output history. It could go something like:

start C:\Windows\System32\cmd.exe /k path\to\Blender.exe --debug-memory

Replace "debug-memory" with whatever you need like "debug-all".

If you model is not too complex (rigged, or animated or with physics) and you don't risk loosing important data you may also force flush a cleanup of settings by exporting it to a non-blender format (like OBJ, or FBX, or 3Ds) so that it is stripped of any settings, preferences or additional Blender specific data that may have gotten corrupt throughout the versions.

Remove any modifiers that you may easily add again later and export only a pure raw base mesh of your Yoda model, and then re-import it in a brand new fresh blend file, so that any settings or outdated information is left behind, and only the clean mesh data is kept, then manually recreate any modifier stack you had.

Your file may also be of use to the developers if the crashes can be reliably reproduced so they can fix any bugs that cause them, although now is probably not a good time with the start of 2.8 development just around the corner big changes are expected, and backwards compatibility won't be a priority.


Substance offers two options for normal maps, DirectX and OpenGl. DirectX is the default (normally set when you first setup a project). The difference between the two is that the green channel is inverted from one to the other. Blender expects normal maps in the OpenGl format.

There should be options in Substance Painter to export with the OpenGl format instead.

You may need to look at export presets to do this:
https://support.allegorithmic.com/documentation/display/SPDOC/Creating+export+presets


How to display armatures in front of the object?

Select armature, in Properties go to Data>Display and tick X-Ray.


That can be this kind of settings:

Base nodes (with X and Y centered from "generated" coordinates, using "vector mapping")

Take the angle through "separate X Y Z" and "artan2" using X and Y.

Get the "sin".

And compare it to Z value.

Tuning (in green above)

Multiply the angle with some value to have the wave amount.

Multiply Z to handle the wave height.

Use some value to tune the wave line height.

here a blend file for 2.8:


You are already really close to setting up a fluid simulation and have all the right steps - you're just getting caught out by the order as it's at the point where the domain is set and containing flow meshes are being initialised - so since you're creating the flow last it appears that it isn't getting linked to the domain correctly.
There are (at least) two ways of resolving this. The first is to simply switch the sequence of creating the domain and the flow - create the flow first, then position and assign the domain; the flow object should then be initialised with the fluid particles and you can run the simulation.
Alternatively, you can change the domain to object's Fluid Type to None and back to Fluid (and change Domain Type back to Liquid) - this should also re-initialise the fluid. Additionally, I've discovered that changing the cache to Final and clicking Bake also re-initializes the simulation.


How to affect displacement textures using objects?

You can parent the empty to an object or to three vertices of an object.


Press Ctrl+E and choose "Mark Seam" or "Clear Seam" from the list.
Then, in order to add a shortcut, you can do as explained here: How to assign a keyboard shortcut for a mesh selection mode?


How to make a glass material having a dotted design and lines?

How about that:

And that's the bump map for it (made in inkscape in less than 5 minutes)


The Problem was the adaptive domain. It stops simulating with a small amount of smoke. Without it, it works


I think you mean you want the children objects (i.e. the legs) to follow the parent in a delayed way like this:

To do so:

Parent the feet to the body.
Under Relations Extras in the Object Settings, check the Slow Parent checkbox and set the Offset to 10.0

This next step is optional, but if you want to prevent the feet from ever getting farther than a few units away from the body, you can add a Limit Distance constraint. Go to the constraints tab, add a Limit Distance constraint, set the distance to something around 4.0 units and set the target to the parent object:


There are many, many ways of going about this.

Possibly the fastest for this particular case:

W> Bridge edge loops
Edge select mode (⎈ Ctrl↹ Tab)
Deselect edge ring (⎈ Ctrl⎇ Alt⇧ Shift RMB)
⌦ Delete> Delete edge loops

For two spheres you might do something like this:


Undo grease pencil stroke in sculpt mode

Yes, on Blender 2.79 Grease pencil "DRAW" is more like an annotation. (Obviously you can extend it to some animation functions). But yes, If you´re on the UV editor for example, and then D+Mouse drag, when you finish, you will not be able to "undo" the action. Just END the drawing, because you´re in a supra-mode.
Supra-modes are direct override over the system in which -once you start a session with the tool- you can´t "undo" or "change tools" until you end it.

Other tools that work in the supra-mode are "C"ircle select. Once you enter into a circle select session you cannot undo. If you CTRL+Z, session ends. But you don´t undo. Then you CTRL+Z again, and Blender will take you back to the START of the "C" supra mode session select.

I work on 2.79.7B (Daily verision) and NOW you can DRAW (D) and then CTRL+Z.
Check the version you have.

Thank you if you vote me up for answer.

BFCT_Schiller


How to create a Blender shortcut for "Display files as Thumbnails"

today i found another solution to get the texture list to view in thumbnails.
 go to user prefs > file > and check : show thumbnails !

i was actually searching for a toggle between list view and thumbnail view
 but this solution is working great as well.


Not able to fill in a face between an open space

By the looks of your screenshot, you do not have at least 3 vertices selected. With only two vertices selected, F will only create an edge. To create the face, try Shift+Click-ing on each of the four faces and then pressing F to fill.

Other ways of creating a bridging face:

Alt+Click, then Shift+Alt+Click on the edges to select the "Edge Loop" on each side of the gap. This will select the two connected vertices. Once all four vertices are selected, press F.
Select all four vertices with Shift+Click. Press F3 and search for "Bridge Edge Loops" and press Enter.
Press B to box select and drag a box over all four vertices, selecting them. Press F to fill.
Change to "Edge Mode" ('2' on the number row) select both edges with Shift+Click and press F to fill. You can get back to "Vertex Mode" with '1' on the number row.

If at any time, you select the wrong vertices, double tap A (dbl-A) to deselect all.


How do I import An image with transparancy

This has a rather simple solution:

You need to connect your image Alpha (transparency) channel.
In your material, set up nodes like this and it will work.
In Eevee you also need to enable Alpha Blend.

Cycles render Engine.

Eevee render engine. Remember to enable Alpha Blend.


how do i import a texture/uv map for my model?

I'd just export the texture as a normal image format from Photoshop. Therefore the original .psd file can still be changed.
You should be able to keep the Texture coordinate - as long as you don't drastically change your texture, new exports will still fit onto your model


how to make realistic water texture in blender 2.82

You can make your own transmissive water material and tweak settings,

But i prefer to install an free addon which is included in blender, it's called cycles material library or something like that.

There are many water materials available in it.
You can find whatever that suits your needs.

You would not need to change anything if you are using cycles but IF YOU ARE USING EEVEE,

You will have to turn on screen space refraction
You will have to change blend mode to alpha blend from opaque in your water material settings


I'd find it a bit hard to animate using textures, even though I know it is sometimes done. For Project Gooseberry, I read in one of the weeklies that they were thinking about animating UVs using drivers on bones to achieve this effect for the caterpillar scene, but it didn't look all too intuitive.

My approach would be to use the traditional armature tools, combined with a shrinkwrap modifier workflow. It would be too long to explain everything, so examine the (simple) blend here:

The trick is to have the armature deform the face mesh before projecting it onto the head mesh using shrinkwrap. So all deformation happens in a flat plane, the result is wrapped onto the head with some offset. This is what it look like before projection:

And this is after:

I use the same technique for the eyes, however you can see the distorsion on the circular shapes a bit too much for my taste, so here deeper involvement would be needed. For the mouth it works a lot better:

I really quickly hacked this together to show the concept only, much more dedication needs to go into carefully weighting this, but alas, where you take this approach to is up to you.


I'm not sure I understand the question, but I'll take a stab at it anyway, and you can let me know how close I came. If you want, of course.

It seems there are two questions: 1) How to render without strange artifacts, (or just how to model this form best in general) and 2) How to fill in the top-most open face of an object like the one you have shown.

This is my best guess as to what you are wanting to know. If I'm wrong, I apologize, but this is what I'm going to focus on until I know for sure.

Regarding 1): I'm still weak when it comes to rendering advice, but I do know that clean geometry is the starting point for getting renders to look right. There are many other factors, of course, but  geometry is the starting point, and that's something I know a little bit about. So you want to start with clean geometry. This leads us into a discussion about how to model your form.

Given the uniformity of it and the vertical nature of it, I would simply draw a top-view of the entire shape using curves. But then you will want to convert those curves to a mesh object before extruding it upward. Mesh objects and curve objects can be converted back and forth between one another using the Object Menu at the top of the 3D-View while in Object Mode.

After the conversion from curve to mesh, go into Edit Mode to extrude the shape upward. As for the fill, choose to select by Edges with the Number 2 key, and then hold Alt while selecting any one of the top most edges of the shape in order to select the entire top-most edge loop. Then press the 'f' key to fill in the top side of the shape.

One final note: Rather than start all over modeling this, it might be better to select a single edge loop while in Edit Mode, using Shift-D to duplicate that edge loop, pressing 'p' to bring up the Separate menu, and then separate by selection. This will make the edge loop its own independent mesh object. You could then attempt your extrusion beginning from this new mesh object, rather than modeling a whole new curve object and converting it.

The purpose of this whole procedure, by the way, is to test your results to see if they still have the artifact weirdness from earlier. If not, then this means you have created a repaired version of your mesh by following these steps.


There is an option to get rid of those shadows by smoothing the mesh. Reason of those shadows is hard angle between faces.
Main downside of it is loosing some details along the mesh, but you can try and smooth only needed "patches".
In my example I've smoothed whole mesh by Smooth Vertex 5 times.

You can also Subdivide Smooth selected faces, but this will generate tris/ngons around selection.


Sequences API methods.

Can use API methods of class bpy.types.Sequences, from the instance scene.sequence_editor.sequences to add new strips to the VSE.  As a "rule of thumb" I avoid using operators whenever possible.  Using the API methods can reference the returned strip on creation, eg a new image strip: image_strip = sequences.new_image(...) removing the need to reference the strip by name at all.

Test script, adds an image strip on channel 1, a color strip on channel 2 and a gamma cross effect strip on channel 3.  The color strips color is set to red.  The gamma cross script uses the other two as input.

import bpy

context = bpy.context
scene = context.scene
sed = scene.sequence_editor
sequences = sed.sequences
# add an image strip
filepath = "/home/batfinger/Pictures/BGLTest.png"
frame_start = 1
frame_end = 90
# add an image strip.
image_strip = sequences.new_image("Image", filepath, 1, frame_start)
# give it a duration
image_strip.frame_final_end = frame_end

color_strip = sequences.new_effect("Color", 'COLOR', 2,
       frame_start=frame_start,
       frame_end=frame_end)

color_strip.color = (1, 0, 0)

gamma_strip = sequences.new_effect("GammaX", 'GAMMA_CROSS', 3,
       frame_start=frame_start,
       frame_end=frame_end,
       seq1=color_strip,
       seq2=image_strip)

Can reference a strip by name via sequences[name] I like to use sequences.get(name) as it will return None if a strip of that name does not exist.

If an image strip with same name is added twice, eg image_strip = sequences.new_image("Image", ...) again,  the new strip will get the suffix "Image.001" naming.  (Using the operator will do same thing, but with filename.) Can be sure of the name of new strip with image_strip.name.

An issue with your q script is what is image_file_list.


Simple answer: model them.

There are many different kinds of seams on various furniture so it is essential to have good reference photos and see clearly how they look so you can then decide what will be the most appropriate method for modelling them. The ones in the picture seem to be simple piping seams. If you Google 'piping seam', you can find pictures and even videos how they are actually made and see that it is basically exactly what is sounds like - just a pipe going around, that is sewed into the seam to hide it.

I would recommend to model furniture with correct peaces of fabric so there will be seams on your models in the places there would be seams in reality. This helps with texturing and if you have UV seams already marked it is very easy to select them in edit mode with shift+g > Seams. Once selected you can duplicate them with shift+d and separate them with p > Selection. Then you can hit alt+c and convert the edges to curves. Once you have curves it is very easy to make pipes out of them just adding some bevel and adjusting it's resolution in the curve tab in the Properties Editor:

You could also use another curve as a bevel object if you needed a more complex form. Also because you now have them as curves, you can use more complex geometry and deform it with Curve modifier to follow the shapes of these curves. This way you can model various complex patterns for classical furniture:


I'm not entirely sure what you want, but you can make a "stretchable pipe" in Blender by using Hooks:

Add a cylinder with a fill type of Nothing
Add hook to one end by pressing CtrlH> Hook to new object:

This will add an empty with a Hook modifier that you can control the hooked vertices with.
Add a hook to the other end.

Now you can manipulate the newly created empties to stretch the "pipe".


Can we parse "string" as Driver Variable?

in this method we try to identify the object that is running the driver then we access its properties ( image and file ):

we add a new property to all scene objects this property is their index in the scene objects list ( we need to run this every time we add/delete an object to the scene ) :

import bpy
for obj in bpy.context.scene.objects :
    obj["index"] = bpy.context.scene.objects.find(obj.name)

we pass only the object index to the driver to identify it and access its properties.

import bpy

def change_image(n,min,max,index):
    obj = bpy.context.scene.objects[index]
    val = int(n*10)
    if (min <= val <= max):
        filePath = obj["file"] % val
        bpy.data.images[obj["img"]].filepath = filePath

bpy.app.driver_namespace['change_image'] = change_image


I am not sure why you are worrying about selected objects. You are running code for all scene objects. If you wish to change all scene objects, that are 'MESH' type that will do it:

for obj in bpy.context.scene.objects:
    if obj.type == 'MESH':
        obj.location = (-6.0, -3.0, 0.0)
        obj.scale = (0.001,0.001,0.001)

If you wanted to run the code for every selected object it would be:

for obj in bpy.context.selected_objects:
    if obj.type == 'MESH':
        obj.location = (-6.0, -3.0, 0.0)
        obj.scale = (0.001,0.001,0.001)

The code you have

bpy.ops.object.select_all(action='DESELECT') # deselects all
if bpy.context.selected_objects == []: # checks if nothing is selected
    for obj in bpy.context.scene.objects:
        if obj.type == 'MESH': # for every object in the scene that is 'MESH' type
            bpy.context.object.location = (-6.0, -3.0, 0.0)
            bpy.context.object.scale = (0.001,0.001,0.001)
            # it changes the location and scale of the same object that
            # happened to be active before the loop started


Final

You can make your light source (Plane with Emission) 'diffused' as you want.

I've created this:

Then applied it as a Mix Factor between Emission and Transparent shader:

With this method you can create any light diffusion you want.


What is the shortcut for attribute node? In Cycles Render, also.. (see below)

If you are in the node editor,use Shift+A to add a new node, followed by I then A (Add>input>attribute).

From the properties panel you will add it under the normal rollout of your material.


No. There is not.

There are two good places to look for shortcuts. The Space menu, and the user preferences.

If there were shortcuts, they would show up there:


In the rigid body world there is a rigid body constraint 'motor', this is assigned between two rigid bodies.

What you need is:

The original wheel - active rigid body
An object to push on (a simple cube) - passive rigid body - constrained to the original wheel (hidden inside for example)
An empty - rigid body motor constraint: angular motor - also constrained to the original wheel

Now the wheel is motorised and will drive itself across the ground plane.

Hope this helps!


http://blenderartists.org/forum/showthread.php?389535-Light-shader-GLSL&p=3005199&viewfull=1#post3005199

looks like there is a example of what you seek in this thread
"
Hey, I add a few shader examples to the file: Light(1).blend
-reduce code for hemi light.
-lighting for all lightypes (use properties)

By the way will the lightype patch (with or without compatibility) find his way into official Blender in the future?

-different kinds of normalmapping like in Blender
-Vertex lighting (useful for things that don't need detailed lighting to get better performance)
-functions for all specular shading methods that are available in blender

And I make an example with lighting and a diffuse texture. I don't get it like in Blender maybe someone can help?

"

.blend inside thread


You need to have your animated model and hair object on the same layer, or it won't update in the viewport (it will work only in render).