Questions tagged [source-code]

For questions relating to the blender c/c++ source code.

Filter by
Sorted by
Tagged with
0 votes
0 answers
17 views

About principled bsdf parameter "Subsurface" in node_principled_bsdf.osl

According to Blender manual, Subsurface Mix between diffuse and subsurface scattering it acts as a multiplier for the Subsurface Radius. After checking the source code, I found: ...
Edward lee's user avatar
0 votes
0 answers
20 views

Python: How to code "changeover buttons"? [duplicate]

I would like to code three changeover buttons in python, that behave each other. If you click on one, the others keep switched off. So you can change between their states. An example is found in ...
Christoph Werner's user avatar
2 votes
1 answer
110 views

Accessing C pointers to vertices in Blender's Python API

I'm currently making a render engine in C and C++ for Blender. I want to access the vertices of a mesh from C via a pointer, to reduce the time spent in Python and avoid unneeded data duplication. I ...
elzaidir's user avatar
2 votes
1 answer
47 views

how to achieve slerp in the graph editor

i have keyframed an objects rotation, im using quaternion rotation mode cuz i wanna avoid gimbal lock, however a new issue arises. i need there to be proper linear interpolation between these ...
space sheep 1017's user avatar
0 votes
1 answer
23 views

How to set the origin of the object to the center of the face of the bounding box of that object using python API?

I want to know how to set the objects origin such that it is in the middle of on of the faces of the bounding box. The input for which face to use will be taken by the user in the form of +X,+Y,-X,-Z, ...
Warhead980's user avatar
1 vote
0 answers
47 views

Taming big bad Blender

How big is Blender lite and headless (uncompressed) on Linux? Blender 3.5.1 uncompressed is roughly 1250 MB. I can delete directories like addons, Eevee engine, built-in world shaders/EXRs, and still ...
chhdgxhuc's user avatar
0 votes
0 answers
35 views

What's the math and intuition behind Smooth F1 Worley Noise?

I can't find any information nor article about it on the internet. The only thing I've got is Blender's manual page. If anyone could read the source code, please help me. Thank you! Any help would be ...
Ian Ambrose's user avatar
0 votes
0 answers
152 views

Get pixel data from rendering in script using built blender python module

I need to get the Pixels of the render pass to convert them to a numpy array within a python script. From my research there are 3 possible ways to solve this: using a viewer node in Compositor using ...
el_flamenco's user avatar
0 votes
1 answer
39 views

Compiling Blender from branch does not find precompiled libraries

If I try and compile blender from any other branch than master I get the following error during make: ...
Ilovemesomeramen's user avatar
0 votes
0 answers
157 views

Script to wipe out every Vertex color

Please can somebody help me with a script that wipes out the vertex color attribute from every mesh in the scene? I need to get rid of them so when I export to .gltf the textures won't get multiplied ...
AAA Yerus's user avatar
2 votes
0 answers
147 views

Recreating Point Light Power/Radius/Falloff/Attenuation

I am attempting to recreate the Eevee point light within Cycles using nodes (using Drivers to get the light info). I have the basics working, but I cannot figure out how exactly the Radius and Power ...
Ascalon's user avatar
  • 6,469
1 vote
0 answers
40 views

How dose blender handle tiny roughness in BSDF with GGX?

I am curioused about the implementation of principled BSDF in blender. As we know, the GGX would produce "inf" value when the roughness is close to zero. Some renders, such as filament, ...
Wu Haoqian's user avatar
0 votes
1 answer
14 views

is it possible to make a code to combine several blender files and make several combinations of them?

if I want to make an avatar and I have 10 bodies, 10 clothes, 10 weapons and 5 backgrounds and each part is saved separately in a blender file. Is it possible to create a code that will create a ...
Magnus Juniour's user avatar
0 votes
0 answers
304 views

Where can I change the default value for vertex color attribute?

I am currently trying to see if I can make a change to the blender code to allow me to have a default value of the vertex color attribute to (0,0,0,0) instead of (1,1,1,1) when I create a primitive ...
Jamie's user avatar
  • 1
2 votes
0 answers
23 views

BMesh: does an edge include itself in the disk cycle?

I'm basing my work on BMeshUnity and there's something that could be a bug in its disk cycle implementation. Here's a log of a simple triangle face, numbers are indices for each element, focus on each ...
CodeSmile's user avatar
  • 173
5 votes
3 answers
1k views

What is the difference between "Mesh" and "Geometry" in Geometry Nodes (or in general)?

I'm a programmer new to Blender and solely interested in Geometry Nodes. Here I do not understand the difference between "Geometry" and "Mesh" ports. They seem to be ...
CodeSmile's user avatar
  • 173
