text:
How does texture mapping work in Blender?
New to Blender last month, I had mapped a rectangular image onto a
sphere using Cycles nodes.  I noticed that Blender put the seam (where
the left and right edges of the image meet) on the front of the sphere.
I wanted the seam in the back.  Rather than rotate the sphere, I decided
to rotate the texture around the sphere.
First I tried a simple Z-axis rotation of the texture.  The result was
worthy of Salvador Dali — not at all what I had expected.
Next, I tried shifting the texture by 50% of its width in the +X
direction and changing the Image Texture node's extrapolation option
from Clip to Repeat.  (See the picture below.)  The result was not
as distorted as the previous attempt but still nothing like my goal.
Obviously I was making some bad assumptions.  So I set out to figure out
exactly how transformation of textures works in Blender.  I built the
test bed pictured.  The Generated output of a Texture Coordinate node was
fed into the Vector input of a Mapping node.  That Mapping node's output
was fed through a second Mapping node (to allow multiple transforms in an
unambiguous order) and then to the Vector input of an Image Texture
node.  The Color output from the Image Texture node traveled through a
Diffuse BSDF shader node to the Material Output node.
I drew a test picture with distinctive regions, edges, and corners so I
could see what was getting mapped where.  I then projected the image
onto five test objects (cube, rectangular prism, sphere, cylinder, and
meta cube) in various ways by adjusting the transforms in the Mapping
nodes and the Image Texture node projection options.  I also did a
simple Flat projection of the image onto a rectangular plaque in the
foreground for reference.

I started with simple Flat projection and tried various multiple
transforms.  Once I had developed a model of what Blender was doing
and tested it on the Flat projection I went on to the Tube and Sphere.
So how was my original thinking wrong?  It took a long time for my
experiments to yield enlightenment because of side issues mentioned in
my answer below.  Hopefully someone else new to Blender can glance at
this question/answer and avoid losing the time I wasted.

Some related experiments on the same subject: http://blender.stackexchange.com/questions/73769/how-do-i-get-a-better-understanding-of-the-coordinate-system-in-blender/73797#73797

I eventually came up with a reasonable model for the mechanism.  But
along the way I was confused by Blender's order of transforms and
its display of materials.
Projection Model
My basic problem was that I was not considering exactly where the
object and the texture are located in what I will call "texture space".
Conceptually the object and texture are placed into texture space and
the surface of the object is colored according to where it intersects
the projected texture.
As a starting point for the texture mapping the object and the image are
made "the same size".  The object's bounding box (a rectangular prism in
its local coordinates) is scaled in the X, Y, and Z directions to create
a cube one unit on a side.  The cube with its distorted object is placed
in the first octant of the 3D texture space with its lower left front
corner at the origin and its upper right back corner at (+1,+1,+1).  The
rectangular image is scaled in the X and Y directions to become a square
one unit on a side (usually making its pixels rectangular rather than
square).
For a Flat projection the texture square is placed into the X-Y plane on
the bottom face of the object cube.  The lower left-hand corner of the
image is at the origin and the upper right-hand corner is at (+1,+1,0).
Each pixel of the texture square projects as a perpendicular rod
(rectangular in cross-section) that extends parallel to the Z-axis
towards infinity in both the +Z and -Z directions.
The problem that arises with rotations is that the axes of rotation are
the texture space coordinate axes which pass through the texture space
origin, not the more convenient axes at the centers of the object and
texture.  So if you want to rotate either the cube or the texture around
its central Z-axis you have to

Translate its center to the texture space Z-axis.
Perform the rotation around the texture space Z-axis.
Translate the center back its original position.

With the Tube projection the image has been wrapped around a vertical
(parallel to the Z-axis) cylinder of irrelevant radius one unit high
centered on (0.5,0.5,0.5).  Each pixel of the image projects
horizontally from the center of the cylinder outwards in an infinite
pie-shaped wedge one pixel high passing exactly through its rectangle on
the surface of the cylinder.
The Sphere projection wraps the image around a sphere of irrelevant
radius centered at (0.5,0.5,0.5).  Each pixel of the image projects from
the center of the sphere outwards to pass exactly through its rectangle
or triangle on the surface of the sphere.

So rotating the object or the texture about the Z-axis without the extra
translations separates the projected texture and the object, grossly
distorting their intersection.
Order Of Transforms
The first diversion on the way to the texture mapping model was figuring
out the order in which Blender was executing the transforms from the
Mapping nodes.
It turns out that within a Mapping node the transforms are essentially
performed right to left.  The scaling is performed first.  Then the
rotations are performed in Blender's default Euler XYZ order.  Finally
any translations take place.
However the order in which the chain of Mapping nodes is applied depends
upon the choice of Texture vs. Point set in the Mapping nodes.  (Assume
that all Mapping nodes use the same option and ignore Vector and Normal for
present purposes.)
With the default Point selection the Mapping nodes describe how the
object is transformed in texture space while the image projection
remains fixed.  The chain of Mapping nodes is applied left-to-right; the
leftmost Mapping node is applied first, and each Mapping node
transforms the result coming from the node on its left.
With Texture selected the Mapping nodes describe how the texture is
transformed in texture space while the object in its cube remains fixed.
The chain of Mapping nodes is applied right-to-left; the rightmost
Mapping node is applied first, and each mapping node effectively
transforms the result from the node on its right.  (This is the effect,
not how it is actually implemented.)
Point and Texture chains create net transforms which move the object
cube and the texture relative to each other.  Choosing between the two
approaches is a matter of convenience for the user.
Display Of Materials
The second diversion on the way to the texture mapping model involved
accurate display of the mapped texture.
The Preview display in the Material section of the Properties Editor is
your best friend.  If you are doing transparency or texture mapping you
need to have it active.
It did not dawn on me for a while that the 3D View was lying to me about
materials.  I naively assumed that if I set the 3D View's "Viewport
Shading" to Material I would see the actual material.  In fact the only
way to guarantee that is to select Render from the "Method to
display/shade objects in the 3D View:" (Viewport Shading) list.  The
limitation is perfectly understandable in terms of computation time;
using Render can be very slow so Material can be expected to compromise.
But one result is that an Image Texture node set for Clip will show in
the Material selection for the 3D View as if Repeat has been chosen.
That was confusing during the early tests.
The other limitation on the Material shading arises directly from
computational expense.  The non-Rendered display methods for the 3D View
cannot display some materials (e.g., transparency) on any object.
And they cannot display any material on some objects (e.g., a meta).
Moral
Do not make assumptions about how Blender works without taking the
time to test those assumptions.


text:
How to move multiple objects to a single point?
I don't really know if I am asking the question correctly. If you notice the picture, the objects are being pulled towards a single point (as seen by all those green lines). It doesn't look like they are using G, R, or S. I'm curious as to the method behind what this person is using.

https://www.take-a-screenshot.org will help you.

Its really hard to tell what is going on there, is that a tutorial? If so post a link to it.

"If you notice the picture" - I noticed the picture, but couldn't figure out what it was supposed to show...

you fixed the screenshot! (un-downvoted, and upvoted)

This effect is what happens when you transform (move) several objects along one of their local axis. You can tell this because in the status bar in the screenshot it says 'along Local Y'.
Each object in that screenshot has been rotated so it's Y axis is pointing inwards or outwards:

Then the Transformation orientation in the 3D header has been set to Local, which means each object's local axis will be taken into account during the transformation:

With all the objects selected, pressing G,Y,Y or moving the 3D Manipulator will start a local transformation on each object's local axis (the green lines):

Ahh, good call & correction, I started along this path before the last updated screenshot, so I didn't quite catch that, as I was already down my own thought process.

This is most likely a group with a parent.
The reason for the Green Color explains the group part.
The influence all coming from the same place indicates that there is most likely a common parent amongst the grouped items.

And if they are not using G, R, OR S, then they are probably using manipulators like the following:

OR
It most likely has animation keyframes or drivers controlling this.

Per your update on your question:
Here is the Shape Key version of this same concept:

I have added a new snapshot. It is a timelapse video of the tree from the "Monkaa DVD."

OK, the screenshot shows shapekeys, that's animatable (keyframe-able), you want to study up on shape keys.

source: Stack Exchange

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

sort: votes


text:
Panel to the right disappeared (properties? Not the one you toggle with N)
I'm new to the software, using blender 2.78 on an iMac with OS X 10.6.8.
I've been working on a file for a few days now, when a important panel to the right suddenly disappeared.
This is how it looks right now:

The panel marked in red in this picture is the one i need:

Notice how the three lines in the corners that you can grab to change the size of view windows/panels also is gone in the file I'm working on. Marked with green circle in top right corner.
Edit: Solved the problem by opening the file with "load UI" unchecked. Still wonder why the three lines in the corners of the panels disappeared though.

You probably hit Shit + Space and made the 3D view fullscreen

Probably you have hit Ctrl+"Arrow up or down" or Command+"Arrow up or down" which allows to focus on the view your mouse cursor is on

@DuarteFarrajotaRamos... it seems, both are working!! But I did not know yours...

This is why I love BSE, after so many years of using a software we can still find hidden features :)

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


text:
How to correct cloth physics?
Alright, so I work in a print lab and have recently been asked to make some product models for our website. One of our products is a table cloth. I have made the plane the proper size and shape, and have a simple cube which represents an 6' table. At this point, there are no issues, the simulation is just slightly glitchy. However, when I resize the table to 8' (our cloths fit both sizes) the cloth seems raised on the sides. I'm not sure how to correct this. A screenshot is included below.

Does anyone know how I can get it to lie flat rather than look like there is something on the table underneath?
Update: Here is the mesh I used for the cloth

Can you post your mesh? Try applying the scale of the cloth

So I managed to resolve the issue. It turned out the impression was due to my vertex group. I made a large selection of what would be on top of the table, and the sides of the mesh which were not part of that group were being raised as a result (for some reason). I deleted the vertex group and it now looks the way it is supposed to.

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


text:
How do I destroy all these user preferences UI elements?
I'm new to blender and for some reason when I clicked on "edit user preferences" from the dropdown menu of the wrench in the top left nothing happened, so I dragged the corner near it which  created a new toolbar somehow. I tried to drag that to close it but it made even more toolbars. I kept trying to close them but I only got more and more! Then I was somehow able to get it open as a pane in the main window, and the same thing happened when I tried to slide that one closed! Why is the even possible? Why would anyone ever want more than one? Is this real life? Is this just fantasy?

