More than 32 colours for gradients in Cycles? I'm trying to use UVW generated mapping of a lot of splines and each spline has a lot of points. I want to add gradients of colors to the meshes and I hit a limit in Cycles ColorRamp. I can't add more than 32 colours for one gradient or I get an error.

Using python and any automated way, how is it possible to have a gradient with more than 32 colours that I can map on uvw coordinates ?

I already thought of breaking curves into many polylines but I'm trying to find a clean solution on the mapping side.

Follow-up, May 2015

This question arose from a previous one answered here How to colour vertices of a beveled curve mesh without converting to mesh?

I have curves with sometimes more than 32 points and I would like to color these points without converting to mesh I insist so UVW texturing is a good way to do it. However, the gradient node only accepts up to 32 colours.

So far, I solved the problem by writing an OSL shader that parses XML data.
The shader takes a value as input, let's say a voltage, and outputs a colour for it, based on a colour map. For scientific visualisation, it often happens you want to map some values to colours. So this answers your question gandalf3, the colours are representation of values of a certain unit and I don't think we can work on a pattern here.

What's important here is that a voltage at a given point is mapped to a colour, regardless of interpolation and all. Each and every voltage point will have its colour, which can then be interpolated with the following voltage point.
A voltage point can be anywhere along the curve so what matters is the ratio. 0.0 is the start of the branch, 1.0 is the end of it. Points can be somewhere within that ratio.

When we simulate voltages, the values change over time so the colours will reflect the state of each time step.

So here's the node setup:

The example below takes this XML data – produced on the fly while reading voltage values – and converts the voltage points to colours.

<report min="0" max="100" unit="mV">
    <compartment id="0" start="0.0" end="0.2" value="12.0" />
    <compartment id="1" start="0.2" end="0.4" value="25" />
    <compartment id="2" start="0.4" end="0.6" value="10.5" />
    <compartment id="3" start="0.6" end="0.8" value="38.5" />
    <compartment id="4" start="0.8" end="1.0" value="76.6" />
</report>

And the OSL sample code (took me a while to figure out this works!):

#include <stdosl.h>

shader xml_color_mapper(float Value=0.0, string Xml="test.xml", output color Color=(0.0))
{
    // The second parameter is an XPath string
    // Example string xpath = concat("//color[@name='",Name,"']/text()");
    int report = dict_find(Xml, "//report");

    string smin = "";
    dict_value(report, "min", smin);
    float min_value = stof(smin);

    string smax = "";
    dict_value(report, "max", smax);
    float max_value = stof(smax);

    color value_color = color(0);
    for (int comp = dict_find(Xml, "//compartment"); comp;  comp = dict_next(comp))
    {
        string sid = "";
        dict_value(comp, "id", sid);
        int id = stoi(sid);

        string sstart = "";
        dict_value(comp, "start", sstart);
        float segment_start = stof(sstart);

        string send = "";
        dict_value(comp, "end", send);
        float segment_end = stof(send);

        string svalue = "";
        dict_value(comp, "value", svalue);
        float value = stof(svalue);

        if (Value > segment_start && Value < segment_end)
        {
            float ratio = (value - min_value) / (max_value - min_value);
            value_color = color(ratio*ratio, 0.1, 0.1);
        }
    }
    Color = value_color;
}

The only drawback to this method is that I need OSL and thus CPU mode. OSL isn't supported yet in Blender (2.74) in GPU mode simply because it takes time to implement it.

Now that I have written the OSL shader, there may be a way to do the same with Cycles (math) nodes.

These are some node groups to accomplish colorRamps mixing based on the UV coordinates and certain scale ( in this example it's 8 ), which give as a total of 256 color,  this is the final setup :

and these are the node groups needed :
"Equal to" node group : compare two numbers and output one if they are equal else a Zero

"Mapper" node group : remap the input ( by scaling) and output an integer number ( 0, 1, 2...) for controlling the color switches

"ColorRamps" node group : a group of colorRamps sharing the same factor input

"Decoder" node group: switch only one of the outputs to one if the input is equal to it's order

"ColorMix" node group: switch between colors based on the input if input = 5 the output will be the color-5

this will allow you to combine multiple color ramps as follow :
for this example ( scale = 8 ): colorRamp zero will be used for U coordinates from 0.0 to 0.125 ,and colorRamp one from 0.125 to 0.250 and so on. You can try any scale equal to or less than 8 .
Note : since color ramps are separate there will be no transition between them but you can fake this by repeating the last color of the previous node as the first color of the next one.
test render :


Why does outliner show a different object selected Is there a reason that the object selected in the viewport is not the object shown as selected in the outliner?

As far as I know it was intended, where in Maya it always sync, but I know there is a good reason to make it unsync, I've read about it like sometimes ago but forgot what it is, but make it unsync can be confusing sometimes.
So there is a Gsoc branch for outliner which has an options to make it sync or unsync mode between outliner and viewport, it is not in the master just yet, but let's hope it will eventually at the end.
See the discussion here :

https://devtalk.blender.org/t/gsoc-2019-outliner-weekly-reports/7642/7

https://devtalk.blender.org/t/gsoc-2019-outliner-branch-testing/7616/63


How do I snap objects to edges in version 2.79? I'm a beginner/newbie.
How do I snap objects to edges in version 2.79?
Thx for help,
Michael

Below the 3D window click on the magnetic icon to activate

Beside the magnetic icon there are type of snap. Click on it and you can find several type of snap inside it.


Printing special characters and latex using python script for geometrical diagram labeling I am trying to create figures such as this:

Or this:

This clearly requires text to be linked to objects. In addition, there is a large requirement of special characters which would most easily be handled if latex could be used to render the font used to make the text object.

I have found the following links which point me towards a direction:

SE python script text

Latex python text

However, the latex solution does not appear to work for me. I am unable to find the settings php file they claim is installed under the root folder in my ubunutu desktop, and windows is unclear as to where this file may be.

The second, perhaps minor requirement is that I would like to do this using a python script, such that the figure can be recreated easily without the ble der file, and some text performs all of the required steps.

Trying to do something similar, I found a potential solution.

You can create a tex file, convert it to a dvi file, and convert that to an svg, which blender can import via bpy.ops.import_curve.svg(). The result will be a collection of curve objects rather than text objects, so you'll have to do any text-related styling from the tex file itself, but if you're working with scripts, that might be easier anyway.

As a starting point for doing this in python, I used functions defined around line 300 of this github file (related to quite a nice math animation YT channel, incidentally). The functions themselves just pass commands to other utilities that do the actual work, but they show a process that could be used to get from tex to svg. tex_to_svg() is the core function, from which you can follow the flow to other functions as you make sense of things and adapt to your needs.

The needed utilities are pdfTex (for tex->dvi) and dvisvgm (for dvi->svg).


How can i modify a Displacement texture roughness? If i add a single  texture as a Displacement texture on Cycles, how can i modify? i had been trying with Mix but i don't get the right number, or maybe is the wrong option?

Displacement expects a number, not a color. You can see that because the displacement's input is grey whereas a color-value is marked as yellow in the Node Tree.

So you normally convert the color to a value via a RBG to BW Node. You then can use Math nodes to freely manipulate the value until it fits your needs. In your case I would use a Multiply and then play with the factor a bit until satisfied.

I've used a Voronoi Texture as a stand-in for whatever texture you want to use, so you can just swap that out.

Note: I've heard that this conversion is done automatically when you connect a color-output to an value-input. Apparently this won't lead to any problems, so you can leave out the RGB to BW node and just connect the color output to the Math input (thanks @TARDIS Maker).


How to fix brush tool for sclupting? My brush tool is not working (not even the grab one). I even tried the clip end solution, changing the values of clip start and clip end. Does anyone here have idea about what´s happening and how to fix this?

You probably need to add more geometry. Say for example you are trying to sculpt on the default cube. Select the cube, and press tab to enter edit mode. Notice how the cube is composed of just the eight corners. This means that the sculpting tools only have the 8 corners of the cube to play around with to simulate the brushes, which obviously isn't enough.

Now try adding and applying a Subdivision Surface modifier to the cube. Ignoring how it changes into a sphere, the sculpt tools now work since they can edit the existing geometry.

You can try enabling "Dyntopo" meaning Dynamic Topology in the top right-hand corner. This will add more geometry as you sculpt, but be careful as if it starts adding too much, your computer will lag.

Alternatively...You've turned the brush strength down to zero.


How to create a custom colour management profile I am interested in creating a custom colour management profile. How you can get an image that looks very different depending if you use log or film or false colour, except I want to try and create a toon profile. One that will basically take the millions of colours normally rendered and round them to the nearest colour available of say a couple hundred.
Yes I know this is possible through shaders, but this requires manual tweaking of every material for every scene and every light. For a small project sure, but not for a large project with many scenes. There has to be a way for blender to do this in a "smarter" way.

If you want to affect color globally, through a variable accessible in the color management controls, you need to create LUTs (Look Up Table), that will allow you to convert values of pixels in an image into other values. Creating LUTs has to be done in a different program, Blender has no tools for this. There are many Lut creation programs available online, DaVinci Resolve would work fine as well.
Once created, the LUT has to be saved into one of the folders where Blender stores the LUTs that constitute the color management system.
To make the LUT accessible in blender's color management, there is a file that needs to be updated with the information for the new LUT. The file is called config.OCIO. Create new definitions (or stanzas) in that file so that the new luts can be applied to the images. Creating new "looks" would work for your purposes.
For detailed instructions, please refer to the following posts:
How to make 3D LUTs and use them in Blender?
and
Can I use my 3D Luts with Flimic?
Note though that LUTs will not self adjust or analize data to convert values from scene to scene depending on varying brighness and ranges. LUTs  are static, in the sense that they will only work for a certain set of data and will not re-adjust to others. For a case-to-case conversion of parameters you would need some scripting and other kinds of trickery before you process information throught luts.


After adding a new constraint,the whole rig is broken I'm trying to rig the wing of a bird (I'm following the piero training course of the CG Cookie) and a strange behaviour is happened when I added a new constraint to the bone called "CTRL_armPole". It seems that the whole wing is broken. I add two videos,the first one is a little piece of the tutorial that I'm following,and the second one is what happens to me :

1: little piece of the tutorial

2: what happens to me

how can I fix this situation ? thanks.

change the pole angle in the IK constraint to have it pointing toward the pole target, you have to eyeball it.

Quadripedal Rigging: Twisted limbs

https://vimeo.com/171279647