0 votes
1 answer
48 views

Change Blender logo

I realize that questions about the source code are considered off topic, but in light of this answer, I figured I'd ask anyway in case there's someone out there that does know the answer. I've been ...
Anson Savage's user avatar
  • 3,342
0 votes
1 answer
38 views

How does blender pick the face you are pointing at?

For objects of more than 40.000 faces picking a face by iterating trough every face/triangle and checking if it intersects with the camera ray should slow down the program by a lot but it still works ...
Adrian's user avatar
  • 3
0 votes
1 answer
199 views

How to access source code in Mac OS?

I want to open Blender source code file for studying more details. There's a YT video for doing this, but it's about 2 years old and on my laptop, somewhat reason, Blender can't open the file then ...
PhewphewMathew's user avatar
3 votes
0 answers
154 views

Intersect (SEL_OP_AND) not working, but all other selection types are fine

Working on a diff that will allow some more selection options. Devtalk Post with Build and Diff and Description Mainly for Select Through, which is essentially just accessing X-Ray selection in ...
Lukas Sneyd's user avatar
3 votes
1 answer
276 views

Schlick's approximation in Blender?

Is it just me or is there really no Schlick's approximation in Blender? I know that building such a node with the available vector math nodes isn't terribly difficult, but there is no way that Blender ...
tempdev nova's user avatar
  • 1,445
2 votes
0 answers
334 views

How to add curve widget to n-panel?

So, I have one value controlled by the Float Curve node (in the geometry nodes). And I am trying to get an access to that float curve through the N-panel. It looks like Curve Widgets are available in ...
3DBear's user avatar
  • 703
0 votes
1 answer
1k views

How do I do animation using csv file? [closed]

I am trying to make an animation creation script using cvs. I referenced several csv scripts here, but I couldn't understand it at all because I not long ago learned Python. How can I input the csv ...
bline's user avatar
  • 11
0 votes
0 answers
359 views

How to make Extended Asset Browser feature turned on by default in 3.0?

Blender's 3.0 release is awesome especially the asset browser. However, I notice that I couldn't mark a Collection as an asset. In previous beta releases you could turn on Extended Asset Browser ...
Legogo1R's user avatar
1 vote
3 answers
965 views

How does Blender compute local rotation axes for pose bones?

Consider the following armature: Two important notes: first, I'm using local space for posing, and two, the arm has zero bone roll. When I attempt to rotate the arm and restrict to the X, Y, and Z ...
Grimelios's user avatar
0 votes
1 answer
99 views

Remesh modifier script won't let me modify scale

So I made a script with two independent properties for the octree depth and scale features in the remesh modifier. The octree depth one works fine, but the scale one has no effect. what am I doing ...
SmallAngryChild's user avatar
4 votes
3 answers
2k views

Can I use Blender to set up game logic?

I want to create a game using Blender 2.93. I don't know if I can use Blender to create the game logistics. I want to create a 3D game that's set up like Minecraft. An almost infinite world that's ...
Grace's user avatar
  • 142
0 votes
0 answers
560 views

How do I recover my corrupted blender file through reverse engineering?

The only thing that crashed is blender, and my C drive keeps running out of space. The crash was caused by adding a remesh modifier after a subdivision modifier. I saved the backup file that saved my ...
Stavros Piliaris's user avatar
0 votes
0 answers
25 views

OSL 2.93 issues

Trying to edit procedural OSL script bricks and I can't seem to get the thing to render. I've just copied a few scripts and the shaders ins and outs appear but theres nothing coming out in cycles when ...
Juno Mars's user avatar
1 vote
1 answer
500 views

How do I build an older version of Blender from source code?

I'm a beginner and I'm building Blender from source code for the first time. By using this URL "https://wiki.blender.org/wiki/Building_Blender/Windows", I was able to build the latest alpha ...
user131424's user avatar
0 votes
0 answers
115 views

How to change Default Object Color in Source Code?

All new primitives have their default object.color set to white. Anyone know where to edit the source code so I can change the default object color to gray for example ...
Armored Wolf's user avatar
1 vote
1 answer
751 views

How to enable or disable panels with the click of a button

When I click on the "new" button, some panels that were disabled appear. I read their code, but I didn't understand. How do I get certain panels to appear when I click a button?
niadhson's user avatar
2 votes
1 answer
38 views

How to know what's happening with a patch I submitted for Blender