That image made my day! thanks, +1 just for that :) Now good luck closing them all..

How do I close them though??

OH! I figured it out. Only a toolbar can truly kill a toolbar... Thank you!

Flexibility kills flexibility....


text:
How to align one vertex to X, Y or Z of another vertex
sometimes I need to complete tasks like in this video, any easier way to connect this vertex to edge?
https://www.youtube.com/watch?v=PVCdgss5gKI&feature=youtu.be
And also, sometimes I need to align one vertex in 3D space by using X, Y or Z of other vertex, is there any combination of keys which can do it?

before your cuts (if several), set pivot as active element, after the cut, make select and active the wanted vertex, then scale X (or Y or Z) 0...

A bit better : is you start to cut from the existing vertex, it stays active after the cut : so method in the previous comment is faster

Yep, I know this way and it's working, but it's align both vertex to median point between them, isn't it? What if I want to align first vertex to second or second to position of first?

The key is to set the pivot point to active element first (so that this is not the median which is reached)

Please edit the title of this question so it is descriptive of the task you are trying to achieve.

To do that quicker,
first method
set the pivot point to active element and start your cut from the existing point (as this will keep this point active).
Then scale to 0 using the wanted axis :

second method
Use 'offset edge slide' Shift+Ctrl+R.
During the movement place the mouse along the shortest edge and hit E.
After that you'll need to remove doubles or merge the vertices.


text:
Best way to model the top of a rook piece?
I'm having problems modeling the crenels (battlements, castellated parapets) of a rook piece. The basic modeling is easy, the problem comes with subsurf modifier. I can't achieve the shape I'm looking for.

Any combination of bevel, edge loops, creases, gives me artifacts, or I lose the circular shape in the top view.
Here is the blend file, if you want: http://www.pasteall.org/blend/31339

You never want triangles on a mesh you are going to subdivide as they will result in pinching.
The images above seem to have some, introduced by the bevel tool probably.
Using a pair of edge loops to sharpen the rings, and then a pair of edge loops top and bottom per crenelation you can get close to the shape you want. But there is some blockiness when you look down from top view.

If you want a smoother circumference, you can
-select the face loop you have inset near the top and hide them. (Hiding faces will prevent edge loops from continuing past them when added.)
-Add some additional "spoke" edge loops as shown. As there is one ring hidden, the loops won't cross the entire object, creating some ngons in the inset area.

-Scale the new short edge loops up just slightly on the not z. scale the entire section above the hidden faces down about half that much to split the difference
I know, I just said don't use triangles and then here I go introducing poles in to your mesh, but they are nicely tucked away, it works and it's easy :P

http://www.pasteall.org/blend/31346
Source: I just finished watching 4 hours worth of topology videos by Jonathan Williamson, the cg cookie guy.

That's just what I wanted, thanks. I discarded the option to make a lot of loops to make the top part rounder, as it creates too much topology, and distorts the circular sections below. But with the hide trick, it becomes a nice solution. Thanks!

While studying your solution, and trying to make all the 'spoke' edge loops at once, I've discovered the Subdivide Edge-Ring command (in the search box). The nice surprise is that you don't have to hide the ring, and the best of all, it keeps the circular shape in the perimeter! Hope you don't mind if I add this technique to your solution.

@DavidGasku  not at all. that's downright handy.

Add EdgeSplit modifier, set to less than 90 degree and then use MeanCrease only on the top of model.


text:
Knife Tool Limited Cut - Not Cutting All of Mesh/Edges
Currently, I am trying to cut my mesh in half with the knife tool, K. The cutting seems to work at the top and side of the mesh (I pressed enter), but it won't apply at the bottom.

Img1 and Img2 show the bottom edges which I am not able to cut. The knife tool won't even apply on these edges and doesn't change them into the red/purple color.
Img3 shows the cuts at the top and side which work perfectly fine. Without the bottom, I am not able to cut my mesh in half. Have I missed something?
Thanks.

Hi, welcome to the site. In future please crop your images to only the relevant areas and upload them directly to your question instead of linking to them.

It's hard to make out what's happening in the images but have you checked your model for doubles? Go to edit mode, hit Atrl-A, then W - Remove Doubles.

Try uploading a .blend file. Maybe also consider using Ctrl + R for Loop Cut instead of the knife tool (more efficient/easier).

@ Ray - Hi, sorry... in future i'll do that, thank you ! ...... @ metaphor - My bad , you were right !!! after i used "remove doubles" it worked. Thank you so much !! ..... @ Shady - i'll keep that in mind. i like the loop cut function ! .... thank you all for your help

@Roadhouseman If you want to mention a user you need to make sure there is no space between '@' and their username, otherwise they won't be notified.

Since you said "trying to cut my mesh in half ", is using the knife tool mandatory? Maybe you already discarded them, but there are other (probably better) tools, like the bisect tool, or the boolean modifier.
Bisect tool: this allows you to create edges through the whole mesh by setting a "bisect" line, like this:

Start switching the 3D view in edit mode, and adjust view to allow you to "bisect" drawing on the 3D view, like:

After clicking on "bisect", draw a single line (eg) from top to bottom: after confirming the end point, the cut is already done!

Now your mesh has an edge that goes through all its geometry: you can use this dividing line as reference to delete all geometry (eg) to the right of it:

you'll get

Another way, as said, it using boolean difference, and since is a modifier, is also non-destructive (until you apply):

Create a big cube that contains all the part of the mesh that should be "cut" away from the mesh

Then select your mesh, and apply a "difference" boolean, with the big cube as target

Done! Your mesh is cut, but you can still change cube (and this cut) position. Note that the cut zone ill be "closed" by a side - you can get rid of this after, if needed.

Yes, the knife tool can do what he wants, exactly the same way the bisect tool does.

Yes, you're missing something.
The Knife Tool can cut all the way through a mesh if you toggle "cut through" by pressing z. Notice at the bottom of the 3D Viewport after you press k to start the Knife Tool, there are instructions about the other functions the Knife Tool can use. It'll even show you whether "Cut through" is currently ON or OFF.
It also describes other functions of the Knife Tool that you might find useful.

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


text:
Automatically "routing" a tube through a confined space
I have an irregular curved funnel-like 3D space and I need to "lay" a "tube" in it so it is goes through the "middle" of the funnel.
The sketch below shows a 2D section of a possible scene (the "tube" is shown in red, black represents "walls" of the space, blue is just a place where the "tube" is attached.):

Is there a way to get Blender "route" the tube through the space (semi)automatically?
By semi-automatically I mean manually selecting possible additional constraints (objects/points/...) or entering some parameter values and then letting the automated process do the rest.
I know I can use Curves to draw a path and manually adjust it so it fits, however, I would like to automate it as much as possible because the process will have to be done many times in different spaces (but generally similar in shape).
(I also know how to make a "tube" by adding a bevel to the curve as well as how to use hooks to modify it.)
Could this be done by first creating a curve (with high enough resolution) and then making it "snap" to the "average" of the enclosing space ...?
I'm new to Blender and 3D modelling but I'm quick in acquiring new skills.

I have updated the question to emphasize the point that I'd like to make the process of routing as automated as possible. Thank you Mentalist and PaulGonet for trying to hep, I appreciate it, I learned something from each of you.

What you are looking for is somewhat mathematically complex but of course possible through scripting. Here and here are some approaches. Laplacian smooth and Decimate are implemented in blender as modifiers and could be used as a starting point.

If you know the mathemathic function which describes that curve it should be possible to use Add Mesh: Extra Objects addon with that function entered in value field, like in this question. It won't be possible to edit that created mesh afterwards in this way as this is only possible to change using Last Operator menu though.

Thanks @user2859, that is interesting material, I'll look if there is a way to use it.

@MrZak, thanks, but unfortunately the funnel in this case cannot be described with a mathemathic function so cannot the resulting curve. Besides, if I had that, I would not need to route it. That is, unless i misunderstood your comment ...

After giving this some thought, I have come up with another approach that might be a solution for you. It does require that the mesh of your space has quad topology, so that edge rings which flow along the tunnel can be selected and scaled in.
Of course, if you don't have control over the initial topology you will have to retopo first. I believe the RetopoFlow add-on would be the fastest way, if you need to do this.
Select and Scale your Edge Rings
So you have your mesh object of your space:

Press ShiftD to make a duplicate of it, and move (M) it to a different layer.
In Edit Mode, with Edge Selection enabled, select only the edge rings. This can be done from the menu: Select > Edge Rings, or with the shortcut ShiftCtrlAltRClick. Do this until every edge ring is selected.
Set your Pivot Point to Individual Origins. This causes each selected edge loop to shrink toward its individual center when you scale them down, creating a path that passes through the center of the mesh.

Scale your edge rings down to zero. (S,0,Enter)

Press W > Remove Doubles to get rid of extra overlapping geometry.
Smooth it Out
In Object Mode, add a SubSurf Modifier to your object to smooth it, if you want it to be smooth. Adjust the subdivision levels as desired.

Apply the SubSurf Modifier.
Convert your Mesh object to a Curve object. (AltC)

Adjust your Curve Settings as Desired

Above: A wireframe display of the original Mesh object, and the new Curve object, with both layers made visible together.
That's it!

Alternative to RetopoFlow would be shrink wrapping your quad geometry to the tunnel.

@Mentalist, this does looks like a solution although I'll need to look into the retopo thing as the funnel shape I have is rather "organic". I can't do it today though, not sure about tomorrow. Will report on results as soon as I try it out.

@spacer Cool, please let us know how it works out for you. I am a fan of the Shrinkwrap method that Jerryno mentioned as well.

@Mentalist, Jerryno, I have finally found some time to test this and it looks very promising. However, I'm having two problems: A) shrink wrapping nicely around the curving funnel (I get "artifacts" spanning empty space outside the funnel) and B) selecting all edge loops automatically (without having to pick them out by hand one by one). Can you, please, give me some hints toward solving that?