The reason why the person in the tutorial didnt need to do it was probably because their bones had a different role angle (select bone in edit mode Ctrl R and rotate it) or the bones have a different rotation mode (select bone in pose mode, go to properties editor->bone->transform->rotation mode)


Outline that follows character? I downloaded an anime model off of the internet and it has this really cool outline effect that follows the rotation of the character.

As you can see, it has an outline that constantly follows the character's rotation. This is a really awesome effect that I want to learn, but I have absolutely no clue how I could. Does anyone know what it is and/or how I can do it?

You can get an outline in the viewport with a simple hack that involves a solidify modifier and a second black material.

The image contains all the setup you need. To summarize, what we are doing is:

Add a second material to the mesh you want to have the outline one, set color to black.
Add a solidify modifier with the above settings, which creates an inverted normal shell around the original mesh. Assign it the outline material using Material Index Offset.
Turn on 'Backface Culling' in the viewport so that the backface of the black outline is not visible.
To make this setup work in Blender Render and Cycles, check this answer.


load and change material with python script My script is not functioning as I would like.  I am appending a material from a file and the material is not adding to the material list.

Second I am trying to change the generated ellipsoid to a different material.  I believe this code is simply changing the name and not changing to the saved material.

I can get around the first error by manually going to append and finding the file in my downloads.

Thank you for any support.  S

import bpy

mat = 'Gold'

path = "C:/Users/ME/Downloads/78-gold.blend\\Material\\"

#ERR1
bpy.ops.wm.append(filename = mat, directory = path)

import numpy as np
loc_scale = 0.05
anisotropy = 10

for k in range(10):
    for j in range(10):
        for i in range(4):
            context = bpy.context
            scene = context.scene
            # add a sphere
            offsetx,offsety, offsetz = [0.5 , 0.5, 0.5] - np.random.random(3)

            bpy.ops.mesh.primitive_uv_sphere_add(location=(2 - k + offsetx, 2- j + offsety, -.5+ i + offsetz), rotation=( .1 - .2*np.random.random(), .1-.2*np.random.random(), .1-.2*np.random.random()))
            sphere = scene.objects.active
            # scale to (rx, ry, rz) of ellipsoid
            sphere.scale = (loc_scale, loc_scale, anisotropy*loc_scale)
            #apply scale
            bpy.ops.object.transform_apply(scale=True)

#ERR2
            bpy.context.object.active_material.name = "gold"
            activeObject = bpy.context.active_object #Set active object to variable

Set the active material not the name

The line

bpy.context.object.active_material.name = "Gold"

sets only the name of the material on the object to "Gold", not the material to the "Gold" material. Do something like this

ob.active_material = bpy.data.materials.get("Gold")

Please Note: blender is case sensitive, the material in file is either named "gold" or "Gold", there is a mix of both in your question.

Using the link / append operator adds a new material to the file. If there is another material already in blend of same name, the naming convention will append numbers to it, meaning above will only ever link the first material named "Gold" from file.

Simple API methods to link append rather than the op

How to Link/Append a data-block using the Python API?

# Append material named "Gold"
filepath = "C:/Users/ME/Downloads/78-gold.blend"
with bpy.data.libraries.load(filepath, link=False) as (data_from, data_to):
    data_to.materials = ["Gold"]
    #data_to.materials = data_from.materials #  append all materials from blend

Copy an object (and optionally its data)

Second lastly rather than call the add sphere operator 400 times, can call it once outside loop then copy and link to our collection

collection = bpy.data.collections.get("Blahs") or bpy.data.collections.new("Blahs")
bpy.ops.mesh.primitive_blah_add()
blah = context.object
for i in range(copies):
    copy = blah.copy()
    copy.data = copy.data.copy() # a copy of data (mesh) also
    collection.objects.link(copy)

Apply transforms directly to mesh

and lastly rather than the transform apply scale operator

from mathutils import Matrix
# don't set ob.scale = scale do
S = Matrix.Diagonal(scale).to_4x4() # a 4 x 4 scaling matrix

ob.data.transform(S)

Changes suggested will reduce operator calls from 801 to 1, could get rid of add primitive operator, but nuffnuff one is ok.. lol.

Related

Python performance with Blender operators


Text with cracks and a different material inside Hello everyone,
how would you recommend to do something like in the attached picture?
Basically a roundish text with some sort of cracks and a different material inside.
I guess a way would be to use a bezier curve with Bevel depth, converting it into a mesh, sculpting the cracks, duplicating it to make a second object with a different material, using boolean to make the missing parts
Do you know better ways?

As you say you could use a Boolean modifier to create the cut:

Create your 2 cylinders, give them materials, Curve and Subdivision Surface modifiers:

Create the boolean object, it's a subdivided cylinder with a Displace modifier:

Give your orange object a Boolean modifier, put it on the top of the modifiers stack:


"Start" and "exit" buttons are not working properly in blender game Screen 1
When I hover over and click the exit button it works, but when I am doing the same thing with the start button it shows an error:

line 9, in main  KeyError: 'requested item "startGame" does not exist'

Screen 2
In the second screen, when I deactivate all sensors and actuator of the exit button, the start button is working properly.

Please help me.

Mouse over text does not work, instead use a plane invible and parent it to the text (child), to make parent use Alt+P.

The plane needs to be an actor to be detected.

Use the logic on the planes:

And to change the color use cont.owner.children[0].color = [1,1,1,true].

When you use module execution mode it pass the controller to the function.

#Note that there is no imports

def start(cont):
    l_click = cont.sensors['MouseStart']
    m_over = cont.sensors['MouseStart1']
    game_actuator = cont.actuators['startGame']
    if l_click.positive and m_over.hitObject:
        cont.activate(game_actuator)

def exit(cont):
    l_click = cont.sensors['MouseExit']
    m_over = cont.sensors['MouseExit1']
    game_actuator = cont.actuators['Game']
    if l_click.positive and m_over.hitObject:
        cont.activate(game_actuator)


Screen Space Reflections in EEVEE I am struggling with understanding screen space reflections in EEVEE.

I am aware of the excellent answer to this question, however, this only talks about when an object is off screen entirely.

Maybe it is the same point (if so, I apologise), but can someone confirm for me that this is actually the correct behavior? The partial reflection seems so odd that I am having trouble believing this is how it is supposed to work.

Is the entire bottom face of the cube really supposed to be missing?

I haven't dig into the theory of the implementation yet, but I have a feeling that Screen Space Reflection is just mirroring the already rendered pixel (aka what you actually see on the screen, the screen space data).

I think that's the intended behaviour. It's an heavy approximation that on the other hand gives nice and fast results, expecially for the objects that touch the ground.

You'll have to use a Reflection Plane to get the reflections of the occluded geometries.


Baked texture without shadows I want to bake a material to an image for use in an external program without shadows but if I don't use a lamp the result is too dark. Is there a way to add light to the material without adding shadows, or is there another way of getting the material onto an image for export?

Blender provides settings for this. Use Diffuse (on) Direct (on) Indirect (on) with the rest (including shadow) turned off. This will bake only the light that directly comes from the lamp.
Alternately, you can use the "Diffuse Color" pass to get JUST the color, with no lighting at all.
A note about bake time: Baking will use your render settings, so if you have set up to render a lot of samples, baking will take a long time. Time to render is quite linear, though, so if you bake 5 samples and divide the time it takes by 5, that will be how long each sample will take, and you can use that to estimate pretty accurately how long a bake will take. You could just to 1 or 2 samples to benchmark, but there's a little bit of imprecision in how long any given sample takes. Calculating from multiple samples evens that out.

From the Manual:

Bake Modes
Combined
Bakes all materials, textures, and lighting except specularity.
Combined Pass Options The passes that contribute to the combined pass can be toggled individually to form the final map.
Ambient Occlusion
Bakes ambient occlusion as specified in the World panels. Ignores all lights in the scene.
Shadow
Bakes shadows and lighting.


Create a plane that renders nothing behind it? I'm kinda following this tutorial, but using cycles instead of blender internal. Because I'm using cycles, I had to manually set up the nodes and render layers. This image is what i'm supposed to have currently (from the tutorial):

And this is what the render result is for me:

I have transparency checked. This is my node setup and render layers:

And these are my layers:

Layer 1:
Layer 2:

Give the plane a holdout material. This should make it block everything behind it and yet be completely transparent.

I will try to update the answer with screenshots soon.


What is causing this giraffe patterning in my fur? What is causing this giraffe patterning in my fur? The hair particles don't have vertex groups controlling them.

The issue is you have too little particles (and too many children particles). The 'clump' setting makes the children particles follow the nearest parent particle direction. Since your parent particles are so few, they are far apart, and all the hairs in between are actually children particles leaning in the direction of the few 'parent' particles, and that's creating the pattern.
Increasing the amount of particles should solve the issue, also reduce the amount of children particles so the total amount of particles is still reasonable.
Increase this amount (I increased it to 20000):

And reduce this (I reduced it to 50):

Play around with the values to reach the result you want.


How can I store an animation action for later use? In the action editor, I see there's a stash option.  Is this the way to store an action for later use in animation?  If I reopoen the animation action and then click on stash again, I get an error that the action has already been stored.
What is the proper way to close an animation action (so I can work on another one) for later use?

Stash Them.
By stashing the actions we are doing little more than using the NLA as a bag to hold them, and associate them with their object.  If the object is linked or appended to another blend all the actions will come too. (Similarly with many export formats)  Pushing them down adds a track and action strip contributing to the animation result. Stashed actions do not.

Example of Action Editor above NLA Editor, with 3 previously stashed actions, Hop, Throb and Spin.  The new action "Walk" is in the slot, then stashed too.

To save an action it only needs to be stashed once.

Adding a new action to the slot in action editor automatically
stashes the prior.

The stashed animations do not contribute to the animation result.
(They are disabled by default), whereas those that are pushed down
do.

