text:
"Remove double" is deforming my mesh
On a mesh imported into Blender from a specific format with a conversion plug-in, I get duplicated vertices in the same positions, and the different faces of the mesh aren't connected to each-others.
As far as I can tell, this would be solved by the "Remove double" function, however using it deforms the mesh.
What can I do to merge all the duplicated vertices in the mesh, but without deforming it ?
(This mesh was under PMX format, in order to be used with MikuMikuDance. I imported it in Blender to rig it.)
Faces aren't connected to each others :

Normal mesh :

Deformed mesh :

Most likely removing doubles corrupts imported normals. If after deleting custom split normals and re-adding them with e.g EdgeSplit modifier object becomes the same then you can use that solution. If not then maybe manual cleaning will be needed.

You were correct about the normals : deleting the "Custom split normal data" corrected the issue appearing with "Remove double"; however, the body edges that looked smooth now look sharp. I tried to use EdgeSplit like you advised but couldn't make any difference :-/

Ok this is quite confusing but simply pressing "Add custom normal data" solved the issue perfectly. I have no idea how Blender decided what normals to generate though.

When I pressed the "Add custom split normal data" button I was expecting it to ask me for some kind of input, the fact that it restored the normals to their original "appearance" by itself is quite confusing. In any case that solved my problem, can you make your comment as answer so I can mark this question as solved ?

When removing doubles from the imported mesh the normals split in a custom way aren't preserved, making some dark patches to appear. Probably some of split normals were saved while others weren't because removing doubles doesn't choose to preserve given vertex just because it stores some custom data.
In anyway if removing doubles make sure to remove imported normals as well. That will make model lose its look as it was done before exported though.
If the lost shading is important and irretrievable possible solutions can be to manually join double vertices to control which vertex goes where (long way) or recreating shading as it was before removing normals (may be even longer).
Another way would be to duplicate the object before removing custom split normals, remove doubles,  work with it and once done use Data Transfer modifier to copy normals from one mesh to another.
Adding another layer of custom normals with "Add Custom Split Normals  Data" in the Geometry rollout can eliminate the problem but this solution doesn't seem to be stable as it works somehow differently for different objects.

I guess I was simply lucky that in my case, adding the default custom split normals data was enough to restore the original appearance. Thanks for the help !


text:
Start Game from File, how to send a message
I made a game with my pupils in our geography lessons this year. The task is to travel around the World and collect points.
The single levels work very great but we can´t show the collected points at the end. The reason I guess is that we had to split up the levels to different blend-files. We had to do this because of some pythonscripts (mini-map, mousecursor) and the loading time.
The structure looks like this:
                         ->australia.blend ->show collected points (works not)

menue    ->     spain.blend

                         -> show collected points (works)

(Sorry the arrows should be more rotated...)
So is there any possibility to send a message or something like that from one blendfile to another?
Greetings from Hamburg

You can't send anything from a blend file. A blend file is just a container for data. It gets read and written by Blender. The BGE can read them (but does not write to it).
Game Sessions
As you are talking about blend files I guess you mean game session (you are using the game actuator to switch levels). A game session is when you start your game and lives until it ends (quit). When you start again, you get a new session without any relationship to a previous one. Game sessions can run parallel. They still have no relationship to each other.
What you need is to transfer game status between game sessions.
Parallel
When two game sessions are running at the same time they can communicate via network (Python -> socket). In this case I suggest to search for question/answer regarding network communication. Be aware this is no topic for beginners.
Sequential
When two game sessions are not running at the same time you need to persist the game status. Persistence between game sessions can be in the file system (or a database) -> It must survive the end of the game session.
Therefore I suggest you specifically look for a question/answer dealing with Save/Load. This requires a bit of Python knowledge, but there are quite a few tutorials out there.
Levels as Scenes
When your levels are different scenes within the same game session, you could transfer game data via Messages or via Python. This is the case when you use the scene actuator.
Sorry but I can't give you a better answer with the information I currently have.
I hope it helps anyway

If all of the files are in the same directory, you can use Python scripting to save the points in all of them.
FILENAME = "points.txt"

def addPoints(points):
    with open(FILENAME, "a+") as f:
        f.seek(0)
        data = f.read()
        if data:
            data = int(data.strip())
        else:
            data = 0
        f.truncate(0)
        f.write(str(data + points))

def setPoints(points):
    with open(FILENAME, "a+") as f:
        f.seek(0)
        f.truncate(0)
        f.write(str(points))

def readPoints():
    # Returns 0 if the file doesn't exist
    try:
        with open(FILENAME, "r") as f:
            return int(f.read().strip())
    except:
        return 0

You can use these functions as follows:
addPoints(10)
setPoints(0)
points = readPoints()

If points.txt does not exist when addPoints or setPoints are called, the functions will create it. If readPoints is called and points.txt doesn't exist, it will simply return 0.
Copy all of this into your game files and use them where necessary. If you're making a game, I'm fairly sure that you know how Python scripting works, although if you need more help just write a comment.

You could write the points to an external file, and then read them at the end.
https://docs.python.org/3/tutorial/inputoutput.html#reading-and-writing-files

source: Stack Exchange

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

sort: votes


text:
Possible Fixes? Older Blender File ... UI interaction .... Constraints indicators appear but cannot survive drill down .. Foreboding Console Messages
Old file opened in 2.9. Modified circ@ December 2018.
In the constraint panel I see 4 constraints listed.  They cannot be opened.  The error message in Console Window is listed below.  Some other strange behavior which is omitted for brevity and focus.  UI interaction when inspecting constraints.
Did format of constraints change from older file to newer files??
IndexError: bpy_prop_collection[index]: index 3 out of range, size 0
I am guessing at nebulous possible causes.

location: <unknown location>:-1
Traceback (most recent call last):
  File "C:\Program Files\Blender Foundation\Blender 2.90\2.90\scripts\startup\bl_ui\properties_constraint.py", line 127, in draw_header
    con = self.get_constraint(context)
  File "C:\Program Files\Blender Foundation\Blender 2.90\2.90\scripts\startup\bl_ui\properties_constraint.py", line 121, in get_constraint
    con = context.object.constraints[self.list_panel_index]
IndexError: bpy_prop_collection[index]: index 3 out of range, size 0

location: <unknown location>:-1

location: <unknown location>:-1

My timestamp 2021-10-20
Thanks for any explanation or fixes or suggestions.

How much older?  You might have to go back to 2.83 and open/save the file, guessing that 2.83 updated constraints in a way that 2.9 now assumes.

@MartyFouts  ⊚... Interesting idea ... is that a known technique to solve?  A known shortcoming of recent Blender? ⊚  Thanks.  It may take me 24 hours to do this .. due to scheduling ... Modified @ December 2018,

It's not a common technique, no; more of a desperate last ditch effort.  I came across it when displacement nodes were changed between 2.78, 2.79, and 2.80.  2.80 couldn't handle 2.78 files, but 2.79 converted them into a form 2.80 could then handle.  It became moot when they fixed a bug in 2.80 but it got me through until then.

@MartyFouts Thanks for inside defect info.

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


text:
Is this console message high priority? prefs: blah\userpref.blend Traceback (most recent call last): File blah addon_utils.py
Here is the full message in Console
Read prefs: C:\Users\secret\AppData\Roaming\Blender Foundation\Blender\3.0\config\userpref.blend
Traceback (most recent call last):
File "C:\Program Files\Blender Foundation\Blender 3.0\3.0\scripts\modules\addon_utils.py", line 351, in enable
mod = import(module_name)
ModuleNotFoundError: No module named 'oscurart_tools'
Is this situation likely to cause Blender to crash?
Blender is crashing very often in the recent past two weeks.

bpy.app.version_string
'3.0.0'
Microsoft Windows [Version 10.0.19042.1466]

as far as I know, no module named... errors just means blender can't find the add-on (at least anytime I have noticed anyhow). Maybe oscurant has been moved?

Short answer: No, nothing to be concerned about.
Oscurart tools was removed from Blender distribution by the original author.  Apparently upgrades didn't necessarily notice that and you may have a preferences file where it is listed.  If you're not using it, it's not an issue, and if you are, the Blender Artists thread describes where to get it.
If you reload add-ons, you will sometimes discover messages like this.  The majority of them are harmless.  The ones that will cause you problems probably already have and you've noticed and done something about it.

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


text:
Is Resume of Fluid Simulation possible? Blender 3.1 Crashes Party Often
Sometimes fluid simulation completes sometimes it does not.
Example 250 out of 300 frames are found in the cache.
Estimated success rate 80%
Sometimes fluid simulation pause and resume works .. sometimes not.
Estimated success rate 75%
Often the particles system appears in 3D View on Blender launch after failure. If the Blender User changes the frame particle movement occurs. Yet Baking is not enabled via the Blender UI.
Forbidden Mesh fruit is not a pleasant experience.
VRAM info on Blender 0.9/6.0G
So some data is in the data cache.
Any suggestions before this Blender User is forced to delete partial bake and try once again to bake?
Thanks

This is speculation but you could try to go to preferences then system and increase cache limit. Lemme know if that works!