@spacer Tip#1: Model your retopo mesh while the Shrinkwrap Modifier is on it and set it so you can see the effects in Edit Mode. By extruding one step at a time, and checking your modifier results along the way, you won't run into surprises later. Tip#2: Set the Shrinkwrap Modifier's Mode to Project, and the Direction to both Positive and Negative.

@Mentalist, thanks for the tips! However, I need to automate the process so cannot do manual extruding. I have already set the Shrinkwrap modifer's Mode as you suggested. Maybe Shrinkwrap is supposed to work that way. Or more likely I didn't understand something right - but what?

Hmmm, it sounds like you may need to code something custom to calculate volume and then operate accordingly. The bundled add-on "3D Print Toolbox" can calculate volume, but you also need to do something automated with that data. No tool for this immediately comes to mind, but I'll let you know if I get any more ideas. Maybe you could somehow modify the script.

Thanks @Menthalist, the script is a bit advanced for me at this stage, I'm afraid, but I'll keep the bookmark just in case I decide to revisit that approach. I will certainly appreciate it if you get back with any idea. It is just that I'm too novice with Blender that is hampering me. For example, Bisect tool makes such a nice "loops" that can be scaled - if only I could make bunch of these along funnel axis, connect them and scale them to zero like you did with edge loops ...

Your diagram gave me a chuckle.  :-)
Beveling Curves
There is a handy Bevel feature you can enable with Curve objects to get the effect you are describing.
In Object Mode press ShiftA to Add > Curve > Bezier
Press Tab to switch into Edit Mode for the Curve.
Then in the Curve Context, increase the Bevel Depth. Set the Fill mode to Full to make it round like a tube. Increase the Resolution so it will become rounded. Raise the Resolution of Preview U if you want to smooth out the length of the curve.

If you then need to convert this into a Mesh object you can do this from Object Mode by pressing AltC and "Convert to Mesh".

Taking it further
If you need something more complex than a simple wire or pipe you can experiment with Taper and Bevel objects to further shape your Curve. Or you can even model a custom Mesh object and use the Curve Modifier to stretch it along a Curve.

thank you, but I know about the Bevel feature (I will edit the question to clarify that). What I need is to - automatically or with some manual "help" - "route" the tube to nicely follow the funnel.  Maybe something along the idea of snapping the curve to "average" of the enclosing shape?

Oh, and yeah, maybe I should have added another bend so the diagram would look more like elephants front appendage rather than the middle one ;) lol

You may easily control the tube using Hooks.

Select the Curve and bevel it using Bezier Circle.

Now select the curve handle's center and press Ctrl+H-->Hook to New Object. Repeat the process with other handles. Now transforming, rotating and scaling the hooks you have a full controll over your tube.

Thank you @PaulGonet, I'm aware of hooks too. I realize now that I should have mentioned that in the question too, sorry. The post is useful though, I'm learning :) What I actually need is to automatically fit the tube within the funnel, then tweak it if necessary.


text:
My wrist controller is angled oddly
I want the controller to be more aligned with the hand.
Anyone know how to fix it?

here is a
using the cutting edge software update

Please mention when you are using Blender 2.8. Since it is still an unreleased, unstable, beta version: a lot of people don't even have it, don't open files with it by default or don't know how to deal with it.

I don't know why your hand controller is rotated, because your metarig doesn't produce that. You might have done something we don't know to get that. Fixing it manually might take some time.
However, since you're using Rigify and that your metarig seem to be correct, it will be quite simple: regenerate your rig from your metarig and it will be fixed.
For that, select your metarig object. Then in the object data tab, head over to the Rigify Buttons panel, usually located at the very bottom. You will just need to change the target object in your meshes's Armature Deform modifiers for them to be deformed by your new rig. The skinning should remain intact.
If you want to generate a new rig, simply hit the Generate Rig button.
If you want to override your already existing rig, hit the Advanced Options button first, set it up like the following and then hit the Generate Rig button:

No need for modifiers retargeting this time.


text:
Slide edge to opposite edge - geometry nodes
I'm working on sliding the edges of a cube to the opposite side using geometry nodes.
I almost have the solution; it works by sliding the factor of the mix, but there is one problem: when the edge slides to the other side, it scales to zero.
Could you help me fix the nodes so that it slides completely to the other side?
Blender 3.6.9

You don't want to sample the edge, instead you want to sample the vertices. It would be a bit more complicated, as you need to adjust 2 vertices instead of 1 edge, but I think this is the way. In fact, I think Set Position works on the vertex domain, so currently both vertices of 9 go to the position of the edge 6.

@Lutzi Thanks, you're right, it works this way. It doesn't look too good, but it works! :)
But I'm sure there must be a more elegant solution, if anyone has a good idea for this, please share it here, thanks! Here is my solution:
link

I agree with @Lutzi here, the Set Position node works on the vertex domain. Using the edge index for the Selection input selects both vertices of the edge with index 9. Then sampling the position of edge 6 gets the center of the edge, then the Set Position node moves both vertices to the center.


text:
how could I get the neighbor faces of a face in GN?

For the face F, how could I get the ID/Index/any information of f1-f4 in GN?
The Face Neighbours node only provides face/vertex count, just doesn't help.

AFAIK you can't...but...maybe in the future...

To select the faces adjacent to a specific face, you can use the following solution:

Here, first evaluate the corresponding selection in the Face domain and then repeat the process with the node Evaluate on Domain, but select the Edge domain and set this to "Float".
What happens here?
First, a Boolean value is defined in the face domain, which outputs true or false depending on which faces are selected.
In the second step, this is evaluated in the edge domain with a float value, which means that all edges of the selected faces are assigned the value $0.0$ (for false) and $1.0$ (for true).
However, as the neighboring faces are to be selected at the end and the query is therefore based on the face domain, the float values from the edge domain are then interpolated and rounded up again to a Boolean value (true or false) as soon as just one of the edges has a value above $0.0$.
Btw: If you switch the node from "Edge" to "Point", you can also select all adjacent faces that do not share a common edge:

And of course this solution also works if you select several faces at the same time:

Is there any update to this?  I have an open mesh, and am resorting to Evaluate on Domain from face to edge to point to face in order to select (yuck). But even then there's not a good (fast) way to read a stored attribute. With Eval at Index I can get 30 FPS on a grid with known indices, but on arbitrary topology the domain selection technique yields 12 MINUTES per frame.

@SO_fix_the_vote_sorting_bug Yes, there are now more elegant solutions than the one proposed here. I have updated the answer accordingly. Regarding the speed: In my tests, the calculation takes approx. 2ms for 500,000 faces. How many faces does your mesh have or can you show an example?


text:
Scale edges symmetrically, preserving UVs
I want to Edge Slide two Edge loops on Y-axis. Normally, I would press S and Y to scale on Y-axis but that wouldn't preserve the UVs. And Edge Slide doesn't allow me to slide symmetrically along an axis. Is there a way to achieve that effect using Edge Slide?
Thank you!

Hello :). Since Blender 2.9 it does actually update your UVs, so no need for edge slide :).


text:
Anyone know why in this video, this bone detaches the arm to my mesh?
I don't know why this happens: https://i.sstatic.net/fZG2S.jpg. This happens with NO other limb. Any help?

It probably is just that the upper-arm's mesh is assigned to that bone or a child bone.
Select this mesh, switch to weight paint mode, and check the different bone's weights.


text:
Object says it's zeroed on an axis, but it's not. How do I fix?
I have this object that says it is zeroed out, but it's actually not and I have a reference object to prove it. I believe it started showing this "false zero" because I joined it to another object earlier, moved it,  but then separated it. Is there a way to move this object to the "true zero"?

It depends on the object, and where you want "zero" to be in it. You could try selectcing the object and (in object mode) from the top of the viewport select Object > Set Origin > and then try something like Origin to geometry or Origin to Center of Mass. That will reset the origin of the object, then you can place it back at 0,0,0 coordinates using the transforms in the N tool menu. However, if your object had its transforms modified  (and applied) when you joined it, you may have to reset it manually (by eye).

Coordinates are linked to origins of objects.
So, Right click in Object mode > Set Origin > Geometry to Origin will move the object to its origin which has zeroed coords.

Thank you! Also, one more question. Do you see Christopher Bennett's answer? Why doesn't it give me the ability to upvote or make his the answer? It doesn't even show the arrows.

He probably hid it to clean up the site.

His answer can't be marked as the preferred answer because it was given in the comment section, instead of in the answer section. Only answers given in the answer section can be marked as the preferred answer. Sometimes users give their answers in the comment section when they want to offer something helpful, but don't see their contribution as a full answer. Or sometimes they give simpler answers in the comments section for convenience.


text:
Is there an addon or method to find all objects that don't have a certain modifier (solidify)?
It would be very useful. It really sucks to come across a weird looking object after you have already worked on the export and have to go back to Blender to fix one mistake. Sometimes you have to go back multiple times because you keep coming across them. It would be cool if I could just select all then solidify them. Anyone know what I could do other than to just make sure to solidify each object as I create them?

is a python script solution ok for u?

you can use this python script:
import bpy

for o in bpy.context.scene.objects:
    if o.type == 'MESH':
        for eachMod in o.modifiers:
            if eachMod.type == "SOLIDIFY":
                print(o.name)
                o.select_set(True)

it will select and print out the names of all objects which have solidify modifiers.

Or as a one liner
[o.select_set(o.type == 'MESH' and not [m for m in o.modifiers if m.type == 'SOLIDIFY']) for o in bpy.context.scene.objects] :)

Very nice!!!!

@Gorgious Ahem!.. sorry, I seem to have a slight cough today... :)

@RobinBetts Yeah ! it's a self-centered running joke but I can clearly see how it's a bad idea to encourage people to use this kind of monstrosity ^^


text:
Distribute object instances at every vertex
Can I distribute object instances at every vertex? I tried with the new geometry nodes but it only distirbutes randomly (see screenshot).

Get rid of the Point Distribute node. Just use the Point Instance Node.


text:
Normal maps Problems
well after some time of breaking my head trying to figure out what im doing wrong, i decided to ask.
here is the blend file with my different "try's", i just dont know what im doing wrong, every single one has an artifact or a seam, etc