About three months ago, I submitted a proposed patch for changing how the ParticleInstance modifier works in Blender (https://developer.blender.org/D9100). Since then, there has been no feedback. I ...
kitfox's user avatar
  • 1,586
0 votes
0 answers
482 views

No module named 'branch'

i was making a addon and i have this problem , i was looking for two days ago and i have not found nothing , im so tired with this. i saw a lot of question about this but they are not help me when i ...
Misha bytes's user avatar
0 votes
1 answer
247 views

Node Editor - Python - Expose listed Node Groups dynamically in Node shelf panel

Issue Currently, node groups are only accessible in the Add menu then group sub-menu. You can't just click and drag them into use. You have to search, or go into sub-menus to use them. Question It ...
Draise's user avatar
  • 206
1 vote
0 answers
254 views

Z_buffer, where to find it and how to use it?

I'm trying to implement some function in blender for an university essay but I'm stuck. I need the z_buffer of the rendering camera in cycles to find the distance between every pixel of the render and ...
Leonardo Vezzani's user avatar
1 vote
0 answers
36 views

Position cameras on all vertices with respect to center view [duplicate]

I would like to generate training-data for an image classifier, based on a CAD model. Therefore I would like to position my object in the center of the scene and render it from different positions. ...
Alex's user avatar
  • 11
1 vote
0 answers
98 views

Write new bone constraint

I have an idea for an IK-like bone constraint solver which I'd like to try. As far as I understand, there is no way to add such a constraint via the python API, is this true? What is the simplest way ...
thorst's user avatar
  • 78
2 votes
0 answers
101 views

Help me understand the viewport render pipeline with cycles

I am trying to understand the pipeline that creates a rendered image in the viewport with cycles from start to finish in the blender/cycles source code. A little bit of context (Skip if not interested)...
Alpengringo's user avatar
0 votes
1 answer
80 views

Python panel source code [duplicate]

I saw a tutorial where the guy right clicked on any object in the GUI (he chose Transform->Translate) and he got the Python source code for that panel with an indicator for the line where the ...
DrDress's user avatar
  • 543
0 votes
1 answer
129 views

Git Flow when coding for blender

I am sry if this is the wrong place to ask this or if this has already been answered elsewhere but I couldn't find it. I am confused about the git workflow when coding for blender: When I clone the ...
Alpengringo's user avatar
0 votes
1 answer
114 views

Has anyone edited the blender source code to enable unlimited undo's? [closed]

I was looking for a method that removes the undo cap, some said to make the count 0 which was so wrong, 0 just removes undo's that should have been made more clear, i lost an enitre file cuz of that, ...
Dank Heehaw's user avatar
0 votes
1 answer
84 views

Looking for code files

I'm working on a project that will be evaluated in my university class "image processing and computer vision": I'm trying to recreate some experiment we studied in class with Cycles and, in ...
Leonardo Vezzani's user avatar
1 vote
1 answer
745 views

Hot Key for Manifold Extrude

I know that in the beta release of Blender 2.9 there is the new manifold extrude function. It allows you to erase the edges or walls from an extrude and helps provide a quicker hard surface modelling ...
John Faurbo's user avatar
0 votes
0 answers
392 views

Can addons be written in C to modify parts of Blender inaccessible through Python?

My experience with and understanding of coding is currently limited to three college courses on programming for business with Java, but I'm trying to learn how to code stuff for Blender. I want to ...
christsdude's user avatar
1 vote
1 answer
86 views

How to check for an operator property

Trying to modify this to show up in the keymap instead of in toolsettings https://developer.blender.org/D6322 Creator says it was done as a tool setting so it can know when to draw facedots in xray. ...
Lukas Sneyd's user avatar
3 votes
0 answers
401 views

How to find python code of a built-in python operator?

To my knowledge, some built-in operators are written in python. This could be handy if I wanted to create a modified version of an operator for my add-on, since I could probably just copy the code and ...
ChameleonScales's user avatar
0 votes
0 answers
56 views

Why is Blender not procedural?

best example, changing the vertices after you add a circle, same with cylinder, sphere segments and so on. I think it is in the most 3D software like Maya, C4D and Houdini of course. Has it something ...
Josephbt's user avatar
0 votes
3 answers
950 views

Looking for Blender source code of version 2.79.7

Where can I find the source code, corresponding to this exact build 2.79.7 blender-2.79 e045fe53f1b0 ? - https://download.blender.org/release/Blender2.79/latest/
Wisi W's user avatar
  • 1
1 vote
0 answers
42 views

Is it possible to create editable 3D templates in blender?

I hope someone can help me: Is it possible to turn animations created in blender into editable 3D templates that can be used in websites or apps where users can edit the scale and add textures etc I’...
Aggers11's user avatar