If you load a project where you don't have the Resume button (as in, all it says is Bake All) and you know that your partial bake has had the Is Resumable option checked, then you can navigate to your cache folder and check the last rendered frame (they're all named 001, 002, etc.. 099).
If your last frame is, say, 99, modify the start frame of your simulation (not the project) to be frame 100.
Hit Bake All. Assuming the cache has been loaded properly (i.e. you can see particles/mesh data on the viewport, Blender will resume simulating from that point forward.
Reminder that this only works if you've selected Is Resumable on your first time baking.


text:
How does the Blender User select random linked components of a Single Mesh?
Goal
In [edit mode] this Blender user would like to select random connected components.  Does this feature already exist in Blender? If yes, what are the steps?  Thanks.
Context
If Python is used, then a list of one vertex in every Connected Component is fine. Perhaps the lowest numbered vertex. Vertex selection from a list is relatively simple.  Blender has select linked once a vertex is selected.
Component means selectable in Blender by the concept of Blender Select Linked.  Many references would call this a connected component.  Blender API users may use the word island. Connected Component, Linked, Island seem to be alternatives.
The menu choice [select random] feature is readily available in Blender. It can work in either edit mode or object mode. The [select random] almost does what I want. The general concept of random selection by linked component is what I want for some task, not artistic selection.
Suppose a Blender single mesh contains N mesh primitives such as spheres. N is a number large enough to be time consuming for manual labor .   In the vein of  the provided random select, I would like to select some random percentage of linked components, connected components.
Substitute
Manual Elided steps. Create a collection.  Put Mesh in it.  Separate by loose parts. Select all in collection. Use built in random select/deselect in object mode.  Join.  Select the other items.  Join.  Result is one original mesh is now two meshes.
Potential Substitute
Python Script


text:
An object disappears when I start the game engine. How do I fix this?
I am working on a game, and one particular object disappears when I press "P" to start the game engine. The scene this problem is occurring in was copied from another scene, and this problem didn't happen in the original scene that I copied from. Changing the normals had no effect, invisibility is turned off in the physics, and this object has no keyframes. All the other objects in the scene are visible. I am using version 2.69 of Blender. Any solutions you can provide would be greatly appreciated.

Uncheck restrict rendering in the outliner.

A typical cause: * one of the objects parents is not present

If the object is a plane, make sure you are rendering the back face in the materials tab.

The object might be located somewhere else. So it is not visible to the camera.
Check the existence and the location with this code:
import bge

name = "Cube"

object = bge.logic.getCurrentScene().objects[name]
print("Object", object.name, "is at", object.worldPosition)

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


text:
Objects not following curve
I'm having a bit of a trouble with the curve modifier. The object seems to not be following the curve. I have checked other threads and posts about the similar problem, and I followed their given solutions. Still, the issue remains. What do you guys think might be the problem to this. I have provided a screenshot with my blend file.
http://pasteall.org/blend/index.php?id=49106

if you move your object on the Z and Y axis so that it sticks to your curve, it will work

Thank you very much, I didn't know that.


text:
Objects appear mixed and transparent when compositing
I am working on a sci-fi project, I rendered my scene and my objects are rendered on separate render layers. I encountered a problem and that is the spaceship and the planet in the scene both appeared mixed and transparent. I wanted to ask if maybe someone know a solution to this issue. Here is a picture of the compositing.
Many thanks in advance

just a guess but check your render layers, you may have the wrong layers selected.

Looks like you need to enable Transparency in the Render panel. This would allow you to composite your layers with more Alpha Over nodes instead of Add nodes. In general, I would keep Add nodes only for layering lighting effects.

Ok, great, pleas mark the answer as accepted if it solved your problem.


text:
Make a sphere of cubes in Blender using python script
Having trouble running code on Blender.  What this code is supposed to do is make a sphere of cubes.  It can make a circle just fine but is having troubles with the embedded while loop.  It runs through the inner loop fine and makes a circle (of radius 0), but does not go through the "phi" while loop to make a sphere.
import bpy
from bpy import context
from math import sin, cos, radians

cubeobject = bpy.ops.mesh.primitive_cube_add

#get the cursor location in the scene
cursor = context.scene.cursor_location

#increase the radial distance of cubes in loop
RadDist = 5.0

#initialize some variables
xsize = 1.0
ysize = 1.0
zsize = 1.0
phi = 0
theta = 0.0
RadStep = 6.28/8.0
while phi < 3.14:
    while theta < 6.28:
        x = cursor.x + RadDist*cos(theta)*sin(phi+3.14/2)
        y = cursor.y + RadDist*sin(theta)*sin(phi+(3.14/2))
        z = cursor.z + RadDist*cos(phi)
        cubeobject(location = (x,y,z))
        #add cubes along the radial
        theta += RadStep
    #add cubes along the azimuthal
    phi += RadStep

theta = 0.0
phi = 0.0

related: http://blender.stackexchange.com/questions/33542/how-to-make-a-mesh-surface-that-looks-like-cubes-stacked-in-the-shape-of-a-spher

I figured out the solution.  The issue was that once i got out of the embedded while loop the theta value remained at 6.28 instead of returning to 0.0  it was remedied by putting theta = 0.0 in the outer while loop.
lesson of the day When you leave a while loop the values you have made remain the same when you leave, remember to reinitialize them.
here is my sphere of cubes.


text:
How can I make an object face or locate to the active camera?
I want the eyes of a character to rotate to look in the direction of a specific point.
I have a rig for the eyes of a character and I want the part of the rig that controls the eyes to be at the active camera, the rig crosses the eyes to its location and thus the character looks to that specific point. Also, I want the head rig to face the active camera. I just need to know if and how I can make the two bones snap to the active camera.

You want specific bones to [rotate] towards some other object? Is that correct?

I have a setup like the one below, I need to know how to specify which camera is the active camera, and thus, the object the rig should follow.

Consider a [track to] constraint which rotates the bones

You can track to the camera or some object like two rectangles next to each other lets call them a pair of eye trackables, similar in placement to a pair of eye glasses. Depicted above in the animation is an example. Left eye tracks left point, right eye tracks right point.  The points are eye distance apart.  At a far distance the eye trackables cause the eyes to rotate and be nearly parallel.  At a close distance the this can prevent crossed eye problem.  Some blender people might say the having a separate eye trackables is more flexible than tracking to the camera.  You can move the trackables independent of the camera.
Consider searching Blender Facial Rig Eyes

A very complete answer. Up voted.


text:
Cycles Rendering Issue
I have an issue..when I use cycles render and I use color,  normal,occlusion and spec map I see some lines.(I think they are the marked seam lines).It look like the 1st picture here.

But when I take them off and keep just the color map it looks normal.

Any ideas guys how to fix that?Is a common problem to me and I have to find a solution:P Thank you for your time!

Are you sure it isn't just a tiling texture?

Here are the node trees http://imgur.com/vyNwwEF

It looks like the normal map is using different texture coordinates than the other maps.  Try deleting the Texture Coordinate node at the bottom left.

Still nothing :/

I have received your scene and have found the problems. There are some issues with your scene. I will send you the modified files via mail.
Here is a first screenshot for the audience with the solutions for your problem.

You are not using any dilation in your images. (This is not a real problem, but would be better). Dilations can be done with tools like xNormal.
Your normal map is strange and produce extreme curved borders. Together with the dilation problem it produces the main issues to your result. I guess you used a filter to produce your maps like normals, depth etc. This is not really a good way. You should use a better filter for such things or better color templates.
Your mesh need some editing. You are using "custom splits normals data" in your mesh. Remove this data and smooth the mesh. Add an own smoothing value to the mesh then. For example a smoothing of 20 degrees. This makes nice architectual shapes and helps to remove the smooth edges too.

Proposal: How about plug the normalmap output into the normal inputs of your diffuse and glossy nodes instead of the material output node displacement input?

thank you for your interest and your proposal but still I can see the lines..

Any chance to send your file? You could just add a example object instead of yours, if it is under a NDA. And the linked material. So we could check this.


text:
Blender Orbit Locks up
I am new at blender, and as I was orbiting w/ middle mouse button on my logitech mouse, releasing the middle mouse button didn't stop the orbit. The only way I could stop the display from orbiting with my cursor was pressing escape. After that, orbiting didn't work anymore, and I had to restart my mouse.
Any idea what's causing this?
Thanks

I just realized that it happens when I move my viewpoint under the grid. Any ideas?

Nvm, I realized how to fix it. Simply tilt the middle wheel in one direction or the other.

Glad you got it working :) I'm closing this question as it seems the problem was caused by the mouse itself


text:
How to make objects follow armature bone shape? (images included)
This probably is a very simple thing but I'm not able to figure out as I am very new to blender and animation.
I want to do a paper folding animation and I am stuck at beginning itself :D
I have a plane(actually a cube) and an armature setup as shown below.

After I apply parenting with armature and move the bones in pose mode I could get the plane to move but they are not following the bones

I wanted it like this for accurate positioning(shown in black line). I've kept the length of second bone to be same as the middle portion of the plane. I am thinking maybe a bone constraint would help not able to figure out which one.

Thanks in advance!

Looks like you have weighting wrong: delete the armature modifier you have created, select the paper, then the armature, then Ctrl P and choose "with EMPTY GROUPS option".
This option will create 3 empty vertex group with the same name of the three bones,  that can be manually weighted:
select the paper and enter in edit mode
select the vertex group tab in the properties window, select the first bone, select all the vertices around the first portion of the plane and click assign.
Do the same with the others two bones/portions of plane.
Done.


text:
Can i control emission brightness using an object controller with animation nodes?
I would like these pipes to gradually light up when the ball floats over them but i cant work out how to get each pipe to work independently of each other. At the moment the brightness is dictated by how close the ball is to the original pipe and i want the brightness to be controlled by how close the ball is to each instance. This is what i have so far...

There are multiple ways to do this, one way is to send the location and scale of the controller object to the material and compute the distance between the locations of the pipes and the location of the controller in the material:

How you use the distance is up to you.


text:
how to get rid of these weird artifacts in my fluid sim?

Theyre most prominent in the top left of the image. Ive tried increasing the resolution but that didnt seem to help.

What lighting are you using? Have you tested the reflection with a more simple object?

increase the roughness of the reflektion to sth over minmum.
i have no model to test. Play with the value a bit.


text:
I am having very slow performance running Blender
I just installed Blender and I am having very slow performance,when I press any menu buttons it takes around 3 sec. to respond or show is this normal? Do I need to set up something additional or install a driver?
I have read the system requirements are looking fine,it shouldn't be that slow.
Thank you
P.S.
I am using:
Samsung RC530
Intel core i7 , 2.20GHz
GeForceGT 540M,
6GB RAM DDR3,
500 GB SSD Samsung,
Windows 10 64 bit

