text:
Variable in bpy. context
Is it possible to insert a variable into a bpy context?
Like
bpy.types.Scene.propertyNameProp = StringProperty(name="Name", default="", maxlen=10, description="Name of your property")
propName = bpy.context.scene.propertyNameProp
bpy.types.Scene.propName()

Yes you can, but I think that you are heading into what Drivers are created for.
Specifically registering your code within the Driver_Namespace. Click here for a similar solution


text:
Get access to generator modifier x values for drivers
I want to know if its possible to get access to the property of the generator modifier in the driver panel. I want the X property to live set it in the Tools Panel.

Looks like you cannot access this property, but there is a workaround by scripting the generator yourself and by adding 2 custom ID properties to the object to control it.

import bpy

class Panel(bpy.types.Panel):
    bl_label = "Custom Panel"
    bl_space_type = 'VIEW_3D'
    bl_region_type = 'TOOLS'

    def draw(self, context):
        layout = self.layout
        layout.prop(context.active_object, '["offset"]')
        layout.prop(context.active_object, '["multiplier"]')

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

def unregister():
    bpy.utils.unregister_module(__name__)

if __name__ == "__main__":
    register()

source: Stack Exchange

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

sort: votes


text:
clear ID Properties completely
I want to add some custom properties to a bone by an if statement
if len(bpy.data.armatures[armSearch].bones[boneSearch].items()) > 1:
    itemCount = len(bpy.data.armatures[armSearch].bones[boneSearch].items()) + 1
    bpy.data.armatures[armSearch].bones[boneSearch]["skName"+str(itemCount)] = shapeKeySearch

elif len(bpy.data.armatures[armSearch].bones[boneSearch].items()) == 1:
    bpy.data.armatures[armSearch].bones[boneSearch]["skName"] = shapeKeySearch

else:
    bpy.data.armatures[armSearch].pose.bones[boneSearch]["skName"] = shapeKeySearch

But when I look for the ID properties in the console there are already tow of them even though I deleted them. How can I delete them completely ?

You delete custom ID property by:
del pose_bone["ID_prop_name"]

But why are they not shown ?

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


text:
Dual Xeon vs High-End GPU for Cycles rendering?
I read everywhere that render farms have dual Xeon processors with some 30-odd cores to render complex scenes, but I also read about powerful workstations that contained a rendering GPU like something a Quadro.
My question is, which one actually performs better in Cycles? And what will surpass my overclocked 980Ti? (I will do rendering benchmarks if you wish)

@cegaton I forgot to mention that I don't own a Xeon machine. However, hearing that Quadros can't beat my GTX, I may look into building a farm then :)

@cegaton  The general statement that "A Quadro card will not be faster than your gtx GPU" isn't really true,.  For the same price a gtx will probably outperform a Quadro in Cycles (definitely not in other 3D software though).  But I can pretty much guarantee you that a m5000 or m6000 will outperform the 980ti.  (Note that CPU rendering has the advantage that new features come out for CPU first, then they get them working on CUDA.)

I think you might get better answers to this question at Hardware Recommendatons Stack Exchange, even if it is still in Beta.

@brasshat Ah, I've not heard about that SE, I'll give it a look later.

Remember that the crucial difference between GPU and CPU is the fact that complex scenes will almost always run out of memory on GPU. Multiple EXRs as textures and such will flatline a GPU fast.

I use Blender at work. This might help you out.
My work computer used to be a Mac Pro with a hyper-threaded Xeon processor. It was a little older, like from 2010, but it could run 16 simultaneous threads. That translated to 16 little squares rendering at the same time in Cycles.
A year and a half ago I asked my boss if I could build a PC instead of getting a new Mac Pro. They approved and gave me a budget of \$3500, roughly the amount a new Mac Pro would have cost. Because I was choosing my components I bought two GTX 980s (they were about \$550 a piece, so \$1100 total).
When I compared the Cycles rendering speed on the two computers, the PC I built rendered the same scene SIXTY TIMES FASTER than the Mac Pro with the Xeon processor. That meant projects that used to take multiple week to render would now be done over night.
I used Render.st once. It was a very smooth experience, and didn't cost me anything because they had given me a \$25 credit to get started. It wasn't blazing fast, but it did render for much less money than the cost of building and maintaining my computer. And like Pyroglyph mentioned, all the frames began and ended around the same time.
If you are rendering things every now and then, for fun, I suggest trying a render service like Render.st. It's very easy to set up.

I realize I'm coming a bit late to the party, but I've just noticed the thread and I'd like to make a couple of comments:
NVidia has 3 lines of GPUs : GTX (consumer cards, targeted towards gaming), Quadro (targeted towards CAD professionals) and Tesla (GPU processors for HPC). For Cycles, you'll definitely get the best bang for the buck with a card from the GTX line. However, if you're working on very complex projects, high-end CPUs may perform better. There are a number of reasons for which this could be happening, like for instance parts of the rendering code not being optimized enough for GPU (take volumetrics for example) and the actual way the computing process works at a GPU level. You can see the Blender Institute benchmarks on a number of systems here if you're interested in comparing results. And I've seen situations in which our dual Xeon servers performed far better than our quad GPU ones. So my advice to anyone looking to buy hardware would be to keep in mind the complexity of the projects you'll be working on.
Regarding the way a render farm works, the hardware we're rendering on at RenderStreet is pretty fast - both the CPU and the GPU servers. But the true power of the farm is that we're able to throw dozens or hundreds of identical servers at your projects and render in a couple of hours what you would render in a few weeks on one machine.
And lastly, using a farm isn't that expensive, either. For instance, the price Tim mentioned for one GTX card can buy 11 months of unlimited rendering, and that's a lot of crunching power. Plus, it's available from anywhere you are traveling, with the only requirement being a decent internet connection.

Check out this page for GPU render performance Benchmarks across some popular 3D Software Render Engines. It doesn't Include Cycles, but gives a good comparison of how the currently modern GPUs rank
Dual Xeon wouldn't be the way to go for cycles, as this Render Engine is heavily GPU optimized. If you were to go CPU-Rendering style, I would recommend a Threadripper, as these have much better Render Performance per Cost. There is a good overview here for best CPUs for rendering.

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


text:
Adding New Mesh Is not Working In Sculpting Mode!
I'm new in Blender, I tried using sculpting mode in Blender but the problem is when I added new mesh in the sculpting, the brushes are not working. but when I delete the added mesh it'll work again. Please can someone help me because I keep searching for it but I can't find any solution. Thank you so much.

Hi! I just added my screenshots >< thank you so much!!

maybe the mesh you've added (the eye?) is a separate object, you can't sculpt 2 separate objects at the same time, you first need to join them (Ctrl J), they will still be 2 separate meshes, but within 1 object, and now you can sculpt both

oh yes! thank you so much!! I'll try to do that! I do really appreciate your help!!<3

You may also sometimes want to boolean 2 or more objects if you want the meshes to be kind of merged

How can I do that boolean 2??

I meant you can boolean 2 different objects or meshes. To boolean meshes: Merge the 2 objects with Ctrl J, switch to Edit mode, select one of the 2 meshes, then go into the head menu > Face > Intersect (Boolean)

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


text:
Selecting vertices only visible in camera frustum
I want to select the vertices which are visible in camera frustum and delete the rest which are either occluded or not in camera frustum. I don't want to do it manually but with a python script. Thanks!

Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.

ans may you want:  https://blender.stackexchange.com/questions/32975/python-check-if-vertex-is-on-camera-field-of-view

I have tried this method. The problem is, it also selects those vertices which are not visible to camera i.e. the occluded ones. But I need to select only those which are visible to camera.


text:
Selecting most and least brightened vertices in a model
Let's say there is a point light source which is casting light on a model. There will be some most and least brightened vertex/vertices on the model due to point light source. Is there a way to select only these vertices i.e vertices which are most and least brightened or somehow extract their (x,y,z) coordinates?

The "most and least lit vertex" are not trivial to find arbitrarily out of thin air, and can only be accurately found as the result of rendering or possibly even baking. From there you would have to do reverse lookup from a baked texture back to geometry

You could look into the BVHTree.FromObject().ray_cast() function. I was fiddling with it a bit yesterday, I couldn't really figure it out. But I think it's at least a step in a direction you might be looking for.


text:
How do smooth a faceted model that has been imported?
I have imported an Obj of an arrow and it's rather faceted. How can I make it smoother (I assume split it into more faces?) and look as expected?
Edit: I want the mesh to actually be smoother (rather than smooth shading that just makes it look smooth) as I will be exporting it.
I have quite a lot of these to do, so if anyone could point me in the direction of a video/tutorial I can follow I would appreciate it.

right click > Shade Smooth and also you can enable the Auto Smooth option in the Object Data panel > Normals, what does it give?

Isn't that just cossmetic? I want the mesh itself to be smoothed as I will be exporting it out

in that case apply a Subdivision Surface modifier, but first remove the Mark Sharp with a Ctrl E > Clear Sharp and bevel the angles with a Ctrl B?

You can give it a Subdivision Surface modifier, then remove the Mark Sharp with a CtrlE > Mark Sharp and instead bevel with a CtrlB in order to keep the angles sharp. When you're good apply the Subdivision Surface (but first always keep a version with the modifier non-applied):

Edit: Your topology is bad, you have edges overlapping, select this edge and dissolve it (make sure that you select the bad edge and not another one, and do the same on the side underneath):

Create this topology:

Also collapse the 2 edges of the tip (X):

Now select all the edges that you want to keep sharp:

Press CtrlB to bevel:

Shade smooth, give it a Subdivision Surface modifier:

Thanks, unfortunately, I'm struggling to get anything remotely nice out of it. I recall in Maya there is a smooth tool that in about 2 clicks does exactly what I am after. I am clearly missing something here as it seems like a rather fundamental thing to want to do

Where are you struggling? Have you done what I recommend? It's rather simple...