The top shown animation in the NLA editor, is the one in the slot..
(I call the active action the one in the slot, like putting a record
from your stash on the turntable. ... pushing down on the other hand
is like having multiple turntables, and some kind of mixing is
required. Would generally say if you are going to use NLA to animate
don't have one in the slot (unless editing)

Can select a stashed animation in the NLA and hit Tab to
put it in the "slot" to edit. (tweak) Shown as green in my colour scheme.

Have demonstrated editing by dragging keyframes in action editor, if
it's in the slot can also use timeline, dopesheet or inserting in 3d
view or over property field, or in graph editor to edit.


How to get the meshes name from the object name In Blender, object names and meshes names may be different, as in Cube2 and Cube.001.

Is there a way to get the meshes name from the object name using Python?

Also,Is there only one meshes node per Object?

obj.name gives you the object name. obj.data.name gives you mesh name. And yes, AFAIK there can be only one mesh per object. However there can be multiple objects sharing the same mesh data block.


Sculpting effects not showing until I switch to edit mode? I'm not very experienced with blender. I imported an .fbx-model and tried to sculpt in a few changes, but I can't see what I'm doing, because while in sculpt mode, it appears that nothing is changing at all. Only when I enter edit mode afterwards, the vertices get updated and I can see the effect. Please help!

I had this same issue and was caused by joining 2 objects together which had shape keys, after removing the shape keys sculpt mode returned to normal.


How to rotate model so it matches X, Y and Z axises Hey blender stackexchange,
I am working on a remake of a game called Assaultcube, and want to use an original gun model as a reference. I found is in usr/lib/games/assaultcube/packages/models/weapons/assault/world/tris.md2. I used a md2 to .3ds converter (there was no direct md2 to blend converter I could find) and imported it to blender. I used Shift + Ctrl + Alt + C and set the origin to geometry and set the object's location to 0,0,0. However, the gun is at a weird angle. I want the gun to be perfectly snapped to all 3 axises, but I'm not sure how. Could someone please assist me? Thanks.
Here's the blend file, I hope google drive works:
https://drive.google.com/file/d/0B6smClKpjHImOWdvVFRJT3JVSTg/view?usp=sharing

While it is not a solution all on its own, How do I construct a transformation matrix from 3 vertices? shows how to create a matrix from 3 points.  You would have to get the coordinates of 3 points (and the first 2 you would pick to match one of the axes;  The third you would want to chose such that when combined with the other two defines one of the planes.)

Then you would need to take the inverse of that matrix and apply it to the matrix_world of your model.  Then it should align the model with the world axes.


Do motion blur shutter curves work correctly? I have some problems understanding the motion blur shutter curve. I am near to the point to report a bug, actually ...

What I have done:

use any mesh or the default cube, animate it to move in any direction
go to the middle of the animation (the speed should be max there)
enable motion blur (cycles)
set the shutter curve to an extreme like from bottom left to top right

Now when you render the image, you will see ... well ... I can't tell from the image in which direction the cube is moving. Whatever I set the curve to, I can't tell the direction from a single image. Shouldn't that be obvious? Maybe I misunderstood that functionality.

This is an example of a moving cube with such a shutter curve

I can supply the blend file, if needed.

To clarify what I expected: I expected a (nearly) sharp cube with some trails to the side it is coming from.

I experimented with the shutter curve and it actually works like you expected. I have a Picture here showing tests with different shutter curves:

The white diagramm shows the curve I used for that render. As Object I took the default cube and made it glowing white on black background. I think the main trick to achive the effect that you want is to increase the shutter time to at least 1 (I used 1 for my renders) but that depends on the speeds of your objects in your scene.


Missing the circle brush in sculpt mode using Blender 2.8 When I open a new sculpt scene it works perfectly, but as I was editing my own model I must have pressed something by mistake and now it's disappeared. The green arrows are pointing to the diamater/radius/sculpt circle thingy that I'm talking about.

Also, if anyone knows the official name of that pinkish colored circle that would be very helpful, I might be able to simply find it in the UI myself if I knew what it was named... I'm calling it brush circle which is not an accurate description. :)

OK This could be a little bit issue from Users from 2.7 to 2.8
If the sculpt Brush cursor is not visible just go here.
You only need to Brush Settings and Activate the Cursor option on.
This option is in the side bar.
But it also avaliable in the header of Blender.


Parenting Objects to armature changes position So, i made this Palkia model which is made of several objects (for example the wings arms..) that i parented to the main body. Now i started rigging it for animation, but i only want the main body rigged and the other objects to follow it when posing in pose mode. Just like when you move it in object mode.
In order to achieve this i parented the objects to the armeture, but somehow this changes their position or rotation. I've included pics to make it easier to understand (to show i did it with the shoulder piece). Does someone know what i did wrong.
[1]: https://i.stack.imgur.com/4M7Z4.jpg                    Before Parenting
[2]: https://i.stack.imgur.com/YE28Z.jpg                    After Parenting

i took a closer look on the rig and this is what i found:

All objects of the character were parented to the body and had no vertex groups, only body was parented to armature and had vertex groups. They were parented to the body-object, but the armature had no influence on them still.

2. There are too many separate objects. It makes the character incredibly difficult to weightpaint. Keep the model as simple as possible - or - as complicated as really necessary.

3. There were different transformations on the model and the armature.
Im not 100% sure, but this may have caused the shoulder bug. I assume the shoulders had a transformation related to the world origin - and the armature had a transformation related to the world origin too.
When you parent the object to the armature with weights, the transformations get mixed up + there is additional influence from the rig.
Anyone please correct me, if I'm wrong.
But to avoid such errors, make sure the armature ist centered and the model as well. Also make sure you apply all transformations before parenting.

4. Loops of armor is not matching to body at some parts. That makes trouble in weightpainting. Extrude armor from body, if you can.

5. trouble with automatic weightpainting
-->arms too close to head -> arm bones deform head
--> model character in t or a pose to avoid that

You would have to parent "Ellenbogen" bones to root bone, not arms. Otherwise you get depedency cycle between those bones and that makes arm unusable.

Here is your file back: https://we.tl/t-IP1Wo7iwz9
I hope my answer was helpful and let me know if it helped.


constraining object to a triangle plane I've been looking all over the place and I can't seem to find the right constraint for this. I have a circle that needs to be constrained to a triangles area.

Limit Distance Constraint doesn't seem to work because it limits it to a sphere which can go out of the bounds of the triangle.

Limit Location Constraint doesn't seem to work because if my triangle's vertices are (0,0,0),(2.5,5,0),(5,0,0) and I max out x at 5 and y at 5 the object can go to (4.9,4.9,0) which is not in the triangle.

Any help would be greatly appreciated.

Create a new mesh shaped in the way you require the object to be constrained - in your case a single triangular face - and add a Shrinkwrap constraint to your object set to Closest Surface Point with Target set to the mesh. This will constrain the location to the closest point on that mesh. This will work for any shape of constraint.

To demonstrate, here a Copy Location constraint has been added to Suzanne to move her to the location of an empty. In addition, the Shrinkwrap constraint has been added and targetted at the triangular mesh.

Moving the Empty causes Suzanne to follow, but only within the bounds of the triangle mesh :


Use Blender VSE from Outside Blender Does Blender have an external-facing API that makes it possible to generate a VSE sequence from outside Blender?

I am working on a program that generates simple video sequences; and I'd like to be able to send a sequence (in and out marks, tracks, properties, etc.) to the Blender VSE for a final render.

The goal here is to have an automated video sequence generator that uses Blender as an engine to produce the final result. I've searched a bit and discovered MLT but would much rather use Blender if possible.

Out of the box Blender has no pre-installed API that can be accessed from the outside. Although there are 3 ways how to accomplish this.

Use BlenderAsPyModule. This is a headless blender that can be accessed and controlled from any Python Interpreter.
Use Pythons http.server module to create a custom API that you can access from other processes (even on different machines) using the HTTP protocol. You write an addon that starts the http server. and your external client can connect to it.
Use blender command line with a startup script. This will start blender run a python script and stops executing when the script is finished.

All three options have pro's and cons and depends on your specific use case what will work best.

BlenderAsPyModule I use for generating thumbnails (also animations) on a webserver of blend files that users upload. Here Blender runs inside a celery process to be sure that only one generation is happen at once.

server.http I typically for render farms or when networking comes into play or when the client has no python possibilities.

And the command line I used for simple automation tasks or when I want to do many tasks at a time (start 5 blender instances doing something)


How to highlight selected Faces in Texture Paint? Is there a way the left panel can highlight the selected faces on the right just so I can track where I am paint? Switching ack and forth between UV Editor and Texture Paint doesn't do it either.

In the UV Editor, disable the Sync UV option:

And in the Image Editor, enable the View > Display Texture Paint UVs option:


Cloth simulation breaks mesh I wanted to simulate a cloth ribbon wrapped around a guitar. After baking a cloth simulation however, the ribbon breaks into individual pieces and I have no idea why. Can you help me?

Ribbon was made by array and curve, simulation is using the "silk" preset.

When you generated your ribbon, did you make sure that the Merge checkbox on the array modifier was checked?

If it isn't checked, none of the mesh segments will actually, joined. Checking it makes overlapping vertices in the array get merged and so the result will be a single connected mesh.

For more details see https://www.blender.org/manual/modeling/modifiers/generate/array.html


I can't install an add-on (plugin) I have a problem with installing an add-on Boolean Collections Plugin

and problem is this

How i can fix this?

Installation

The addon installed fine for me, no idea why you are getting that error message.

Firstly I copied the code from link provided pasted into and ran from  text editor, to test,  no issues.

Then I saved the file as blender_collections.py into my Desktop folder, hit install addon, chose the file, once again no issue

Thought how are you getting that error message, then it twigged, if you hit the download button the file is saved as blender_2.8_boolean_collections_plugin_by_ispheria.py and there is your issue.

The file name has more than one period "." in it. This is the issue.  Only have one period in the file name before the py extension.  Python uses the dot to separate modules, and objects contained therein, eg bpy.props where both are modules.

Recommend you rename the file to boolean_collections.py and it will install.

Note

Always pays to check the homepage of the addon. In this case on blender artists forum.  The same issue has been raised.


Boids particles - setting Render as Object breaks simulation I have a boids system that moves its particles to a Goal avoiding certain objects.
This works fine when I'm testing with Render as Halo.
As soon as I change Render to an Object, or Collection, the simulation breaks and most of the particles slow down to a halt shortly after leaving the emitter.
Changing back to Render as Halo does not fix the issue.
Any idea what may be causing this?
initial state

final state with Render as Halo

final state with Render as Object

i think you changed the scale of your object, when you changed to render as object, right?
Just leave the scale as it is

and select your icosphere.
Press tab to enter edit mode, press A to select all then S to scale and scale this little guy up until you see enough and run simulation again.
result:


No splitter widget in new separate window I am new to Blender and I am trying to find my way through its interface. I want to have several windows (I mean OS windows, not Blender windows). So I create a separate window by dragging splitter widget while holding Shift.

The problem is there are no splitter widgets in the newly created OS window. So I can't have multiple blender windows in it. The new window does not have a Layout type drop down menu either. So how do I add new Blender windows in a new OS window? (Sorry if I'm using the wrong terms, but hopefully its clear what I am trying to achieve).