I had this problem recently, and it was resolved by updating my Nvidia drivers. Instantly things were back to normal.

I just reinstall the drivers of NVIDIA and its working fine,thank you!

Make sure you have your video drivers up to date since Blender's UI is run entirely through OpenGL. Just search for your graphics card (GPU) online. If you do not know what model of GPU you have, then try going to the GPU brand's website usually you can find which brand of GPU you have somewhere on your computer's case or the box it came in. The brand will usually have an easy way to find out what GPU you have and provide you with updates.


text:
materials different between render and viewport cycles
Right now I have a scene set up with two emmission shaders on two planes. In the viewport render I get this image
But whenever I render it, I get this

The viewport render is as desired but the final render doesn't turn out as wanted.
here is my simple node setup for the mountains

and the backyard

If you have any tips I am greatful for them!

Can you show the modifier stack for each object? There seems to be something changing the material on the second plane.

neither of them have modifers and I have restarted the blend file as well as importing both objects into a new scene

Related: http://blender.stackexchange.com/q/985/599

Thanks my bad, Sorry for reposting. couldn't find that article.


text:
how to prevent arm from twisting with rig
Right now I have a base mesh of a human with a basic rig structure, I am trying to have him point a finger gun but whenever I raise the characters arms the mesh
twists. (see below)

I don't know what is causing this but I have good topology and the rig vertex groups are all pretty good. any ideas?

Your issue is likely with blender's strange weighting system. Every vertex on a mesh is given a weight value (0-1, decimal based) of how much influence a particular bone has over that vertex. Your arm bone, of some farther down the arm, likely have weighting bleed over into the chest which is causing that twisting. Simply go into weight painting mode and adjust the weighting so anywhere not associated with the given bone is solid dark blue. This should take care of any unwanted twisting, unless you also have the same issue I do, where the armature seems to have applied it's self to the arms sideways, so they roll forwards and the elbow bends sideways. (I managed to get the IK and poll targets working too so this is really infuriating...)

weights are not the problem, the bone/rig design is.


text:
Move an object while connected tubes "follow" it, automatically stretching and shrinking
I have a real-life 3D object placement "problem" and I am wondering if using Blender to help me visualize the scene is a viable option.
I need to manipulate the object's placement (move around) within a given space until I'm satisfied with the placement.
I do not need to get a fully animated interactive game-like thing - just editing objects within Blender will more than do.
The catch is, it is not just moving a box inside another box - I have an irregularly shaped funnel-like space and a multifaceted object that is attached to fixed wall points on opposite sides of the funnel via two flexible "tubes".
The idea is to move the object within the space while the tubes "follow" it, automatically stretching/shrinking.
Ideally, it would be possible to detect and correct any "collisions" with the walls, either automatically or using a script or something.
It is not just one-time problem; the object will be the same but the space will be different every time.
So, the question is:
While I do understand that it is possible to create a scene like that in Blender, how practical would that be to use for this purpose?
By practical I mean how easy/hard would it be to manipulate the object and the tubes to fit them into space.
I'm new to Blender and 3D modelling but I'm quick in acquiring new skills.

Please place an image in your question to explain visually what you have written above.

I will try to make a skecth over the weekend.

While I don't see a way to automatically detect collisions, I expect some things can make your task fairly easy.
The first task of placing an object within a modelled room is easy. You can use snapping to place a mount point onto the wall. then by 'locking' the right axis of each wall mount you can easily move the mounting around the wall and have it stay on the surface, a small adjustment can be made to transfer it to another wall.
Curves are defined by a number of control points. By adding a bevel to the curve they become "tubes" that automatically flow between each point.
By using hooks each control point can be moved while the tubing adjusts to suit. One end of each curve can be hooked to the wall mount, the other end to the object, and then a simple empty can be used to adjust each point in between. Instead of using hooks for each control point you vould edit each curve manually.

In the following example that I created for the previous screenshots, I have two curves, that go from the wall to a fume extractor. Each curve has two control points to adjust how it flows from the wall to the extractor. For easy viewing the building is set to always draw in wireframe.
To use, you place the mounts on the wall, then position the extractor and then adjust the curves to flow nicely between the two.

While I have used a nurbs path in this example, you can also use bezier curves to get more control over where the curve goes to and how sharply it bends at each point.

Thank you @sambler for this great explanation! It really is helping me understand Blender's capabilities better.
Collision detection, however, may be important after all. Could this be handled by a "game" created in Blender? (Maybe I should post another question for that?)

What I actually meant by "collision detection" can also be taken as "collision avoiding" - I have posted another question related to that here:[link]http://blender.stackexchange.com/q/46543/21569.
I'm accepting this answer as it does answer my question (especially the new title ;) ).


text:
Undo in script does not work?
I am trying to undo an operation in a script but the bpy.ops.ed.undo() does not work.
The exactly same sequence of statements run in Python Console works as expected.
A code that demonstrates this behavior is this (run from Text editor):
import bpy

# ... already in Edit mode, selected all

bpy.ops.mesh.remove_doubles(threshold = 0.1)
# the above says "Info: Removed 30 vertices"

# create new undo step (without this it doesn't work in Python Console either)
bpy.ops.ed.undo_push()

# this undo does nothing ...
bpy.ops.ed.undo()

# because this ...
bpy.ops.mesh.remove_doubles(threshold = 0.1)
# says "Info: Removed 0 vertices"

Interestingly enough the pushed undo step is visible in Undo History right before the Run Script step - and it can be undone, of course.
Is there a catch I'm missing here?

Nobody? Should I post this on Stackoverflow instead?

https://blender.stackexchange.com/questions/159873/how-can-i-get-an-objects-previous-location-with-python/159892#159892 the last half answers this I guess


text:
Is there a file format with CSG operations that blender can import?
I misuse Blender as one possible editor for a 3D simulation program. The 3D simulation program also has other ways to create and modify geometries, among them are CSG operations. If there were a file format supporting CSG operations, then I could export to that format for visualization with Blender.
Blender 2.71 offers the following import formats

Collada (Default) (.dae)
Motion Capture (.bvh)
Scalable Vector Graphics (.svg)
Stanford (.ply)
Stl (.stl)
3D Studio (.3ds)
Autodesk FBX (.fbx)
Wavefront (.obj)
X3D Extensible 3D (.x3d/.wrl)

I'm pretty sure that .dae, .ply, .3ds, .stl, and .obj don't support csg operations (because I have read sufficiently deep into their specifications to be sure). I think that .bvh and .fbx are motion capture formats, and that .svg is a 2D format.
My guess is that .x3d/.wrl doesn't support CSG operations either. I also guess that there simply aren't any portable non-proprietary file formats supporting CSG operations, independent of Blender and its supported input formats. Are my guesses and assumptions correct?
A more limited form of CSG are overlapping (solid) objects, where an order of the solids is specified and determines which object wins in case of overlaps. Does any of the above formats (or their implementation in Blender) supports this more limited form of CSG?

None of these formats has true CSG operations. X3D does have support for overlapping objects via layering, see http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/layering.html. VRML on the other hand didn't support layering.


text:
How do you export a blender file as an .avi file in Blender 2.74?
I am working on a video file in Blender. I have saved it as a .blend file already, but I want to save it as an .avi file.
How do I do this? I have watched multiple tutorials and have no idea what to do. I am using Blender 2.74.
Thanks.

Just to clarify, you're working on a video edit in the VSE, correct? And you just need to export your video as an AVI file?

In order to export your video edit to a new AVI file, you need to:

Set your Render Settings to a movie format that supports AVI
Click the Render Animation button.

As long as you have the Sequence checkbox selected in the Post Processing panel, it should render out your video edit to a new video file.
There are a number of Movie formats that also support the AVI encoding format.
They include:

AVI JPEG
AVI Raw
H.264 (with AVI format selected)
MPEG (with AVI format selected)
Xvid (with AVI format selected)

Wouldn't setting the Audio Codec to None result in a mute video?


text:
How to map keys in Blender 2.80?
I'm using Blender 2.80 and I need to map the "view selected" / "frame selected" for a different key because I'm using a notebook that doesn't have the numpad. How should I proceed?

Edit>Preferences>Keymap.

Thank you! :) :) :)

You can change shortcuts in the Keymap section of the Blender Preferences. Just open up the preferences and search for either the name of the function you want to remap, which in this case is 'view selected' and all the bindings for it will appear. You then simply click on the current shortcut and Blender will ask you to press the key you want to change it to.

Note that in Blender 2.80 you can also bind keys by right-clicking on buttons or options in menus and selecting 'Assign Shortcut'. Since the frame selected function doesn't appear on any menus, it must be assigned in the preferences.

Thank you! Do you know why it is "View selected" instead of "Frame selected"?


text:
How to make a material with texture in Blender 2.8?
I'm trying to apply a blue texture to a material, but the texture is not displaying in the 3D view port.

I'm using blender-2.80-387c1f2e0d5d-linux-glibc224-x86_64
What should I do? What I'm missing? Bellow is the .blend file.
File

Thank you Cegaton!

Here is the node setup to achieve the result:

And here is the .blend file:
LINK


text:
How can I access focal length of active camera, render resolution using animation nodes most directly?
I would like to use animation nodes to create edge line meshes for fast edge line rendering-- meshes slightly displaced along their normals, with only backfaces rendered.  To create an edge line that's a single pixel wide, the world-space displacement needs to depend on the camera FoV (focal length + sensor size) as well as the rendering dimensions.
I would like to use animation nodes to do this, as it would simplify the creation of objects and should allow for easy reuse between projects.  I have just started learning animation nodes.
How can I most easily get these numbers into my node trees?  I've tried using object attribute input with a copied data path on my active camera object, but get an "attribute not found".  A copied data path to an expression node for render resolution likewise gives me "name is not defined."  Drivers seem to not be working on float input nodes in animation nodes.  I can create drivers on the positions of empties and access their positions in my node trees, but I'm wondering if there is a more direct way to access this for animation nodes?