I'm not sure how to show/explain, but I can't get it to keep the edges as one would want. All i want is the cylindrical faces to be smoother, the edges should remain hard/as is. I'm happy to admin I'm doing something stupid, here's the obj if you would be so kind to try yourself      https://justbeamit.com/cbrb7

it says "sorry, this download link no longer exists". As I said you need to create a bevel all along these edges, or give your object a Bevel modifier before the Subdivision Surface modifier and apply. But please share again

Have you tried adding a bevel modifier before the subdivision surface modifier so you get a smooth shape while retaining some sharper edges

Thanks for everyones help. I have tried the bevel modifier and following @moonBoots instructions and the geometry just looks worse. Not sure what happened to the original link heres another to that arrow  https://ufile.io/bfhw8cca

Your object has bad topology, please see my edit

Thanks, It is something I got of turbo squid. Unfortunately, I have about 30 of these to do! I have not tried your approach, but given your detailed answer, I think it all seems logical so marking it as solved. Thank you for all your help

As you said, if you simply Shade Smooth it won't smooth the shape, only the shading, it may be enough for some of your objects though. That said, what I see with your arrow is that you need to Clear Custom Split Normals Data in the Object Data panel > Geometry, otherwise you may have bad shading with a simple Shade Smooth.

Yes I guess when you purchase these 3D objects you can't be sure that the topology will be correct...


text:
Material is shown only glossy on one object
Solution: Simply forgot to unwrap the object. (Select, press U, unwrap...)
I've just come to the Shading stage of some headphones I am currently modelling. However, I just can't wrap my head around one problem: I applied a downloaded PBR from polyhaven and applied it as already done in an example file provided by the creator. However, the material only looks glossy and in the designated color.
When I tried to put that same exact material on a basic cube the material looks just fine. What could be the problem here? The material nodes are exactly identical...

When applying the material on the whole headphones another weird thing happens, i dont know how to describe it:

Does anybody know what could be wrong with my object(s)?
Thank you :)

It looks like you don't have a proper UV unwrap for that mesh, or it was changed after an unwrap.

@AllenSimpson oh man thank you. I am kind of embarrassed, should have researched more and watched some more tutorials. Anyways, thank you! :)


text:
Object path tracking needs smoothness on a curve
I have added a constraint to my object to follow the path and the rotation of a front empty that is set to follow the curve; upon the first curve, the empty and the wheels snap back to the front instead of rotating smooth.
GIF here: https://gyazo.com/3b28024cd26c0e471fd9bafec49cd61f
.blend file: https://drive.google.com/file/d/1v9cqEXpdL5R2HGKaBd-4dHMgM4VzT1II/view?usp=sharing

hello, please share your file, just the important objects (wheel + curve?)

Hello and welcome. While files, images, and external videos or links may be helpful additions they should not be the only way to obtain information about your issue. Don't make understanding your question rely on downloading a file, watching a video or visiting an external site. Use the builtin tools to upload images or gifs, along with thoroughly explaining the problem in written form so it can be indexed and searched for thus helping future visitors with similar issues.

Okay, I will try to delete everything else in the project

@moonboots I edited the post, you may now download the .blend file.

I can't see any problem in the file you share but you didn't keep the axle, it may have to do with the axle local axis that is not aligned with the wheel axis?

I mean, the rotation it does on frames 495-507, it snaps to the path, but I would like to have it smoother, so the rotation wouldn't be so choppy. If you check the GIF, then on 0-2 sec the turn starts and then it literally snaps back straight instead of going smooth like is realistic.


text:
Modify node value in all materials with variable name?
I'm trying to automate a process where I have to change a Value node for all materials starting with the prefix mb:. I've been messing with it, but I'm such a novice with Python that I'm stuck.
Looking at the console, I see that the code for changing the value of the node would be this:
bpy.data.materials["mb:o:150:27"].node_tree.nodes["Value"].outputs[0].default_value = 10
But my issue is that I don't know how I would apply the variable of mb: to the to string in the above line.
Is there any way to do this?

You want to iterate over all materials and check each material's name. IF it starts with 'mb:' then modify it.
import bpy
for material in bpy.data.materials:
    if material.name.startswith("mb:"):
        material.node_tree.nodes["Value"].outputs[0].default_value = 10

Thank you! I had a bit of trouble at first, but this solved it all.


text:
Make meshes simulate like water?
What I want to do is, instead of using water with water simulation, I want to make lots of cubes flow like water (like the water simulation does with the mesh). Remesh won't work, because I want to be able to edit the cubes afterwards to make some of them different.

Update: I'm thinking of doing water simulation somewhat like this:
http://4.bp.blogspot.com/-Jevy4dr861A/U0AmZDk_BhI/AAAAAAAAIOw/AWqvuBpYhv8/s1600/lego+wave.gif
I couldn't find any way to do it in Blender, so I thought I'd ask here. Is it possible?

You could check out Molecular.

Why remesh does not work for you?

Finally a solution to this has been found. Mike Pan's solution was great, but another method is here. I found this on Blender Nation:
http://www.blendernation.com/2015/02/12/lego-fluid-effect/
More details:

The process is to do a standard fluid sim, add a remesh modifier set to 'blocks' and then turn on dupliverts for the fluid object (and parenting a 'brick' object to the fluid). That's basically it! Dupliverts gives great performance and remesh allows lower or higher resolution fluid depending on it's resolution. The material is just a gradient mapped on the 'brick' which changes colour depending on height.
The actual building effect at the beginning is a particle system and an 'Explode' modifier on a different object. An animated object defines the 'time' of when particles emit and the explode modifier makes sure the particles are invisible until emission (by unchecking 'Unborn' and checking 'Alive' and 'Dead' on the modifier). The reverse happens on the pile of bricks to the side so they disappear as the other ones appear.
If all that sounds confusing, a full tutorial will be up in a few weeks hopefully.

https://www.youtube.com/watch?v=_SU8ISvRn5E

I see you found the answer faster, though I found that sometimes the remesh modifier jumps around and the shrinkwrap is sometimes more stable.

You can approach it like this:

Make simple fluid sim, low resolution will be enough:

Create a plane and subdivide to get your blocks "resolution", position it very high above the water. Add Shrinkwrap modifier to project it onto the simulation:

Parent a little cube under the plane and set dupli verts:

Render it with plane transparent:

Add an ground plane and make column of little cubes from just 1 little cube (to fill holes in water):

As this is based on a voxel simulation you don't get data how the cubes move inside the volume (or on the surface), they are just stationary. To do that you would have to base it from particles. Thats for another approach, this is super fast to setup and simulate.

Thank you! I am definitely going to try this. May I ask how you set up your fluid simulation to make it have waves like that? I cannot figure out how (I know it's a bit off-topic).

@rioforce The simulation has default values, on one side of the domain box I have an inflow object with animated Enable attribute so it does "produce" fluid only for the first halve of animation and with Inflow Velocity aiming into the box.

If i understood your question correctly, you can use the particles engine with dupli-object to simulate a flow of cubes.
Fluid Particles are explained in the Blender manual here.

Check out the sample file I put together.

Thanks for that, it worked well. The only problem is that the cubes are intersecting with each other. I looked around, and is there any way to make them where they will collide with each other?

I don't really know much about this, but you could try investigatin about "rigid bodies"?


text:
Neutral pose for animation
In Softimage we have Netrual Pose, it simple set position/rotation/scale to 0 without moving pivot or object self. It just offset your object. I see that in Blender is Delta Transform, so I copy Transform values to Delta transform and set Transform to 0 0 0.
It works as I need, but:
1) Is there better workflow for copy values? Shortcuts, script ...
2) If I Clear Value, it also Clear my Delta, but I need only Transform.
It looks that I will need some scripts for this workflow, but maybe there is better ....

Do you mean the Rest Position for Pose Mode?

No, you can imagine some text where every letter will be animated, so my workflow in Softimage was: Create Empty (null object) for every letter, parent and set Empty to neutral pose, so it has all transform 0 0 0, but it is not in same place, because there is offset. It is good if you want set your text to default pose. So I wonder, what workflow is recommended for Blender.

Are you talking about parenting?

Yes letters are parented under Emptys, but question is: Is there any option for Empty or another control object for setting to zero transform = neutral pose

You can first store the expected neutral pose to pose library for further use.

Go to Object Data tab,  Click  button in Pose Library;
Click  on the right-hand side to add/store pose based on current pose;
Adjust the armature to the expected neutual pose;
Click  again to store it.

Then you can apply either one of them back to the armature object by clicking  on the right-hand side.

You can press Ctrl A > Apply Pose as Rest Pose, if you want to apply the neutral pose to rest pose (the real zero transformation, not offset) by then.

Thank you Leon. It looks that I have to use bones more often than only for character animation. So I have to make armature rig for text too (animated logos). In Softimage you dont need use armature until you need IK and you have all options. NLA, rest pose ... etc. It is different for me :)

@Cenda Actually, a single bone can be considered as an empty, There's no much difference I bet, right? :)  You can even change it to empty-like appearance.


text:
Create NLA transition with Python
Is it possible to create transition between clips with python?

This is an example of how to do it, using bpy.ops.nla.transition_add
import bpy

# Generate an override that can be used for this call.
win = bpy.context.window
scr = win.screen
areas  = [area for area in scr.areas if area.type == 'NLA_EDITOR']
regions   = [region for region in areas[0].regions if region.type == 'WINDOW']
override = { 'area': areas[0], 'region' : regions[0] }

# Replace this line with one that selects the object that has the NLA Tracks
object = bpy.context.active_object

# Replace this line with one that selects the NLA Track you want.
track = object.animation_data.nla_tracks['NLaTrack']

# Replace the next two lines with ones that select the desired strips.
# They must be adjacent.
# No other strips should be selected so you may have to deselect all first.
track.strips[0].select = True
track.strips[1].select = True

# Add the transition, using the override calculated earlier.
bpy.ops.nla.transition_add(override)

The key is that you have to select two adjacent NLA strips and that the bpy.ops.nla.transition_add call needs a context override.
3.2 Update
Context overrides are deprecated in Blender 3.2 and are scheduled to be removed in Blender 3.3  The replacement is temp_override. The manual has examples of how to use the new function.