The reason you cannot split the windows is because you have one of your part of the User Interface maximized.

Once you go out of this maximization via pressing the "Back to previous" in the info header or by pressing Shift Space you can change your UI and create new windows.

Some other shortcuts to manipulate the User Interface.

Shift+Space, Ctrl+Up,Ctrl Down: Maximize Window under mouse
Ctrl+Left, Ctrl+Right: go to previous/next Layout


can not set the camera viewpoint? I want to use python to set the camera viewpoint but failed to do so, here is my code to render the model through python

import sys
import os
import bpy
import math
import datetime

if __name__=="__main__":

    configureBlender()
    setCameraPosition([0.49123,-2.22974,6.74501],[123.942,0.578,0.1])
    run(os.path.dirname(os.path.realpath(__file__))+'/test')

def configureBlender():
    # rendering constants
    RENDER_RES_X = 640
    RENDER_RES_Y = 480
    FRAME_NO = 1
    bpy.context.scene.frame_current = FRAME_NO
    bpy.context.scene.render.resolution_x = RENDER_RES_X
    bpy.context.scene.render.resolution_y = RENDER_RES_Y
    bpy.context.scene.render.use_border = False

def run(output_dir):
    bpy.context.scene.render.filepath = output_dir
    nodes = bpy.context.scene.node_tree.nodes
    links = bpy.context.scene.node_tree.links
    nodes['File Output'].base_path = output_dir
    bpy.ops.render.render(write_still=True)

def setCameraPosition(location, rotation):
    bpy.data.objects['Camera'].location = location
    bpy.data.objects['Camera'].rotation_euler = [math.radians(rotation[0]), math.radians(rotation[1]), math.radians(rotation[2]) ]

I don't know what is wrong with code or maybe model(anywhere to upload the model, it is 5mb)

update

for obj in bpy.data.objects:
    print(obj.name)

it prints out only one Camera object, i guess if there is only one camera, this camera must be the active camera.

Another wield thing is i changed the camera position and saved the model but it is still rendering with the previous viewpoint. so I guess maybe the code is fine but something wrong with the model.

here is my model link

Is this the entire script?  It looks like you forgot to import required modules.

import os
import math

Edit:

Er, well, I think Blender automatically does import math as *
so you'd remove the preceding math. from radians.

I believe you'd still need to import os, unless I'm mistaken about that point.

Edit  You have to define functions before you can run them in Python.  Don't know exactly what you're trying to accomplish with node tree in your run function, so I chopped that out for now, but this script at least runs.

import bpy, os
from math import *

# rendering constants
RENDER_RES_X = 640
RENDER_RES_Y = 480
FRAME_NO = 1

def configureBlender():
    bpy.context.scene.frame_current = FRAME_NO
    bpy.context.scene.render.resolution_x = RENDER_RES_X
    bpy.context.scene.render.resolution_y = RENDER_RES_Y
    bpy.context.scene.render.use_border = False

def run(output_dir):
    bpy.context.scene.render.filepath = output_dir
    bpy.ops.render.render(write_still=True)

def setCameraPosition(location, rotation):
    bpy.data.objects['Camera'].location = location
    bpy.data.objects['Camera'].rotation_euler = [radians(rotation[0]), radians(rotation[1]), radians(rotation[2]) ]

if __name__ == "__main__":
    configureBlender()
    setCameraPosition([0.49123,-2.22974,6.74501],[123.942,0.578,0.1])
    run(os.path.dirname(os.path.realpath(__file__))+'/test')


how to stick an object to another object that has a wave modifier? I want to get the black strip to follow the wave motion of the white plane above it

i tried simply linking the modifiers of the black strip to the plane, but this was the result:

Here is the modifiers i am using on the plane:

Any solutions to this?

From your second screen it seems like wrong order of modifiers ... Solidify-Wave-Subdiv ... the order on the third one is correct (Subdiv-Wave-Solidify).
Are you sure both objects use this order?

Few Loop Cuts Ctrl+R

Same modifiers

Another way ... use the Wave modifier only for Plane and for Strip object add Surface Deform modifier with Plane as target. Be sure before Bind disable Wave modifier and enable back after binding.


How can I (easily) create particles falling from the ground I am creating a very low poly, very simple rocket take off animation for a college assignment. I cannot figure out how to make particles fall from the rockets engine no matter how many youtube tutorials I follow. Frankly, I don't even know where to start with it.

Make particles fall off from the engine is a rather easy task.

you need to define some faces as the emitter, for example, the rocket engine. Assign the faces to a Vertex Group. Alternatively create a simple object (circle) that is used as an emitter, place it in front of the rocket engine, and parent it to the rocket. The extra object can be excluded from render (Particle Properties > Render > [_] Show Emitter).
add an Ico Sphere (very low-poly, just 1 subdivision in create popup dialog), scale it down to 1 cm. This is your particle object. Give it a material with an Emission to make it glow. Enable Bloom in Eevee
add the Particle System to the rocket and adjust a few settings:

type is Emitter, increase the Number of particles to something like 5000, and set Lifetime to 20 (or higher for a longer tail), Frame Start to 1, End to 200
set Velocity > Normal to 10 m/s to speed up the particles, and Velocity > Object Velocity to something like 0.482. This makes the tail a little "fringy"
in the section Physics > Forces give the particles some Damp, like 0.121, so they don't bounce around like crazy.
in Render set Render As to Object, set Scale to 1.0 (adjust if needed), and select the particle object (Ico Sphere) as Render > Object > Instance Object
if you have defined a vertex group for the emitting faces you can specify it under Vertex Groups > Density.

Have a good rocket launch!


How to recalculate bone roll in action keyframes or in pose mode I hope my title is specific enough

Is there a way to recalculate the bone roll while I am editing an action? It seems like you can only do that in Edit Mode which goes back to the rest position automatically.

I need it to work while I'm not in rest position, but while in in the Action Editor moving between keyframes or in Pose Mode at least. I need it to clear rotation with respect to the global axis somehow.

I'm semi-new to Blender, so forgive me if I have the terminology wrong. Tell me if I need to explain more.

Here's the armature after I recalculated to bones so that they are straight:

Then I clicked back into an old action and it is like this:

Consequently, I concluded that I need to recalculate the bone roll for all my key frames. Luckily, my actions are rather simple so I don't have many, but still, I can't see how to change bone roll in pose mode.

All those planes were re-rotated with 90 X rotation and 0 Z rotation to supposedly make it simpler to animate. We'll see about that! Anyway, when the roll gets messed up, all the planes get out of whack.

If you set the roll good for one pose, it will be messed up for a different pose, so I don't think it's a good approach: better set up the rig in edit mode so that every bone is parallel to the view plane (use "keep offset" instead of "connected"), then lock two rotation axis so that only the one needed is allowed. In this way you will never have planes deformations.


What is the “proper way” to make a walk cycle I’ve seen many different walk cycle tutorials on YouTube, a lot of them using different techniques, eg. walking on the spot then using NLA editor to repeat and make the root bone follow a path, or using IK foot bones to keep foot in place and moving body forward overtop,

So I’m wondering what the proper way of doing it is.

The second method I mentioned makes sure there’s no slipping but you can’t loop the animation.

So is there a “proper method”?

Thanks

You're saying walk cycle. By definition, that's going to be a loop. Cycle = loop. Therefore you're going to have your character walking in one place. Because if he were to leave that place, there would be no loop.

If, on the other hand, you needed to animate a clip of a character walking in some environment, then you would manually place each IK platform on the surfaces, alternating feet and moving the character body around. Except for cases where the character is going in a straight line with constant speed. In that case, you can get away with using a single loop and just moving the body forward. (you can do that by linking the whole armature object to an empty and moving the empty, while applying a Cycle modifier to your walk animation)


Animate the Viewport Visibility of an Object within the Timeline? I want to hide an object in the Viewport up to a certain frame in the Timeline and then make it visible (e.g. at frame 30). How can i do that?

Make your Object visible at frame 30:

You can keyframe the Viewport Visibility of an Object from within the Outliner:

In the Timeline select Frame 1
Then open the Outliner
Set your Object to Hidden
While the mouse hovers over the eye icon in the outliner, press I to keyframe the visibility.
Move on to frame 30
Click on the Eye icon again to make the object visible
Then press I again to keyframe the visibility change.

Note: If you want to achieve the same for your render, then please check the answer in here: How can I animate the Restrict Visibility property of an object?


Can not render via GPU ERROR Illegal address in cuCtxSynchronize() (device_cuda_impl.cpp:2016) All of a sudden, my system stopped rendering via GPU. It renders fine via CPU, it looks like the error has something to do directly with my graphics cards too. I have tried rendering via CUDA and OPTIX, no luck. I have tried 3 different versions of Blender (2.90, 2.91, 2.92 beta). I have reset my preferences, uninstalled, re-installed graphics drivers, roll back graphics drivers and nothing. I was able to test rendering. I ran heaven benchmark on direct x11, cinebench (Only openGL), and ran Counter Strike on high settings with no problem. I lastly ran Compubench 2.0 which I believe tests via the CUDA API. Computer specs and the error from the blender console below. Thanks to whoever can help me in this confusing endeavor.
SPECS
CPU: AMD RYZEN 7 1700
RAM: 16GB 3200
GPU: 2 x GTX 1060
MOBO: AsRock x370
ERROR
Illegal address in cuCtxSynchronize() (device_cuda_impl.cpp:2016)
Refer to the Cycles GPU rendering documentation for possible solutions:
https://docs.blender.org/manual/en/latest/render/cycles/gpu_rendering.html
Illegal address in cuGraphicsMapResources(1, &pmem.cuPBOresource, 0) (device_cuda_impl.cpp:2102)

Refer to the Cycles GPU rendering documentation for possible solutions:
https://docs.blender.org/manual/en/latest/render/cycles/gpu_rendering.html