I don't know of a way to directly access the current Scene's properties in Animations nodes but you can circumvent that with custom properties
.
Add 2 custom properties to your camera and drive them using your resolution. Example with the resolution X :

Now you can access theses properties in AN using an "Attribute Input" node.
Note : To access the "Camera" part of the Camera "Object", the path is obj.data
So : the focal lens is accessed with data.lens

Thank you very much!  Much more direct than using object transforms to store the information.


text:
Planetary/Atmospheric volumetric clouds
I created a planet in blender a while ago, and now i'm interested in adding volumetric clouds instead of using a 2D texture. I considered adding a bump node to my material, but then it would remove the realism in the image.
This is what I've created:

This is the effect I want to create:

Any thoughts?

Related https://blender.stackexchange.com/questions/18393/3d-volumetric-planetary-clouds-in-cycles and https://blender.stackexchange.com/questions/45484/render-of-planet-earth-in-blender-render-and-cycles

A 3D cloud effect with shadows on a planet can be generated using the experimental micro-displacement with adaptive subsurfaces and shader displacement. Using subsurface scatter and transparency in the shader given an appearance similar to a volumetric shader.

Procedure (tested on blender 2.79b)

Create the planet by adding a sphere to the scene. This will be the planet surface.
Add a second sphere for the clouds. This sphere should be slightly larger than the planet surface. The distance between the cloud sphere and the planet sphere will be the height of the lowest clouds.

Add a subsurface modifier to the cloud sphere. Enable the 'Adaptive' option.

Enable experimental feature support in the render panel.

Create an image for the cloud height

Create an image for cloud coverage. This image will be used to set the transparency used for the cloud shader. If you look carefully, you'll see that the cloud coverage in this example is set to cover more area than the image for cloud height.

Enable cycles and create a shader for the clouds. The cloud material is a mix of a subsurface scatter and a diffuse nodes. This is mixed with a transparency node using the cloud coverage image. The cloud height image is connected to the displacement input on the material output node.

Without displacement, the clouds are flat.

With displacement, adaptive subdivision, and experimental features, the clouds become 3D.

If clouds with overhangs are needed, multiple layers of clouds can be used.

Blend file:


text:
Adding a texture to follow the shape of the mesh
I've stumbled on an issue while texturing my model. I can't seem to figure out how to implement a rust texture correctly on top of the base texture of the mesh without losing its initial look to the UVs.
Thanks for the help,
Dave

You can create multiple UV maps (click the add button alongside the list of UV maps in the mesh properties). You can then position your UV for the rust over the rush image without upsetting your ‘base’ UVs.
Your material will then need to be aware of both UV maps and mix between them as appropriate (eg, my using the Alpha of your rust image) although this depends on your choice of render engine (Blender Internal, Cycles).


text:
Placing mesh particle on top of a diffferent mesh
There's an issue that i can't seem to solve with the hair particles. I have a mesh that I want it's bottom face to stick on the surface of another mesh. I've tried it on a flat surface and it seems to work just fine. But when I try it on a round surface it's giving me a totally different result. On a side note, I did check that the origin of the particle object is set to its original position.
Any thoughts?

I tried, It still doesn't work, I think it probably has to do with normals.


text:
Can I Put 2D GIF Image on 3D Object
Is there any way to put 2D GIF Image on a 3D Object? For example, I have a box. The box has 6 Faces. Can I put 2D gif on one of the box faces?

Also known as a decal.  Try a search using decal.

I don't know about GIFs, but JPG and PNG will work.

@batFINGER - thx, I'd double upvote your comment if I could ... was driving me nuts attempting to do this ... until you posted the word "decal". For anyone else, batFinger mentions 'shrink wrapping' here (http://blenderartists.org/forum/archive/index.php/t-204348.html) which is exactly what I needed to do.

I am not sure if animated gifs are supported, but videos can be used as color inputs.
You can see more about video textures here:
https://www.blender.org/manual/render/blender_render/textures/types/video.html
in order to make the video appear on only one face of the box the best way would be to add one more material slot and assign a new material to that particular face.


text:
Mesh + Armature Problem
I finished modeling a LEGO man, so I decided to rig him.
After I rigged him, everything was fine:
https://youtu.be/ahPx-qFXO4o
But, when I tried to move the hips or body, the other parts were glitched out and didn't move correctly:
https://www.youtube.com/watch?v=fjmQoTe8Xlg&feature=youtu.be
Would really appreciate it if someone told me what the issue is. Thanks :]

Both YouTube videos are private.

What technique were you using for rigging and weight painting?

@LukaŠimić what do you mean? i joined all parts of the LEGO guy with ctrl + j and parented the Mesh and Armature with automatic weights. I then saw none of the parts were moving in relation to the bones, so I manually assigned all the specific parts to their specific bones.

Finally fixed it
if anyone has this problem, just recreate the bone structure and it should work :)

Can you add details to your answer, so others can follow the steps you propose?

@someonewithpc I just recreated the bone structure by deleting what i had before and making a new armature. Once that had been done, I joined all seperate parts of the mesh together with ctrl + j and parented it to the armature with automatic weights.

@xWeasel I'm not sure if the suggestion to redo a big chunk of the work is a welcome suggestion, even though we know sometimes it happens that way. However, I think your issue could have been adressed more easily If you had provided your blend file here: http://blend-exchange.giantcowfilms.com/ This way other users can examine what's wrong, and save you some time plus show you what actually caused it. Proper weighting of characters has a lot of catches and gotchas, so it's difficult for others to know which one was the issue THIS TIME  :)

@aliasguru i see what you mean, but unfortunately i don't have the blend file anymore, so that's the only solution i came up with :l


text:
How do I set a vertex color material in Blender 2.8?
I have a model with vertex colors in it. I would like to display it in rendered shading. There is no more an input called vertex color.
I'm using Blender -2.80-387c1f2e0d5d-linux-glibc224-x86_64
How should I proceed?

Here is Attribute node with Color output and Col parameter according your Vertex Color name.

Updated:
List of all what can you call from the attribute node

Thank you very much!

And what it may mean? How can I make some parts red, some parts blue? I added this attribute as base color of model shader, and became gray.

@Tertium https://www.youtube.com/watch?v=HDWSkCDIu1E


text:
Is it possible to change the text color inside the VSE by changing the source code?
I would like to know if it is possible to change the color value of a text strip made in the VSE.
The default color is white, but what if you have a background which the predominant color is white?
Is it possible to change the text color via python or changing the source code since there is no option in the user interface?
Meaning a different solution other than to render the text with an alpha background and then change it by color correction and re-render it again.

What is to do with the "source code"?! From the question it could be understood that you want to rewrite blender's source code for changing a text color...


text:
How to change the duration of an added game object in multiple empties simultaneously?
I'm trying to make an empty that adds a game object be modular.
Suppose that I have an empty with an edit object / add object actuator.
This empty adds a plane that lasts two seconds.
Later, I did make many copies of this empty, so I ended up with a scene with many empties that adds many planes, that lasts two seconds each.
If I want to change the time for which the planes lasts in the scene, to let's say, three seconds, now I need to copy the game logic to the other empties.
I would like to make this in a more modular fashion, by using linked objects instead of selecting many empties to then copy the logic.
Is it possible?
Actually, when in the process of linking the "empty", and change the parameters of the original one, the modifications do not reverberate automatically to the other empties inside the scene, because Blender reads the copies as different objects.

Both answers are valid, Thank you so much Monster and
sdfgeoff! :)

Assign the "template empty" to a new group "Plane.Adder".
Move the "template empty" to an hidden layer, or scene (does not need to be active), or file (and link the group from there).
Add any number of instances of group "Plane.Adder" -> Plane.Adder.001, Plane.Adder.002 ...

When you change the duration at the "template empty" the instances inherit this change.

Have you considered making the object vanish a parameter of ... the object doing the vanishing?
As in, the empties all add the object with no time limit, and then in the object, you have a delay sensor to end the object. This way you have a single place to control the lifespan of the object.


text:
Blender 2.8: how to cut non visible edges?
I'm using the knife tool (shift + spacebar + K)  to cut a cube.
I would like to reach the edges that are behind my current view also.
What is the procedure?

To cut through, press Z just after you've activated the knife.
And press C to cut perpendicularly to the view and ctrl to cut an edge by its center.


text:
Where is "view selected" inside Blender 2.80?
Do you know inside which menu "view selected" is located in Blender 2.80?

It seems the feature is now called Frame Selected

You can find it in View -> Frame Selected
The default shorcut is . on Numpad

Thank you very much! :)


text:
Where the Dyntopo button is located in Blender 2.8?
I would like to know where the Dyntopo (dynamic topology) button for sculpt mode is located in Blender 2.8.

The Dyntopo checkbox is in the new Tool Tab at the top of the Properties Panel.

Thank you very much.


text:
Blender 2.80: What is the difference between "Rendered" and "Look Dev" display modes?
By pressing "Z" inside the 3D viewport in Blender 2.80 one can access the display modes of Blender. I would like to know the differences between "Rendered" and "Look Dev". Thank you.

LookDev uses the eevee renderer and some pre-selectable hdris to light your object. It ignores the lights in your scene. Rendered uses the lights in the scene, and you can change between cycles render and eevee.


text:
Where shading "smooth" and "flat" are located inside Blender 2.80?
I would like to know where the realtime rendering options for faces "smooth" and "Flat" are located inside Blender 2.80.

In the 3D Viewport, while in Object Mode, under the header's "Object" menu

To use it in Edit mode for some selected faces, look again in the Viewport's header, but this time under Mesh > Shading > Smooth/Flat Faces


text:
Transferring shadow from raw footage to render VFX
I Have footage of my hand moving over a wall and it casts a shadow on the wall. In Blender, I am putting VFX objects on that wall. How can I transfer the shadow from the real wall onto the CG one that my VFX objects are on?

If the wall is key-able then you need to remove the wall and leave your hand. Then use the hand alpha channel and offset it to simulate a shadow.