all where baked with xnormal, 1024x1024 8 edge padding 4xaa.
the blend consist of different cubes, a standard one, a bevel one, and a bevel one with a bit more details. (also seam,noseam,sharp, i just had to try every single method..) also the normals are packed in.
well hopefully i could get some help. here is the result of the normals, you can find more into the blend (different try's in different layers)

hopefully i can get some help, long time breaking my head with this, sometimes it works with more complex objects, but now i cant even do a simple cube.
Bye!

Oh dear! you already broke your head? I usually ask before I get to this point

Hmmm ... don't seems to get what sort of issues you are having with the seams but it all seems alright to me. You mind adding a red circle on the area with issues?

sure, added, also if u open the file u can check from different angles, i just dont know what method to use, if the sharp are used correctly, the difference beetwhen seams and no seams.. (mb my eyes are tricking me)


text:
Render only an object and its shadow in Cycles
I am trying to create a an image of an object (say a cube) and its shadow, with any other pixel except for the object and shadow being transparent, in Blender 2.7. I need this since I will place the resulting images next to several others in Photoshop later, and also as standalones, in a scientific paper which requires that all images have a transparent background.
I know this question has been asked many times before, but all the answers I found are lacking, namely:
this question is similar, but the answer uses a "shadow" output of the layer which I couldn't find (I assume it doesn't exist in 2.7?). On the other hand, this video gives a nice solution in case you are trying to place your objects + shadows on top of an existing image by multiplying outputs, but does not produce an image with a transparent background, and I don't see a way to modify it easily.

The shadow pass does exist in 2.7.

Related: http://blender.stackexchange.com/a/5160/599

@gandalf3 Thanks, I am quite new to blender, I didn't figure you could add a "shadow" output. I now went to the layers dialogue and ticked the "shadow" tickbox. This added the "shadow" output to the render-layer node, but inspecting it I see that it is simply zero everywhere. Am I still missing something?

Mesh lights won't cast shadows, see http://blender.stackexchange.com/q/5416/599

@gandalf3 Great diagnosis based on symptoms only. you should be a doctor :) Thanks! You prefer to answer this or close it as yet another duplicate?

@gandalf3 - one last question: I changed my light to an area light, but now the "shadow" output outputs a binary mask, of only completely white or completely black patches. The real shadow has a smooth gradient, and according to the other examples this is what I should get from the "shadow" output, no?

That's odd.. I seem to remember that happenening to me a while ago, but never was able to figure out why.. Is it possible you could upload your .blend?


text:
How to split a beveled surface to two parts to use different materials
Recently I asked this question and got a very nice answer:
What is the easiest way to smooth the intersection of two planes?
However, now I would like to use a different material for each face. Could anybody help me on how to do this? Written in python script would be best.
Thanks,
Mojmir.

Would you be willing to use a subdivision surface with "control loops" ? http://www.youtube.com/watch?v=aQZ5ZAldzu4 (I couldn't find a text article that explains the technique in my time quota).  Solving it in python would require about 30 minutes of analytic geometry and 30 minutes of futzing with bmesh.

You can directly set the material of a face. api docs

pink vertex: Yes that is true but how do I select the face? Where are they located I was trying but they are not as edges. One cannot do obj.data.faces[i] like with edges obj.data.edges[i]


text:
Font too small in tool shell
I have to clarify that this is only the case in one file and only in the bottom of the tool shell

Blender kept crashing when I tried to convert hair particles to mesh on windows so I went to Ubuntu and converted them there however I must've pressed something there because the font on the bottom of the tool shell is suddenly small
What I've tried :
*reset theme to default
*make side by side comparison of the "broken" user preferences with the user preferences of a new project

You can zoom individual panels in and out. Try pressing Home while hovering your mouse over the keyboard.
Similar Question


text:
object.ray_cast returning a Vector with zero coordinates
For some reason my raycast always returns zero location.
import bpy
import mathutils

originObj = bpy.context.active_object

#This converts tuple and Vectors to local or global
def globalToLocal(globalToLocalConv, objectForLocal, vectorOrTupleToConv):
vectorified = mathutils.Vector(vectorOrTupleToConv)
if globalToLocalConv:
    #global to local/object space
    return objectForLocal.matrix_world.inverted() @ vectorified
else :
    #local/object space to global
    return objectForLocal.matrix_world @ vectorified

#Actual rayCasting code
castResult = originObj.ray_cast(globalToLocal(True, originObj, originObj.location),
    globalToLocal(True, originObj, (0, 0, originObj.location.z)))

print(castResult[0], castResult[1])#show if the ray hit and where

Any ideas as to why?
Here's a demo file(created on 2.83 but it has the same result in 2.93 portable edition)
Also I'm an amateur with Python. The only other time I use it is for Robotics which has nothing to do with the Blender API. So maybe I'm missing something obvious?

I'm confused - are you wanting to detect the circle hitting the cube, the other way around, or detect the circle hitting itself? It would have been great to clarify that as well as a picture from the file:

Instead of waiting for feedback, I'll assume the first option is what you want based on your file naming convention. But first, regarding your main question of why it's returning zero, remember that the hit location given to you is in that object's local space. You don't need to convert it to local (as you did in your file). Second, self-intersections are possible, so it's best to add some epsilon to your origin (if part of the mesh is on that origin) so the ray cast doesn't accidentally hit itself at your origin.
In short, an object's ray_cast() is only aware of itself, and therefore can only hit its own mesh. You can use the context.scene.ray_cast() which is nice since you don't have to worry about coordinate conversion between spaces, but that means it can intersect any object.
If you want to use the object raycast, simply do the ray_cast() function on the obstacle instead. Here's the final result (some slight refactoring for readability for other users):
import bpy
import mathutils

context = bpy.context
originObj = context.active_object

obstacle = context.scene.objects['Obstacle']

def globalToLocal(objectForLocal, vectorOrTupleToConv):
    vectorified = mathutils.Vector(vectorOrTupleToConv)
    return objectForLocal.matrix_world.inverted() @ vectorified

def localToGlobal(obj, vectorOrTupleToConv):
    vectorified = mathutils.Vector(vectorOrTupleToConv)
    return obj.matrix_world @ vectorified

#Actual ray_cast code
origin = globalToLocal(obstacle, originObj.location)
obstacle_origin = mathutils.Vector((0,0,0))
direction = obstacle_origin - origin
is_hit, location, _, _ = obstacle.ray_cast(origin, direction)

if is_hit:
    '''moving some vertices to visualize the locations'''
    world_loc = localToGlobal(obstacle, location)
    #Ray visualized. Origin
    originObj.data.vertices[0].co = (0,0,0)
    print(originObj.location)
    #Raycast hit location
    originObj.data.vertices[1].co = globalToLocal(originObj, world_loc)


text:
Weird deviation when extruding vertexes
I banged my head yesterday, thinking my modeling was sloppy, but now I see the problem is somewhere else.
Take a look at the picture:
What I did: simply extrude the top-left vertex to the bottom-right vertex of the cube, using the Snap during transform option, set to snap to vertexes.
In every case, there is a deviation of sorts and will happen on one axis (always the third axis, which should always stay at 0, but it deviates instead).
Does anybody know what's causing this issue and how to fix it?
EDIT: If I wanted to simply connect those verts, I could have done it just as easily by selecting them both and press "F" to create an edge. That is not what I wanted to do.
What I want to do: basically, by extruding vertices to other ones using the Snap feature, I was measuring if there were deviations in my mesh geometry, removing those extrusions after (with Ctrl-Z). The Extrude feature can easily be used as a measurement tool like that - even extrude a face toward a desired edge or vertex, to check how it sits in correlation to the face being extruded.
But with those deviations that happen even on the basic starting cube, how in the world can I use the Snap-to feature when it produces such deviations?

Are you talking about the less than 1/1 000 000 of units ? If yes, you can't. This is due to floating point values accuracy.

I just tried the same on a default cube, blender 2.77, and I get

X 0.000
Y 2.000
Z -2.000
I can't replicate your picture having different precision levels on x,y,x... ?

@m.ardito Did you use the snap during transform option (set to vertex)? Because I just extracted a second portable Blender to another location and it shows that issue as well!!

yes, I used the vertex snap (extruded with E hotkey) but I get x,y,z vector coordinates all with 3 precision digits, while you have y,z with 3 and x with 7... that's weird, imho...

@m.ardito The only face of the cube, where there is no deviation when extruding the vertex, is the top/bottom part (Z). Every other side gives deviations of 0,000002, 0,000004, 0,000007 and 0,000009 respectively...

I'm still looking for a solution to this (or even an explanation). Please, help!

I even tested it on Blender 2.78 (testbuild 1 and 2) and the problem persists.....

Creating new edge between those 2 vertices with F will mean the same in terms of measurement the mesh accuracy as in case of using extruding. No such behaviour was noticed in 2.77. Do note that this creates additional non-manifold geometry.

Try this - don't snap to anything.  Get into Ortho view mode so you're looking flat at the side to be extruded, extrude one vertice only a small distance in the axis that will take it along top edge.  Then press G and move your mouse down so the loose vertice is near but not touching the bottom right vertice.
Highlite the loose vertice, and with shift held, highlite the 2nd vertice at the corner, press ALT-M and select "first to Last" or similar, to "marry them". (my term)
If that doesn't deform the cube's shape, do the same with the other side.  Round it all off by removing any doubles.


text:
Is there a way to invert a wireframe?

Im curious if there is anyway to invert a wireframe so that it makes cuts in the mesh rather than form a wire, if anyone has a solution that would help in the scenario without using the wireframe modifier that would be appreciated as well, thank you

Makes cuts in the mesh?

maybe overlay this cube over the solid one, apply modifier and use boolean difference to cut wires out of another cube

Duplicate object, have one with wireframe modifier, add boolean?

Is this a hack?
First, give your object a vertex group, set to a very low weight for all vertices.. mine's called 'Shell_VG'
Give your object an Edge Split modifier, on all edges, followed by a Solidify Modifier, set to fill the rim, and weight the 'Shell_VG' group.

Then a Displace modifier along normals to shrink the faces, and a Mask modifier aimed at the shell vertex group, set to a higher threshold than the one you set originally.

For the pink result:

If you don't mind solid faces, you can cut out all the masking steps.

This could be done with shaders, too, if you don't need the geometry, or you could use a variation on this method, which uses bevels, rather than displacement..