Thank you Marty! But is there solution without selection these clips? Something similar to: bpy.types.NlaStrips.new( ... )
I am creating simple addon for duplicate whole NLA from one object to other. I can easily copy all clips with settings, but I don't know how to copy the transitions.
It is releated to this: https://blender.stackexchange.com/a/163875/1910

bpy ops tend not to be very flexible and there's really no way to add a transition without knowing where it goes, as far as I know. Unfortunately "where it goes" is between two selected strips. But copying might be a different problem. Maybe ask a separate question about copying between two tracks?

@Cenda I just added an answer to the other question that should handle your transition case.


text:
Import images as planes -> flickering from a distance?
First of all i'd like to comment that i m relatively new to blender but know the basics.
My scenario: I import an image (as plane). Use a cube as an object. I use shrinkwrap modifier to stick the plane image to the cube. I use default values with an offset of 0.001 - 0.002
Everything is ok, but, when i go away from the object (zoom out scene), and also move it left right, i see some flickerings in my image.
Do i miss an option here?
Pic here
https://ibb.co/4tqQPtq

Try tweaking Blend Mode and Shadow Mode in Material Properties tab and see if it becomes better. Maybe Alpha Hashed instead of Opaque.
Also, in Shading try changing from Linear to Closest that image which you imported. If that doesn't work, try uploading .blend file, so someone will probably find solution.
Also, I didn't use shrinkwrap. I just placed my plane manualy as closest as I could.

Hello and welcome. Instead of having users go through links and external sites please use the builtin tools to embed images in your post. See How to upload an image to a post? or GIFs


text:
Viewport Render Animation - From the Command Line
Inside of the 3D Viewport, there is an option available to perform a 'Viewport Render Animation'.  My understanding of this feature is that it performs a full render, using viewport settings across the entire blend file.
Is it possible to invoke this feature directly from the command line?  (From either command line arguments or custom python?)  I understand it may be possible to look up the individual viewport settings, and set each one in python from the command line, prior to the '-a' argument.  But I want the render settings to update as viewport settings change, without updating the render script.
Thanks in advance for all help and consideration.

I don't think you can do specifically what you want from the command line.  The problem is that the code in Blender that does the "Viewport Render Animation" is simply calling opengl() to make screenshots but command line render doesn't have that option -- it only knows how to render using one of the render engines.  You could write a script, of course, because screenshot is now in the API, but I haven't figured that out yet.

Thank you very much for your help!  Ever since your first comment, I decided to start looking more deeply into this issue by referencing blender's source code.  I was able to find the 'bpy.ops.render.opengl' operator and call it from the console.  It did create an image in the 'Rendering' tab, but did not save it to file.  If I can find a way to render full animation frames to file, and change viewport settings from python (choose Material Preview Mode, and select overlay options,) then it would completely solve my current issue.

You're welcome.  Sorry I didn't understand your problem when I wrote my answer. You probably want bpy.ops.image.save_as() as a starting point to look at.

I did some investigation, and I may be mistaken, but I don't believe this feature is currently possible in Blender 3.1.2.
It's possible to perform a Viewport Render Animation inside of the python console via:
bpy.ops.render.opengl(animation=True)

This will use the context and settings of the viewport in the scripting tab, and will save to the directory defined in Output Properties.  However, if you were to run blender from the command line, passing in the following python script:
import bpy
bpy.ops.render.opengl(animation=True)

It will come back with the error:
RuntimeError: Error: Cannot use OpenGL render in background mode (no opengl context)

Line 733 of ~/source/blender/editors/render/render_opengl.cc contains
  if (G.background) {
    BKE_report(
        op->reports, RPT_ERROR, "Cannot use OpenGL render in background mode (no opengl context)");
    return false;
  }

Which leads me to believe this is a hard-coded limitation.  Blender is checking whether it is simply running in background mode, with no apparent means of instantiating an opengl context and passing it to the opengl operator.  (bContext *C is never checked prior to G.background in that method, so it does not matter what is passed.)


text:
While using the skin modifier and the subdivision surface modifier, for some odd reason, a chunk of it is missing
anyone know how to fix this? i've tried for days to no avail, and yes this is related to my last post.
Edit: here's the blender link https://pasteall.org/blend/9eb51ad0504b4d9a8bdbaa513af7379d

Hello, could you please highlight the part? Maybe even share your file: https://pasteall.org/blend/

@moonboots here's the link https://pasteall.org/blend/9eb51ad0504b4d9a8bdbaa513af7379d

I don't know the Skin modifier enough but it looks like you can't avoid it: https://blenderartists.org/t/holes-with-skin-modifier/619594/4


text:
How do I make stuffing/cotton balls/poly-fil
So I'm rendering what I want my room to look like before I remodel it and I'm gonna do a ceiling of stuffing/cotton balls/poly-fil with LED Lights underneath to get a sorta cloud look with streaks of color through it. I've been trying for days to figure out how to make a material that achieves this desired effect but I cant figure it out. Can anyone help
This is what im trying to make:

https://blender.stackexchange.com/questions/6835/how-to-create-and-render-clouds-in-blender-cycles  https://blender.stackexchange.com/questions/201071/suggestions-for-fog https://blender.stackexchange.com/questions/43600/low-lying-fog-bounding-object-rendering-as-solid/43648#43648

https://blender.stackexchange.com/questions/144113/how-to-create-cotton-wool


text:
Run code after texture baking is complete (multiple objects)
Problem
I'm writing an addon that needs to:

Do some pre-baking setup.

Bake multiple objects' lighting to the same image texture (already UV mapped to not overlap).
(Note: this step should not block the UI.  I feel like this should be obvious, but freezing the UI for long bakes with no way to cancel is not acceptable UX.)

Revert/clean up the setup from step 1 only after baking is complete, because the setup is necessary for the bake results we need, but is not something the user should be left with.

Step 1 and step 2 are pretty straightforward to accomplish by just running the setup code and then calling  bpy.ops.object.bake() with INVOKE_DEFAULT.  But so far step 3 seems impossible, because there doesn't seem to be a way to determine when baking is finished when run in a non-blocking way.
Things I've tried
Attempt 1
My first thought was that I could accomplish this the same way I have for rendering in the past, via the bpy.app.handlers.render_post and bpy.app.handlers.render_cancel hooks as in this answer:
https://blender.stackexchange.com/a/71830/146003
Unfortunately, similar hooks do not exist for baking, and the hooks for rendering do not work for baking.
Attempt 2
The second thing I tried was to simply do the clean up immediately after starting the bake.  When baking a single object this works fine, because the bake works from the state of the scene when it was called, and ignores subsequent concurrent changes.
Unfortunately, this doesn't work when baking multiple objects because the baking operator updates its version of the scene before baking each object.  So the first object bakes correctly, but the rest of the objects use the version of the scene with the setup already torn down (and as mentioned earlier, the setup is necessary for the bake results we need).
Attempt 3
The third thing I tried is from this answer:
https://blender.stackexchange.com/a/253550/146003
This solution uses the dirty state of the image to which we're baking to determine when the bake has finished.  Unfortunately, this solution has two problems:

Unlike in that answer, my addon works from an already existing image.  And if the image is already dirty when the bake starts (which is common), this obviously won't work.
Even if the image starts non-dirty, we still run into a similar problem as attempt #2: after the first object finishes baking the image is immediately marked dirty and the setup is torn down, and subsequent objects will therefore bake with the setup already torn down (and again, the setup is necessary for the bake results we need).

Attempt 4
As suggested by @XY below, I tried checking if img.bindcode changes when baking is finished.  Unfortunately, it doesn't change at all, so that won't work.
@XY also suggested checking if the actual pixel data changed (e.g. img.pixels[0]), but that won't work because there is no guarantee that any particular pixel--or indeed any pixel--actually changes.  The user may, for example, re-bake "just to be sure", resulting in a bake with exactly the same pixels.
Ideal solution
An ideal solution would present a general way to wait for any modal operator to finish/cancel, not just the baking operator.  Because I suspect this is an issue that I (and others) will run into with other operators as well.
Short of that, a baking-operator-specific solution would work for my specific situation.

Is it work if check the img.bindcode or img.pixels[0] are changed ?

@XY: if img.bindcode is guaranteed to change whenever a bake finishes, then it would basically be like attempt #3, just without the first problem.  In which case I could probably make it work by manually calling bpy.ops.object.bake() for each object, rather than baking them all with a single call.  So it might work!  I'll give it a try.
(Having said that, it seems hacky and brittle, much like attempt #3 itself.)

@XY: I just tested, and unfortunately img.bindcode does not change at all with baking.  Also, just to clarify: checking img.pixels[0] definitely wouldn't work, because there is no guarantee that any of the pixels change.  Imagine, for example, that the user re-bakes just to be sure, but the resulting baked image is exactly the same.
Anyway, I'll add this as "Attempt 4" in the question.

To answer my own question: this is not currently possible in Blender's Python API.
But it looks like there is interest in addressing this, and making it possible.  For more info, see https://developer.blender.org/D14587#391718
I will update this question and answer once it's been addressed in a stable Blender release.

Try this
If this is not work, you have to consider modifying the source code.
import bpy

def run_every_01_sec():
    if RETURN in ({'CANCELLED'}, {'FINISHED'}):
        print("op end")
        bpy.app.timers.unregister(run_every_01_sec)
    else:
        print("op running")
    return 0.1

RETURN = bpy.ops.object.bake_image()

bpy.app.timers.register(run_every_01_sec)

This doesn't work.  RETURN only gets set once to {'RUNNING_MODAL'} when you first call bpy.ops.object.bake_image().


text:
Want to edit Snap Utilities Line script
I recently found the inbuilt blender add-on "Snap Utilities Line". I think it could potentially be very useful for me but I would like to make a few simple changes to it. 1) I would like it to automatically reset after creating a face. This can be done by clicking the right mouse button but I would like it to be automatic 2) I would like to make the indicators (that show when your cursor is above a vertex) larger.
It seems like to me both of these things should be relatively simple changes. I have been looking at the .py file in blender but I just cant decipher them. I have tinkered with making my own simple add ons before but not really a good enough coder to parse the code.
Any help is appreciated, I understand this is an extremely niche question.