is it possible if the wall is not key-able?

Well how are you putting the CG objects on the wall but under your hand?

I masked my hand and the object on the wall has an alpha channel. I cant project the mask of my hand onto the wall because the angle of my arm isn't close to the shape of my shadow. I could ask the shadow and project it but that would produce a mediocre result and it would take a lot of time. Is that what I have to do?

Could you post a setup of hand and wall or other elements? For example how are you superimposing the hand? Are you using the compositor or making the hand a 3D texture mapped object? Does your hand change shape during animation? Could you post a frame of your hand footage?

Possibly related solution: https://blender.stackexchange.com/questions/633/when-integrating-live-action-footage-and-cg-how-to-make-proper-shadows-for-acto?rq=1


text:
Alligning vertices in a UV image
I have an object that is similar on one side and the other. However, the UV image editor UNwrapped it so that each half has slightly different vertex positions. How can I get it so that all the vertices line up?

If those UVs are exactly the same, you can align UVs to some common vertex and then rotate one UV with enabled vertex snapping and snap the rotation to some vertex of the other UV.

Enable snapping Shift+Tab
Set Snap UV Element to Vertex Ctrl+Shift+Tab
Set Selection Mode to Island Ctrl+Tab
Grab one island G and align it to corresponding vertex of the other UV island
Change Selection Mode to Vertex, select the common vertex and hit Shift+S to set Cursor to Selected, so you can use this vertex as a pivot point in next step
Change Pivot to 2D Cursor .
This is quite unpredictable but hopefully it will work - rotate the UV R and hover your cursor over vertices on the second UV until the rotation snap to it.

If your UVs are not exactly the same, you can then select all vertices and press W > Remove Doubles to merge vertices close to each other.

I don't think there is a tool in blender which allows you to do it automatically (you may try to ask another question how to do it by scripting though). Here's my method which uses a pinning option. Place two UV islands close to each other. Enable the snapping tool (vertex) and snap all the external vertices of one island to the vertices of the other to match islands' shapes.

Now select the rim of the first island (Alt+RMB) and press P to pin it. Press L to select the whole island and hide it (H). Repeat the pinning process for the second island. Next unhide the first one with Alt+H, select both (A) and unwrap again. Finally unpin everything with Alt+P.


text:
Why do Boolean operations tend to fail on overlapping faces?
Very often I'll get erratic results with a Boolean operation on two objects with overlapping faces. The most usual result is missing faces in the combined object, or else internal faces are left after a Union, for example.
Why is this? Is there anything I can do to avoid it?


text:
How to get photos or videos from tmp
I started a render without fully reviewing all the settings and I left the file output as /tmp\ is there any way I can get these files out of the /tmp\ folder?

You can browse to /tmp with any file manager (nautilus, finder, dolphin, etc.) and copy them. Are you getting any strange errors?

You can navigate to /tmp\ by typing %tmp% in your windows search bar. Your renders should be there.

I just had to figure this out myself. If you're on Mac, go to Macintosh HD in the Finder, then you need to reveal hidden folders (Command+Shift+.). This will show the tmp folder. Organize by file type to see the pngs (or whatever file type you saved). Should be there!


text:
How can I fix an unintended hole in my mesh?

I've created a hollow object with a Boolean Difference, but it has left a hole in the mesh that I can't seem to fix. There are no vertices on the periphery of the hole itself, and it extends across two faces at right angles to each other.
When I look inside the hollow (as far as I can), I see that there are "shadow" connections between vertices that I would have expected to be unrelated.
I've tried manually reducing the NGON faces to quads and triangles, but it's had no effect on the hole. I've tried Mesh > Cleanup > Fix Holes, also with no effect. I've tried to Beautify the affected faces, again with no effect.
I've attached a link to the file in a state prior to my messing around trying to fix it (approx. 10MB)
Link to the .blend file, approx 10MB

You have some manifold Geometry inside of your mesh. You can select the affected edges or vertices with Ctrl Shift Alt M in Edit Mode:

You need to delete every connected Face and readd it manually in a "logical and watertight, clean" way.
After you corrected this - you need to delete this one face which isn't connected in one flat plane but with many of these vertices that got selected - you will get quite a clean tank model without holes ;-)


text:
Blender installation package not opening
I have tried to install blender 2.76 multiple times, even on different accounts, i have no trouble downloading the installer package but when I go to open it the same message comes up every time.

I tried searching up the problem, but the closest I could get was to create a new account and try it again, that didn't work either. I also tried downloading it from other servers, as I live in Australia and there isn't an Australian server, but the same message appeared every time and I have no idea what to do.
The questions I would like to ask are, can I fix this problem and install blender?, if so what do I do?

It's hard to tell what the problem is without more information. Is there anything unusual about your computer? Have you tried older versions of Blender?

no I don't think there is anything unusual about my computer, i will try downloading a different version. thnx

I try'd  downloading 2.75a and it works, thanks again for you'r help

Check the version you are downloading. And if the executable didn't work you can try downloading the zip package where you do not need to do any installation. The zip package lets you drag it's content into any directory and run blender directly from it.
A Zip package can be found just below the installer versions.
But you may have to do a manual registry entry using this method. That being said 2.7 versions have a registry bug that sometimes doesn't register even if you do a proper install so this step may still be necessary even if you did a proper windows installation.

Basically fixing the registry registering will enable .blend files to display an thumbnail of it's content. Without proper registration, .blend file will just be displayed as with a default blender icon.

thanks for your help, i run a windows 8.1 64bit operating system, i will trying downloading different versions, if that dosen's work i will try the zip file.


text:
Weird lighting and how many tris for games
I'm new to blender, I am looking to create a game using unreal 4.
That being said, how many tris are too much? currently working on a character's boots and am riding at over 2000 for just one of them...
Also, after working on the shape for a while the lighting is acting weird on just one part, as shown in the pictures.
Why? and how can I fix?
Thanks.

generally speaking, the polly count should be kept as low as possible without sacrificing too much detail. Remember that game engines render things real time. If it takes a few minutes to render the scene, you will probably have miserably slow frame rate in your game.

Related question about the shading issue: http://blender.stackexchange.com/questions/16602/color-faces-with-wrong-normals/16608#16608

please limit your Questions to one question per post. The shading issue already has an answer and is separate from the question about how many triangles is appropriate.

Generally you want to keep the rule to making a really high poly mesh and then baking the normals of the hi resolution mesh on a low poly version of it. So you get the illusion of a really high poly looking model in game. That's what all the next gen games are doing. If anything , it's defintely not the foot of a character you want to spend your polygons on ... any artist must know it's the face and the eyes of a character that would require the most details. Cos that's where your audience will focus on.
As for the feet of your character , it's not the shader looking strange but rather you need to improve the model, or rather improve on your observation of real life objects. You can use GLSL shader to improve the viewport's feedback while you sculpt. I will add a few images below.

You can observe here that I have a high poly model on the right. And a low poly one on the left. After sculpting I bake those information out onto the low poly version to get this ...

From here on out , I will leave it to you to run through google for tutorials
using keywords in your search eg. Blender Baking Normals and Blender High Density Mesh Sculpting and Blender Dynamic Topology Sculpting.


text:
How to Set Shape or Direction of Particle Trail