Illegal address in cuGraphicsResourceGetMappedPointer(&buffer, &bytes, pmem.cuPBOresource) (device_cuda_impl.cpp:2103)
Illegal address in cuModuleGetFunction(&cuFilmConvert, cuModule, "kernel_cuda_convert_to_half_float") (device_cuda_impl.cpp:1971)
Illegal address in cuFuncGetAttribute( &threads_per_block, CU_FUNC_ATTRIBUTE_MAX_THREADS_PER_BLOCK, cuFilmConvert) (device_cuda_impl.cpp:1993)
Illegal address in cuFuncSetCacheConfig(cuFilmConvert, CU_FUNC_CACHE_PREFER_L1) (device_cuda_impl.cpp:2000)
Illegal address in cuLaunchKernel(cuFilmConvert, xblocks, yblocks, 1, xthreads, ythreads, 1, 0, 0, args, 0) (device_cuda_impl.cpp:2012)
Illegal address in cuGraphicsUnmapResources(1, &pmem.cuPBOresource, 0) (device_cuda_impl.cpp:2116)
Illegal address in cuCtxSynchronize() (device_cuda_impl.cpp:2016)

Solved. I yet again reinstalled my nvidia drivers, except this time I made sure Windows did NOT automatically update my drivers, and manually updated with the latest. For the record, the Nvidia driver version I am now using is 432.00.


Worms crawling under skin I wanted to create a scene where you can see a worm crawling underneath the skin of a person's belly.

I've tried it with the tools provided in Blender like the deform modifiers (mostly I tried with Cast modifier, warp modifier and partially the displace modifier) but it just doesn't look like a worm.

The cast and warp modifier do not support custom shapes, only the basic sphere, cube and cylinder.

Does anybody know how I can achieve this result? I also tried with softbody physics, but that didn't really work out well when pushing a collision from the inside, especially because the shape didn't really come through.

Is there any way I can get the form of a more abstract shape seen and shaped through another object without using shapekeys?

The whole scene is CG, so it isn't about a real video where I want a CG worm to crawl underneath the skin; its just a CG character.

You could use the Vertex Weigh Proximity modifier to control displacement.
It will use the actual shape of the mesh to correctly displace the surface.

Create a new vertex group in your "skin" mesh and add all vertex to it with a strength of $1$. Now add a new Vertex Weigh Proximity modifier, pick that vertex group, set the "Worm" mesh as Target Object and make sure to set the Distance Mode to Geometry.

After that add a Displacement modifier with weight affected by the previously mentioned vertex group. No texture is required (although you can optionally add one), just adjust strength and displacement distance values as necessary.

You can move your worm mesh around and it will deform according to both position and shape.


Body Deformates In Weird Ways When Bone is Rotated I have made a human model for my game, i have rigged it but now when I move any of the bones the player starts to deform in a really weird way, I have been searching for how t ofix it but i couldn't find anything useful, also whenever I try to move one of the bones with "g" it only starts to rotate and won't move properly.

plese help

From your Screenshot i can tell that a lot of vertices are assigned to the Vertex group/Bone from the lower arm (or the corresponding hand/fingers). You should be able to see this influence if you go into Weight Paint mode and select those bones.

First I recommend going into wireframe mode and selecting every face you know, shouldn't be influenced by these bones at all. Then hit "Remove" for the Vertex Groups of the Bones in the corresponding lower Arm and Hand. This way those Bones won't effect Areas they aren't supposed to.

After that you'll have to balance the influence from the upper and lower arm in Weight Paint Mode, so it bends in a natural way.


How do you transfer Weights? I have good weights for my upper arm on the left side, as shown, but how can I apply those weights to the upper arm on the right side. I already tried transfer weights and chose destination as the upper arm right, but it didn't work. Please help

I think what you're looking for is mirroring weights, not transfering them.

First, just for the sake of having a clean file, delete the Armature modifiers you're not using. Second, to mirror weights you need two things: that the bones are correctly named, telling Blender which are right bones and which are left bones (see Naming Convention here*), and that you have an active mirror modifier or the X Mirror option turned on in Options, in the T menu while painting weights. If you didn't have the bones named correctly when you created the Armature modifier and created the vertex groups then you need to either rename them manually in the Data menu or delete them and create the Armature modifier again, recreating the vertex groups.

So, explained in other words:

Name your bones correctly BEFORE creating the Armature modifier (which creates the vertex groups with the same names).
Have your model with an active Mirror modifier or turn on X Mirror in T menu in Options tab without the Mirror modifier.
Paint.

*Extract from Blender's Naming Convention documentation linked above:

  If you have a bone that has a copy on the other side (a pair), like an arm, give them one of the following separators:
  Left/right separators can be either the second position (L_calfbone) or last-but-one (calfbone.R)

  If there is a lower or upper case L, R, left or right, Blender handles the counter part correctly. See below for a list of valid separators. Pick one and stick to it as close as possible when rigging, it will pay off. (...)


Hair collision problem in Blender 2.8 I have been trying hair dynamics in Blender 2.81. I am using a hair particle system on my mesh. I need the emitted hair to interact and collide with the mesh. Can someone tell me how to achieve this?

I am also struggling with this.
Here you have some advice: How do I stop hair particles going through the body and the head?
Hair dynamics works, but not perfectly. In faster speed of the object, some strands always will go trough the mesh. Also there is a bug in Blender 2.8. - When the quality step (hair dynamics) is above 1, hair explodes. So, don't use this verison if you want some collisions.


How to minimize/soften the shadows? I am very beginner in Blender Cycles.
I am trying to imitate this in cycles: Easter Eggs
Not sure if this scene is CG or an actual photograph.
I have modeled the eggs (easy), now I just want to imitate the lighting setting of this scene.
I have tried adding:

One White Plane emitter above the eggs
Same Plane emitter behind the camera, directly facing the eggs.
Two Plane emitters on either sides of the camera facing the eggs.
Turned Ambient Occlusion ON for the world.

I am getting either too crisp shadows or crossing shadows but never the same as in the scene.

So my question is which lamp should be used and where ?
Please also explain why ?

I am currently here:

If I make the plain larger, the whole scene gets too bright:

You don't need much. A single large light source (the less sources the easier it is to deal with multiple shadows), and a semi-refletive surface for the ground.

Larger sources will create less defined shadows.

Why?

Do a search online the concepts of Umbra and Penumbra.

Larger sources will make the umbra be smaller than the penumbra.