text:
Making a polycube
I'd like to make a polycube. That is, I want to create an object which is composed of cubes which share faces. For example:

I first tried simply taking cubes and sticking them close together, the the resulting mesh data does not correspond to a polycube, as these cubes would not be sharing a side. I then tried taking a rectangular prism and using the loop cut and slide tool, but this would require the prism to be dividable into equal sized cubes (which I wasn't sure how to enforce). Furthermore, I don't see how I could make certain figures (such as the bottom left one from the picture) using this method.
Is there an efficient way of building such polycubes? Any help is appreciated, thanks!

If the cubes would share faces it would be considered a non-manifold geometry where 3 faces share an edge. This is not advisable and  considered a rather wrong construct of a mesh, maybe you can elaborate why this is needed vs cubes not sharing faces inside

Have you tried just extruding the faces of a cube?

You can simply extrude the default cube.
Turning on Grid Snapping will make it a fast and easy process.

Or simply in edit mode select a face, press "e" for "extrude" and the press "1" to set that extrusion has to be "1 unit" long.

Default Plane, Edit Mode, S6 scale,  Right-click > Subdivide,
enter 11 cuts.
Select ground-floor shapes.
CtrlI, invert selection, and X delete faces.
All selected, E1 extrude.
2nd-floor faces selected, E1 extrude.

P > Separate by loose parts...

... and possibly, all objects selected,  Header > Object > Set Origin to.. Geometry?.. and maybe pick colors from your reference using the eyedropper.


text:
Objects messed up when I re-open the file
I'm not an expert in Blender (and sorry for my english), so I'm really having troubles with an issue I'll describe here:
I've modeled a body with every part as a different object.

I want to sculpt it now, so I applied the scale of each body part.

The problem is that now, if I close the file and then I re-open it, I find every object completely messed up in scale, location, ecc..
I also tried to apply every transformation but the result is the same.

What am I doing wrong?
I am using Blender 2.91.2
Thank you

If you want to know more attach your file via https://blend-exchange.com copy -paste given code into your Q to let us see. BTW Do you need keyframes at this stage of work?

Because you have keyframed Location, Rotation and Scale values.
To see the issue you don't have to reopen file, just move on Timeline to another frame.
After Apply Ctrl+A All Transforms you have to set keyframes again I. Yellow color indicates keyframed value, orange edited/unsaved a change.
What is happening here? When you apply transforms they became to zero and  1 for scale, but unsaved keyframes remember saved value and when you move on timeline or reopen file, they "jump" back, so they are used like twice now.

Thank you very very much, now it's working! You saved me :)


text:
Long shadow - Landscape - Displacement
I use displacement (With a greyscale) image, to create a 3D looking map.
I would like long shadow, as if the scene were light up by a morning sun.
I tried to change the position of the sun.
I tried to change the rotation of the sun.
I tried to change the angle of the sun. (from 10 to 90 degree)
But I always have to same result : a harsh shadow, instead of long casted shadow.
Thank you for reading this post and sharing your knowledge
.

hello, are you sure there is not another source light like your world? could you please share the floor + sun? https://pasteall.org/blend/

hello @moonboots exactly, there was a "surface" background strength = 1 which overlapped my sun light. I change this to 0 as suggested by metacontent and it worked perfectly

Have you tried setting your global illumination strength to 0?
I'm not sure the exact name for it in Blender, I'm used to calling it "global illumination" from Maya, but the idea is that it is the underlying ambiant light setting that affects everything in the scene.
In the image below you can see the strength is set to 1.000 try setting it to 0 and see if that helps. This will help your shadows seem darker.

Thank you very much!
That's exactly it !
Now that I,ve put this parameter to 0, the changes on my sun angle have a real impact.
Perfect. Thank you very much !
Claire


text:
Render scene with background jpg in python
Fairly new to python and blender, so apologies if this is super basic. I've searched around and haven't found an answer.
I'd like to render some procedurally generated objects with a background image. In case it makes a difference, I'm using:

I don't need any interaction between the generated object and the background image so I've left a skeleton script I'm using to render below
import os
DIR ="/home/path/to/folder"
bg_file = os.path.join(DIR, "myimage.jpg")
bg_img = bpy.data.images.load(bg_file)
bpy.data.scenes['Scene'].render.filepath = os.path.join(DIR, "image")
bpy.context.scene.camera = bpy.data.objects['Camera']
bpy.ops.render.render(write_still=True)

I managed to find some scripts that seem to be trying to do what I want online, but none that I could get to work. e.g.
import bpy
filepath = "/home/path/to/folder"
img = bpy.data.images.load(filepath)

for area in bpy.context.screen.areas:
    if area.type == 'VIEW_3D':
        space_data = area.spaces.active
        bg = space_data.background_images.new()
        bg.image = img
        break

cam = bpy.data.cameras.new("Camera")
cam_ob = bpy.data.objects.new("Camera", cam)
bpy.context.scene.camera = cam_ob
bpy.context.scene.objects.link(cam_ob)
bpy.context.scene.objects.active = bpy.context.scene.objects["Camera"]

Any thoughts/tips would be greatly appreciated!

My thoughts on this are the same as what I posted here:  http://blender.stackexchange.com/questions/76005/cant-get-script-to-auto-execute/76009#76009

I'm running this on ubuntu, so don't see why this would make a difference?

Have you checked if the trailing slash makes a difference?

Could use the addon specified in answer to Create plane to fit camera

I tried the same thing above, but didn't work. What worked for me is with the textures. In this case, I think you also have to take care of the Texture fields.

bpy.data.textures['Texture.001'].image=bg_img

It works if you need to Change just background
Also add this,

bpy.context.scene.world.use_sky_paper = True
Set also influence, horizontal

Sorry, I dont have enough credits to comment!

One easy way to layer objects over an image without doing any python is to use blender's compositor.
You have to make sure that the 3D rendered scene is transparent ( technique explained by Not render sky texture? ) .  Then rig up some nodes in the compositor (not texture or material nodes).

Once you have built these compositor nodes every frame you render will be mixed with the background image respecting the transparency of the 3D scene.

Here is a function that I wrote that seems to work for me:
def add_background(filepath):
    img = bpy.data.images.load(filepath)
    for area in bpy.context.screen.areas:
        if area.type == 'VIEW_3D':
            space_data = area.spaces.active
            bg = space_data.background_images.new()
            bg.image = img
            space_data.show_background_images = True
            break

    texture = bpy.data.textures.new("Texture.001", 'IMAGE')
    texture.image = img
    bpy.data.worlds['World'].active_texture = texture
    bpy.context.scene.world.texture_slots[0].use_map_horizon = True

If it's for rendering an image, and the camera isn't moving around, put the pic on a plane.
File > User Prefs > Add-ons > Import-Export > Import Images as Planes
import bpy
bpy.ops.import_image.to_plane(files=[{"name":"starfield.jpg", "name":"starfield.jpg"}], directory="/home/eli/Pictures/Blend/Python/")
bpy.context.object.scale[0] = 9
bpy.context.object.scale[1] = 16
bpy.ops.transform.translate(value=(0, 0, -3))

That's my best advice, 'cuz I can't figure out the other way without seeing example code to begin with.  I looked a a few, but they all looked like were for an earlier ver of Blender.  I'll leave the notes of what was tried below, in case someone else can figure that method out.

I've got Blender rendering something else,
so I can't test it, but I believe this code is right:
import os
import bpy

DIR ='/home/eli/Pictures/Blend/Python/'
bg_file = os.path.join(DIR, 'starfield.jpg')
bg_img = bpy.data.images.load(bg_file)

for area in bpy.context.screen.areas:
    if area.type == 'VIEW_3D':
        space_data = area.spaces.active
        bg = space_data.background_images.new()
        bg.image = bg_img
        break

bpy.data.scenes['Scene'].render.filepath = bg_file
bpy.context.scene.camera = bpy.data.objects['Camera']
bpy.ops.render.render(write_still=True)

...
OK, I was under the assumption the second bit of code you posted was decent, and you essentially needed 'em merged.  You're right, hmm...
This seems to be the way to load images:
import bpy
img = bpy.ops.image.open(directory="/home/eli/Pictures/Blend/Python/",
files=[{"name":"starfield.jpg", "name":"starfield.jpg"}])
I'm at a loss.  If I add a Background node by hand, then check type, I get:
bpy.data.worlds['World'].node_tree.nodes['Background'].type
'BACKGROUND'

but if I try to use a script to add that type:
bpy.data.worlds['World'].node_tree.nodes.new('bpy.types.ShaderNodeBackground(img)')

nothing happens.  You obviously have to define it before you can assign it,
though I'm guessing it's already pre-defined within shader data somewhere.

running this (with correct file location subbed in) in the new start up file just renders the default cube (with no background) for me?


text:
Issues installing Blender Animation Nodes on v2.79 on my mac
I downloaded the zip file for the latest version of Blender Animation Nodes. I then went to Blender's "file -> "user preferences" menu, pressed "install add-on from file" and selected the unopened zip file. I can't seem to find the addon on the list now, and the addon is not showing up in the node editor. Did I do something wrong here?
Thanks in advance.

You need to download it from here: https://github.com/JacquesLucke/animation_nodes/releases/tag/v2.0

I just downloaded Animation Nodes for Blender 2.79 on my Mac as well. What is the .zip name? This is the one I used.

After I clicked "Install Add-on from File." it immediately showed up in my list of add-ons. Then I just enabled it.
This is where I downloaded it from.

Did you download the file called "animation_nodes_v2_0_macos_alternative1.zip" ?

@BriannaSinger No, I downloaded https://github.com/JacquesLucke/animation_nodes/releases/download/v2.0/animation_nodes_v2_0_macos.zip


text:
Why can't I see the background image in front or side views?
I've been not using Blender for quite a while and just came back. I have pressed Number 1 and 3 on the keypad for front and side view but they are not working properly. Properly by which I mean, it's not showing the background images.

Did I screw up with the settings somehow?

Background images can only be seen in Orthographic View. You're in Perspective View. Press Num5.

@PaulGonet Thank you so much and sorry for the stupid question! :D


text:
How can I export UV Baked Image Filmic Log Encoding Layer (Save as Image)
I recently installed Filmic color and its awesome.
My issue is that I use Blender to create and bake textures for an external program.
When you bake an image with Filmic installed it actually creates two images on the UV (This is under the Color Space option)
Here are both UVs
sRBG EOTF

And Filmic Log

My main issue is whenever I do "Save as Image" it only exports the sRBG layer and I can not figure out how to export just the Filmic Log layer as an image. I have tried saving JPG, TGA, PNG and so on and it always exports only the sRPG layer.
Either this is a bug or it something I am missing in the settings.
Can someone help me or have any ideas?
Thank you!

By changing color space you don't actually change the image itself but rather the view of it, same image seen differently.
If you want to bake the view in the texture you need to check save as render when you save your image.

But what is it for? Will your texture will be lighted in the other program?
If it's the case it's isn't a good aproach, better bake it as an Albedo.
The transfer fonction of the filmic from scene referred data to display referred data must be the last operation on the image. It means that if your texture will be light after Blender you would need filmic in the other software.
EDIT1
You're not in the right place to manage color, here it's just the color space of the texture when you look at it.
To save your image with the right look you must :
-Go in the scene tab
-Under color management set display device to sRGB, view to Filmic Log, and look choose the one you want.
-After that you can save your image.

EDIT2
I think I have the point now, you are confused by what happens in the image editor. When you rendered your texture and saved it, you already baked the filmic look in the texture, then you load the texture in the image editor and change the color space to filmic.
What is happening in image editor when you change the color spaces to Filmic is that it bring back the transformation to linear (only if you baked your image with filmic).
The steps you made:

Linear scene referred datas (raw render) to BT.709/Filmic Log color space (saved image)
BT.709/Filmic Log back to linear scene referred data.
Consider the image color space in the image editor a invertor of thansformation curves.

Like this you can encode a linear scene referred data (that you can normally only export in EXR 32bit) in a 8/16bit image (with the possibility to decode back to linear scene referred data) exept for the desaturation part of the Filmic. I think to decode back without loss you'll need 16bit image.
So for your need, bake your image with the Filmic (like I said in the Edit1 part), then put it in your other software (emission shader or so, strength to 1) you're done.
And if you want to see a texture in image editor let it by default unless you know why you change it. In your case you must set it to sRGB EOTF.

Hi, save as render changes nothing (tried it before)
So you are saying I am not actually changing the image, just the filter applied in the UV image window? That is a bummer.
I bring these models into Secondlife, which technically has a lighting system of it's own, but it sucks and it so much better to bake the lighting and shadows.
I can achieve a look using regular lighting tricks in Blender, I was just hoping to take advantage of Filmic to make it more natural without blowing out my textures.
I understand the limitations of Filmic since the look can't actually be baked?

Of course you can save your image with the filmic LUT applied.
I'll edit my answer to explain how to do it.

Hi there. This is already my settings. Don't get me wrong... I think you are awesome for responding.
Here I will create a link to IMGUR
Here are my scenic settings
And here is the end result exporting image
My texture
Do you get different results?

I'm close to have a proper answer, but I want it to not introduce mistake, so I'm verifing a point.


text:
How can I rig this kind of mechanical, kinematic setup?
I don't know how to rig this,
it's kind of mechnical, I'll try to explain it:
dl the blendfile https://www.dropbox.com/s/8xtmubzqfm8pry7/mechrig.blend?dl=0
Bone.Main = should be controlling this on, by pulling up and to the side
the Bone.Arm.right and the Bone.Arm.right.stiff should be fixed in angle, just like one glued part
so, what should happen is:
dragging .main up/down: opening and closing the big legs
pulling main to the side: pulling the legs sideways
it's all based on kinematic, so maybe the ik constraint does this,
but I've never used any before ...
I tried to but I did not work, it's kind of too difficult for my knowledge state
anyone can give me a hint...
I'd like to parent meshes to the bones and use a proxy armature later...

The .blend link is 404. If some bones are glued you can substitute them for 1 bone. You dont need Ik, you need bone constraints or drivers.

^^ here's the link https://www.dropbox.com/s/8xtmubzqfm8pry7/mechrig.blend?dl=0


text:
Object inner is black with clipping camera for cutaway view - add inner lighting?
I am using cutaway view with camera clipping, and managed to show the cut area by geometry node, looks soo good, but see the image there is a cube with room inside,
it is black because no light can pass through...
you agree - it looks awful ;)
If I uncheck "Ray Visibility" of the object with Shadow or Diffuse it also doesn't look so good because shadows of the objects are missing in general.
Is there a node trick to bring light into the darkness...?
As a solution I also could add a pointlight into the geometry...
but is there anyting better ?