I can't seem to make the trail into a cone shape.
Right now, the particles spread out from the emitter.
I want them to start at the emitter radius and move closer to each other - to have a cone shape, with the smaller radius being the path the Ball is taking (there's an actual hidden line the ball follows).
Please help

I don't know if this helps, but maybe add a force field which has a pulling force to the scene and parent it to you ball.

I recommend watching this.

In your particular case (with a spherical emitter) you might be able to get away with simply reversing the sign of the initial particle Velocity along the Normal. With a positive Normal velocity the particles will spread out from the surface. However, a negative Normal velocity will start the particles in a direction towards the centre of your mesh so they will naturally converge on each other. You will need to tweak the strength, particle life span and/or damping so that they don't cross over.

EDIT : To retain the 'engulfing' effect of the emitted particles, you can emit the particles from a separate (non-rendered) mesh that surrounds the original object. This will allow the particles to be emitted a distance away from the surface so that they surround it rather than emanating from within.

Note that the emitter mesh is set to not render.

To fill in the gap between the surface and where the trail particles are emitted you can add a second particle system - emitting short lived particles from the surface to the point at which the trail particles are emitted. This will make the object appear to "fizz" with particles and will mask the fact that the trail particles are actually emitted at a distance from the surface. Increase the number of particles to get the desired density.

This can produce the following result :

You could add Brownian motion or a turbulance field or other fields so as to make the particle path less linear.
Blend file attached.

Thanks!
Excellent and quick fix. Got a great looking effect.

Any idea how to do this AND keep the "engulfing" effect of the particles while the ball is traveling?

@Cypher_CS Glad it helped. I've updated the answer to include more 'engulfing' particles.

Yeah, I figured it couldn't be done from the same object as emitter.
Thank you very much.


text:
How to Programatically Render Multiple Times with Different Materials each
I have an animation about 170 frames long (not important).
In the animation I have Balls with a certain Material on them (UV map).
I'd like to have this Animation rendered 100 different times - each time with a different UV Map on the Balls.
Additionally, I'd like each of the 170 set of PNGs to have a different name, corresponding to the UV Map being rendered.
Like:
Ball01_001.png ... Ball01_170.png
Ball27_001.png ... Ball27_170.png
.
.
.
Ball99_001.png ... Ball99_170.png
Is this possible with some code?

If the UVmap is the same, but the image must change each time, you don't even need code in Blender: you just need to a) render from command line with textureX to image1, b) change what textureX is (renaming/copying texture1 to textureX, then texture2 to textureX and so on), and then render to image2, etc... you could do this with any scripting language, imho...

That sounds about right.
Looking into it here: http://www.blenderist.com/b/?p=131

Basically, what I'm thinking of doing is writing a python script that gets all the Texture files, enumerates them, then for each, runs the render - first replacing the texture of the balls, of course.
Just need to find what property changes the outputed names.

looking at the command log into "info" window, when saving a rendered image it logs something like:
bpy.ops.image.save_as(save_as_render=True, copy=True, filepath="/home/marco/Desktop/untitled.png", relative_path=True, show_multiview=False, use_multiview=False)
so I guess you could use this same command to edit your save path/filename

Okay, so with m.ardito's help in the above comments, this post on Blenderist and some related questions on Stack, I came up with the following Python script, running it with
blender -b filename.blend -P setting.py

Here's the script:
import os
import shutil
import bpy

uvMaps = os.listdir('C:\\GameDev\\UVs')

for i in range(len(uvMaps)):
    if uvMaps[i].endswith('.png'):
    shutil.copy('C:\\GameDev\\UVs\\' + uvMaps[i], 'C:\\GameDev\\UVs\\Actual\\BallActual.png')

    Scenename = 'Scene'

    #quality
    bpy.data.scenes[Scenename].render.resolution_x = 900
    bpy.data.scenes[Scenename].render.resolution_y = 900
    bpy.data.scenes[Scenename].render.resolution_percentage = 100
    bpy.data.scenes[Scenename].cycles.samples = 200

    bpy.data.scenes[Scenename].frame_start = 0
    bpy.data.scenes[Scenename].frame_end = 44
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos1_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)
    bpy.data.objects["Ball1"].hide_render = True

    bpy.data.scenes[Scenename].frame_start = 45
    bpy.data.scenes[Scenename].frame_end = 77
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos2_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)
    bpy.data.objects["Ball2"].hide_render = True

    bpy.data.scenes[Scenename].frame_start = 78
    bpy.data.scenes[Scenename].frame_end = 108
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos3_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)
    bpy.data.objects["Ball3"].hide_render = True

    bpy.data.scenes[Scenename].frame_start = 109
    bpy.data.scenes[Scenename].frame_end = 135
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos4_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)
    bpy.data.objects["Ball4"].hide_render = True

    bpy.data.scenes[Scenename].frame_start = 136
    bpy.data.scenes[Scenename].frame_end = 160
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos5_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)
    bpy.data.objects["Ball5"].hide_render = True

    bpy.data.scenes[Scenename].frame_start = 161
    bpy.data.scenes[Scenename].frame_end = 181
    bpy.data.scenes[Scenename].render.filepath = 'C:\\GameDev\\Balls Sprites\\Ball_' + uvMaps[i][:-4] + '_Pos6_###.png'
    bpy.data.scenes[Scenename].render.use_placeholder = True
    bpy.ops.render.render(animation=True,scene=Scenename)

    bpy.data.objects["Ball1"].hide_render = False
    bpy.data.objects["Ball2"].hide_render = False
    bpy.data.objects["Ball3"].hide_render = False
    bpy.data.objects["Ball4"].hide_render = False
    bpy.data.objects["Ball5"].hide_render = False

The idea here is that each Ball is coming out from behind a Masked object and travels a number of Frames until it reaches an end, spins down and stops (end_frame). The animation is one long animation from 0 to 183. Each ball begins the travel after the previous one has completely stopped.
By hiding the previous Ball each time, I'm allowing to completely disregard the previous animation - using each Pos (in the file name - from 1 to 6) to be used as a different layer in the Spritehseet I'm creating from these animations.
Since all 99 animation sets are the same, I've created 594 different animation combinations. To be used as sprite animations in a 2D game.
Update:
After running this for three whole days, and barely passing half of the 99 ball renderings, I've added this:
bpy.data.scenes[Scenename].cycles.device = 'GPU'

See a tripling of speed, on average.

After running this for three whole days, and barely passing half of the 99 ball renderings, I've added this:
bpy.data.scenes[Scenename].cycles.device = 'GPU'


text:
Top structure that accept custom property
You can create custom property associated to a data type like this:
bpy.types.Objects.MyProperty = bpy.props.IntProperty ()

So now all objects have this interger property and it's entrered value is saved with the blendfile. Same thing with Scene , NodeTree , Nodes ... etc.
But where I can save a value available for the entire blendfile? Not associated to something can be added or removed from the blendfile by the user. A kind of top node in the datablock. I find a place but not really sure it's a good idea:
bpy.types.WindowManager.MyProperty = bpy.props.IntProperty ()

I can retrieve it to:
bpy.data.windowmanager ['WinMan'].MyProperty

Thanks a lot !

Think you'll find WindowManager properties aren't saved with the blend file.


text:
Exr data window in compositing
I try to make image compositing with Blender and my sequence images layers are EXR coming from another software ( Houdini ). Many software use a feature of openEXR call "data window". It's make a crop in the full image where you have data. This informations is probably embedded in the exr metadata. Most software are be able to read this cropping informations and get you image back to it's resolution ( for example 1920 x 1080 ). But in Blender compositing module , it's not to be the case and I just don't know if a option exist for that. If I render a image where all my 3D geometry take the place in the screen is not a problem but rendering a layer for a small object taking just some space in the full 1920 x 1080 resolution , Blender show it as cropped around this object. If it's a animated sequence , the crop just fellow the object frame by frame.
Any options or workaround for that ?

Display and data windows are not implemented in Blender.
For those wondering about them, read page 5 of the OpenEXR introduction.

Thanks for the info @troy, this look like still true up until today, is there any workaround for this ?

You would have to test it. I would think it still is a bit of a broken mess?

Sadly, I've tested in latest 3.0 alpha and it seem still true, my current workaround is to mix other image with the exact resolution and translate the exr image to fit, it works with still image but I don't think it will work with image sequence.

It is unsurprising that these details go unfixed for years. It’s half baked things everywhere, creating the illusion of fully baked.


text:
Generate Rig is not scaled correctly
So at first I was having problems generating my metarig so I went into the preferences and turned on the auto run python scripts which fixed the problem, but then I ran into another one my generated rig isn't scaled accurately to fit my character or pre-existing metarig what am I doing wrong? I've tried everything so far and I'm still running into problems.

What is the scale on your meta-rig?  Suggest applying scale to it before generating.

Your mesh should have its scale and rotation applied before rigging.
Select your mesh objects in Object Mode and hit ⎈ CtrlA > Apply Rotation, and redo it again for Scale.
When you manipulate Rigify's metarig, you should also have its scale and rotation applied the same way before generating the rig. If you already generated the rig, fix the metarig and then re-generate the rig.
You should avoid editing the rig object itself, many constraints might brake when doing that.

You can simply scale the rig with mesh using S then apply scaling using Ctrl+A

I've tried that it doesn't work

@DillonAble could you upload your .blend file to be able to help you?


text:
Blender with Digital Ocean?
Digital Ocean offer SSD cloud servers. Is it possible to run Blender on one? If so, what is needed?
Thanks,

Hum not sure what type of Cloud server that is or what services they offer, but this doesn't sound like a question about Blender, itself, more like a question for their support team. Could you please clarify, is this a question about Blender?

I'm voting to close this question as off-topic because it doesn't sound like a question about Blender itself

It is definitely possible to run Blender on a DigitalOcean server. That being said, I wouldn't recommend it as it's pretty expensive if you want good performance and fast render times.
Here's how to install Blender on a DigitalOcean droplet:

Download the latest 64-bit version of Blender (choose the right one for your droplet)
Move the file to /usr/local and unzip it
Add Blender to the PATH variable
Install some missing libraries. There's a how-to guide on which packages you'll need here: Installing Blender on a virtual server
Once everything's installed, you'll want to run your render via the command line: ./blender -b path/to/your/file.blend --engine CYCLES [the rest of the render options]

I toyed around with the idea of building a DigitalOcean-based render farm. After a few tests I concluded that it would be prohibitively expensive.

Did you find another service over DigitalOcean?

@BlenderGreenhorn No, I didn't really do much more research. My university has over 100 lab computers that I can connect to and render on, so I don't really need a cloud-based rendering system right now.

Yes. Though how much you can do may depend on the resources of the droplet you spin up.
If you need to run relatively simple scripts against the python api (i.e. load a .py script from the command line) you can do this on the s-1vcpu-2gb or what the droplet resize UI currently says is:

Basic / Regular Intel
1 vCPU / 2 GB memory

Though it may be tempting to use one of the headless docker images, I wasn't able to get those images to run, possibly due to memory limitations.
However, you can successfully install it on a 1-click ubuntu 20.04 / docker digital ocean template using:
snap install blender --classic

# Validate binary location
which blender
# Test execution
/snap/bin/blender --version

If you get an error:
/snap/blender/4036/blender: error while loading shared libraries: libSM.so.6: cannot open shared object file: No such file or directory

You may also need to install some dependencies:
apt install libsm6 libxext6 libxrender-dev


text:
Zoom locked to 3D cursor
So here's the problem: Regardless of whether I have "zoom to mouse position" checked or not, for my view is zooming to the 3D cursor. I am running 2.77, and I feel it is important to mention that this is only occurring in the 3D views. I cannot figure this out for the life of me so someone please help, it is getting annoying, especially when zooming way in.

Sounds like you may have accidentally enabled Lock to cursor in 3D view > Properties region > View:

Yes finally fixed

I'm using Blender 3.x. Click anywhere in 3D viewport, press N. Docked menu pops out. In the View tab, View Lock section, untick Lock to 3D Cursor.
That should be it. You should now be able to change navigation options in your preferences.


text:
How to setup blender to generate 2d background(s)
Okay. Let me describe in detail what I would like to achieve.
I have created a 3d scene that I would like to render so I can use it in my point-and-click adventure game as a background.
I know how to add a camera and set it to ortho and I can set the rendering to 640w 180h but when I renderer it looks pixelated (maybe 300w 80h) which might be because it uses a wrong resolution?
Is there a tutorial explaining what I need to do?
Thanks in advance.

Did you make sure the percentage under the resolution is at 100%?