(imgage source: http://www.viz.tamu.edu/faculty/parke/ends375f04/notes/sec7_5.html)

So in this case just make a large area light and let it do the magic.

For a nicer tonal reproduction use the Filmic Blender OCIO Confuguration, you can read more about it here:Render with a wider dynamic range in cycles to produce photorealistic looking images


Offset mirrored geometry I'm trying to offset the mirrored geometry procedurally.
For example, here I have some beams with two simple deforms and a mirror modifier:

But I wish to have the beams interlace and look like this:

Which I got by applying all the modifiers and manually moving one side along the x axis a bit.
I want to find a solution that doesn't involve having to apply all the modifiers, for example being able to offset the mirrored side of the geometry, is this possible?
Blend file for anyone interested:

Actually a linked duplication of your object would be simpler than any solution: Duplicate your object with AtlD, flip it on the Y axis with SY-1 and move it so that the 2 objects cross each others.
But other than that I was able to do it with the Array modifier. It looks like you can't shift the object with the Mirror modifier(?).

Create an empty close to your object.

Give your object an Array modifier, disable Relative Offset, enable Object Offset with the empty as Object.

Select your empty, flip it on the Y axis with SY-1. The object is mirrored on the Y axis.

Move the empty so that the objects cross the way you want.


Disable gravity for a single dynamic object in the BGE? I have a sphere which I use to restore dynamics on objects it collides with (by expanding to cover the shards over the course of the animation); the collided objects are "shards" of a crystal, and the sphere is a ghost so it does not affect any part of the crystals except the state of their dynamics. I have a collision node set to detect collisions with the material of the sphere, but that requires it to be a dynamic object.

I need to make the sphere unaffected by gravity during physics simulation, since there is no way to set the mass to zero, and collisions will not be detected with static objects.

This question has a similar problem, but setting the sphere to a character simply made it glitch out and not expand correctly.

In order to make an object "not have" gravity, you can move the object up at the same speed gravity pulls it down.

Connect an Always sensor to an And controller and this last one to a Motion actuator, with a value of 9.8 * mass (where mass is the value for Mass, set in the Physics tab of the Properties window) for the Z axis.


How to create big reflective dark glass Respect for all answers i got on this forum these years. From programming to blender. Now I need a bit specific help.

I need to texture my object that looks like this(black shiny glas)
or this

Tx for this(PS:I am a beginner)

If you are a beginner, an easy shader to get good results will be the Principled BSDF, it's a little different than other shaders, you can google it to know more, here is a example:

Keep in mind that if you want glossy objects to look good or realistic, you will need reflections from somewhere, in my example I used a HDRI map to my world shader, I post here to help any guys out there, but it's not a beginner node tree mind you. Essentially what you want is, a image texture to light your scene and also reflect on it.

For you to better understand HDRI maps, maybe these links will help you:

https://www.hyperfocaldesign.com/tutorials/blender-hdri-tutorial-cycles/

https://www.creativeshrimp.com/hdr-lighting-in-blender.html

https://blenderartists.org/t/beginner-professional-lighting-in-blender-2-78-using-hdri/677353

http://hdrmaps.com/blog/blender-hdri-setup/

Hope it helps,

Edit: Here's the file with a better bench topology,

Notice that for you to access the world shader, you need to click on the little globe icon in the node editor. That's where the magic happens with HDRIs.

Also I packed the HDRI maps in the blend file. But If you or anyone reading this, want some free quality HDRIS, here a great source:

https://hdrihaven.com/hdris/

Cheers,


How to change alpha value of all material in a single go? I have a blend file in which all the materials alpha value is 0.
There are too many materials for me to change the alpha value manually to 1.
Is there a way I can change alpha valuec of all materials in a single go??

Try running this script
import bpy
for mat in bpy.data.materials:
    if not mat.use_nodes: continue
    for n in mat.node_tree.nodes:
        if n.type == 'BSDF_PRINCIPLED':
            n.inputs["Alpha"].default_value = 1


Marker offset shortcut does not work In version 2.72 when tracking markers are in use in movie clip editor, normally I could move marker with offset from original position to new one in purpose to skip some frames from place where originally marker is not able to track that place. And rather to use settings in properties panel, I can also use shortcut GG to move marker with offset using mouse.

In Blender 2.77 somehow that shortcut is not working. When I want move marker pressing shortcut G I can move marker to new tracking place, but when I want move marker with just offset GG it's not working.
 And I must use panel properties to change offset of that marker.

How I can fix that problem? Maybe is some settings wrong?
 I try import shortcut settings from earlier version of blender, but that didn't help.

I had this problem.
I had accidentally locked the track in the movie clip editor dope sheet.
Once I un-padlocked it and gg worked again.


Fluid goes through effector So im trying to make a hallway with a light that's a little lower than the ceiling so fluid can flow through the crack but the fluid goes right through it. I have it set to effector. I used the knife project tool to cut the hole on top.
https://pasteall.org/blend/22b6fceb661f44e896c65db600ee82ef

The problem is that the collider's normals are inverted.
In solid view with the domain hidden, you can turn on the face orientation overlay to display the front of faces as blue and the back of faces as red.
As you can see, the collider's faces are facing inward:

To fix this problem, select the object enter edit mode, select everything, then press ShftN to recalculate the normals.
After doing this, the collider will work.

For the hallway object, be sure to tick the Is Planar radio button since the mesh is not closed.

To get the simulation fine enough to flow through the cracks, I set the domain resolution to 256.


AMD GPU Render on Ubuntu I use Blender 2.79 on Ubuntu 16.04 with an AMD Radeon RX 560 GPU. However, Blender doesn't detect my GPU as a "Cycels Compute Device". My approach is listed below:

Installation of Ubuntu 16.04
Installation of AMD GPU driver

My terminal output from  is:

*-display

description: VGA compatible controller
product: Advanced Micro Devices, Inc. [AMD/ATI]
vendor: Advanced Micro Devices, Inc. [AMD/ATI]
physical id: 0
bus info: pci@0000:01:00.0
version: cf
width: 64 bits
clock: 33MHz
capabilities: vga_controller bus_master cap_list rom
configuration: **driver=amdgpu** latency=0
resources: irq:26 memory:d0000000-dfffffff memory:efe00000-efffffff ioport:ee00(size=256) memory:fba80000-fbabffff memory:c0000-dffff

Download Blender 2.79 from Blender.org
Open the Blender User Preferences

The System Tab in the window Blender User Preferences displays None as the Cycles Compute Device.

I am not shure whether I'm doing somthing wrong or whether it is a bug.
I would appreciate any help on this subject because I would like to render with my GPU.

Solution:

Install OpenCl Packages.

For Arch Linux: libopencl and opencl-amd


How to rotate a bone using python I have a bone, which i need to rotate. It has to be done on a server all the time, which means, that it would be nice to avoid clicking on the bone.

I understand that i need to use:

bpy.data.objects['Armature'].pose.bones['Bone'].matrix_basic[0]

allthough i might be wrong.

After the bone is rotated, I need to Keyframe the rotation, how would i go about this?

I assume you are rotating the bone in pose mode, for this you can use the following lines:

import math
import bpy

ob = bpy.data.objects['Armature']
bpy.context.scene.objects.active = ob
bpy.ops.object.mode_set(mode='POSE')

pbone = ob.pose.bones[bname]
# Set rotation mode to Euler XYZ, easier to understand
# than default quaternions
pbone.rotation_mode = 'XYZ'
# select axis in ['X','Y','Z']  <--bone local
axis = 'Z'
angle = 120
pbone.rotation_euler.rotate_axis(axis, math.radians(angle))
bpy.ops.object.mode_set(mode='OBJECT')
#insert a keyframe
pbone.keyframe_insert(data_path="rotation_euler" ,frame=1)

the code from this wiki page , it contains useful scripts for batch job


Can you paint multiple texture layers simultaneously? There are tons of textures on the web that provide different images for color/albedo, reflectivity, bump, normal maps, displacement maps, etc... Suitable for PBR shaders, for example.

I'd like to be able to paint on a mesh in 3D using stencil or clone such that all of the source layers get transferred to the appropriate destination layers subject to the UV map.  I.e. A single brush stroke transfers correctly transformed texture layers to my object.

Can Blender do this?  If not, are there any plugins for this?

I believe other programs (substance painter?) do this. But I'm hoping to stick with Blender for now?

I believe you are looking for a mix of Sculpt Mode and Texture Paint mode. They work similarly as ZBrush, allowing you to sculpt in high poly mode, export a normal map, and also paint the UV maps directly over the model. There is no need for extra plugins, Blender does that natively. Just click on "Object Mode" and try the other modes.

You might also try Sculptris, by Pixologic. It's freeware (gratis, but not libre), like a very bare-bones version of ZBrush.


View Reference Images In All 3d Views I recently watched a video on YouTube that used two images simultaneously for front and side views. The images don't disappear when the speaker moves around the 3d-viewport. It's a little difficult for me to explain it in words, please watch the video to look at the image orientation.

I would love to know how that kind of image reference would be possible, because when I load any images they're only visible in one view and disappear when I switch the view.

Please let me know if any more information is required.

I guess, that is not the case, he is using one image for the front view and one for the side view and as he is switching between views using a short key so its look like he has background image for every view

Background image is disappeared in many views, take a look below:


How to compare modifiers with python? I'm writing a quick 'n dirty script to create a render-visibility based stop motion animation. In order to optimize things, I'd like to merge objects which have the same modifier configurations.

Unfortunately, I haven't found simple/clean way to check if two objects' modifiers are identical (or mostly identical; if the only way to do it is by comparing each setting of each modifier, I only care about settings which apply to the render).

How can modifiers be compared?

A function that returns True if all the properties of mod1 match mod2

def mod_equality(mod1, mod2, ignore=["name"]):
    return all(getattr(mod1, prop, True)
             == getattr(mod2, prop, False)
             for prop in mod1.bl_rna.properties.keys()
             if prop not in ignore)

Edit: added an ignore list.

Simple test in console, Cube with Subsurf modifier and copied.

>>> m1
bpy.data.objects['Cube.001'].modifiers["Subsurf"]

>>> m2
bpy.data.objects['Cube'].modifiers["Subsurf"]

>>> m1 == m2
False

>>> def mod_equality(mod1, mod2):
...     return all(getattr(mod1, prop, True)
...              == getattr(mod2, prop, False)
...              for prop in mod1.bl_rna.properties.keys())
...
>>> mod_equality(m1, m2)
True

A method to see if one object has same modifiers, all with same settings and in same order as another object

def same_modifier_stack_ordered(obj1, obj2):
    return all(mod_equality(m, obj2.modifiers[i])
                for i,m in enumerate(obj1.modifiers))


Materials are staying the same as another object even if changed I try to change a material in Blender and it stays the same as another object. When I change the material appearance of the other object, it will also change the material that I set for the other one.

You are not setting the material in the correct place. The tab you have set the material is for the material override, which sets all object on the render layer to the same material.
See https://docs.blender.org/manual/en/latest/render/post_process/layers.html

Instead you should clear the material from there and set it on the materials tab (the one with the ball symbol). See https://docs.blender.org/manual/en/latest/editors/properties_editor.html#tabs


Align to face normal vector Help me rotation new object by normal a face other object.
I have code that works half.
The axes at the selected polygon and the new object must be the same

code - http://pasteall.org/632513/python

scene - http://pasteall.org/blend/index.php?id=48131

code - http://pasteall.org/632513/python

scene - http://pasteall.org/blend/index.php?id=48131

Align to vector using  Vector.rotation_difference(v)

Altered the script from this answer to find the quaternion rotation difference between the local z axis of the edit mesh and the normal of its selected (active) face.

Run script with target object in edit mode, one face selected and active. An object in scene named "Cube.001" will be located at face centre and oriented by face normal.

import bpy
from mathutils import Matrix, Vector
import bmesh
context = bpy.context
obj = context.edit_object
mw = obj.matrix_world.copy()
bm = bmesh.from_edit_mesh(obj.data)
# for this example jmake a face active
face = bm.select_history.active
o = face.calc_center_median()
# calculate the axis dif in local coords

axis_src = face.normal
# local z-axis
axis_dst = Vector((0, 0, 1))

matrix_rotate = mw.to_3x3()
matrix_rotate = matrix_rotate * axis_src.rotation_difference(axis_dst).to_matrix()
matrix_translation = Matrix.Translation(mw * o) #

obj2 = context.scene.objects.get("Cube.001")
obj2.matrix_world = matrix_translation * matrix_rotate.to_4x4()

Result of script. Moved cube in edit mode, showing local coords.


How can I make triangle using mapping nodes? I have a custom texture and need it to appear in triangle shape I know that I can use few Mapper nodes to make triangle or circle or any other shape but I don't know what other nodes I need to use to make a formula for triangle. Can anyone help me?

I'm "math disabled" ;) so this is my dumb version of triangle.

You can change Rotation in Mapping nodes as well as values in math nodes to achieve different triangles.

What it does is basically creating 3 black&white planes and then rotating them and offsetting.


How do I subdivide a cube? Just installed 2.91 and I'm having a hard time finding some really basic questions answered.
Subdividing Primitives.
If I create a cube primitive how do I make it have 3 subdivisions on the X, 5 subdivisions on the Y, and 300 subdivisions on the Z.  Other programs have a dial or something.  I can't find it.
How do I make a primitive sphere with 41 subdivisions.  How can I see how many times the sphere is subdivided and change it when I change my mind.  I can see the number of faces but then I have to think.  I want to be able to ...again...dial a specific mesh density before it's editable.  Is that possible?
How do I select a ring of faces?  I found the grow and shrink selection but for the life of me...
I spent all yesterday doing tutorials and stuff but I'm brand spanking new.  And I think my questions are so basic that they don't get covered as much.  Or maybe I accidently deleted a toolbar.

For subdividing a cube non-uniformly: your best bet is using the Loopcut Tool ⌃ Ctrl + R in edit mode and then Scroll to add more segments). Some of blender's primitives don't have the options you want like other software does.
To add flat divisions uniformly: when in edit mode, press A to select all components and then RMB >Subdivide (destructive operation, can no longer edit after activating a different tool). As long as you don't perform any operations afterwards, you can expand the little properties panel in the bottom left to control how many subdivisions you want.
For non-destructive smooth subdivision levels:
⌃ Ctrl + 1 for SubD level 1 ⌃ Ctrl + 2 for SubD level 2, etc. Using this hotkey simply adds a subdivision surface modifier and pressing different hotkeys for different levels simply changes the level of that exact same modifier. You can access this modifier from the Modifiers Panel on the right (little wrench).
For selecting ring of faces: Switch to Edit, then Face mode. ⌥ Alt + LMB  in between two faces to determine the direction of the loop. Add Shift to select more face rings or deselect existing ones.