That node setup should work. Is it added to the end of the node network?

yes, this is plugged into the material output... It works in term of the organe shading but light can't pass into the inside...

It works in term of the organe shading but light can't pass into the inside... the ones in the bottom are just cubes = work. the one on the top is a representation for meshes where there is room inside = no light in the inside = black. This is the normal behavior of camera clipping - I think - because it's no a real cut in the geometry - but is there a hidden function or a kind of trick

Oh I see. I misunderstood. You want the exterior lighting to pass into the cube. Correct?

yes correct, It's kind of maybe not possible, because light should pass into but not through the material. Shadows which are caused by the object should be there, to ;)

The only way I can think of it being possible is to render two images. One with the side of the cube and another without, then combine them in a photo editor. But there is no way I know of to do it within the node editor.

This is because the geometry is still there, even though it's not visible to the camera. Rays bouncing through the scene will still interact with such geometry.
Instead try something like in my answer here.

you can do the clipping in the material nodes and make the clipped points transparent :

if you set the value of the math node to the clipping_start  of the camera then what is clipped by the camera will also be transparent ( the diffuse material is a place holder replace it with your material )
if you use the clipping in the materials only, you can clip only the desired object that has this material :


text:
How to model hard surface sword
I want model a sword like in the image below, please give me some hints about how to model it:
I want any complete tutorial  I tried this model but I really don't know to use polygonal modeling or curve?
I am sorry for this.
Only one or tow tips I want man!

finally I did it:

Have have you tried so far? Where in the workflow are you stuck? What difficulties are you having? This is not the right place for tutorial requests.

This sounds like a better question for BlendSwap than BSE; you haven't even started modeling yet. This is more of a "can someone make me this model?".

It all depends on how you want to model it.

I would first start by drawing or getting a top down view of the sword and starting there. It is a great way to understand the shape of the object you want to make.
From there, just stretch out a plane using extrude E and adding loop cuts (Ctrl+R in edit mode) to add cuts where necessary.
I would suggest looking at some basic modelling tutorials if that doesn't make sense or doesn't help.


text:
3d model geometry fix
Is possibe to fix geometry of model made in Photoscan? I've made a scan of XVII century ceiling joist which is straight and looked straight on the photos from which model was calculated of. Final model however bends and hangs down (looks like a delicate arch). Center of the model is also top of the arch.
Is there a way to make it straight again in blender without deteriorating dimensions and texture quality?
This is how the model looks in blender:

As You can clearly see, this is not the straightest element on earth...
In general it should be straight construction, just as in the reality. On the first glance model looked good, similar to the reality

we need to see the model... can you upload the blend via blend-exchange.giantcowfilms.com?

Please add some images to illustrate your question.

Thanks for responding. You can download blend file through this link:


text:
Origin to geometry does same thing as geometry to origin
Anyone else got this same problem?
I got this tower of blocks which with I wanna do some collision stuff and I try to set each block to have its own origin/center, but when I do "Origin to geometry" it instead moves all blocks to origin point that they all have from original block which I multiplied with Array modifiers to make this tower...
"Origin to geometry" worked just day before, anyone got any idea what is causing this not to work? ...
Edit: Here's the .blend file. Thank you!
Edit2: Filename too long which derps the site (for me) and I can't download it, so here's better download link with shorter file .blend name:

Are these blocks children of another object or do they still have modifiers? Is each block a separate mesh or are they still one object with array modifier?

Could you provide a .blend file on http://blend-exchange.giantcowfilms.com to be able to help you?

They are separate meshes, they have no modifiers on them and none of them are parented to anything (or child of anything). Sorry I should have known to provide .blend file, I'll provide it next time I am on my computer (within 7-12 hours.) sorry and thank you!

Edited/added link to .blend file to question.

As you use rigid body simulation, move the timeline to the 1-st frame as for now it's on the 2-nd. Do any changes with objects while on the 1-st keyframe.

It's that simple thing?!? :D Well damn...... Thank you so much! Dude, make an answer, I'll mark it as correct one!

I had this same issue as well, with a rigid body world activated.  I had to either move to frame 0 and then set the origin, or I could uncheck the rigid body world and then set the origin, or I could adjust the simulation start of the rigid body world to the same frame as the frame start in my output properties- and then set the origin.
Don't know why the rigid body system does this to the objects but at least there's a solution.

I had the same problem just recently and the culprit seems to be "Rigid Body World" as mentioned by Max Appian.
If "Rigid Body World" is ON and objects are created using the array modifier, attempting to "Set Origin to Geometry" causes the spawned objects to relocate to the spawner object. The origin is not set. This is after separating the spawned objects.
The only way I could get the Set Origin to work properly was to temporarily turn off Rigid Body World. Then everything works as expected (don't forget to turn Rigid Body World back on, of course).


text:
Blender exporting wrong image
I created an object and initially mapped the wrong texture to it. Now, even after loading, applying & UV Mapping the correct texture, every time I export my model, it still exports the old/wrong texture instead.
I even tried "packing" the new texture, but it didn't help.
I'm a bit of a Blender novice, and I still use old v2.79b because I never learned the new version/interface.
Why is Blender still exporting my model with the wrong texture? How do I fix this?
TIA
(I've attached the source files here if anyone wants to test it.)

I dont think we can help without seeing yor blend https://blend-exchange.com/

Because it is JPEG file :) You or someone accidentally changed file type to PNG just in name. Export fixed the issue :) If you check metadata you can see. I also see you used Photoshop ... so you can check File > File Info ... sorry for late info ... for quicker response its better to type me a comment as @vklidu