it is 100%. Funny thing is also that blender starts to render the objects black but without me touching the lights. I then tried to move objects around to see if it was my lightning that there was something wrong with but when rendering it was the same image as before I moved. Weird.

It would probably be helpful if you posted some more information like screenshots of your 'pixelated result' and blender settings

First of all, make sure your render resolution slider is set to 100%,
Also, (forgive me if I'm mentioning the obvious here), but If you're rendering in Cycles, you need to set your sample-count higher, as that may be what's causing the "pixelated" look. A good starting point should be something like 500 samples. See below:

Yes. it is 100% :-)

still pixelated? how about your sample count?

A question that was totally overlooked.... What reender method are you using? Are you just going to the render mode of the 3D viewer for a quick render, or are you using the render context panel and doing a full render?


text:
Cycles render starts black and then renders as white
When I go to render my project; the render preview starts off black, and what is rendered is just a solid white. I've let it render until it's finished just to be sure, but it is in fact a blank white image.
I've started a new render so that I can provide an image of the problem:
https://drive.google.com/file/d/0B4v-GkVPDQUQVXZfRWd6TEU3Tzg/view?usp=sharing
Here is my project file from my google drive: https://drive.google.com/file/d/0B4v-GkVPDQUQaHdtdWU5RGVsa0E/view?usp=sharing

You are viewing the rendered image in the Alpha mode, so it's showing you the transparent data. To toggle back to the Color view, select the checker-board icon in the image viewer:


text:
How do I create displacement on a hemishere which can be 3D printed
https://drive.google.com/file/d/0B4v-GkVPDQUQNlJYZTltcmFrMUU/view?usp=sharing
I am trying to create a printable height map from a hemisphere shape.
The way I know how to do it on a flat plane is to use the displacement modifier and use an image. When I use an image that have the dimensions of the Radius (for Height) and Circumference (for Width) it creates the result shown in the above link.
I would like to know how to do it so that the image can wrap around the hemisphere and show the relief of the image. I would also like to do it in a way that would have minimal distortion of the image when I'm done. The image of the flower will not be the image I use for the final product, I just used this as a test. The final image will be a full image.
Later I would cut the object into pieces for easier 3D printing but right now I just want to get the object created.

although different shape, this could help you http://blender.stackexchange.com/questions/63106/how-to-decorate-cyclinder

The trick here is unwraping your mesh in such way that the image fits nicely on top with little distortions. The rest should be the same as a flat mesh. See how to unwrap a sphere in Blender


text:
Render is blank
I've made a field of grass as a test. When I click on the render button it flashes the progress bar for half a second and the render screen is black
Here is a link to the file on my google drive https://drive.google.com/file/d/0B4v-GkVPDQUQWkhzbTFwTHM4dFE/view?usp=sharing

How do the options in the Post Processing tab work? should also be of help.

Under the Properties Window > Render Tab > Post Processing Panel disable the Sequencer option

That seemed to work, thank you! Although it is functioning now, it seems to be rendering from that black screen to a white screen, do you know what might be a fix to that?

No clue. Check your render settings and lighting setup. When in doubt just create a new scene in the same file, link all relevant objects to the new scene, and render it from there

I've created a new scene and linked the objects to it but now it only displays a black screen even in render preview. What happens when you try to render it? Does it work for you?

Working fine on my end it renders albeit everything is pink because of missing textures. Don't forget to import lights and world settings too into your new scene. Also don't forget to change the render engine to cycles otherwise you wont be able to render


text:
Grid to many planes?
I need a lot of independent planes (like 200x300), but creating them programmatically with a loop took a lot of time (with bpy.ops.mesh.primitive_plane() or with vertices and faces). But creating one grid with subdivisions is very cheap. My problem is, that the vertices of the subdivision planes are connected and i need them independent (having each inner vertice four times).
So i would ask you, if there is an option to divide an grid in many independent planes?

@UlfAslak this is using a script not the UI

you can use the edge split operator to divide the grid into individual squares , then you can separate them by loose parts , here is the lines that do that :
        bpy.ops.object.mode_set(mode = 'EDIT')
        bpy.ops.mesh.select_all(action = 'SELECT')
        bpy.ops.mesh.edge_split()
        bpy.ops.mesh.separate(type = 'LOOSE')
        bpy.ops.object.editmode_toggle()

this works pretty good on small amounts (20x30), but if i use it on 200x300 blender freezes also. is there a solution for it? thanks a lot

I have tested this in the UI (no script) and blender is still frozen while i'm writing, so I suggest that you create small grid ( 10x10) separate this parts then loop over them  subdivide each (20x30) and separate ( when you separate the planes will be selected so just loop through selected_object )

can i divide a plane to a grid?

@vtni  mesh.subdivide(number_cuts = 10)

i have one last question: how can i get all separated planes in a list, to iterate over them (and split again)?

@vtni  list = context.selected_objects.copy()  then loop in this list , it want change with the selection because it is a separate copy

unfortunately with this method the whole computer freezes. i think i have to take a look at Modals.


text:
Depth map with distance along the camera Z axis
With RenderLayers Node you can get the Z distance from the camera to the object behind (x,y) which is sqrt((x - xcam)² + (y - ycam)² + (z - zcam)²). But is it also possible to get only the distance along the camera Z axis for each pixel in the rendered image?
Assumed my camera is at (0,0,0) and looks parallel to the X-axis and I have a point at (3,0,4). Then i would get the distance of 5, but it i need it to be 3. The camera could also be somewhere else or rotated in all directions.
Is this possible to read out?

You can achieve this using cycles' camera data node.
One of the outputs on this node is the view vector, which can be separated to x, y and z.
Using a simple node setup you can display only the Z distance from the camera in grayscale values.
In the example below I used the light falloff node to enhance the contrast (the Suzanne model is rather small and all the distances were small as a result, something that produced a low contrast whitish image, before contrast was added).
EDITED: replaced the seprate RGB with separate XYZ (does the same thing, but this demonstrates what's happening more clearly) and added an invert node so that farther values are darker (which is more intiuitive).


text:
Auto toggle between isometric when using 1, 3, and 7
Previously, I've always had a setting or something which would always switch to isometric view whenever the view is moved to front, left, or top view (with 1, 3, and 7), and automatically switch back whenever i pan away.

do you mean orthographic view? because the definition of isometric view would make it impossible to have for all front, left, or top views.

In 2.79 and older versions that would be the Auto Perspective setting. You can find it in the preferences under Interface.

If you are using 2.8 and later versions, it's now under Navigation then Orbit and Pan (it's enabled by default):


text:
Animated Curve Modifier + Cycles Motion Blur = Weird Render Artifacts
I'm trying to render an animation which involves two animated objects which have curve modifiers attached to them. After making a test render, I found some odd render artifacts, and I was hoping there's just some button I need to push to make this look normal.
I have done some tests and it appears the artifacts won't show up if I disable motion blur, but I want to leave it enabled for this animation.
Here's the animation
And here's a still frame where the artifacts are clearly visible:

Possibly overlapping geometry causing z-fighting. Check for overlapping faces or meshes - even if set to be transparent.

@RichSedman just checked for that, and I even tried applying the curve modifier during one of the problematic frames, and it seems to be clean geometry :(

Can you share your .blend - perhaps someone can spot something.


text:
2.79 Crash on Render (Except Viewport)
I just upgraded to 2.79, very excited about the new features (specially the Principled BSDF) but every time I press render image or render animation, it just closes. If I run blender from the command prompt, I can see the error
RNA_pointer_get: SceneRenderLayer.cycles not found.
Error: EXCEPTION_ACCESS_VIOLATION

Google turned up a couple dead threads, and nothing changed when I tried what was suggested.
I tried just making a new file, empty scene with just a camera, press render image and it closes. Same thing happens if I expand the preview pannel on a material. Strangely enough, viewport render still works.
PS: Is GPU support seriously gone? So far, 2.79 seems like a downgrade.

Make sure your system specs match the requirements for Blender 2.79. Also no, GPU support is not gone.

Make sure your preferences are set properly, and that you are using cycles. If necessary, download the installer/package and unpack/install Blender again and see if it works.

@VRM That did the trick :D

Using the "Repair" option with a fresh download of the installer from blender.org did the trick. Also fixed GPU rendering abilities


text:
Blender won't open correctly
I'm going to be real blunt here I don't have much to go on about but everytime I open blender I get a little lag from the application then a window in python opens up with the following text show in the picture below anyone have an Idea what's going on with my blender app the program won't respond I don't know what to do?

Spare us more information so we could help you. Example the version of blender you are using, your system specifications ... windows 10 64bit ... ram and build, etc... Also where did you get the version of blender, did you happen to download it off a unofficial website?

Some basic specification requirements to run blender here. http://blender.stackexchange.com/questions/75888/how-much-space-does-blender-take-up-on-a-computer/75899#75899


text:
Unwrapping angular mesh gives some islands distortions, why?
Selected islands are skewed, mostly the one on top. My process was modeling in sketchup, then knifing it to get quads, importing to blender via skp plugin, selecting 90 edges and marking them as sharp + seams, then unwrapping. But some islands get distorted, my suspicion is on small triangles at curves that confuse blender.. what do you think? Smart UV doesn't produce distorted islands, they all are straight (but it produces more islands compared to manual unwrap).

You said you marked all 90-degree edges as seams. This causes each little piece surrounded by 90-degree angles to become an island. Try then unmarking some of the edges (ones that would make sense to share as part of a larger area) and UV-unwrap after that.


text:
Incorrect instancing Collection Instance on mirrored faces
I'm modeling mechanical bird wings. The workflow until now was:

Collection of feather parts
Instance Collection
Make a Plane, added Array -> Curve (linked to Bezier curve) -> Mirror (linked to Empty)
Link Instance Collection as a child to parent Plane, enabled instancing on Faces on Plane

Result - as you can see, left side is correct, right side is incorrect and I don't know why, nor how to fix it.

I've made a simplified .blend file if someone would like to poke personally (just a small note, Collection Instance "FeatherInstance", is hidden in viewport)


text:
getting mask data into shader network through python or any other way
is it possible to fetch bpy.data.mask[] into cycle or blender internal shader as texture? Thanks.

I don't think there is a direct way to do this; Blender only has a Mask node in the render layer compositor, and not in the material compositor.


text:
How can I better utilize GPUs during CUDA rendering?
I'm using Cycles with CUDA rendering on a GTX 1070. CPU and GPU utilization during rendering is extremely spiky, most of the time both appear to be doing little work. Is it possible to smooth this out so that utilization is close to 100% all of the time? It seems like my renders could be ~5x faster if the GPU was actually working to its full potential.

Are there knobs I can tweak to try and improve this, or is this expected?

Looks to me like you're rendering multiple frames of an animation and you're seeing the scene geometry and bvh build phase on the CPU (unavoidable in many cases) and then the raycasting portion happening on the Cuda cores.
You may be able to take advantage of the cache options for the features you're using, but you'll need to provide a little more detail for a proper response.

This is likely the explanation, seeing as the CPU graph is spiking when CUDA is at 0 and conversely. Maybe there is a way to render on two Blender instances to take advantage of it ? I think it's highly unlikely to improve render times :)

@Gorgious I wonder if scheduling would be an even greater issue but it's an interesting idea.


text:
Cannot execute boolean operation with imported SVG
I imported some SVG objects, extracted them and converted them to a mesh. When I tried to perform a boolean difference operation between them, I saw the error message "Cannot execute boolean operation". When I looked in the console, I saw these errors:
uncontained hole loop does not share vertices with any face loop!
CSG failed, exception /build/buildd/blender-2.72.b+dfsg0/extern/carve/lib/triangulator.cpp:898  "didn't manage to link up hole!"
CSG failed, exception /build/buildd/blender-2.72.b+dfsg0/extern/carve/lib/triangulator.cpp:898  "didn't manage to link up hole!"
CSG failed, exception /build/buildd/blender-2.72.b+dfsg0/extern/carve/include/carve/csg_triangulator.hpp:330  unpaired.find((*i).first.first) == unpaired.end()

Here is a link to the file that I'm trying to use. I'm trying to subtract the 'QR' object from the 'BG' object. Is there something wrong with the meshes resulting from the import/extract step? What's going on here?

I'm about to look at the mesh, I suspect it's geometry weirdness like nGons or very large polys being compared against very small polys.

I used Remove Doubles.  I also removed all the interior faces.  I also diced up the large block into smaller segments and I still cannot get it to work.  Maybe the mesh has too many non-manifold components to be useable with the boolean modifier.  Hopefully, someone who knows more about this can help. :)
I even tried separating some of the pieces so it could be done in stages and that failed as well.