For goal 1),
copy the green box text to line 349 in op_line.py

if not self.wait_for_input or not is_making_lines or event.type == 'ESC':
    if self.geom:
        self.geom.select = True
    self._exit(context)
    return {'FINISHED'}
else:
    snap_utilities.cache.clear()
    self.vector_constrain = None
    self.list_edges = []
    self.list_verts = []
    self.list_verts_co = []
    self.charmap.clear()

For goal 2),
change glPointSize to 50.0 in drawing_utilities.py (line 185)

Thank you so much!
For goal 2) the add-on uses these little square indicators to communicate some information. I have attached some pictures to the original post. The indicators are extremely small and tend to get blocked by my cursor. If I can I would like to know how to make those larger. I sincerely appreciate the help.


text:
Geometry Nodes How do I get the scale of this modified Object
I wanna use the Scale values of this object which has this Geometry Nodes Modifier on it.
Like this Object Info Node, which uses other Objects, just empty doesnt work, is 0.0.0

https://docs.blender.org/manual/en/latest/modeling/geometry_nodes/input/object_info.html
How do I get the values?

Dirty way
Found one little hack.
So as you understand, all objects inside current object is in object itself coordinate system. So if the current object is scaled, this means that everything outside this object is in inverted scale.
So I just add a helper object (basically an empty with default scale) and use its relative scale to get the scale of the current object by dividing 1 by the scale:

Proper way
The only proper way to do this, as I have found, is to pass object socket into group input:

And then set object itself in the modifier:

Sure, it requires manual work, but it is better than nothing.
Simple way
Of course, you can just select object in the input field if you are not going to reuse this geometry nodes on other objects.

Thats the thing, it is also on other different objects. it should get directly the modified object scale.
I really wondered why this not exist or I miss something.
It should get directly this Object, if input field is empty or an 'this' attribute.
Its also in C# like this, you use 'this' for the object-oriented reference.

So, using modifier inputs, you can select each object.

Empty field is regarded as no object, it may be useful in some cases

Okay, like the Normal Map Node in Shader Editor an empty UV Map input is like the existing UV Map, because Normal Map needs any UV unwrap.
So would be cool to have a 'this' attribute in Geometry Nodes Object Info Node.

No, empty UV is active UV, marked by render icon in properties.

Ah okay, big thanks for this information.

I've updated the answer BTW

Oh wow that works fine. Thank you much


text:
Mesh to Curve Geometry Bevel Round is not really circular
So for test I just added a Cube, top quad to one element, bottom quad to one element.
Convert Mesh to Curve, you can see they are closed curves.
Using Properties - Geometry - Bevel - Round
it actually does not have a Round profile, its "squished"
How can I make them totally round profile with Curve or with Splines methods? That should be possible, actually...

https://blender.stackexchange.com/questions/66353/how-to-make-beveled-90-degree-corners-on-a-curve-better https://blender.stackexchange.com/questions/259501/inconsistent-thickness-of-curve-profile-using-geometry-nodes

Hi there, I am involved in addressing this issue in Blender (in Geometry Nodes only as of v3.5). This is still in development but closing in on a solution and that'd be great if you could provide some feedback here: https://devtalk.blender.org/t/curve-to-mesh-node-even-thickness-feedback-thread/27271 - Thanks in advance!

Okay, I found a solution. Because it actually works with e.g. Curve - Rectangle or Curve - Angle and add another point for Rectangle.
If you have a Mesh, for instance a plane, and convert it to curve. It must be in localspace only x and y and then it must be set to 2D in Curve Properties Shape and Fill Mode: None
Then the round bevel is even circular. And then you must rotate the object in worldspace only. That's limiting workflow. But it works...
Idk if this is actually a bug in 3D mode.

They also have the nicer function for 3D curve-type in development for a long time, but it's not easily to implement in existing blender versions.
Also with Geometry Nodes are good solutions:
https://blenderartists.org/t/z-curve-sweeper-for-blender-3-0-curve-to-mesh-with-superpowers/1365277


text:
Black background after rendering
I have a problem with background transparency. In the viewport the background is transparent but after rendering it is black. I checked transparent in film and also render in RGBA but it's still black. Also add the image to photoshop to check if it is from my photo viewer but it is not.
Does anyone had the same problem?
This is how it looks in viewport:

This is while rendering:

And this is the final image:

I have no idea why it adds a black background
A screenshot from compositing nodes:

And you saved it as a PNG or which format?

So, are you using the compositor? If so, would you mind sharing a screenshot from the node setup there?

Yes, just added it

You're using a Lens Distortion node in the Compositor. This doesn't support alpha transparency and makes the background black. Effects like Dispersion work on all pixels to create the color distortions, therefore it needs an opaque image.
Of course you could take the Alpha output of the Render Layers and plug it into the Alpha input on the Composite and Viewer node. But in this case distortions that are exceeding the opaque area of the original image will be cut off.
A workaround would be to plug the Alpha output into another Lens Distortion node with the same settings as the first one. This way the  alpha will be distorted in the same way and you can use this on the Alpha inputs of Composite/Viewer nodes.
Just be aware that semi-transparent areas resulting from this will be mixed with a black background. This might make problems with overlaying the image on backgrounds with brighter colors.

Since effects like dispersion are dependent on the image colors, overlaying a different background color than black also results in incorrect results:

This is of course an extreme dispersion. But as you can see, with transparency you first of all have a less colorful dispersion, since it is semi-transparent. The other things is, with a white background added before the dispersion effect, the color would not be blue, but yellow.

Thank you very much. I didn't know it can effect the transparency. After removing the node it can be export without a background

@Mona_ I'll edit the answer to give a workaround. You can have transparency with Lens Distortion, the problem is just it's mixing with a black background which can be problematic if you want to overlay a bright background withthe transparent image.

@Mona_ Last edit for today ;) Just another example what the problem with dispersion on transparent background is.

The composite node needs to have "use alpha" enabled.

You can find this node by going to "compositing" in the top bar and then clicking on "use nodes".
However, this checkbox should be enabled by default, so it might not be the problem.

If she wouldn't know where the compositing is and didn't enable Use Nodes, she would most certainly not have to go there and enable Use Alpha, because by default Blender uses the Alpha when set to RGBA and Film > Transparent enabled. Just sayin'

I know, but there's no other reason I can think of. Besides, I said in my response that "this checkbox should be enable by default, so it might not be the problem".

Use Alpha is enabled. I will add images in the question what it looks like.

@ColinT That's why I voted the question for "needs more details / clarification." Because there is no information if the compositor is used, and there are other possible reasons like e.g. saving in JPG instead of PNG. I just wanted to say: if she used the compositor, the explanation how to enable it is redundant.

When you save your .png, enable RGBA

I quote from the question: "I checked transparent in film and also render in RGBA"


text:
Geometry node spacing along curve
Is there a way to have the bolts instanced along a curve in geometry nodes with proper spacing between one another on each side of the pipe? I want each segment of pipe to have the same amount of bolts on each side.

The Curve to Points node is really useful for this. If you need even spacing instead of even amounts, change the mode from Count to Length.

This would work on any curve (or multiple curves at once):

The same curves but with mode changed to Length:

Update
What you really need to do to make this work correctly is to create two offset curves based on the original base curve (I'm assuming that your pipe is based on a curve) and then use the Curve to Points node to spread out the instances evenly:

Sorry this is not what I need, I want the bolts along the curve to be evenly spaced not the ones on the connecting peice

@MasonHeilman Just saw your edit, doesn't the Curve to Points node with Count set to 11 solve your problem? The curve circle is just a representation of your curve, it could be whatever shape. Otherwise, you need to clarify what you're trying to achieve.

I am talking about the bolts along the length of the tube not the flange, they are closer together on the inner bend

@MasonHeilman I've updated my answer with another curve as input.

The photo you added to your post is showing the same issue. the spacing between the bolts is not the same. Say the curve to the left you updated your post with was to make a full circle. There should not be the same amount of bolts on the inner radius as there are on the outside.

@MasonHeilman Quote from your question: "I want each segment of pipe to have the same amount of bolts on each side." Set the mode to length instead of count if you need even spacing instead of same amount.

I added an edit showing the nodes I am using. It is set to length. Are you using two different curves

Yes, there are two curves.

@MasonHeilman I updated my answer with a node setup that creates two offset curves (one on each side of the pipe) based on the original one. Hope it helps!

@TobiasEinarsson Thank you for another update, this solves my problem. Sorry for all the confusion

This is a near-repeat of @Tobias Einarrson 's answer since he's edited it (.. the main point being to sample a curve by length). This adds a workflow option, though, so maybe it's worth posting.
Starting after you've made your mesh, somehow, inside  or outside a GN tree.

You can select edge-loops of the mesh to carry the bolts, weighted 1, and add them to a vertex-group.
Feed  that group as an input to an 'Add Bolts' GN modifier

In this example, the vertex-group input as 'Linear':

First of all, the Normal of the underlying mesh is captured.. (curves
can twist undesirably)
Then the vertices with enough weight in the group are separated from the mesh. (Edges are preserved)
The separated edge-segments are converted to a multi-spline curve.
The curve is sampled by length, and the bolts instanced on it.
The bolt-instances are rotated to align with the mesh-surface Normal.

When you sample a curve by length in GN, the endpoints are always included, and the rest are 'best fit'. Which, in this case, IMO, is quite helpful.
The method would work just as well for stitches in upholstery or clothing, ornamental beading.. etc.

you can use this node setup, to achieve the effect:

The resample curve node with "length" gives you even spaces.
result:

by adding scene time, some map range nodes, you can even animate the bolts:


text:
Organically curved wireframe
I'm looking to create a wireframe of this object to be 3D printed. I been playing around with the wireframe modifiers and attempted to curve the lines more by enhancing the creases/ applying skin modifiers/ and subdividing it. But it still isn't the exact look I want. The best I can explain this is that I would like the wireframe to not be little squares, and instead a more curved organic look - like an organic looking tessellation but made up of less lines as well. I could sculpt it from scratch but I'm also looking to create a few variations and hoping there is some way that is simpler that I'm missing.  :quick sketch I did, I just want the wireframe to be less lines and smoother lines (less of a grid look
Here is the wireframe I have now:

I'm not too picky about the outcome, just want to see the possibility of curving the lines more. It can even be the curving of the actual object - just wondering if this should be sculpted or if there is a simpler way I'm missing. Thank you in advance and hoping this all makes sense!

have you tried a voronoi mesh? https://blender.stackexchange.com/questions/217518/how-can-i-improve-the-quality-of-a-voronoi-style-mesh?rq=1

you could also try this approach https://blender.stackexchange.com/questions/145697/find-a-way-to-voronoi-structure

I think your best bet is with the built-in Tissue add-on, that thing is a beast. Check a couple of tutorials by the creator, Alessandro Zomparelli. For example, on this video you'll see pretty much the same I will show you, and much more.
Install the Tissue add-on

Go to Edit > Preferences
Go to Add-ons tab on the left.
Search for tissue and enable the check at the left of the result called "Mesh: Tissue".
The add-on will add a new tab called "Tissue" on the N side panel in the 3D viewport.

How to use
You'll need two objects and the add-on will create a third one as the result of the operation :

First, the base object that you want to tessellate/convert to wireframe. Each face of this object will become one "cell" on the mesh. For this to work nicely, you´ll have to follow a quad modelling technique (that is, your mesh has to be constructed from loops of squares as much as possible). You can then add a Subdivision Surface modifier to this base object (but do not apply it) to round it off. If this is not enough roundness for you, you can use a Multiresolution modifier instead, and sculpt as much detail as you want on increasing subdivision levels. On the image, this base object is represented by the rounded square marked as 1 (it's just the default cube with a subdivision surface modifier at level 4).

A frame object, a reference to the shape you want to give to each cell of your wireframe. On the picture, it's the one marked as 2. Remember that the add-on pretty much replaces each face of your base object with this frame object, so in general you´ll have to watch out for internal faces. In my example, I deleted all the faces around the edge of the frame.

Once you have these two objects, select the frame first and the base last, then go to the Tissue panel and press "Tessellate" at the top. An operator panel will appear :

The add-on is non-destructive, so don´t worry too much about getting it right and experiment. For starters, uncheck the "Use Modifiers" setting for the Base object, and choose "Patch" as the Fill Mode, then press OK at the bottom of the operator panel. In my example, I get the object marked as 3 on the picture above.

After that, you can edit both the base and the frame, then go back to the resulting object, go to its Data properties (in the Properties panel). There you´ll find a section created by the Tissue add-on, allowing you to update the mesh and touch all the parameters found on the initial operator panel.


text:
Bringing up the bottom left menu
Since I generated a landscape, I created some cubes and moved them around. After that, I was trying to adjust the landscape, but the left bottom menu is completely gone. Although I tried Adjust Last Operation, it just showed me the Move option. It totally makes sense because what I did last was moving around the cubes.
Then how do I recall the left bottom menu for the landscape? Or is there another way to adjust it?

Not possible. Once you do another action, that will become the new last operation.

Is that mean, I should generate another new landscape? And you can't adjust if you did other operations?
That means you should set everything perfect before you decide to do other operation. That's harsh.

yes unfortunately, because it is already a finalized mesh.]

@HarryMcKenzie This is true for the mesh primitives, but not the A.N.T.Landscape

@GordonBrinkmann oh yeah you're right. I completely forgot

Press the N key to open the right sidebar menu. You can find the Create tab there.


text:
Subdivision modifer selected surface not hiding until turned of in viewport
I don't know if this is intended on Blender 3.1.2, but I am working on a model and when I try to hide with the sub-surf modifier on it doesn't hide the surface. The vertices no longer select-able but still visible in the view port. The vertices under the model surface are select-able but the body doesn't hide until I turn the sub-surf modifier off with the View port off button in the modifiers. The vertices I am working on were created off a surface using Duplicate but are not their own Object. I was trying to keep the sub-surf modifier on while working on the duplicated area. Pictures and replication as follows:

Sub-surf mod on, nothing hidden

Sub-surf mod on, cube hidden and still visible? but only duplicated face select-able

Sub-surf mod off in view port, cube still hidden no longer visible but face loses modifier
Replication steps:

New project cube
Enter Edit Mode
Duplicate (Shift+D) top face of cube of cube and place a small distance over cube
Apply the subdivision-surface modifier
Verify modifier boxes are selected (cage, viewport, etc)
Select all faces of cube and Hide (H)
The cube is still visible and no vertices/edges/faces are select-able, except the face that was duplicated.
Click the View port button on the sub-surf modifier and the cube disappears but now the duplicated face no longer has the modifier.

Is this a bug or as designed?

This appears to be a bug. Please report it on Blender's bug tracker or let me know and I'll create a ticket for you.

Yes please do. This is an issue with GPU sub-surf turned on in preferences.

I was informed by Philipp Oeser that this was already report in https://developer.blender.org/T96080

Ok, thank you again for reporting the bug. Looks like it’s been elevated to get solved now.

I have tried doing exactly the steps you provided. When I tried doing step 6 (selecting the face of the cube and pressing H to hide it), this is where our outputs differ. In my case, the cube is no longer visible. This led me to think that our settings might be different so I tweaked here and there and found that your GPU subdivision might be turned on. You can turn it off by:
edit > preferences > viewport > Subdivision > Uncheck GPU subdivision
This might do the trick.
I can't explain why the GPU subdivision does this because I don't know anything about the backend side of blender but turning it off might give you the output you expect.
Kind Regards.

Yes that was the issue. Turning the GPU subdivision off allows the cube to hide now.


text:
how to create n items in geometry nodes
first of all: excuse my very bad english :-D
i made a geometry node of a lego brick, but i stuck at the little pins on the top.
i let create a cylinder at a specific position. but in order of how long and with the brick is - so there must be even more little pins at the other positions.
How can i achive this? have somebody a little tip for me?
some images to show you the problem:

EDIT: to clarify my question
i have made a lego brick generator. You can adjust the size of the brick (length and width) is it a 2x1 or a 6x2 Stone etc... I can adjust the size. But the little studs and the number of them on the top is making me some problems. for a 2x1 brick i need two studs, for a 4x4 brick i need 16 studs etc..
the number of studs are a little math, but i need to create and position them for this count - thats the problem of mine.

It is hard to understand exactly what your request is.
Anyway, creating n elements can be achieves using a line with n vertices and then just using the vertex index as the counter.
Please add some more information on your request.

Please clarify your specific problem or provide additional details to highlight exactly what you need. As it's currently written, it's hard to tell exactly what you're asking.

I hope my question is now a little bit easier to understand. :-/ its quit different at another language. :-/

Using a Grid and Point instances for the cylinders, you can specify the number of the grid dimensions.
See this example in the picture.

Thank you very much :-D Thats exactly what i need!


text:
the .fbx that I export with my animation is isn't the same when I import it back in
Been tinkering about with Blender 3.1 for a little while now. I imported an animation that starts from frame 1 and ends at frame 123. (I imported another one, copied some of its keys and pasted it into the main animation to make the tail move). All the keys are fine, none have red lines underneath them, and it works perfectly fine.
I export the animation as a .fbx, and everything is fine.

But... for some reason, when I then take the .fbx i've literally just exported and re-import it, my animation is gone.
What i'm left with is another animation (Don't know what it is), that's 71 keys long. I don't know what or where it came from, but it's 100% not my animation.

Does anyone have any idea on what the hell I've done wrong?
Thanks!
UPDATE 1:
I've looked into the Action Editor and can see that there's a dozen or so extra animations. How do you delete them so you only have one?

Animations are separated from objects in FBX, this allows to store different types of animations (idle, run, walk, etc.) in one file. So I believe you have animations imported, and one of them (wrong) has been selected by default. I see that they have different names in screenshot. So try to change Dope sheet in action editor mode, and select another one:

Oooooh! I see in the action editor there's like a dozen more that animate different parts of the rig! How would you delete these extra bits? (Just updated the main comment to show the actions)

Ah. You have to select it, then go to the hierarchy and delete it there. Why can't I see all of them? Surely they have a way to show ALL animations, no?

Those with 0 will be deleted on saving.

Interesting.... When I hit save after making them all 0 they still persist.

save and reload


text:
Have some shadow problem in cycles render (low poly mesh with normal map)
sorry for my poor English first..
this is my low poly mesh without textures

and in marmoset toolbag 3 or blender eevee, the normal map works well

but in cycles, light causes strange bar shadow result(red arrow part), looks like the normal map comes into no effect.

Can someone help me how to fix this? thank you!
.blend file here!
https://drive.google.com/file/d/1QjGzhOqGrY05mmHspnv0MyzeH0I0pIOX/view?usp=sharing

Hi :), please provide a download link to your .blend file. Ensure your textures are packed with File > External Data > Pack resources

thank you!  download link added.

Im taking a look at the file right now and the scene is different, so I don't know where to look. Regardless of that though, I'm looking at the multiple crates and there seem to be no problems whatsoever, in cycles OR in eevee. Can you take a screenshot in the new scene and edit your post to have that? That will really help me help you

I added new screenshots, thank you very much!

You can upload your blend file here: https://blend-exchange.com/

To add to what @moonboots already said:
A normal map can basically be thought of as a high-performance way of telling the render engine "Hey, that light ray your shooting at this mesh? it'd look alot cooler if instead of bouncing away at this really sharp angle, it bounced away at a different softer angle"
How the mesh normally works while rendering.

What happens when you use a normal map:

Then, when you introduces smooth shading into the mix this is what happens:

Put a normal map on top of it and it gets even messier, You can see that there are parts of the mesh where the normal map has to do a ton of heavy lifting to get the mesh to look how it thinks it should. This is where those gradients are coming from.

So ultimately you have one of two options: Either split the normal with Auto Smooth and let the normal map do it's own thing entirely. This has it's drawbacks. Each split edge on the mesh has to be on it's own UV island or it will cause other normal map issues. From a technical standpoint it also turns each vertex on a split edge to two, which can increase poly count and slow performance (though this doesn't really matter much anymore these days).
Or you can bevel the edges slightly, and use weighted normals to find the happy medium between the two.

You want to pick one or the other though. Other wise you'll keep getting your render engine confused like this.
I would recommend reading all of EarthQuake's threads on normal map baking on polycount. I probably read them about 15 times apiece until I really "got" them.

Thank you for the answer, but I still want to know that why only cycles has this problem, I tried Unity/eevee/marmoset etc,they all show correct shadow result....
maybe cycles is based on "realistic", and others are more for "videogame style" rendering..

That's probably  it. Realtime rendering uses alot of magic and fakery to make the render happen so quickly, whereas ray tracing probably leaves all the flaws of your mesh laid bare.

Edit: So you have bad split normals, which gives this bad shading, and besides that the normal map is particular as the baking must have occured when you already had split normals edited, see the gradient, it creates the bad shading:

If I disable the Auto Smooth or if I Clear Custom Split Normals Data it won't give the best result, so maybe the best thing to do is to rebake from the high-poly onto the low-poly, but this time clear the custom split normals of the low-poly before baking.

Thank you, but this operation just delete the low-poly mesh`s normal information, and my normal map will be useless

thank you, maybe bake again will solve this problem but I don`t know why these situation happends only in cycles render(this normal map works well in other render tools)

yes that's weird, the sure thing is that the normal map doesn't look good


text:
UV Map editing with python
I have been trying to figure out the best way to make a material for Minecraft blocks inside of my addon. Excluding special cases, a Minecraft block is a 1-meter cube that has an image texture of 16x16 pixels for each side. This is stored in a png file in the game files to which I have access. The goal of my script is to add a cube, properly align the UVs, and add a material with an image texture. I have no problem doing this in regular Blender. Add a cube, tab into edit mode, select all the vertices, open a UV editing window, select the whole UV map, rotate -90°, scale up by 4, and shift to the right by .5. This scales and aligns the UV map so that when I assign the material and set the image interpolation to 'closest' it properly displayed the block.
The issue I am running into is the complexity of manipulating UV maps via python code. It requires loads of matrix multiplication which I only half understand. So far I have managed to rotate -90° and scale up by 4. What I can't figure out how to do is shift it right by 0.5
My questions:

Is there an easier/faster way to assign a 16x16 pixel image as a texture for each side of a 1-meter cube? If so, what is the workflow in Blender and/or BPY?
Is there some function or library that helps with editing UV maps in python?
If there isn't a better way, how would I go about shifting the UV map to the right by 0.5?

EDIT: I figured out how to shift the UVs. But I would still like to know if there is a better way. Especially for the blocks that aren't 1-meter cube.


text:
Global / Local View is returning view
When I use View > View Local/Global and I will returning to Global, it will also change my position of camera. It is so annoying. I want stay on same position without any change. Is there any script or something so that camera stay in position?

It just returns to the previous angle before you entered local view.

Yes I know, but it is very annoying, because I dont want change my view as before :) I want remain my current. I also looked to API python and Hotkeys there is not options for it. So maybe some custom script so I save my position and apply it after switch to Global.


text:
Hiding source of particle instancing
I have emitted instanced object as particle. I can hide emitter with Emitter checkbox but how can I hide source object? It is still visible in scene, but I want only instance. If I hide source object, also emitted object dissappear.

are you using the Particle instance modifier? because it is supposed to hide the source object automatically

No I didnt know this modifier :) It is working good! :) Why there is two same things in Blender?

do add this as an answer or it is done?

Be careful using the particle instance modifier, as it creates a copy of the mesh for each particle (very memory hungry). Regular particles use instances, referencing the same mesh data for every particle. @Chebhou Feel free to add it as an answer :)

One way is by putting all the source objects on a separate layer (M).

Thanks for tip! And what if my scene with particles is grouped and linked in another scene? I need use same particles in many scenes. If I used proxy to source object it is duplicated, but still remain in scene.

Set the object material like this if you want the emitter linked:

This will render them with material for particles and transparent for the original object.
I wish just unlinking the object from the scene would work as it works with bone shapes so it doesn't pollute the scene and also works with linking. But it doesn't :/


text:
Bad bone rotation in Unity humanoid
It looks that I can not export roll setting from Blender to Unity, because it still has bad rotation. I tried different axis, different roll, blend file, fbx file. Nothing is working.
It is working good with generic animation, but with humanoid it is bad.
Blender:

Unity:

I tried FBX and also Blend, I am not using driven keys


text:
Link blend multiple times
I am solving this problem in all my animations. I need to use same linked group of objects multiple times (characters and vehicles). But it looks that Blender can link group only once and after Make Proxy my object is jumping between proxies.
My workaround is, copy Blend file to another position and link it as another file. Is there better solution?

I think this is a known limitation of the current system, not sure there any workaround other than what you already mentioned. I think it is planed to be improved for upcoming 2.8# series

Why Make Proxy and not link group directly? Linking a group more than once without Make Proxy works okay.

I need Make Proxy for animation on armature.

Is there any improvement you know of on this yet... I am running into the same problem needing to have lots of the same character in the same scenes... asked a question here...https://blender.stackexchange.com/questions/80522/multiple-character-instances-with-blenrig-workflow


text:
Hidden hotkeys in the 2.8
I can not find many hotkeys in the "Keymap", but they are searchable. I need find where they are, because I want to add more variants.
Is it bug or it is hidden somewhere?
For example "Time scub" or "Gizmo":

The gizmo category is not included in the keymap_hierarchy.py which can be found in release\scripts\modules\bl_keymap_utils. Therefore the category isn't displayed in the overview of the keymap. When you export the keymap you can view all shortcuts and it includes the ones for the gizmos.
It's not entirely clear to me why these entries are missing, hence I've created ticket T77799 on Blender's bug tracker. The reply by the UI team will be your definitive answer.

Why would you consider it a missing feature? Looks like a bug to me. The feature here would be to list all hotkeys for user to modify, wouldn't it? If the list is incomplete, it means it is not functioning as it should. If it was fixed, there would be no new functionality added, would there? I think it should be considered to be a bug and then reported as such. Or am I missing something here?

@MartynasŽiemys The default view of the keymap tries to have an organized hierarchy. I'd have to check with the UI team if it was intentional to exclude some in order to reduce clutter or if it should be displayed as their own category. I might also be missing something and they are somewhere in there but as a subcategory (it's almost a year since I've taken a look at it). Will take a look, but likely not before the next weekend.

@MartynasŽiemys I've created a ticket for this T77799, since Campbell Barton also suggested that this could be a bug.


text:
How to export an fbx skeleton animation?
I am failing over and over again, trying to export an fbx skeleton animation from Blender.
I am using a Mocap program that spits out a very basic animated rig. I've never used Blender before and have followed various tutorials for two days, trying to get this thing exported.

I try to follow these steps
https://www.youtube.com/watch?v=ysl0qYq5p9w&ab_channel=RoyalSkies
Everything I do, either the file exported is a tiny file size and doesn't work, or Blender just says (NotResponding) and hangs infinitely.
Please could someone break it down for me, in the most simple, simple, simple, beginner steps, like I am a 5 year old, how to do this?
I'm not sure if I'm just selecting the wrong things or do I need to "BAKE" the animation first? I just don't understand
The sample file is here, if that helps:
https://we.tl/t-IiwQUJQFVX
Thanks so much

Hello and welcome. Please briefly describe what you trying to do in your blend file. The  Mocap program has created this file? There is an animated stick figure floating around with a Rigify metarig, 4 video(?) planes, and a bunch of empties (for the mocap data?).

Hi, @Blunder Thanks for responding. What I am trying to do is export an fbx of some Mocap data out of Blender and use it in Maya. This file is from an open source mocap software that is currently in development. This is the file exactly as it is currently exporting from the software. I am not familiar with Blender but wish to generate an fbx of the bone animation for use in Maya. I need only the bone animation, to drive a control rig, similar to the way I would use the exported data from Mixamo, or Plask. I currently cannot work out how to export successfully and wanted guidance. Thanks.

Oh okay. It looks a bit strange (the orientation, the animation, all these empties...?) Maybe someone else knows? Can't you just import the mocap data into Blender or Maya? Blender can import bvh data. Usually, the imported data is an armature (skeleton) that can be used for animation or for retargetting to use your own armature. (I guess these empties are for retargetting, kinda.)

There are gaps or "holes" in your animation making it impossible for Blender to successfully prepare an fbx file. For one, the metarig is completely missing from frames 1 to 26 and again from frames 300 to 325. It needs to be present in all frames especially since it is parenting the stick figure mesh. Secondly, within the metarig itself, certain bones, for example hand/finger bones - are present in some frames and completely absent in others. The right-hand bones appear in frame 66 disjoint at 70, vanish at 85 then reappear later etc. You need to provide Blender a neat, complete metarig and animation to work with especially given the length of your animation and the fact that there are additional hand and finger bones.


text:
Change scale and rotation when seperating meshes
I have an extremely specific issue, I'm trying to import my blender environments into a virtual reality game, Beat Saber. But the program made for beat saber can't handle mesh deformations. This means everything is placed as a cube from the same scale and rotation as in the transform window of the mesh. I've found a partial workaround by separating every face from a mesh, by splitting every face and then separating by loose parts. But here comes the problem, all the separate parts share the same location rotation and scale values, I fixed the location error by selecting all the separated faces and putting origin to geometry. But the rotation and scale are still the same for every single face. So due to the rule that, apart from scaling and rotation, every mesh gets converted to cubes in Beat Saber. The converter turns every single face into a square the size of the whole mesh before separating and with the rotation of the beginning mesh (as seen in the two images added below, above is the input and below what it gets turned into in Beat Saber).