text:
Blender 2.8: My 2.79 creations have no textures!
I created a model using v2.79b including textures, but when I "upgraded" to 2.8 and loaded my project, all of my textures were gone!
The entire interface has changed so much they really should have called it "Blender 3.0". Just figuring out how to switch to "Texture View" required some Googling. And since my textures still don't show, I'm not 100% sure I'm even doing it right, but when I check the Collection Tree, I find there are no textures linked to any of my materials!
The whole damn interface has changed so much simply reapplying all of my textures is going to be a PIA... unless I'm simply missing something.
Am I wrong or does v2.8 ignore linked textures assigned using earlier versions of the program? :(

This may an issue of just putting the textures back as when I " Upgraded to blender 2.8" most of my textures stayed.

I'm not sure what you mean by "putting the textures back". They're are in the same location as before. I did not move any files.

By that I mean are the textures still connected in the node editor are they still connected are they layed out correctly.


text:
Baking object with "combined" results in much too bright an Image Texture (Cycles)
I am attempting to bake the chairs in a living room scene in Cycles using the "Combined" bake.  When I apply that image texture to the chair it is MUCH too bright compared to a render of the same chair. What other types of bakes should I use and how would I combine them?  The original chair uses a Wood.jpg image texture into a diffused shader mixed with a glossy shader.  I've tried baking diffused direct, diffused color, and glossy, and MixRGB them together, but it looks even worse.  Adding a brightness node & turning down the brightness looks bogus too. What am I missing?

I'm adding some more info, but I don't consider this problem answered because what I came up with is a ridiculous kluge that's sill not quite right.  I've tried so many things that at this point I don't think I can replicate all the bakes I'm using. The chair on the left is the one I'm trying to bake. In a nutshell:
Two slightly different 'combined' bakes are totally subtracted from each other which leaves shadows too dark & the color messed up. A color adjustment node (RGB Curves) corrects the color which is 'lightened' with a 'diffused color' bake to reduce the shadow from the table.
Like I said, not really a solution.

Looks like it could be a bug, but I notice that the emission shader you're using to view the baked texture has a a strength of 1.7. Is it still blown out at 1?

Ha. I didn't spot that, but no, even turning the emission shader to .5 still gives me a washed out surface where you can't see any wood grain in it.

By the way, that scene is nicely done, I really like the lighting and materials :D !

Well, I discovered the solution to my problem, which is similar to your problem, so I wonder if the solutions will be similar. The emission shader (that you have to use for the baked texture) can't imitate the roughness value of a diffuse shader (in my case), and that roughness aspect also can't be baked in. I wonder if there's some similar aspect of your original shader (probably something that depends on view angle) that just can't be replicated by the baked texture.

I can't be sure, but it seems entirely likely that your whites are getting crushed. I can guarantee that the white in your specular highlight on that chair is much higher than "255." But a typical image can only hold up to a 255.
Generically, this situation is handled one of two ways. Either, anything over 255 is just clipped/clamped to 255, or the whole range of values is crushed/scaled so that everything fits in a 0-255 range. This makes all the highlights darker because what used to be between 1000-2000 level of intensity gets scaled down to something like 150-250.
You situation would only be explained if Blender is doing some kind of intensity compensation that's tuning everything down so that your whites are crushed instead of just clipped. I don't know if Blender actually does that or not, but it'd explain what you're seeing.
I also don't know how to solve that, unless you can bake to an EXR or HDR that will record values higher than 255.
Hope that helps.

Nevermind. I misunderstood the problem. I thought the bake was too dark, not too bright.

Try just using a diffuse shader for the baked texture. If it's still to bright try turning down the lights to about half the strength.
When you're baking Blender factors in the lights in your scene. So when you're just exchanging the wood texture with the baked one there's basically double the light for just that chair.
What I meant with "double the light" is that when you're baking with the light source you'll later use to light the chair, the baked texture already contains that light info. I once had the problem you're having, figured that's what it was. Sorry..
Also I think I misunderstood. Your saying the baked image by itself is messed up? Not the image looks fine and only weird when applied to the chair? Maybe you changed a setting that's causing that? Have you tried using default settings?

Not sure why there would be 'double the light'. In this case the window sill was an emitter too, as well as the sun.  Turning the lights down still doesn't give me a good bake.

I'm not sure what you're saying. The reason for baking is to keep the material/texture from rendering, and that requires an emission shader.  If I substitute a diffuse shader it defeats the whole reason for baking.


text:
Exported UV map is blurry and doesn't line up with UV mapper(editor)
I'm just messing around with blender trying to learn how to use it. I'm on the texturing part of the model creation process, and I'm having issues I don't know how to deal with.
When I export the UV layout the lines are blurry. I assumed it was because of anti-aliasing.
Blurry Lines http://www.chrispcr.com/wp-content/uploads/2015/04/blurry1.png
Googling the issue doesn't bring up much results. Maybe I'm wording it wrong?
I did find this:
Exported Blender UV Map is blurry
and:
http://dluat.com/exported-blender-uv-map-is-blurry/
It's the same question and answer.
Increasing the dimensions to 4096x4096 gave the same issue but its effect on the image was a lot smaller.
going the svg route gave roughly the same thing:
svg blurry http://www.chrispcr.com/wp-content/uploads/2015/04/svg-blurry.png
That's fine, I just need to know what pixel the UV editor stops at, and keep that in mind while I paint.
I'll just throw in some markers to help:
blender uv editor http://www.chrispcr.com/wp-content/uploads/2015/04/blender-UV-Editor.png
Well, thats annoying, the editor doesn't even line up with image it created.
Am I doing something wrong? Is there a work around that the pros use?
I'm assuming it has something to do with moving the vertices, in the UV editor, to have them line up with the image, but wouldn't that mess with the bump, displace, reflection, etc... maps? (I guess not if they're all lined up.)
Any help would be appreciated, and thanks in advanced.


text:
How to move multiple faces along their individual normals?
I'd like to grab multiple faces and move each one along its normal. Is there a grab individual command?

Set Transform Orientation to Normal (, 2) and Pivot Point to Individual Origins, then hit G and then Z button twice to move along normal.
Using Alt+S shortcut will do the same for individual faces, but will scale faces that are connected.

This does not work well if you have selected/connected polygons next to each other or multiple adjacent, then they move in an average vector together.

There seems to be a way to do it even for connected polygons simply using the Shrink/Fatten tool (Alt + S). Source: https://blender.stackexchange.com/questions/148586/move-connected-vertices-along-their-individual-normal-paths

@VitKovalcik it is already in the answer, but it gives a different result.

@Denis: My mistake, I missed the part under the picture.

Works great in 2.8, too


text:
Find lower left vertex of a quad with python
I'm a looking for a simple and fast way to find the lower left vertex index of a quad with python. What I've tried so far is to change the coordonate system to fit with the normal and sort the coordonnate of the vertices to the x and y axes and get the first element. Unfortunately this doesn't seem
to work, any idea of a simple solution ?

I think, this is doing the job:

The principle is the following:

Get objects faces that are quads
For each face, get its normal in world coordinates
Define a left axis from a (0, 0, -1) vector and this normal (cross product)
Get the face's vertices and calculate their center
Compare each "v minus center" in world coordinates to the left axis
From this, take the lower (along z) vertex

Here is the commented code
import bpy
from mathutils import Vector

def SelectLowerLeft( obj, polygon ):
    worldMat = obj.matrix_world
    normalInWorld = worldMat * polygon.normal
    polygonVertices = [obj.data.vertices[vI] for vI in polygon.vertices]

    if abs(normalInWorld[2]) == 1.0: #If normal is along Z, all are lower left... a choice
        for v in polygonVertices: v.select = True
    else:
        #Left axis is defined from down (Z=-1) cross the normal
        leftAxis = Vector( (0, 0, -1) ).cross( normalInWorld )
        #Create pairs of vertex and in world coordinates, sorted by z in world
        verticesAndWorldCo = sorted( [(v, worldMat * v.co) for v in polygonVertices], key=lambda vAndco: vAndco[1][2] )
        #Center of the polygon
        centerInWorld = sum( [co for v, co in verticesAndWorldCo], Vector() ) / len(verticesAndWorldCo)
        #Take the first going left
        for toSelect in [v for v, co in verticesAndWorldCo if (co - centerInWorld).dot( leftAxis ) > 0]:
            toSelect.select = True
            return
print( '-------------' )

obj = bpy.context.object

data = obj.data

prevMode = obj.mode

#Deselect all
bpy.ops.object.mode_set(mode='EDIT')
bpy.ops.mesh.select_all(action='DESELECT')

#To be able to select via 'select' property
bpy.ops.object.mode_set(mode='OBJECT')

#All object's polygons that are quads
for polygon in [p for p in data.polygons if len(p.vertices) == 4]:
    SelectLowerLeft( obj, polygon )

bpy.ops.object.mode_set(mode=prevMode)


text:
Hair Particle Instance Objects Inheriting Emitter Colours
Blender 2.9
Hello. I have a bird model with UVs and texturing on it. I need to create realistic feathering. The bird model has a hair particle system. I created a custom feather shape and used the Particle Instance + Follow Path options so the feathering follows the hair system paths. This enables me to be able to groom the feathers for a more natural look.
The issue I am having is that unlike the hair system itself, I cannot get the feathers to inherit the coloured values of the bird based on the skin. I have tried many ways including 'from dupli/from instancer', following tutorials on linking instanced objects to emitter systems, looked at many blender forums and even asked in the Blender discord. No solution has worked so far.
All the ones out there (including the popular youtube videos for shading particles/instances) will only work if the instanced object uses a particle system, not the hair system.

Here is the link to the drive with the files. If you're able to get this working, I would be so grateful!
Bird


text:
normal map error in mesh with subsurface
I was making my character for study, I made the model with many vertices, then I made the retopology, so far so good, I put the color texture and the normal map, but when activating the subsurface, I had this problem as you can see keeps showing these imperfections in the character's neck.
Eevee does not have this problem.
when i disable subsurface the problem goes away


text:
boolean modifier removing the exact opposite of what i want it to?
i’m trying to animate the marvel title card and i want to engrave the marvel text through the metallic box but when i apply the boolean modifier to the box it removes the box and not the text (i have converted the text to a mesh)
before:

after:

sorry if this is stupid I only started blender a few days ago and couldn't find an answer to this anywhere

Boolean modifier can be a bit finnicky sometimes, if the booleans cutting the wrong way try giving the text the boolean modifier and setting "back" as the object instead. Also try changing the solver to fast instead of exact, as exact is a bit broken from my experience.

@NascentSpace i changed it to fast and switched the objects and the back cut into the text as a normal boolean should. so i switched the objects again and changed it to fast and it cut out the M, E, and part of the V but the rest of the letters stayed without cutting. i looked on the underside of the back and saw that the R had almost cut all the way through but hadn’t made it all the way

You select the box, go to modifiers -> add boolean modifier.
As object you select your text mesh.
Choose intersection.
Apply.
Delete your text.
Ready.
If this was too fast, checkout my tutorial video:
https://youtu.be/Zshq7pk8Psg

Thank you so much, Chris! That worked perfectly and I really appreciate you taking the time to make a whole tutorial for it. Subscribed!!

You are welcome!

I encountered the same issue, but I discovered that it was caused by the normals of the model being inverted (the outside was on the inside and the inside was on the outside). To view the orientation of the faces, you can go to the drop-down menu to the left of the material views next to the two overlapping circles.
The blue colour should be on the outside of the mesh. If this is not the case, you can fix it by selecting the red parts in edit mode, then going to the mesh drop-down menu, selecting "normals," and clicking "flip."


text:
How to create diamond pattern on object?
I'm trying to make a pendant covered in diamonds and I can't figure out how to get the diamonds to go on the surface clean. I've tried shrink-wrap and the results are awful. The pendent base is complex, and the diamonds are pretty simple.
Any ideas?
enter image description here

I recommend using a particle system instead, possibly remeshing the base mesh first and admitting one particle per vertex.


text:
TypeError: expected 'Depsgraph' type found 'Scene' instead
I have found an awsome script by @Leander to do exactly what im trying to acheive here:
https://blender.stackexchange.com/a/109468/30363
which has two scripts, the first generates an object, the second script uses that generated object to extend its mesh until it hits another object in the scene, this then produces an object which looks like a laser plane scan.
I have managed to get the 1st script to run with blender 2.83.1 by updating the python code, using this https://blenderartists.org/t/2-80-cheat-sheet-for-updating-add-ons/1148974 as a guide,
import bpy
import bmesh
from mathutils.bvhtree import BVHTree
import mathutils
import math
import numpy as np

EPSILON = 0.00001
MAXIMUM_DISTANCE = 10

object_name = 'light_plane'
radius_start = math.pi*1/4
radius_end   = math.pi*3/4
radius_step  = math.pi/256

angles = [(math.cos(a), math.sin(a)) for a in np.arange(radius_start, radius_end + 0.00001, radius_step)]

def create_mesh_obj(bm, p_name = "from_bmesh"):
    scn = bpy.context
    me = bpy.data.meshes.new(name = p_name)
    bm.to_mesh(me)

    if (p_name not in bpy.data.objects):
        ob = bpy.data.objects.new(name = p_name, object_data = me)
        scn.collection.objects.link(ob)
    else:
        ob = bpy.data.objects[p_name]
        ob.data = me
    scn.view_layer.update()
    return ob

def create_vertice_shapes(angles):
    bm = bmesh.new()
    for a in angles:
        bm.verts.new((a[0], a[1], 0))
    bm.verts.new((0, 0, 0))
    ob = create_mesh_obj(bm)
    bm.free()
#    basis = ob.shape_key_add(from_mix=False)
#    basis.name = "basis"
    return ob

ob = create_vertice_shapes(angles)
ob.name = object_name

but i have had no such luck with the second script.
import bpy
import bmesh
from mathutils.bvhtree import BVHTree
import mathutils
import math
import numpy as np

EPSILON = 0.00001
MAXIMUM_DISTANCE = 5

object_name = 'light_plane'
radius_start = math.pi*1/4
radius_end   = math.pi*3/4
radius_step  = math.pi/256

angles = [(math.cos(a), math.sin(a)) for a in np.arange(radius_start, radius_end + 0.00001, radius_step)]
print(angles)

def set_positions(ob, angles, obstacles):
    trees = []
    for obstacle in obstacles:
        bm = bmesh.new()
        bm.from_object(obstacle, bpy.context.scene)
        bmesh.ops.transform(bm, matrix=obstacle.matrix_world, verts=bm.verts)
        trees.append(BVHTree.FromBMesh(bm, epsilon=EPSILON))

    for idx, a in enumerate(angles):
        min_dist = MAXIMUM_DISTANCE
        v_loc = mathutils.Vector((a[0], a[1], 0)) * MAXIMUM_DISTANCE
        for bvh in trees:
            v = (ob.matrix_world * mathutils.Vector((a[0], a[1], 0))) - ob.location
            loc, no, i, d = bvh.ray_cast(ob.location, v)
            if d is not None:
                if d < min_dist:
                    min_dist = d
                    v_loc = ob.matrix_world.inverted() * loc
        ob.data.vertices[idx].co = v_loc

def my_handler(scene):
    ob = bpy.data.objects[object_name]
    selection = [oo for oo in bpy.data.objects if oo != ob]
    print(ob.location)
    set_positions(ob, angles, selection)

for h in bpy.app.handlers.depsgraph_update_pre:
    bpy.app.handlers.scene_update_pre.remove(h)
for h in bpy.app.handlers.frame_change_pre:
    bpy.app.handlers.frame_change_pre.remove(h)
#bpy.app.handlers.scene_update_pre.append(my_handler)
#bpy.app.handlers.frame_change_pre.append(my_handler)
my_handler(bpy.context.scene)

The error i get is
"TypeError: expected 'Depsgraph' type found 'Scene' instead" highlighted on line 24
bm.from_object(obstacle, bpy.context.scene)

Can anyone offer some assistance?

Some API changes are newer than others
The bmesh from object method requires argument 2 to be a depsgraph, not a scene, as IIRC it was prior, circa when answer was written.
Consult more recent docs, however for this stuff highly recommend using the console's autocomplete feature
>>> bm.from_object(
from_object(object, depsgraph, deform=True, cage=False, face_normals=True)
.. method:: from_object(object, depsgraph, deform=True, cage=False, face_normals=True)
Initialize this bmesh from existing object datablock (currently only meshes are supported).
:arg object: The object data to load.
:type object: :class:`Object`
:arg deform: Apply deformation modifiers.
:type deform: boolean
:arg cage: Get the mesh as a deformed cage.
:type cage: boolean
:arg face_normals: Calculate face normals.
:type face_normals: boolean

will notice depsgraph doesn't make the doc string, clearly it is an argument.
Test clean up.  Have made minimal changes to get this to run as a frame change post handler. Have used a 256 vert  "Circle" as a test object, (giving it the requirement that it have at least as many verts as the number of angles.)
The script throws an index error for mesh with too few verts...
The method is hooked up to a frame change handler, so it will do "its thing" when the frame is changing.

_An example moving a couple of cubes with the animation playing, to call (handle) on a  frame change event the mesh update with the handler code.
import bpy
import bmesh
from mathutils.bvhtree import BVHTree
import mathutils
import math
import numpy as np

EPSILON = 0.00001
MAXIMUM_DISTANCE = 5

object_name = 'Circle' # change this to your object name
radius_start = math.pi*1/4
radius_end   = math.pi*3/4
radius_step  = math.pi/256

angles = [(math.cos(a), math.sin(a)) for a in np.arange(radius_start, radius_end + 0.00001, radius_step)]
print(angles)

def set_positions(scene, depsgraph, ob, angles, obstacles):
    trees = []
    for obstacle in obstacles:
        bm = bmesh.new()
        bm.from_object(obstacle, depsgraph)
        bmesh.ops.transform(bm, matrix=obstacle.matrix_world, verts=bm.verts)
        trees.append(BVHTree.FromBMesh(bm, epsilon=EPSILON))

    for idx, a in enumerate(angles):
        min_dist = MAXIMUM_DISTANCE
        v_loc = mathutils.Vector((a[0], a[1], 0)) * MAXIMUM_DISTANCE
        for bvh in trees:
            v = (ob.matrix_world @ mathutils.Vector((a[0], a[1], 0))) - ob.location
            loc, no, i, d = bvh.ray_cast(ob.location, v)
            if d is not None:
                if d < min_dist:
                    min_dist = d
                    v_loc = ob.matrix_world.inverted() @ loc
        ob.data.vertices[idx].co = v_loc

def my_handler(scene, depsgraph):
    ob = scene.objects[object_name]
    selection = [oo for oo in scene.objects if oo != ob and oo.type == 'MESH']
    print(ob.location)
    set_positions(scene, depsgraph, ob, angles, selection)

# to debug n test clear the lot.
bpy.app.handlers.frame_change_post.clear()
bpy.app.handlers.frame_change_post.append(my_handler)

TypeError: Element-wise multiplication: not supported between 'Matrix' and 'Vector'
EDIT
See Scan plane "shadow" re my take on an update for 2.8.

Thanks for the re-work,but I must be doing somthing wrong here, the scrript you have done doesn't show any errors, but all it does is print out the angles and exits.
For all my testing the "my_handler" function is never entered (placed print("my_handler") for testing in the function).
can you elaborate on what else you have done for it to work?

Managed to get an indent error when pasting, edited.  Added a gif re running via handler requires animation playing, and my take on an update via answer to original question https://blender.stackexchange.com/questions/109178/scan-plane-shadow/194328#194328

Great work, works great and exactly how i expect it to, can make an animation with the scan plane updating while an object passed through, can render out an image with the "shadow" present, but rendering the animation doesn't show the object interacting with the scan plane.

https://blender.stackexchange.com/questions/109178/scan-plane-shadow/194328#194328 does render  for me in 2.9 with no issue.

Video of what's happening on my end here , using 2.8-2.9 and anything in between on three seperate PC's.
Rendering out a single image updates the Light Ray's mesh, rendering out an animation does not.

Ok gotchya. Even using an evaluated scene,  scene.raycast in a handler doesn't pick up animated objects, but can animate the ray object.  Might ask a question re this.  Could render via https://blender.stackexchange.com/questions/110662/a-script-to-render-each-frame-as-image-not-render-animation-in-2-8