Questions tagged [vector]

In math and physics, a vector is "s a geometric object that has magnitude (or length) and direction." Blender uses 3D vectors in compositing, material and geometry nodes; and elsewhere to represent direction or force. Use this tag for questions about any of the uses of vectors in Blender.

217 questions
Filter by
Sorted by
Tagged with
14k views

TypeError: Element-wise multiplication: not supported between 'Matrix' and 'Vector'

Blender 2.8 produces the following error whilst multiplying a combination of matrices and vectors ...
• 84k
9k views

How can I make my procedural brick texture map correctly to both a cube and cylinder?

I've been experimenting with node-based procedural materials in Cycles lately, and after spending a few hours working out a brick material that works pretty well along walls, I noticed that it has a ...
• 143
2k views

Project scene to plane in real-time

I understand I could render out the view my camera and then just that as an image texture, however, I want to try and achieve this effect in real-time. The idea is derived from an effect present in ...
• 931
875 views

I'm struggle with vector displacement shader. I'm trying to do something like reverse cone but I can't figure out how to add radial direction. I would like to use RGB curves like screw (lathe) ...
• 139
538 views

Please explain logic of this transparency material nodes

For the texture coordinates, I take the vector of the plate that is under the cube. The length of which of the object vectors is taken? And why if I change the 2nd value in "Less Than", the ...
• 127
1k views

Geometry nodes vector interpolation issue

I'm trying to translate the vertices of one object in the direction of the nearest vertices of a second object. I know this can be achieved by blending the two vectors using a mixRGB node like this: ...
• 192
1k views

What's the math behind Vector Rotate node?

I’ve been taught that the Axis input is the value for input vector n^ of the Rodrigues’ rotation formula: v’ = (1-cos(θ))[(v·n^)n^]+cos(θ)v+sin(θ)n^×v But I don’t understand what ‘’Center’’ input do. ...
• 562
3k views

How to create Shape Keys in Geometry Nodes, including support for curve handles?

I am trying to replicate the functionality of Shape Keys but in Geometry Nodes. At the core of the setup I am using the technique quellenform introduced in this answer, but I am adding the ability to ...
• 18.9k
738 views

How to make instances twist about a curve

I am wanting this ring to appear as a twisted chain, hopefully with a variable number of 180 turns it makes as an integer input to the Geometry Nodes group. I want the chain to be twisted as a whole. ...
• 6,159
881 views

Mathematically, what does Faceforward function mean?

Blender's description of Faceforward function is, quoted from Blender's document: Orients a vector A to point away from a surface B as defined by its normal C. Computes (Dot(B,C)<0)?A:-A I have a ...
• 562
710 views

What happens when a vector is fed into a value slot of the add node?

I was wondering what happens when a vector is fed into a Math -> Add node. Notice that I'm asking about the Math -> Add node, not the Vector Math -> Add node. My guess was that the node ...
• 121
3k views

Camera Data "View Vector" Interpretation

I am trying to develop some materials with interesting optical properties. In doing so, I am investigating the use of the "View Vector", however I do not understand it. Looking at the documentation, ...
• 139
391 views

How can I find two vertex indexes per face on a mesh to create a secondary alignment vector

I've had troubles in the past with instance spinning when using "Align Euler to Vector" to align instances to face normals on deforming meshes. I have a setup that eliminates all spinning ...
• 168
405 views

Combining vector displacement and standard black and white displacement nodes

I am currently working on an ocean scene. The water uses a subdivided plane with waves that are displaced via the vector displacement node in the material. I would like to add another whirlpool effect ...
815 views

How do I calculate the normals of a point group?

I hope to come up with an interesting and tricky task this time, and would be happy to receive any expert solutions. First of all: I'm looking for a solution that uses only simple vector math! The ...
• 34.8k
504 views

Why multiply a normal?

I am looking at this tutorial Geometry nodes for damage to stone. It uses a normal multiplied by some random vector to produce offset. What does multiplying a normal of a point with random vector ...
• 182
1k views

How to obtain the vector normal to the camera plane

I'm working on a project where I need to determine the distance along the camera's local Z axis until it hits a plane in which a given object rests. My thought process is to calculate a vecor from ...
• 3,372
322 views

How can I "bend" object coordinates?

As you can see, the object coordinates don't bend along with the object itself. I know this is intentional, but is there a way to perhaps make them follow the contours of the object, or to manually ...
• 1,419
2k views

Materials: How to compare two vectors?

I'm looking for a method that compares two vectors in order to use a mix color/shader. Example : If the camera looks at the object from atop (as the two vectors align) it should select material A. As ...
• 71
5k views

World coordinates in Geometry Nodes

Is it possible to reference World coordinates in Geometry Nodes without using an external object? For example, can you establish a ray direction for the Raycast node which always points towards global ...
• 8,750
157 views

Vector Displacement not showing same result as the mask of it

So recently I decided to try vector displacement. I tried to make something simple, such as this shape. It's sort of a "gun shape", but I've ran into a problem. I wanted to make an "...
541 views

Optical flow generated from cycles render is not proper

Scene generated from Blender, and flow is given. As it can be seen the flow generated is not proper, it is in a zig-zag format. I see the scene at and above horizon have more zig-zag. Can someone ...
663 views

What is the Center in Vector Rotate Node

As per Blender documentation the center in the Vector Rotate node is the Point to rotate around, which, I assume, means the pivot point for rotation. However when I ...
1k views