This spawns my question, even though it wouldn't be perfect, is there a way that the faces after separating get the scale and rotation calculated based on the scale of the default cube and global rotation? So that every face gets a rotation and scale which is roughly equal to the average of the 4 points. Even though mesh deformations aren't possible which would make non-rectangular faces, rectangular. So basically can I turn every face into a rotated, positioned and scaled default cube? (preferably not with a thickness scale of 0 but like 0.01, as a scale of 0 messes with rendering).
(Oh and the ball was just as a reference for what happens to the mesh while converting, I'm trying to put a mountains environment into Beat Saber)

Add a cube as a children of your object.
Go to the Object properties panel, and add instances by faces to your object. (You can tweak with the cube's transform.)
Choose Object>>Apply>>Make Instances Real

Now you have cubes on every face of your base mesh. Those transforms are based on the face's normals, location and size.

Thx for the reply, you've brought me way further than I was, but do you maybe know why it isn't working in the image below? I'm running a subdivided plane through a displace modifier, but my instances are not rotated like the faces are. https://imgur.com/a/HtN3LTX

oh, nvm I didn't apply scale of the square thank's so much for your reply, I marked it as the correct answer

If I understood correctly )

add the desired object
Add the Edge Split modifier to it (it divides the faces of the object into separate parts). Split Angle can be adjusted to the desired angle before triggering.
Add the Solidify modifier to control the projection of the geometry beyond the boundaries of the object
Bevel to taste)

It 's quite simple: https://www.youtube.com/watch?v=LJ8OFebl6Ko

Thanks for the posts. This is not a regular forum, according to site rules links to answers are not answers if the link goes missing your answer becomes an empty shell without content. Answers should be substantial and stand on their own without relying on external data like links, videos or images. Instead of having users go through external links, either transcribe essential parts of the process here, linking the source, or posts these in the comments section instead.


text:
Procedural cel shaded displacement material
I have a material which creates procedural sphere displacement to create a random blob. I want to cel shade the blob, however as far as I can tell this is only possible with EEVEE Shader to RGB node, while displacement is only possible in Cycles which can't do cel shading.
I wanted to use the displacement modifier with an Cloud image texture, however that doesn't have the W value for the seed (I can't find a way to generate unique image textures), and makes the process more convoluted than just a few Value nodes.
I haven't looked at geometry nodes the answer might lie there.
TLDR; I want to use cel shading and vector displacement together.

Any objection to using a displacement modifier instead?

@RobinBetts that's what I meant in the second paragraph

Ahh, OK thx for the edit Yes. GN can completely replace the Disp. modifier.. with a seed, and more control in other ways, too.


text:
Images as Planes in Eevee having weird transparency
I have a weird problem with my viewport. As the images show, there are some very basic objects. But some textured objects are shown through other objects, although they should be hidden. It's obvious with the gravel – the object with grass texture should conceal a part of the object with gravel texture. On the other hand, the gravel goes some way under the plain white object, and is hidden by it, as expected.

I'm anything but a noob with Blender, but switched recently to 2.82. This problem happens with different objects and different materials, even with Cycles or Eevee. Could this be a graphical glitch? My PC isn't anything but bleeding edge, more kind of usable ol' buddy. Never had this behavior with 2.79b.
Thanks in advance.

You need to set the material blend mode to Opaque.
When using Images as planes addon, it's set to Alpha Blend by default.
(Alpha Blend is needed for images with transparency - but in this situation only causes problems.)


text:
Correcting perspective distortion for an angled projector (Keystone effect)
My goal is to create a realistic reproduction of a projector mounted on the ceiling. So far I can reproduce a projector that is projecting straight. But I cannot wrap my head around how to correct perspective distortion when the projector is tilted down.
Edit:
The Solution shoud work like you woud expect from a real world projector. With the light beam originating from the lamp position spreading out onto the surface and interacting with objects in between.
For a projector that points 90° to the wall evything works fine.

As soon as i tilt the Projector i introduce Perspective distortion

Node tree to get the lamp to project a texture without barrel distorion like here or here

This example file:

It would also be nice if we could calculate the Scale and settings direcly from the projector position relative to the wall.

I don't know whether this suits, you might be wanting more of a simulation of real lenses. But we have an unusual advantage here in CG-world .. the projector can know how far away it is from the points it's projecting onto, via a Ray Length output of a Light Path node.
By similar triangles, (multiplying the normal by the ray-length) the spherical look-up, using the lamp's normal direction, can be corrected back to an orthogonal look-up into the texture, correcting the keystone.
Assuming the lamp is rotating around its X axis, that angle can be used in a driver to correct the aspect ratio of the resulting rectangle.A sine is taken only because the wall is at 90 degrees. If the lamp was projecting onto the floor, or the lamp was parented to a screen with its Z pointing towards it, that would be a cosine.

I've also set the lamp's falloff to 'Constant', so the image is evenly bright. You may want to switch that out.

Hmm actualy now after trying to work with this solution i realized it dosnt work the way you would expect form a projector. When i put Objects in the Path of the Light not in the plane which its projecting onto.. the Light beam compes from a totaly unexpected angle and not the Position of the Projecting Lamp.

I made a node group. It isn't perfect but works just fine for non-extreme cases. Hope this helps

This node group can be further condensed, but it is better this way for better clarity.
To know what Horizontal and Vertical inputs mean see: Keystone Correction

this helps already a lot! Now all thats left is to get rid of the distorion :)

I found another method to correct keystone distortion thanks to this paper.
It too has its limitations. I guess if you take an average of this and my previous setup, you would get the best result.

I don't know if this is the mathematically correct way to do it, but this worked for me:

Based on a video from CGMatter: https://www.youtube.com/watch?v=adahnQCqmw0
The nodes additionally modify the Z value before dividing to achieve a perspective correction. This is done by multiplying the X or Y value of the normal vector by the amount of correction desired and then adding it to the Z value.
This is the result:

Thanks, I had the same query.
But to avoid the non linear distorsion of the edges I've found this node setup.
I couldn't explain why it works though.

what did you change?


text:
How do I make the shape of a Kinder bueno chocolate bar?
I'm really struggling tor recreate the shape of this candy bar. I tried making a cube, insetting it and extruding it but I'm at a loss for how to do

and this is what I'm trying to make:

You're on the right track :-)

Start with a modified cube
Add an Array Modifier and a Subdivision Modifier (3-4 levels)
Use beveled Curve with Shrinkwrap modifier for the topping

(I took a small bite, sorry about that...)

YOU SAVED ME THANKS SO MUCH!! as a beginner, I am so so grateful.

No problem, glad to be of help :). If you get stuck anywhere, I could also share the .blend

+1 for the cute 'apology' :D


text:
Subtract object in front of other objects to make it transparent on intersection
I am new to blender and tried searching for 2 days now how to solve this but I am unable to formulate my question properly to find an answer that was probably answered somewhere. I am aware that it needs compositing or a certain node setup but I am still afraid of those.
My situation is that I am making a virtual tour for a client and the room is rendered as a equirectangular image.
There is one base layer of the whole room with sofa, table, carpet etc. and the end product is to be completed in 3dVista to make it interactive so the walls, floor and couch change color.
Every color change has a transparent rendered image that should go over the original room, and that's no issue for the sofa that is not covered by anything from the camera angle.
But when it comes to walls and floor they are covered by many objects and in the place of those objects covering the floor for example should be a transparent silhouette of that object so it can be overlapped with a PNGA.
I hope I explained it I will leave a picture of the whole room and successful sofa layer.
Full Room

transparent layer to be added on top

Any help is appreciated. Many thanks!

Yes, Thank you very much for your fast and accurate response!

No problem, good luck with your project ;)


text:
How to scrape/pinch a mesh in the center?
I am a noob when it comes to sculpting in blender. I am trying to recreate a similar shape to this image I found on Pinterest:

What tools would work best for this?

I think that the functionality you are looking for is called radial symmetry:

It can be used on any brush, this here is Clay strips
Setting can be found here:

Changing these 3 values will give you more copies of your brush in radial array, I have used 22 brushes on axis X to model first image

Does the mesh need to be subdivided a few times before doing this?

it sure does, you should start with few subdivides and subdivide more(or use Dyntopo) to sculpt smaller details... you need to have topology for sculpting, the image I used was a cube subdivided 5 times


text:
How can I make a continuous texture on a non-flat surface?
I would like the text to run on the interface in such a way that it is easy to read

Hello, as Huy Pham says you need to unwrap again but there are several ways to project your image onto the surface so maybe tell a bit more

Looks like you need to UV unwrap your mesh.
Unless you want to project the texture onto it, which is a more difficult task.


text:
Beveling an edge inside an empty space
I am trying to bevel the edges (picture 1) but when I bevel it, instead of just the edges beveling the whole geomtery(picture 2) becomes a solid block.
I have tried various things but I can't seem to created a curved edge inside the space.Any help/tip would be appreciated.

I would like to create a curved edge like the one in the 3rd image, it worked here but its not working for the other side(1st Image)

Thank you.

start with this, make sure, scale & rotation are applied:

add boolean modifier to the big cube:

set visibility of small cube to bounds:

now add bevel to small box:

or instead of using bevel modifier if you just want to bevel the edges, select these edges:

CTRL-B -> move mouse and use scroll wheel to increase loop cuts number.

--- update
do this to with your uploaded version:

select cube2

tab -> edit mode

M -> merge by distance -> A

then select your edges and bevel:

Thankyou for your response, I understand your approach, I used the same way you mentioned by using boolean modifer and setting the visibiliy of the small cube to bounds, but I am just curious to know for the sake of understanding when I select the edges (exactly like how you selected them) and bevel , instead of the edges beveling, the empty space is filled by a solid shape like in image 2(The one I posted) whereas i did the same thing (as shown in image 3) on the other side and it worked fine. What is causing this to happen?