You could try and deal with this in another way.
I selected an upwards facing face and used shift+g->normals to select all the other faces that are facing upwards and deleted them.
Now if you select edges and press f, the faces can be filled in quickly enough.
By doing this, you can build up the large box without having to use the boolean modifier.

I suspect this is caused by several things.

The original QR geometry you provided is all separate triangles, this kind of mesh isn't suitable for a boolean because each vertex is only used by one face, and not shared by all faces that have a vertex at that coordinate. The image below also shows there are interior edges and faces

A few steps to improve the geometry before extruding to thickness are:

remove doubles (removes about 800 duplicated verts)
limited dissolve (joins adjacent faces, islands)
then extrude upwards
also remove doubles on the BG block

Manifold geometry

But the final problem is geometry like this: These islands when extruded are the basis of invalid geometry (though blender Blender can represent it because it isn't thinking about what your intentions are), when you try to operate on it with Boolean CSG it becomes an undefined problem.
More elaborately explained here What is non-manifold geometry?
This is much like if you tried to cut out a silhouette with a hole, the hole will drop out unless it is attached to something. You best option is to have small joins on touching squares:

A nice piece about this is seen in the work of Golan Levin:
http://www.flong.com/projects/qr-codes-for-digital-nomads/ . Of course stencilling is different, but it has similar subtle things to think about.
The negative geometry becomes this, you might find it acceptable.


text:
Match Depth of Field of Background Image
Either using Cycles or Blender Render - Need to match the depth of field on an object to a background image. Basically, I want to have a background image (that has DoF in it by itself), mapped flat on the background, and then a 3D object with matched DoF - so the DoF is only applied on the 3D object but NOT on the background image. Any hints welcome!

Not sure if there is really a way to do this besides eyeballing it..

I'm not asking for automation - the problem is that the DoF gets applied to the background image aswell, but I want the background image to be excluded from it because it has DoF already in itself...

If you enable Transparent under Film, then the background of the rendered image will be transparent, allowing for it to be easily composited with another image:


text:
External neighbors
I have this mesh with selected vertices.
Mesh http://imageshack.com/a/img661/3861/yKrabj.png
I want to do a script that automatically gives for every selected vertice, his neighbors (vertices indices) that are external to the selection. For example, some neighbors of several selected vertices that respect the conditions :
Neighbors http://imageshack.com/a/img537/172/wq2m2M.png
Sorry for my bad english.

How would you formalize the criterion of which verts to choose? Further away from the object/selection center? Higher total edge length (don't think this will work except for a very few, very simple meshes)?

As you can see, i have a hole in this mesh. The user has to select approximatively a border of the hole.
The criterion is for the neighbor to not be on the same side as the hole (the selection is between the neighbor and the hole).
Being furthest away from the selection center do not work as a method if the user didn't select the border well (because of the curvature of the mesh' border).

It's not really well formalized but that's the problem :p


text:
Formal definition of a mesh
For my master thesis, I need to have a formal definition of a mesh (if several definitions, the one used in Blender), in a mathemathical point of view. So "geometric model described by vertices, edges and faces, ..." is not enough. And I can't seem to find good literature giving the definition.
Sorry if my request seems stupid.

This wikipdia article has a good definition.

I already saw it but it doesn't express, for example, the fact that two polygons from a mesh either share a common edge or do not intersect.. I need something really formal. Thanks anyway for your response :)

I'm not sure there is agreement on a formal definition of what a mesh is within the Blender community, at least when I went looking for this some time back, I couldn't locate a formal definition. Further, I would note that based upon how I've seen different experienced blenderheads.use the word, there is no agreement that for a set of vertices to be a mesh, polygons  in that mesh must either share a common edge, or not intersect.

@Chaton you may have more luck piggybacking on the defintions found in Graph Theory and Topology, and valid mesh vs invalid mesh (ie Blender allows an edge to be shared by 3 faces, which can be handy while editing, but it breaks assumptions that some functions make about how meshes are constructed..and is considered invalid)

Your masters Thesis.. oh! i don't think i'm qualified to answer this...


text:
Cycles Render Engine Missing v2.74
After upgrading from 2.73 to 2.74, I no longer have the Cycles Render Engine available. It shows that it is enabled in the User Preferences Add Ons. I am using the Windows version, 64-bit. I am running Windows 7 Home Premium 64-bit.


text:
Scripting - Import, save, delete - Loop
I'm trying to create a python script in Blender, here are the steps I want to follow:

I have an existing scene where I want to import a specific .blend file from folder A.
Once the blend file is imported, I want to save the scene as a new file with the name of the .blendI just imported in another folder (folder B).
The deleted the imported .blend.

I want this script to loop for all the .blend I have in the folder A (100 files)
How can I achieve that? I'm a total noob in python scripting, so I don't know if it is possible or if it is the best approach for what I want to do...

Sounds like you want to move blend files from one folder to another, unless I don't understand your description... In that case you can use a simple python script without opening blender at all: https://docs.python.org/3/library/shutil.html

It is more like adding a blend file to a light setup and then save the whole thing in a new blend file


text:
What is causing this unexpected shading in 3D view?
I’m encountering an issue and I am wondering if anyone could help me figure out why my created 3D model is displaying this way in 3D view. I have tried to use correct language where possible, but I apologize in advance if my terminology is lacking, as I am new to blender and 3D programs.
I am attempting to create an object which shows up as Shadeless in 3D view. However, although I have created and applied a material which is Shadeless, some faces appear to be affected by lighting in the scene. This only appears to apply to the faces on the back of the character's head, and the character’s legs.
Even when I turn off Shadeless in the material, the problem persists in those areas. However, if I turn off Textured Solid (under the Shading panel in the 3D view), the problem is not present, leading me to believe this is potentially some kind of issue with the material as opposed to the mesh.
I have already tried:

Removing doubles
Selecting all faces and recalculating normals

Other things which may be of note:

Although the legs are separated from the rest of the body by a UV mapping seam, this is notably not the case for the area on the head.
The entire model renders with shadeless: the shading issue only appears in 3D view.

Here is a link to the blender file.

There's a few things.
The normals of the faces in those sections are pointing in the opposite direction of the normals around it, but that's not the problem you describe, however it might be a problem later, best deal with it anyway. You can flip selected faces, if 'recalc normals' doesn't quite get all of them.
There seems to be a Vertex Color layer, with specifically those faces coloured. Press the minus on this. That will wipe the vertex colours.

How this happened? Being new to an application it is probable that you accidentally went into vertex paint mode a few times.


text:
Bone parents to the wrong end
I am trying to parent the top of a bone to the bottom of another bone (see image) but when parenting  it will parent to the wrong end, I have tried but was unable to find a way to set it to the other end how can this be fixed?

You cannot parent joints together, only bones. Parenting top or bottom has no sense, you only parent the whole bone. The line is only a visualisation.


text:
Animation Nodes: Simple Grid Mesh not working
What's wrong with the following nodes setup? Why doesn't it create copies of Suzane?

You need to extract the number of instances from the vertex list:

There is only 1 grid mesh, so it feeds just single instance.

what version of AN are you using?
my grid mesh looks a bit different. but it should work for you if you connect the vertices output to the instances of the object output (not the Mesh)

Thanks. That was basically the mistake. And I'm using latest version of AN (2.1 I guess).