how to create a vector (a arrow) in blender

I'm trying to create a interactive vector, but I'm not getting a way to make the arrow stable under rotations and scaling. Make it stable under translation is easy, but make the 'body' and the 'tip' ...
• 165
3k views

Create a Vector with a Value Node as each value

I want to create a Vector Node in Geometry Nodes but with each value being driven by a separate Value Node. Like this: Thanks.
• 429
265 views

Unrotate a square polygon with Python: all 3 axes

I have a rotated square polygon. And I want to 'unrotate' it so that its normal axes would match world axes. I'm able to unrotate it on the Z axis by using the face normal and rotation difference (I ...
298 views

What does a black and white texture look like after converting it to vectors?

Is my guess that I showed in the picture below correct? If not, what's the best way to represent a group of vectors emerging from a black and white texture?
• 1,055
1k views

Geometry nodes: How to distribute points on valleys only?

I want to add vegetation to my rocky semi-desert scene of Himalayan mountains, using geometry nodes. In that scenery, vegetation only grows in valleys, where water would sometimes flow. Note that by '...
• 115
1k views

How can I pixelate a procedural texture with a pixel grid that is completely static in world space?

I am trying to create a voxelized fire simulation, and then texture it so that the center of the fire is the brightest point. Here you can see what I currently have: The voxelized fire sim, it is 3d ...
158 views

Only show whole dots that aren't obstructed by mask

I'm drawing a dot-pattern, based on a vector grid (a) onto a plane. Based on the position of two empties, that can move on the plane, there are masks (b) generated. I then combine both of them (c), ...
• 588
505 views

How to get face normal's x or y axis vector (or matrix)?

Is it possible to get vector of the x or y axis of face's normal orentation? I know it's possible to get z axis of face's orientation like this ...
• 71
388 views

Align viewport rotation to normal vector like Shift+7 in edit mode

I know this question has been asked and answered before but the behavior I want is what ⇧ Shift + Num 7 exactly does in edit mode which is to align the viewport to "face" the element ...
910 views

Is it a correct math definition of averaging two vectors? (Blender vector math node)

There is such a definition in the Blender Vector Math node: Isn't an average vector supposed to be something like: Vector = (input1+input2)/n where n is a number of vectors? It seems what we ...
330 views

Grease pencil vector export

Is there a way to export the new and wonderful grease pencil in any vector format. This would be so nice for logos and graphical stuff!!!!
614 views

Changing Rotation Angle Using Align Euler to Vector Node

I have a vector V = (x, y, z) and I need to rotate an object in the direction of this vector. I can do that by calculating the rotation ...
3k views

Geometry Nodes: Points and Vectors [duplicate]

i want to create lines (edges) connecting the vertices of two grids (what i'm really trying to do is have an array of parallel vectors) with geometry nodes. I thought i could take a grid and convert ...
200 views

vertex positional difference alternative using numpy

I have a function looking at a difference in vertex positions, and storing that difference on a third mesh - ...
• 259
401 views

How to get Vector Length in the compositor?

I have a Material node setup that processes color and I want to recreate that node tree for the Compositor. Unfortunately the setup relies on a Vector Math : Length ...
• 18.9k
3k views

Unable to rotate instances individually in Geometry nodes

I have instanced 14 triangles in a circle mesh. I am trying to rotate these independently of each other, making them point inwards into the circle, or outwards, pointing away from the middle of the ...
• 31
276 views

What does ''Axis'' input of Vector Rotate node do?

What does the Axis input do? I’m aware that if the input is 0-1-0, the rotation will be performed around Y axis, 1-0-0 for X axis and 0-0-1 for Z axis. The math to perform the rotation using those ...
• 562
893 views

Animation nodes: rotate around axis

How do you rotate an object around a given unit vector and angle? I thought I could use this matrix, but I'm unable to create a custom 3x3 matrix inside animation nodes. R= \begin{bmatrix} \cos\...
• 1,067
352 views

Geometry Node: Vector Rotate Angle Incorrect?

I have 2 points p1 = (0, -1, 1) and p2 = (0, -1, 0). I am trying to rotate p2 around ...
1k views

How can I use for loop (or while loop) in python to move 50 objects with random beginning positions to specific positions

I am a beginner of Blender. I want to use the blender to show how proteins form a microtubule. My code creates a piece of microtubule and some proteins on random positions. I want to put the random ...
• 31
790 views

How mathutils.Vector.angle() use?

a = Vector((1,2,3)) b = Vector((4,3,2)) print(a.angle(b)) I'm trying to calculate two vectors' angle between them using Vector_1.angle(Vector_2), but output is ...
• 311
4k views

Complex SVG file fails to import correctly into Blender

No curves get imported at all into Blender, and I'm totally mystified why. I have a CD of vector pattern library images that I'd like to use within Blender. These appear to be good vector images, i.e. ...
648 views

Print vector with more decimal numbers

When outputting values for a mathutils.Vector and mathutils.Matrix, there's normally only 4 decimals printed out. Is there a way ...
768 views

Align vertices along vector (Python)

I have a vector and vertices, and I'm trying to align the vertices to that vector using 'Translation Matrix', unfortunately multiplying the matrix with the vertices' coordinates do not change anything....
• 127
1k views

Offset points in space with python

I have a path-curve that uses a profile with two circles (reference and profile on the image below). I'd like to create a second ...