How to update my blender without losing all my settings on mac How do i update to blender 2.91 on Mac
i currently have version 2.83. How do I update to version 2.91 useing Homebrew?
without overwriting

Just copy the startup.blend and the userpref.blend to a different folder, update blender,  and copy the preferences back to the original folder. See How would I import/export Blender's preferences?


EnumProperty fill dynamically using callback Fellow pythons, greetings. I am trying to create a dynamic Enum property that lists all objects on the scene with a certain custom property. However, whenever a new object is created on the scene (and thus enum is changed automatically including the order of the items in it), it shuffles the values of already selected properties and breaks my whole script workflow. Is there a way to avoid that or use anything else to perform a similar task?

Here is my code:

###############################
## Portal plane
###############################

def GetGroupObjectsReferences(self, context):

    groups = []
    groups.append(('0', "None", "")) # setting a default entry as a first element of our enum

    for obj in bpy.context.scene.objects:
        if obj.WowWMOGroup.Enabled:
            groups.append((obj.name, obj.name, ""))

    return groups

'''
def UpdateFirstGroupObjectReference(self, context):

    if context.object.WowPortalPlane.First == context.object.WowPortalPlane.Second and context.object.WowPortalPlane.First != '0':
        context.object.WowPortalPlane.Second = '0'

def UpdateSecondGroupObjectReference(self, context):

    if context.object.WowPortalPlane.Second == context.object.WowPortalPlane.First and context.object.WowPortalPlane.Second != '0':
        context.object.WowPortalPlane.First = '0'
'''

class WowPortalPlanePanel(bpy.types.Panel):
    bl_space_type = "PROPERTIES"
    bl_region_type = "WINDOW"
    bl_context = "object"
    bl_label = "Wow Portal Plane"
    bl_options = {'DEFAULT_CLOSED'}

    def draw_header(self, context):
        layout = self.layout
        self.layout.prop(context.object.WowPortalPlane, "Enabled")

    def draw(self, context):
        layout = self.layout
        row = layout.row()
        layout.enabled = context.object.WowPortalPlane.Enabled
        self.layout.prop(context.object.WowPortalPlane, "First")
        self.layout.prop(context.object.WowPortalPlane, "Second")

    @classmethod
    def poll(cls, context):
        return (context.object is not None and context.object.data is not None and isinstance(context.object.data,bpy.types.Mesh))

class WowPortalPlanePropertyGroup(bpy.types.PropertyGroup):
    Enabled = bpy.props.BoolProperty(name="", description="Enable wow WMO group properties")
    First = bpy.props.EnumProperty(items=GetGroupObjectsReferences, name="First group", description="First group")
    Second = bpy.props.EnumProperty(items=GetGroupObjectsReferences, name="Second group", description="Second group")
    PortalID = bpy.props.IntProperty(name="Portal's ID", description="Portal ID")

def RegisterWowPortalPlaneProperties():
    bpy.types.Object.WowPortalPlane = bpy.props.PointerProperty(type=WowPortalPlanePropertyGroup)

def UnregisterWowPortalPlaneProperties():
    bpy.types.Object.WowPortalPlane = None

Thank you in advance for help.

Since Blender 2.79 you can do the following.

###############################
## Portal plane
###############################

def is_wowgroup_enabled(self, obj):
    return obj.WowWMOGroup.Enabled

class WowPortalPlanePanel(bpy.types.Panel):
    bl_space_type = "PROPERTIES"
    bl_region_type = "WINDOW"
    bl_context = "object"
    bl_label = "Wow Portal Plane"
    bl_options = {'DEFAULT_CLOSED'}

    def draw_header(self, context):
        layout = self.layout
        self.layout.prop(context.object.WowPortalPlane, "Enabled")

    def draw(self, context):
        layout = self.layout
        row = layout.row()
        layout.enabled = context.object.WowPortalPlane.Enabled
        self.layout.prop(context.object.WowPortalPlane, "First")
        self.layout.prop(context.object.WowPortalPlane, "Second")

    @classmethod
    def poll(cls, context):
        return (context.object is not None and context.object.data is not None and isinstance(context.object.data,bpy.types.Mesh))

class WowPortalPlanePropertyGroup(bpy.types.PropertyGroup):
    Enabled = bpy.props.BoolProperty(name="", description="Enable wow WMO group properties")
    First = bpy.props.PointerProperty(type=bpy.types.Object, poll=is_wowgroup_enabled, name="First group", description="First group")
    Second = bpy.props.PointerProperty(type=bpy.types.Object, poll=is_wowgroup_enabled, name="Second group", description="Second group")
    PortalID = bpy.props.IntProperty(name="Portal's ID", description="Portal ID")

def RegisterWowPortalPlaneProperties():
    bpy.types.Object.WowPortalPlane = bpy.props.PointerProperty(type=WowPortalPlanePropertyGroup)

def UnregisterWowPortalPlaneProperties():
    bpy.types.Object.WowPortalPlane = None


Disable shadows while Weight painting Hello dear Blender community!

How do I remove those shadows while painting in Weight Painting Mode?... I can't see what I'm painting... I tried to change the lamp mode to "Hemi" but this only works in Object mode...  I put a picture bellow.

For your first problem, try pressing Z to switch to wireframe or solid mode. You are in material mode, which does do the shadows. See here for all of the modes.


How to perform Mesh/Sort Elements for objects through Python? I've many objects that i need to Sort its faces with the same criteria(As example according to VIEW Z Axis.
I do iterate through selected objects through:

import bpy
for obj in bpy.context.selected_objects:
bpy.context.scene.objects.active = obj

but haven't succeeded performing the view dependant part.

The answer is in your picture. I modified the Simple Operator template:

import bpy

def main(context):
    for obj in bpy.context.selected_objects:
        if obj.type == 'MESH': #make sure its a mesh
            context.scene.objects.active = obj
            bpy.ops.object.mode_set(mode='EDIT')
            bpy.ops.mesh.sort_elements(type='VIEW_ZAXIS') #this is what you're looking for
            bpy.ops.object.mode_set(mode='OBJECT')

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

    @classmethod
    def poll(cls, context):
        return context.active_object is not None

    def execute(self, context):
        main(context)
        return {'FINISHED'}

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

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

if __name__ == "__main__":
    register()

Press spacebar in 3D viewport and type Simple Operator in the text field.


How can I make transparant objects with a png texture I'm new to Blender, and I have imported a file with a number of vertical planes on which I have put a transparant tree texture, see picture. The planes are intersecting and I have put a png with alpha channel on it However, whatever I try in the material editor, the I can't make the polygons transparanet so that only the tree image is shown. I must oversee something obvious, but does anybody have any idea on how to fix that?

(This answer is for Blender Render, not Cycles, as you seem to have that renderer enabled in your screenshot).

First, on the texture settings panel, look for "Influence" and put a checkmark on "Alpha":

Then, back on the material settings panel, put a checkmark on "Transparency".

Finally, and this is a key step, set "Alpha" to zero here on the material transparency panel.  Think of this as a kind of minimum alpha for the material: The provided texture can make it more opaque, not less.

The results should work in the Material and Rendered viewport shading modes, and if you've selected the same image as the active image in the UV editor, it can work in the "Textured" viewport mode as well.


Eevee: Light leaking into adjacent walled-off room I have a scene with two rooms next to each other. On the left, there's a corridor with area lamps emitting light. However, that light is passing through into the adjacent room. I've tried using different light probes but there isn't enough insight on those yet for me to understand them.
Example from inside corridor:
Green - light from area lamps
Red - incorrect passes into engine room

Example from inside adjacent room:
Green - light from area lamps
Red - incorrect passes into engine room
Yellow - light leakage

Here's an outside view of the two rooms:

Is there a fix for this? I'm aware that this is only a beta and this may be a bug that is going to be patched, but I'm also aware I might be doing something wrong here. I appreciate any answers in advance!

could have to do with this issue eevee is currently having with light https://developer.blender.org/T57752


Any way to fix this cylinder? I messed up along the way and I do not want to have to start over any way to fix this mistake without deleting the cylinder?

Ok to turn my comment into an actual answer:

Within Edit Mode:
Select the vertices you want to delete by pressing C and clicking LeftMouseButton on the ones you wish to delete. Use the mouse wheel to change the size of the brush(press rightmousebutton confirm selection), OR use the box-select tool, B, and drag. Afterwards press X, then V.Then you'll want to exturde the top ring of vertices using ALT+Right click, which is used to select loops.
 do ALT+RightMouseButton anywhere between two vertices on the top loop to select the loop(the red lines illustrate some examples of where you can ALT right click). Once selected press E to extrude. It will be automatically stuck along the local Z axis. If you don't want that press Z again. Press LeftMouseButton to confirm placement.

Related Links:
https://www.blender.org/manual/modeling/curves/editing/introduction.html?highlight=extrude#extending-curves

How to extrude outwards?

https://www.blender.org/manual/modeling/meshes/mesh_structures.html#loops


Change sequencer image strip filename through python i'm trying to access and change the filename of image strips in the sequencer for a little addon i'm developping, but i'm stuck with invalid syntax, i think, and i can't find the correct way to put that... Here's what i've got so far :

import bpy

for scene in bpy.data.scenes:

    if scene.sequence_editor is not None:

        strip = scene.sequence_editor.sequences_all

        if strip is not None:
            for obj in strip:
                if obj.type == 'IMAGE':

                    obj.elements.Sequence_Element.filename="ok"

But last line doesn't work... Does anyone have an idea about that ? Or know the correct way ? Thank you very much !

The Sequencer Strip has a name property, which is assigned by the user in Blender. It also has an SequenceElement list which contains all "file" elements of that strip. (Especially with image sequences you have multiple files.) We need to access the SequenceElements filename property. Image strips only have a single SequenceElement which will be indiced with 0.

The correct code is:

import bpy

for scene in bpy.data.scenes:
    if scene.sequence_editor is not None:
        strip = scene.sequence_editor.sequences_all
        if strip is not None:
            for obj in strip:
                if obj.type == 'IMAGE':
                    obj.name = "ok"
                    obj.elements[0].filename = "ok.png"


Is there something like Layout.template_fileselector? I'm writing an export script and I want the user to be able to export the currently selected object. The real script is finished but now I want to finish my UI. For this I want to display a fileselector like this:

So here is what I got so far:

class MHMDLExporterObject(Panel):
    """
    This exports the current object
    """

    bl_label = "Export My Stuff"
    bl_space_type = "PROPERTIES"
    bl_region_type = "WINDOW"
    bl_context = "object"

    # can I let it write into this property?
    dir = StringProperty(name="Export path", default="C:/tmp/",
                                description="Export which objects?",
                                subtype='DIR_PATH')

    def draw(self, context):
        from .constants import OP_exportMHMUIdent
        layout = self.layout
        col = layout.column()
        from .constants import uvResultIdent
        if hasattr(context.object, '["%s"]' % uvResultIdent):
            uvL = col.prop(context.object, '["%s"]' % uvResultIdent, text="UV Layer")
            uvL.enabled = False
        else: #property doesn't exist
            col.label('To preselect an uv-layer to export')
            col.label('you have to create a Custom Property')
            col.label('with the name %s.' % uvResultIdent)
        from .constants import OP_uvPromtpIdent
        col.operator(OP_uvPromtpIdent, text='Select the uv-layer to export')
        ## here is wher I want to get display a fileselector that writes the
        ## current value in self.dir (see above)

It's not possible to use a path variable from inside the Panel to achieve this effect. The fact that the used path is either used per object or per scene on the other hand offers a great workaround:

In your __init__.py-file you need the following code:

from bpy.props import StringProperty

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

    # assigns a propery someName to every object.
    # If you want one var per scene use bpy.types.Scene
    bpy.types.Object.someName = StringProperty(name="Exported Layer",
        description="The UVLayer that will get exported",
        subtype='DIR_PATH') # so blender notices that as
                            # a directory path

if __name__ == "__main__":
    register()

Now you can use that variable inside yor panel:

from bpy.types import Panel

class MyExporter(Panel):
    """
    This exports the current object
    """

    bl_label = "Mobster Hunter"
    bl_space_type = "PROPERTIES"
    bl_region_type = "WINDOW"
    bl_context = "object"

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

        # use either context.object or context.scene and
        # the same name
        col.prop(context.object, 'someName', text='Export directory')


Values from system console I have values printed in a system console in long lines and the lines are split to fit the window.
Is there a way to copy the values without breaking the lines?
I'm using windows 10

Consider changing the [width] property from the properties of your console.  You need to know the length of the longest line by inspection.

Under MS Windows it is done with the properties panel as depicted below.
Your OS was not specified.

Blender output seems wrapped to the current width of the console.

You can also consider changing your print statements to some some other function which writes text it to a file, append, open and close.  File Redirection may be possible.  I am not currently using Linux/Variants but in some programs one may choose the console.


can't get out of wireframe mode for some reason my mesh is only visible as a wireframe. I would like to get it back to a solid or textured view. Any suggestions?

TL,DR:

In your screenshot, check Maximum Draw Type. You have it at Wire. Change it to Textured.

Long version

Max. Draw Type (as you have noticed) allows you to reduce the visualization quality at the object level.
It is useful to control the level of detail while you're editing your scene. Set objects you don't want to bother with to Wire or even Box, and keep those you want to see in full detail Textured.


Cycles Render reduces workspace by strange cube When I render an image it gets cropped by some kind of cube, making all objects outside invisible. The top view is what I want, the bottom what I get

Do you have any ideas about the reason or the solution?
There is no such cube in my project.

EDIT: Moving everything around (by pressing A and G) changes position of project inside this "room", but does not solve the problem due to animations that would need to be moved separately keyframe by keyframe.

It seems like there is some hidden object in your scene that is not visible in the viewport but still appears in your render.
With the mouse cursor over the 3D view, press Alt + H to unhide all objects in the current scene


Shadow Catcher is Lighter than Rest of Scene In Blender 2.79b, I'm trying to render this motion tracked scene with a simple cube then a plane as a shadow catcher. But when I render it, the shadow catcher is invisible but seems to be brightening the area it is in. You can clearly see it with the bright square under the cube. I'm pretty new to Blender so all help is welcome.

I cannot figure out what's causing this.

The scene in 3D viewport:

Node tree:

I came across this thread when searching for a solution to the same exact problem as the OP. I tried various fixes, included the "simplified" node set up mentioned above by cegaton. Nothing worked.

The node setup posted by bmanner is the same node setup I get when I use a shadow catcher plane in Blender 2.79b (Mac version). I'm a rank beginner with nodes, so reducing the three "inputs" down to the two shown in the fix was not working for me.

Through all the playing around, however, I did find a very simple fix. By checking the "clamp" checkbox in both of the "add" nodes, everything renders properly. The shadow catcher no longer brightens everything it touches. No other aspect of the scene seems to be affected in the render. No idea why or how this works, but it does.

I realize this is an old thread. Since I haven't seen this solution anywhere else, I figured this would be a good place to mention it. The OP's screen shot is attached, with the boxes noted. I hope this helps someone.


How can I get Blender to snap vert using grab command? So I am taking a short course modeling house on Udemi. I noticed that when I use extrude command it is very easy to snap to another vert. However, at one point we need to subdivide (basically one vert missing) to help with making a wall. The teacher just grabs this vert, constrains it to x and snaps it in-line with another vert.
My blender will not do that, even if I have the same snapping settings on as the teacher's Blender.
Blender seems not to notice the vert I want to snap to while grabbing, but if I extrude from another place it snaps to it with no problem.
Then I tried to move a door opening to have it in-line with another door, but it will not snap. If I extrude from a vert, it snaps where I want it to snap within second.
My settings are: Snap on, vertices, closest, and snap onto itself.
Am I missing some settings or is this a bug?

The problem is that you have proportional editing on, press O, or the blue dot at the bottom of the viewport to turn it off (see circled in red)
You also might have forgotten to turn auto merge on (circled in blue), as you seem to have 4 vertices overlapping. To remove them, select everything (A) and use the Remove Doubles function (Press space and search up Remove Doubles).


Is there a way to temporarily parent a vertex group to a bone? How can you temporarily parent certain vertex groups to bones? Something like the "Child of" constraint but with vertex groups instead.

You can parent using the following steps:

Select the mesh then select the armature
ctrl+P then parent with empty groups

After that once you want to clear the parenting:

go to the vertex group menu in the properties panel
Click the small down arrow
Clear all vertex groups


Cycles final render pitch black? In solid mode with Material or Texture, it is shown fine.

But in the Render mode, everything is pitch black. I have a sun, and the Opacity of the scene is set to 100%.

I am new to using Blender, so I have no idea what is wrong.
If you could help, I would appreciate it.
If you need more information to help me, I would be glad to give it.

The sun lamp's position, inside the room, doesn't affect where the sun's light is actually emitted from, it only controls the direction. To quote the blender manual:

  Sun lamps emit light in a given direction. Their position is not taken
  into account; they are always located outside of the scene, infinitely
  far away, and will not result in any distance falloff.

So the light is being cast onto the outside of your room and not getting through the walls to the inside. You can see this by looking at the outside of the room while in 'Rendered' mode of the 3D viewport.

To solve this, you can either disable the 'ceiling' from casting a shadow by changing the 'Ray Visibility' options on the 'Object' tab in the properties space:

Or, change the type of light from sun to something else, like 'Point' or 'Area', whose positions are taken into account. You can also just set any object to emit light, like a plane, by giving it an emission shader.


Script: assign image texture to Image Texture node I am trying to assign an image texture to an Image Texture node in 2.80. Very simple script - I'm just starting to learn how this stuff works.

This is what I have. It creates an image and and IT node, but it doesn't assign the one to other. Can anybody help? I've searched around, but can't find it in another question.

import bpy

#create blank image
bpy.ops.image.new(name="TestImg", width=1024, height=1024)

#add image texture to object, to hold baked lighting
mat = bpy.context.view_layer.objects.active.active_material
image_node = mat.node_tree.nodes.new('ShaderNodeTexImage')

#assign image to image texture node
image_node.image = "TestImg"

Thanks in advance.

The texture is not assigned because you are referring to it as a String instead of a data. Use the following code:

import bpy

# create blank image
bpy.ops.image.new(name="TestImg", width=1024, height=1024)

# get material reference
mat = bpy.context.view_layer.objects.active.active_material

# get texture reference
tex = bpy.data.images.get('TestImg')

# create node and assing the texture to it
image_node = mat.node_tree.nodes.new('ShaderNodeTexImage')
image_node.image = tex


How can I make water follow a path? How can I make water follow a path?

Have a look at the blender manual here.

You can also simply use SPH particles and move the emitter :

the particle settings can be improved to look more like a fluid but that's the basics.

Here's the Blend file :


how to ad wires to my character hi i want to make my model looking like it is made of wires,(the entire model) i do not understand how or if its possible. i also do not know if i can just make the model texture look like wires or actual tubes. if someone can help it will be great. also the wires im thinking of are similar to fnaf sister location tubing. its the best way i can describe it

looks something like this his head

like sister location wires

One of the way to make your mesh made of wire is using wire modifier.  If you want to fill the holes between wires your can check replace original. Like this effect:

Again if you want to make the wire look more like organic,  you can add a bunch of subsurface modifier. Like this :

Other than that,  if you want to see some interesting effect,  you can use tissue addon. Thankfully it comes with blender,  you just have to enable it.  And the effect should look like this:
Hope that helps!!


Can I create an oval spotlight? I'm trying to create an elliptic spotlight, but scaling the spotlight in one axis, while it seems to do what I want in the viewport, in rendered view the lit area stays circular, both in cycles and blender internal.

This bug suggests that the approach of scaling the lamp should work. What am I doing wrong?

P.S. I know that I can assign textures to spot lights in cycles and that should do the trick, however it's a hassle and I'd prefer to avoid it.

The light is a source of emission and can not be scaled. While the dotted line helper is forced to conform to the scale, the render will ignore it.

Two possible ez solutions:

1.) Use a stencil and shadows. literally make a plane with an oval shape in it and place it in front of the light. Make sure shadows are enabled. You can make the plane only cast shadows so that it will not appear in the render.

2.) Shine the light at a different angle. Like pointing a flashlight almost parallel against a wall, the shape of the light will appear to stretch as the light travels further and further to reach the wall's surface.


Wind force field not affecting cloth object I already looked online, but couldn't find anything that worked. can someone take a look? Here is the file:

It's only because your Wind force field is oriented in the exact same direction of your cloth planes. Just rotate the force field a little bit on Z and it will work.

Also, I recommend you to use the noise setting of the force field, as well as animating the force field rotations with some noise modifiers on its curves. It's not needed, but it might just add a little more appeal to your animation.