Pls provide your blend file so I can check it out

Any chance you checked it:?

you had double vertices -> you can delete them in edit mode with A -> select all, then M ...i updated my answer

Thanks for taking the time to help me understand:)

you are welcome


text:
why the child item moving incorrectly with other multiple items including the parent?
Why is the child object moving differently, when moving multiple items?

pls check my video to Understand the issue

Hello, make sure that your object doesn't have a constraint like for example a Child Of constraint, if it's not the case please share the file: https://blend-exchange.com/


text:
How to flip normals with Geometry Nodes
I am trying to flip the normals of an object using geometry nodes.
I know that the flip faces node is supposed to do something like that but it does not seem to create the effect I want.
If anybody knows a way to flip an objects normals using nodes that would be much appreciated

unfortunately you didn't say what "effect" you want. Flip faces does indeed flip faces. like so: [1]: https://i.sstatic.net/G2ctd.gif so please improve your question and tell us 1) what you want to achieve 2) what you have tried 3) what doesn't work

I am trying to acheive an inverted hull effect

Do you mean something like this: https://www.blendernation.com/2020/02/28/daily-blender-tip-inverted-hull-toon-outline/

yes, that is exactly what I am trying to do.

Try Flip Faces node. My question is how to know and distinguish between flipped and not flipped faces.

This works for me:

You need to activate Backface Culling in the outline material:


text:
Vertex paint mode shaded view in cycles
When in vertex paint mode - the object being painted is displayed as shadeless.
This makes painting on a complex model difficult - as you cannot really see what you are doing.
You can use dirty vertex paint to make the geometry visible - but this is not ideal.
This is improved in the Blender render textured view using multitexture shading which gives you a shaded view.
In cycles the object remains shadeless in both shaded and textured mode.
Can this be shaded so it is not shadeless when using cycles?

@Garrett Your screenshot looks shadeless to me (as in there are no dark/light areas dependent on light sources).

@gandalf3, thanks, I was confused there.  I've deleted my comment.  Also, I have made an edit to OP's question which probably doesn't make sense and I can't figure out how to delete my edit (which has yet to be reviewed)

@Garrett No worries :). The edit will probably be rejected, but if it isn't it can be rolled back later.

Since 2.71, you have to select Blender render to have a shadeless model without a wireframe.

This was changed in 2.71, now solid view is displayed with shading, and wireframe view is shadeless:


text:
How to properly orient instances along corner edges
I'm currently trying to create simple level geometry for a game I'm working on. I've seen people use cubes with extrusions and then overlay those meshes with bricks and tiles to quickly create buildings.
I've already looked into it and this is what I have right now:

As you can see, it isn't quite working as planned.
The way I achieve this is by checking the angles and direction of the edges to see what is horizontal vs vertical. Then turn the mesh into curves and using them to create mesh or place instances along those curves.

The main issue I have right now is that the instances I place on the cornes are not aligned properly and I have a hard time finding a solution for this.
I've looked at some tutorials about aligning instances to normals, but it doesn't quite work in this specific scenario.
This is what I have right now:

The whole Transfer Attribute > Align Euler To Vector just doesn't give the right result, even with different combinations.
So my question is: How do I get the right orientation for the instances on the corners?
I'm also very new to Geometry Nodes and especially new to what I'm trying to create right now, so tips and tricks are very welcome also.
Link to the .blend file:

if u provide blend file i will try to find a solution...but i am too lazy to rebuild your setup...

I added the .blend file to the question.

Basically, it is only a matter of deciding on a certain direction for a rotation, according to which the stones are then aligned.
I would solve it like this:

First get the normals of the faces and form the cross product with the up vector. This will move the vertices all in a certain direction.

If you form from these directions again the cross product with the X-axis and the Y-axis, you get further directions with which you can work.

From the directions created before you can then, with a little logic, calculate a precise direction that runs along a wall.

Finally, you use this direction, in conjunction with the rotation resulting from the node Curve to Points, with the node Align Euler to Vector and pass the resulting value to your instances.

Note that the center of the objects to be instantiated is also important.
Here is the relevant group at a glance:

And here is the blend file:

wow, this is a bunch of vector math. Looks nice. +1

This is indeed what I was looking for! I'm interested in how it works.
I did notice that it sometimes swaps back to the old orientation, even with straight edges

@RensPitman Updated the nodes, now it works as expected ;-)


text:
GREASE PENCIL - Create square closed line per face (Quad)
I have add -> Grease Pencil -> Collection line Art
Is it possible to force the creation of the line to be a closed square for each face on a quad mesh ?
Instead to have line connected in chaos way …
I'm trying to get a clean SVG file.
And for that I need closed line art for each face of my mesh.
So that after that, I can select all the grease pencil shapes to fill them properly. So if my shape is a cube, in the camera view I'll have 3 grease pencil shapes with 4 points each....
Thanks !

I can tell that you are unfamiliar with grease pencil and English is most likely not your first language but, that doesn't make this question any less undescriptive. Your goal is convoluted, and I am having trouble understanding what it is that you want to accomplish.

If you are trying to draw closed lines over the quad faces of your mesh, then you have already done so in the blend file you provided because those two meshes are modeled simply. However, if you are trying to generate more lines over the faces of your mesh then this question becomes a Modeling or Topology question. The line art modifier only generates lines from existing edges and faces of your meshes.

If this is truly a question about generating line art with the line art modifier, then your answer can be inferred from the manual.

THANK YOU for the kind words :)
I'm trying to get a clean SVG file.
And for that I need closed line art for each face of my mesh.
So that after that, I can select all the grease pencil shapes to fill them properly.
So if my shape is a cube, in the camera view I'll have 3 grease pencil shapes with 4 points each....

I suggest you change your question to the comment you just made because your comment was more descriptive then your question.

I am answering your comment instead of your question since it is more accurate to what you want to achieve. You are trying to create closed line art for independent shapes within your mesh.
Although this can be accomplished in several ways, since you tagged this question with grease-pencil and lineart, I'll answer your question with only those two in mind. I suggest using the Fill tool as a quick fix.
In your file, you already have an applied line art grease pencil object. I reprojected it in order to show you how to use the Fill tool.

Every fill made by the fill tool has its own stroke boundary whose thickness can be changed like any other stroke.

If you just want the boundaries of your independent shapes or quads then switch the material to Stroke instead of Fill that you use for the fill tool.
If you export all your fills with the same line thickness as your line art then you can fundamentally have your independent closed shapes. As a note, fill tool can only fill closed strokes so, the fills we made using the fill tool should already have closed boundaries. Whether you think it is clean or not is up for interpretation.

Each time I try to use the fill tool it said : Unable to fill unclosed area…
I can only use file tool in a new 2D animation workspace…
What I need to do before to fill the shape correctly ?

Friend, you are descending into a XY Problem. Blender Stack Exchange is a question-and-answer website designed to further the use of Blender and its community. I know the struggle is real for you with your language barrier but, this site is not here to personally teach you how to use Blender.

As for your issue, I don't know what version of Blender you are using or how you have your settings set so, I can't give you a clear response. Please read more about the fill tool, here.

Hello,Obfuscate, I read your comments here as being a completely genuine effort to help @BLenjamin. However, they are open to misinterpretation.. so,  if in this case, you could confine yourself strictly to the problem at hand .. (alternative solutions, open requests for clarification without expressed judgement) that would help us along. If you've done all you can, let it be. Thanks.

You are correct, Robin. My comments were out of context and were too insulting. I apologize to BLenjamin and anyone else who felt I was unhelpful. I will try to do better next time.


text:
Geometry Nodes - Transfer Geometry Faces Materials to Instances on points
I would like to add faces materials to instances, so if the face of my geometry is yellow, the cylinder on it, will have the yellow material.
And I want to be able change the shader on geometry face on the fly.
How I can do this please ?
Thanks !

Please ask one question per post on BSE. Here's one way to do it, by realizing instances:

In Blender 4 you can use a Repeat Zone to create an instance type per each material, and so reuse the geometry without realizing instances:


text:
Subdivision Modifier doesn't make geometry smoother
I have this problem with this model.
When I tried to make it more smooth by adding Subdivision Modifier, almost nothing happened. I do not know what to do.
I don't just want it smooth shaded, because I need this file for carving on cnc machine.
The file is here https://uploadnow.io/f/mLKhQKj
Thanks.
This is original file
This is with subd modifier

Hello, is this for 3D printing or for an image/scene? If this is for an image or scene, do a right click > Shade Smooth and it will make the shading smoother. Then increase the Subdivision Surface level if necessary

Hi :). The geometry is basically all triangulated. Once you turn those triangles back into quads, subdivision modifier starts to work just fine :). Need help with that?

The model is triangulated, that's why Subdivision won't work.
Simply turn those those triangles into quads, Blender will do most of the work:

For best results separate the foliage and the column.
Select all the foliage faces and go Face > Tris To quads with a 180° angle
Select the column faces and go Mesh > CleanUp > Limited Dissolve with 0.2° max angle. The go Face > Tris to Quads.
Add a Subdivision modifier with enough levels and you're done.

The foliage. Tris to quads. Done.

The column. Limited Dissolve and then Tris to quads.


text:
Rounded mouth when using subdivision surface
I can't make my character smiling when I use subdivision surface.

U didn't understand me. I don't want to make lips smoother or sharper. I want to make my character smile. As u see in the first picture (low poly) character is smiling but in the second picture character's mouth is neutral not smiling. This situation is every time although I make smile bigger.

You need understand the Subsurf how to work. Try add more loop cut

It worked. Thank you <3

Your problem is a fundamental topology issue.  The area around your mouth is an ngon, and subdivision will be unpredictable. somewhat related -- https://blender.stackexchange.com/questions/179705/how-to-fill-ngon-with-faces

You need to make the lips sharper so that the character can smile using subsurf... Etiher by creasing or using support loops. But it would help also if you fixed the overall topology of the object, and avoided all of those n-gons (faces with more than 4 vertices, that are only going to give you headaches down the line...