text:
Geometry Nodes - Change the distance between points on a curve, after resample curve node
first of all, I'm absolutely not sure whether I'm right about the title. If the title is wrong, please let me know. :)
I have not been working intensively with Geo Nodes for very long and am currently facing a supposedly simple problem, which unfortunately I cannot solve.
I'm working on a node setup which is supposed to create a nettle. This is my current status, I'm pretty satisfied so far.

What bothers me now is that the leaf layers all have the same distance to each other. I would like to bring in a little more variation.
At the moment I trim the curve to determine the start and end and I use the resample node to determine how many leaf layers should be created.

Now I ask myself how I have to continue after the resample curve to slightly change the distances of the leaf layers to each other.
Here is a section of the entire node setup with the resample curve node.

Thanks a lot in advance! <3

I think the actual question is "How to resample curve by uneven (random) lengths?"

This answer is similar to the existing one by @Crantisz, but since I was already finished I thought I'll add it anyway. In my setup you have control over where exactly on the curve you want to start and where to end distributing points (on which you can instance something later).
First I use an Integer for the count of points to create. Then I subtract 1 from it because the indices of $n$ points go from 0 to $n$-1. Dividing the Index by $n$-1 and using this as Factor for the Sample Curve to determine the position of each point on the curve will spread the points evenly along the curve from start to finish.
Now I use a Random Value node with Min set to 0 and Max to an arbitrary value (in my example 0.05) to get some variation by adding the random value to the ratio of Index divided by $n$-1, which results in getting a factor start value between 0 and 0.05 and an end value between 1 and 1.05 at maximum.
This would already randomize the positions of the points along the curve. To determine now a guaranteed start and end value for the factor, I use a Map Range node.
I enable Clamp on the Map Range node, set the From Min value to the Max value I used for the Random Value node. This way, the first point will always be mapped to the To Min value. The From Max value I leave at 1, this way the last point will always be mapped to the To Max value. And that is how to determine the start and end position, in my example I distribute the points between factor 0.3 and 0.9 of the curve.
You could plug the Index into the Seed input of the Random Value node so every point gets its own seed, but I leave it unconnected to simply change the seed until I like the distribution.

//EDIT: As I know by now, you are using a Color Ramp node to assign a scale to the distributed instances and want to keep it that way. To do this, you can plug the result of the Divide node into the Color Ramp. The division assigns a value evenly spread from 0 to 1 on the points, like the Spline Factor according to the position on the curve.
Now changing the position afterwards by adding random values and map them to a different range does not change the "factor" they are given, which means a Color Ramp using this initial range would still apply the same values to the same instances like on the unaltered even distribution. In the following image you can see the initial distribution (with Add and Map Range nodes muted), below is the new randomized distribution and the nodetree. You can see the icospheres are still scaled the same, although their absolute position changed:

By the way, one reason why you should avoid to use a trimmed, resampled curve for instancing when you are using the original curve for the stem is the following: if you try to align instances along the curve according to the curve's tangent, the result might seem incorrect - that is because the tangents on the trimmed resampled are most likely from the ones on the original smooth curve - and you cannot sample the tangent from the original curve either because the factor does not fit the trimmed curve.

Another thing: You are trimming a curve coming directly from the Group Input - which means, you have added the Geometry Nodes modifier directly to a curve object, not a mesh object. If you now created a nettle and for whatever reason you want to apply the Geometry Nodes modifier, you cannot do this via Apply in the modifier menu even if the instances are realized. Because the Apply option cannot write mesh data into a curve object. If you want to convert it to a real mesh, you have to use the viewport menu Object > Convert > Mesh or the shortcut Ctrl+A > Visual Geometry to Mesh.

As you said, it's like the first answer, only explained in more detail. Many thanks for that too!

@Knudsen Well, it was a bit of a simplification from me to say its the same, but well... I've added a bit more information in the end that might be interesting to you although it has nothing to do with distributing the points.

@ Gordon Brinkmann Many thanks for that! I understand what you mean. Distributing the leaves works well now. Unfortunately, there are many other problems as a result. Just a humble question, is it possible to get in touch with you and clarify one or two questions?
Funnily enough, I found out from your profile that you are practically a neighbor, I live in Bielefeld :D

@Knudsen Really funny, been in Bielefeld 3 weeks ago. You can find me under my name at Insta, just my full name without any spaces, dots or anything

@Knudsen I've edited my answer to fully solve your problem with the addition of the color ramp scaling.

You can use sample curve node to sample curve at any factor. So that you can add a random number to sample factor like this:

This answer literally addresses the OP's approach to modify base distance, but if you want more randomized distances without overlapping, I would suggest using accumulate field node, and a little bit of excess points guaranteeing to populate the entire curve (and removing the excess with randomized factor above $1$).

This is very close to the distribution I had in mind. I am now trying to implement the idead from @Markus von Broady and then implement the whole thing into my system. Thank you very much!


text:
Invert node in compositing tab "distorts" the colors
Hello dear Blender community,
I'm working since a few days a good way to create heightmaps from meshes.
Everything works fine, but when rendering (eevee) the colors are always wrong. White should be black and vice versa.
If I now add an invert node in the compositing tab, the image is totally blended and you can no longer see any structures.
Picture 1: Without invert node, you can clearly see the buildings.
Picture 2: With invert node, hardly anything can be seen of the buildings.
What am I doing wrong? Shouldn't it actually be totally simple?

First of all, heightmaps don't need to rely on what is visible to your eye. As long as the values are correct, you can use them as heightmap. The other things Gamma correction and other things related to how colors are displayed on your screen. I guess you have the default Color Management settings enabled in your Render Properties, which means View Transform > Filmic and Look > None. You can change the contrast by changing the Look or the Exposure or Gamma, but for a heightmap it might be best to not use Filmic at all but set it to Standard and None.

The other thing is, you are using the Mist pass. This is highly dependent on what distances you have set for Start and Depth, because the 0 to 1 greyscale range is distributed over the this dimension. Everything closer will all be 0 and everything further away will be 1. The Mist Pass doesn't output values below 0 or above 1, no matter how close or far objects are to the camera. So simply inverting the colors could mean that values outside this range might get lost because the values are clamped between 0 and 1.

Colors in Blender are in linear space. This means the color values are proportional to the actual amount/intensity of light, eg. 0.8 is twice as much light as 0.4. But the human eye has a non-linear perception of light, it is much better at distinguishing colors near 0 than near 1.
For example, the colors 0.1 and 0.08 are easy to distinguish, but the difference between their inverses, 0.9 and 0.92, is nearly invisible.

So if what you care about is the numerical values, there isn't necessarily anything wrong, it's just a matter of visualization.

Oh, okay! I understand. Thank's a lot! :)

source: Stack Exchange

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

sort: votes


text:
How can I render my camera view when I also have an MP4 in the sequencer?
I'm trying to render from my active camera but it keeps coming up as a frame from the MP4 animatic i'm using as reference. How can i render from my 3D scene?
Please and thankyou!

If the MP4 is only in the Sequencer, you can disable it from the render Pipeline in the Output Properties under Post Processing:

Amazing, thanks Gordon.

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


text:
GScatter addon showing python error
I have tried reinstalling the addon but it didn't work. It occours whenever I am trying to scatter selected object, or to install anything in its library. Here's an SS

Hello, are you sure you're using a version that's supposed to work with Blender 3.5 ?

nodes is a collection and if one references into an empty collection (nodes['stringRef']) -- assuming it is not empty -- an exception is thrown.  GScatter appears to have a bug to be fixed.  look for some feedback on their site


text:
Render Layer showing through other Layers
I have a question about render layers.
When I use the compositor to connect the layers together my first layer is always seen-through. For instance I can still see it in rendering even if the object is behind a wall and such. I'm pretty sure it is something simple that I'm missing so any help would be well appreciated
Screenshot of compositor:

I've tried fiddling around with different nodes but nothing seems to work
Screenshot showing issue:

Most likely your render layer "Gobe" isn't transparent. Check Transparent in Shading rollout. See http://blender.stackexchange.com/questions/1303/can-blender-render-pngs-with-the-background-transparent

I've already tried that but nothing changed

I've changed to transparent and re-rendered, but still no changes, this probably shows what's happening in more detail: http://puu.sh/onVqF/1f1e6eaeaa.png

Another screenshot showing the same issue: the particle system is showing through the bookcases and floor: http://puu.sh/onVM8/efd583909b.png

Try checking "All Z" in the Render Layers pane.

Just checked it and no result :c

Apparently after fiddling with the scene properties I somehow got it to work, by giving the layer that the object was on a mask layer and then ticking 'all Z' the objects stopped showing through other things. Thank you all for your help on this

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


text:
Accessing the RMB feature on a Mac laptop
Please note: I realize this question is very similar to this one but I assert that it is not a dupe because it involves specific a hardware/OS combo! More importantly, this question is really about Mac laptop usage of a particular Blender feature, not necessarily about closing the default cube.
If you downvote or closevote this as a dupe, I at least ask that you add a comment that might help steer me in the right direction! But if you can't think of anything that would help me, then clearly this is a new aspect of an existing question, and I argue that this is grounds for this question being legitimate and not a dupe!!!

I am trying to get "the default cube" to go away on startup. Yes, I realize that once I remove it, that I can just update my default settings by entering Ctrl+U. That's not what I'm asking here.
In the answer to the question I linked above, the user stated that to remove the cube, select it by using the RMB (Right Mouse Button), then clicking X.
But on a Mac laptop, I have no right mouse button (RMB). All I have is a mouse pad. When I select the cube by clicking on it, all of the following have the same effect:

Clicking the cube on the left-side of the mouse pad
Clicking the cube on the right-side of the mouse pad
Hitting the Control button, and then clicking on the mouse pad
Hitting the Command button, and then clicking on the mouse pad

In all 4 of these scenarios, once I make the click on the mouse pad, and then hit X, I see the following screen:

When I select the Delete option, nothing happens. Where am I going awry?!?
Update:
I am in "Object Mode", but I noticed that when I click the cube it does not seem to be actually selected. That is, the cube does not have a thin orange border surrounding it. I think this is an important clue.

Only a fool would downvote this question.

Just as a note, CTRL+Clicking emulates a right-click on most MacOS products.

Yeah, it must be selected.
To select it with no RMB, you must change your user settings.

Now go to the "Input" tab and change to LEFT for select

Firstly, it's just a right-click. Macs "right-click" too. Whether it's the right side of the pad, two-finger tap, or holding another key while you click, it's all the same. Whatever way you "right-click" on a link to "open in a new tab," or "right-click" to cut/copy/paste use the same thing here.
Secondly, you could change the interface to use Left-Click to select. You can do that in the user preferences -> input tab -> "Select With..." While this might solve your problem at first, it might make following tutorials a bit more difficult. Also... you're still eventually going to have to right-click something in Blender.
The last option is to turn on "Emulate 3 Button Mouse..." in that same part of the User Preferences. This will cause "left-click" to become "right-click" but only when you hold the Alt key. It has some similar problems as "left-click to select." There are 1 or 2 commands that are impossible with the mouse if you use "Emulate 3 button mouse," but they're super obscure and there are still other ways to do them. Some other commands turn into a form of keyboard gymnastics, trying to hold Alt and Shift and click and drag...
The reason that the cube isn't being deleted is that it's not selected. Select it with "right-click" and then type x or press del and it should behave as expected.
Hope that helps!

This is more of an macOS question (not Blender), but here is an answer:
Control + Click will activate LMB (left mouse button). But anyway, on a Mac there is no way to Middle click, so you might want to reconfigure the Keyboard and Mouse in Blender.
You can also, alternativly, buy a Windows mouse and use that with a Mac.

The solution is going into the MAC ( laptop ) settings preference, then, under Trackpad , where it says Secondary Click, the default was Off.

Select Click with Two Fingers

This is what it should look like once you've made the right selection

Now, when you go back to Blender, if you click with two fingers, context menu will pop up.
This is the context menu popping up for me once I made the changes

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


text:
Normal direction screwing up rendering in blender/UE4 but not keyshot?
I'm playing around with a 3d tank model from a video game so I can 3d print it. The model consists of 4 parts, the hull, suspension, turret, and gun. I noticed the normals on all 4 of them are flipped in the wrong direction, but the suspension and gun still render normally in all rendering software.
pictures on imgur
The hull and turret render as a dark silhouette in blender internal/cycles (first screenshot) and appear transparent in UE4, but render normally in keyshot. The entire model looks fine in the blender viewport (second screenshot).
In UE4 (third screenshot) you can tell the normals are wrong since the front faces appear transparent (while the back faces appear because their normal is facing the camera). Same thing happens when you enable "backface culling" in blender. What's weird and pissing me off about this, is that the gun and suspension have their normals facing in the wrong direction too, but they render normally (and backface culling behaves normally on them).
I tried flipping the normals and recalculating them ("make normals consistent" box ticked in blender), except they still render incorrectly but now the shadows are in the wrong direction too. I can't manually correct each face since the model has 30k+ faces... This is really stumping me since I've only been using blender for a couple days... Also the models have a copyright on them (they're from a game) so I can't upload it for someone to help with unfortunately.
I already used these two threads and neither worked:
Select normals pointing in a certain direction
How to make all faces flip to the right/consistent direction?

The solution is to recalculate the normals and then export it as a .dae.
When reopening it, it renders correctly.


text:
Vertex Parented empties become offset after Set Origin to 3D cursor?
As you can see on this gif, I have a mesh composed of a bunch of vertices (divided in ~15 parts). Each vertex as an empty parented to it.
It's only when I finished the parenting part that I realised that the origin of the parent mesh was not on the 3D cursor anymore (yeah, stupid I know).
Know, when I move the origin to the 3D cursor, the empties wont follow the parent mesh, as if the vertex parenting acted as a "keep offset" parenting.
In the parent tab of an empty, I can't locate any "Connected" checkbox (which I could have checked for all empties at once, then move the origin to the 3D cursor...)
Any idea ? :x

Maybe the empties have all moved the same way? Can't you move them all back with snapping to vertex?

If you parented using the UI perhaps the parent matrix has been set. Can you go to python console, and with an empty active type in C.object.matrix_parent_inverse ?  If it is not Identity ( all ones and zeros), this is the issue.

@lemon Ok it fixed the offset (that was pretty obvious, maybe I shouldn't have ask a question just for that sorry...).
Although my question was answered, now, why do my empties won't follow the parent ? batFINGER's answer is probably a good hint as my matrix is set as this :
Matrix(((1.0, -0.0, 0.0, 0.18431678414344788),
(-0.0, 1.0, -0.0, -0.06000000238418579),
(0.0, 0.0, 1.0, -0.4116193950176239),
(-0.0, 0.0, -0.0, 1.0)))

edit: you could have selected all the empties, enable snap (vertex mode) and make them snap back to their vertices

Script to fix
To make the parent relation directly to the vertex, so editing will reflect position, run script below. Zeros the location of the empty and clears the parent inverse.
When setting origin to geometry of mesh both the location and parent inverse of the empties are changed, reflecting the translation of the origin location.  (The (0.18, -0.06, -0.41) part of the matrix shown in comment above).
Select the mesh object (make active) and run the script.
import bpy
from mathutils import Matrix
from bpy import context

scene = context.scene
mesh_ob = context.object
empties = [e for e in scene.objects if e.parent == mesh_ob]

for e in empties:
    e.matrix_parent_inverse = Matrix()
    e.location = (0, 0, 0)

The UI equivalent would be select all empties, AltG clear location and AltP clear parent inverse.
Script to add empties at each vertex
Since I have touched on scripting, feel it is a good idea to include a script to add empties to each vertex of a mesh object.
Have named them "Vert<i>" where i is the index of the vert, given them circle display and 0.2 empty scale.
import bpy
from bpy import context

ob = context.object
coll = context.collection

for v in ob.data.vertices:
    mt = bpy.data.objects.new(
        f"Vert{v.index}",
        None,
        )
    mt.empty_display_type = 'CIRCLE'
    mt.empty_display_size = 0.2
    mt.parent = ob
    mt.parent_type = 'VERTEX'
    mt.parent_vertices = [v.index] * 3
    coll.objects.link(mt)


text:
BGE Python: Mouse Sensor Error
I tried to program something that makes the camera look at the mouse for one of my games, but it keeps giving this error on line.7:
Python.001(Camera), Python script error
Traceback (most recent call last):
  File "Look.py", line 7, in <module>
KeyError: 'requested item "Mouse" does not exist'
Blender Game Engine Finished

The code on line.7 is this: ms = c.sensors["Mouse"]
c is the "currentcontroller" variable that I'm currently using.
I've watched tutorials and all of them give me this same error.

Hello and welcome to BlenderStackExchange,
The Mouse string is a reference to a Mouse sensor with type Movement for receiving mouselook input.
Your setup should look like this:

thanks that helped :)

Glad I was able to help. If my post seems to be the answer, please consider marking it as the thread solution.


text:
Problems with IK Rigging and Ragdolls
I'm currently working on a game that uses an AI system that heavily depends on having humanoid rigs (and ragdoll physics), and I have a modeler/animator who made this character for the game that looks great, it's just having some problems due to the way it was rigged.
The animations work great (though I was unable to make the rig humanoid), but the major problems happen when I force the character into a ragdoll when they die, which results in the following:

We immediately figured out that it was because of the way the animator used IK targets to make the animations (specifically for the legs), and that since there were no actual feet in the rig aside from the IK targets on the legs, the rig would always think the feet are still standing normally.
We thought adding "dummy" feet into the rig that follow the IK targets would fix the issue, but unfortunately the problem has persisted. What I really want is to not only fix the problem with the feet, but also make the rig a humanoid (for my sake), but unfortunately simply trying to use the dummy feet to make the rig a full humanoid didn't work that great, the characters just kind of stutter around and never pose properly. This is probably because the animations are depending on the IK targets to work, which complicates things.
To give you an idea of the rig, here is my attempt at making the rig humanoid:

So far the only solution people have recommended has been to completely re-do the rig and the animations, which my animator really doesn't want to do as it would take a significant amount of time and prevent him from doing anything else for the game for a few days.
For this reason, I am making this post to see if anyone has any other solution that could fix this problem and not add a significant amount to our work load. Anyone got any ideas?

You can go to pose mode, choose the menu "pose-animation-bake action", activate "visual keying, clear parents, clear constraints, and click OK: the animation will be baked as it was done without IK.

Unfortunately, that apparently broke everything in the animations. The animations depend on the IK targets for any sort of movements, so removing them resulted in a ton of problems

The process of baking an animation, if done correctly, creates a new animation that will be applied to a new rig: the new rig is equal to the old one except that it has no IK constraints involved. The resulting body movements will be exactly the same.

You can duplicate the deform bones and set each one to copy the transforms of the corresponding deform bone in the animation rig, then bake the animation as normal. This is pretty easy to automate with Python.


text:
Circular selection tool is stuck on the cursor after pressing alt+c
I am modeling a car. While modelling I pressed Alt+C instead of C for circular select tool. The circular select tool came anyway but now I'm unable to exit the tool. It has got stuck to the cursor. When I press C again the new circular tool comes over the stuck one.
I'm not able to do anything. I pressed Alt+C again to undo it but its all in vain. So to rectify it I opened a new blender file and pressed Alt+C and same problem appears. The cursor got stuck on circular tool.

Q: What am I doing wrong?

Hi. Blender comes with a screenshot function: Main menu > Window > Save Screenshot...

thanks for advice.i tried using windows screenshot feature but in that case the cursor error is left out in ss.

I managed to exit it by pressing esc or by changing the selection tool in the top right.

thanks. Problem solved :)

If this answer solved your problem, consider to accept the answer. How this site works: https://blender.stackexchange.com/tour @S.T


text:
how to add multiple boolean to cut from the same object?
Situation
I have walls in blender that have boolean modifiers to cut window holes or simply an open passage (ArchiPack Pro, Blender 2.9). Works fine.
Objective
Now I want to slice the building in a section (to show only the first floor or second floor or basement).
My Approach
I've create a builing-sized cube. I pick a solid (in my case the slab/flat roof) and add a boolean modifier selecting the slicing cube. The slab is cut out whereever I put the cube. Nice.

Now I want to link all other properties with this boolean modifier. Expecting it to cut all solids.
I would press A to select all, Shift+LMB on the slab and Ctrl+L to select Modifiers in order to make links from the slab's modifier to all other solids (including the walls).
Expectation
I would expect that all solids in my scene are cut and they do - BUT - also the holes of the windows disapear if I move the cube up (which entails, that the windows disappear. See in the red circle of pictures one and picture two). I would expect them to stay. Is my expectation wrong?

Question
I do understand that the walls have two boolean modifiers now. For the windows and the cube. How do I activate both modifiers of a wall thus I still can see the windows?

Are the window boolean objects also modified by the big cube boolean ? (They should not)


text:
Import multiple STL files and modify the incoming objects in one go?
I want to import stl files using file browser (by using 'INVOKE_DEFAULT' on import stl operator). It seems that join() operator gets called before importing is finished. Does Blender import the objects in some kind of seperate thread to prevent a potential freeze?
I also tried macros but I'm getting the same result. join() operator gets called before the import is finished. I came across this method of window manager window_manager.fileselect_add() but couldn't get it to work. Sure, I can import the objects if that's finished, the user can join them but the client requires these two steps to be done using one single button.
import bpy

def main(context):
    for ob in context.scene.objects:
        print(ob)

class SimpleOperator(bpy.types.Operator):
    """Tooltip"""
    bl_idname = "object.simple_operator"
    bl_label = "Simple Object Operator"

    @classmethod
    def poll(cls, context):
        return context.active_object is not None

    def execute(self, context):
        main(context)
        return {'FINISHED'}

    def invoke(self,context,event):
        return context.window_manager.fileselect_add(self)

def register():
    bpy.utils.register_class(SimpleOperator)

def unregister():
    bpy.utils.unregister_class(SimpleOperator)

if __name__ == "__main__":
    register()

Q: Is there any way I can import and join the objects in one go?

Umm... can you just exactly tell what you want to achieve here. It is a bit confusing.

@Aster17 I want a operator that imports stl files and join all imported models.

This appears to be  little more than  pasting the simple operator template.  Would say comment re joining finishing before import is akin to https://blender.stackexchange.com/questions/212179/how-to-get-the-file-path-from-the-open-file-operator

Similar to Import STL via python, you can use the ImportHelper class if you'd like to import and modify objects. Have a look into the Operator File Import template that comes with Blender.
In order to join the objects, see @batFINGERs answer on: How to join objects with Python? How to import multiple objects using the file browser, you can find here: How to batch import Wavefront OBJ files?
# ##### BEGIN GPL LICENSE BLOCK #####
#
#  This program is free software; you can redistribute it and/or
#  modify it under the terms of the GNU General Public License
#  as published by the Free Software Foundation; either version 2
#  of the License, or (at your option) any later version.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#  GNU General Public License for more details.
#
#  You should have received a copy of the GNU General Public License
#  along with this program; if not, write to the Free Software Foundation,
#  Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
# ##### END GPL LICENSE BLOCK #####
# <pep8 compliant>

bl_info = {
    "name": "Custom Batch Import Stl (.stl)",
    "author": "brockmann",
    "version": (0, 1, 0),
    "blender": (2, 80, 0),
    "location": "File > Import-Export",
    "description": "Import Stl files and join them",
    "warning": "",
    "wiki_url": "",
    "tracker_url": "",
    "category": "Import-Export"}

import bpy
import os

from bpy_extras.io_utils import ImportHelper
from bpy.types import PropertyGroup
from bpy.props import StringProperty, CollectionProperty

class ImportSomeData(bpy.types.Operator, ImportHelper):
    """Batch Import Stl files and join them"""
    bl_idname = "import_scene.custom_stls"
    bl_label = "Import multiple OBJ's"
    bl_options = {'PRESET', 'UNDO'}

    # ImportHelper mixin class uses this
    filename_ext = ".stl"

    filter_glob: StringProperty(
            default="*.stl",
            options={'HIDDEN'},
            )

    # Selected files
    files: CollectionProperty(type=PropertyGroup)

    def execute(self, context):

        # Get the folder
        folder = os.path.dirname(self.filepath)

        obs = []
        # Iterate through the selected files
        for i in self.files:

            # Generate full path to file
            path_to_file = (os.path.join(folder, i.name))
            bpy.ops.import_mesh.stl(filepath=path_to_file)
            # Append Object(s) to the list
            obs.append(context.selected_objects[:])
            # Print the imported object reference
            print ("Imported object:", context.object)

        # Join the objects based on:
        # https://blender.stackexchange.com/a/133024/
        obs = [x for sublist in obs for x in sublist]
        c = {}
        c["object"] = c["active_object"] = context.object
        c["selected_objects"] = c["selected_editable_objects"] = obs
        bpy.ops.object.join(c)

        return {'FINISHED'}

# Only needed if you want to add into a dynamic menu
def menu_func_import(self, context):
    self.layout.operator(ImportSomeData.bl_idname, text="Stl Batch & Join (.stl)")

def register():
    bpy.utils.register_class(ImportSomeData)
    bpy.types.TOPBAR_MT_file_import.append(menu_func_import)

def unregister():
    bpy.utils.unregister_class(ImportSomeData)
    bpy.types.TOPBAR_MT_file_import.remove(menu_func_import)

if __name__ == "__main__":
    register()

    # test call
    bpy.ops.import_scene.custom_stls('INVOKE_DEFAULT')

Note: If you get paid for that and my code got your job done, please consider making a donation here: https://www.blender.org/foundation/donation-payment/ to make up for that.

Very altruistic of you  Mr Brockman.   May be interested in Updated version of multi file import helper https://blender.stackexchange.com/questions/30678/bpy-file-browser-get-selected-file-names/198926#198926  obs.extend(sublist) ?`

I guess this won't happen anyway @batFINGER Nice, thanks for the link! I'll leave up any improvement to the OP...

@brockmann That is just magic. Script works like charms. And As soon as i get paid i'll definitely make a donation.

Cool, keep us posted @PavanBhadaja


text:
Node group not found after script execution
I was trying to recreate script from video, but with my own node group and I ended up with an Error which is too hard for me to understand. Script did works and create node groupe, but for some reason that I can't understand do not adding it properly to the worrking space, it just added node groupe that's called "Missing Data-Block" and then I need to select a newly created group by hand (It must be selected by default).
Image:

Script:
import bpy

class MainPanel(bpy.types.Panel):
    bl_label = "Custome Compositing Node"
    bl_idname = "MainPanel"
    bl_space_type = 'NODE_EDITOR'
    bl_region_type = 'UI'
    bl_category = "Custom nodes"

    def draw(self, context):
        layout = self.layout

        row = layout.row()
        row.operator('node.pixelazer_operator')

def create_pixelazer_group_node(context, operator, group_name):
    bpy.context.scene.use_nodes = True      #enable "Use nodes" in compositing tab

    pixelazer_group_node = bpy.data.node_groups.new(group_name, 'CompositorNodeTree')

    group_in = pixelazer_group_node.nodes.new('NodeGroupInput')     #inputs
    group_in.location = (-300,0)
    pixelazer_group_node.inputs.new('NodeSocketImage', 'Image')
    pixelazer_group_node.inputs.new('NodeSocketFloat','Pixelazed strength')

    group_out = pixelazer_group_node.nodes.new('NodeGroupOutput')   #outputs
    group_out.location = (800,0)
    pixelazer_group_node.outputs.new('NodeSocketImage','Pixelated image')

    blur_node = pixelazer_group_node.nodes.new(type= 'CompositorNodeBlur') #adding new nodes
    blur_node.location = (-100,250)
    blur_node.size_x = 5
    blur_node.size_y = 5

    first_math_node = pixelazer_group_node.nodes.new(type='CompositorNodeMath')
    first_math_node.location = (-100, 0)
    first_math_node.operation = 'DIVIDE'
    first_math_node.inputs[0].default_value = 1

    first_scale_node = pixelazer_group_node.nodes.new(type='CompositorNodeScale')
    first_scale_node.location = (100, 250)

    pixelate_node = pixelazer_group_node.nodes.new(type='CompositorNodePixelate')

    pixelate_node.location = (300, 250)

    second_scale_node = pixelazer_group_node.nodes.new(type='CompositorNodeScale')
    second_scale_node.location = (500, 250)

    #links connections
    link = pixelazer_group_node.links.new

    link(group_in.outputs[0],blur_node.inputs[0])    #connecting input node
    link(group_in.outputs[1], first_math_node.inputs[1])
    link(group_in.outputs[1], second_scale_node.inputs[1])
    link(group_in.outputs[1], second_scale_node.inputs[2])

    link(blur_node.outputs[0], first_scale_node.inputs[0])    #connecting blur node and scale node
    link(first_math_node.outputs[0], first_scale_node.inputs[1])  #connecting math node and scale node (to change scale by x)
    link(first_math_node.outputs[0], first_scale_node.inputs[2])  #connecting math node and scale node (to change scale by y)

    link(first_scale_node.outputs[0], pixelate_node.inputs[0])    #connecting first scale node and pixelate node
    link(pixelate_node.outputs[0], second_scale_node.inputs[0])   #connecting pixelata node and second scale node

    link(second_scale_node.outputs[0], group_out.inputs[0])  #connecting pixelata node and second scale node

    return pixelate_node

class NODE_OT_PIXELATE(bpy.types.Operator):
    bl_label = "Add Pixelazer Node Group"
    bl_idname = "node.pixelazer_operator"

    def execute(self, context):
        custom_node_name = "Pixelazer Node"
        my_group = create_pixelazer_group_node(self, context, custom_node_name)
        pixelazer_node = context.scene.node_tree.nodes.new('CompositorNodeGroup')
        pixelazer_node.node_tree = bpy.data.node_groups[my_group.name]
        pixelazer_node.use_custom_color = True
        pixelazer_node.color = (0.5,0.1,0.7)

        return {'FINISHED'}

def register():
    bpy.utils.register_class(MainPanel)
    bpy.utils.register_class(NODE_OT_PIXELATE)

def unregister():
    bpy.utils.unregister_class(MainPanel)
    bpy.utils.unregister_class(NODE_OT_PIXELATE)

if __name__ == "__main__":
    register()

Error says:
Python: Traceback (most recent call last):
  File "\CustomeCompositingNodeGroups.py", line 78, in execute
KeyError: 'bpy_prop_collection[key]: key "Pixelate" not found'

location: <unknown location>:-1

You are returning the Pixelate node in your creation method. You want to return the Group node.
Replace line 68 :
return pixelate_node

with
return pixelazer_group_node

Result :

I didn't know one could add an image into a group node input !

Thank you alot!


text:
How to rotate an object?
I want to rotate object in blender, for which I am using following operations.
ob = bpy.context.active_object
ob.rotation_euler = (x,y,z)

It is working well. Now if reaped the this definition for same object, it doesn't consider the last updated orientation. It considers the original orientation.
What can I do?

Have you tried  ob.rotation_euler.rotate( Euler( (x, y, z) ) ) ?

You are setting the rotation.
The code in question you are setting the Euler rotation.  The resulting value will always be (x, y, z)
Instead recommend make a transform (rotation) matrix. Python console example. x, y, and z are 30, 45 and 60 degrees respectively.
>>> x, y, z = (radians(30), radians(45), radians(60))
>>> Euler((x, y, z))
Euler((0.5235987901687622, 0.7853981852531433, 1.0471975803375244), 'XYZ')

The context object, has Euler rotation set to zero.
>>> ob = C.object
>>> ob.rotation_euler
Euler((0.0, -0.0, 0.0), 'XYZ')

Create a transform matrix from our Euler. Make it 4x4 so we can multiply it by the 4x4 object matrix.  Notice after the first multiplication we get the result as above.
>>> R = Euler((x, y, z)).to_matrix().to_4x4()
>>> ob.matrix_world = R @ ob.matrix_world
>>> ob.rotation_euler
Euler((0.5235987901687622, 0.7853982448577881, 1.0471975803375244), 'XYZ')

and again
>>> ob.matrix_world = R @ ob.matrix_world
>>> ob.rotation_euler
Euler((1.6257474422454834, 0.4853370189666748, 2.580118417739868), 'XYZ')

Please note this is global rotation.  For local use ob.matrix_local instead.
Note: As pointed out by @lemon for Eulers could also use
ob.rotation_euler.rotate(Euler((x, y, z)))

to transform  the local euler rotation from another.
For a lot of cases, the axis and angle is defined.  Eg make a 4x4 rotation matrix of 30 degrees around the axis (1, 1, 1)
R = Matrix.Rotation(radians(30), 4, (1, 1, 1))

Our R from above as an axis / angle rotation
>>> R.to_quaternion().to_axis_angle()
(Vector((0.03912381827831268, 0.7727739214897156, 0.6334742903709412)), 1.2104885578155518)

is the equivalent of rotating 69.356 degrees around axis (0.03912381827831268, 0.7727739214897156, 0.6334742903709412)


text:
How to get all collections of the current scene?
I'd like to get all collections in the current scene and can't find a way to do that. I found bpy.data.collections to get all collections stored in the blend and C.scene.collection.children to return the first level of sub-collections. However, I can't find out which collection is linked to each scene. I wonder if there is a simple way like iterating through the objects in context C.scene.objects?
Q: How to get all collections of the current scene?

Recursively walk the tree.
Similarly to https://blender.stackexchange.com/a/137866/15543 and Sorting Collections Alphabetically in the Outliner
import bpy

def traverse_tree(t):
    yield t
    for child in t.children:
        yield from traverse_tree(child)

coll = bpy.context.scene.collection

for c in traverse_tree(coll):
    print(c.name)

Look at ID users
It is most likely a lot quicker to run over the collections and check if they are in use by the scene. If a collection is linked anywhere in the hierarchy of a scene's collection tree, then the scene is a user of the collection.
>>> collections_in_scene = [
        c for c in D.collections
        if C.scene.user_of_id(c)
    ]
>>> collections_in_scene
[bpy.data.collections['Collection 1'], bpy.data.collections['Collection 1 1'], bpy.data.collections['Collection 1 1 1']]

This solution is "WOW", but I wonder one thing, what does it change to use C.view_layer.layer_collection.collection with C.scene.collection?

They're often the same.  coll = bpy.context.view_layer.layer_collection.collection

What is the difference between the bpy.context.scene.collection and bpy.data.collections because with the second one in my case I am getting some extra collections from the ones that are visible in the outliner.

A blend can appear totally empty. The data we see is linked to a scene. Just as an object with no parent really has the scene as a parent, the scene collection is the root of collections in a scene without the need to also define it in bpy.data.collections

So I guess it is always safer to go with the bpy.context.scene.collection rather the bpy.data.collections.

Use context.collection would be my suggestion. Or to be sure to be sure context.collection or scene.collection Unless  I'm creating objects rarely or never use bpy.data  eg if you are interested in an object "Foo" scene.objects.get("Foo") is in the scene, whereas bpy.data.objects.get("Foo") may not be. Similarly with collections.

Thanks for the details, appreciated ;-).


text:
Texture painting issues
How to texture paint normal map? I texture painted the diffuse and its fine but normal map isn't correct. I don't know if the uv's are incorrect or what. And sometimes it dissappear in texture paint in material preview but we can paint. Please help me out.

Hello, it's not clear what you mean by "paint normal map", you can bake a normal map but it's not possible to paint normal map, could you please elaborate?

When i baked textures diffuse and normal. And applied to the model then diffuse is set fine but normal map isn't good when I applied to the model. So, i have to manually texture paint the normals where some parts aren't correct,  but then i have to do it in photoshop.

Adding screenshots and example images will help people better understand the problem you're dealing with.


text:
Convert udims to single uv map
How to convert udims to a single uv map. I'm suffering through an issue. I have a car model that has Udims i want to convert the textures to a single uv map. My gpu cpu memory goes higher when enable texture mode or when i render the scene or car model and another problem is Sketchfab does not support Udims, I want to upload on sketchfab. And my texture size is 4k of udims.

As far as I know, you have to manually move the UVs to tile 1, save it and then, manually adjust each texture on every UV island

once you have created a new non-UDIM UV map, just bake the image textures using the new and the original UDIM UV map. Have a look here: https://blender.stackexchange.com/q/293836/107598

Thank you it helped me.


text:
Vertex Groups transform
I have vertex groups in my model that is bind with automatic weights to an Armature. I have another model with particle system with Vertex group_(Hairs). So, I want both Vertex groups - previous one_(with automatic weights) and one with_(particle system).

To copy the vertex group of an object that is exactly the same, give your object a Data Transfer modifier, Source > object with the hair vertex group, Mix Mode > Add, enable Vertex Data and Vertex Groups, Mapping >Topology, click on Generate Data Layer and apply the modifier. Now the object should have inherited the hair vertex group.

Hey! Thank you so much. This is working properly as i want.

Great! You're welcome  ;)


text:
How do I flip a mesh inside-out and still have the object be the same just so the faces are now facing out-words instead of inside the object?
I'm making fuzzy boots for a game and everything was going well until I tried to add the fuzz and I discovered that the whole thing was literally inside out and the fuzz (hair) would go inside the boot instead of outside the boot. I need to know if there is a way to not change anything about the topology of the boot but make it so the hair/fuzz goes on the outside instead of the inside. (please help)

Usually, the answer is "recalculate normals", and if that doesn't do what you want, enable "inside" on the operator panel.  There are potential situations where that won't work; but those potential situations indicate something other than/additional to normals are wrong, and you should fix that other wrong thing.  The other way around this is to just change whatever the fuzz object is, making it point the other way.

This is called "flipping the face normals". A Normal is basically the front direction of a geometry element, like vertices, edges, or faces. To see if your faces are oriented the right way, you can use some Overlay options in the viewport, both in Object Mode and in Edit Mode:
  Left: Enabling "Face Orientation" in Object Mode Right: Enabling "Face Orientation" and "Face Normals" in Edit Mode
Then in Edit Mode, you can select your faces and Recalculate Normals by pressing Shift + N. There are also other operations available in the Mesh > Normals menu (Alt + N), as explained in the manual:

I just went to view port overlays and turned on face orientation which showed which Normals were the wrong way and I selected any wrong-facing Normals and flipped them by going to Mesh > Normals > Flip


text:
How do I lower tris caused by hair?
I made fuzzy boots and the actual mesh only makes up for 30% of all tris. The rest is because of the fuzz on the boots. How can I lower the amount of tris caused by hair/fuzz without ruining the boots?

Instance planes with a fur texture, perhaps

I learned that it wasn't the fur but instead the Bezier Curve which is causing my model to have 8k extra tris, still don't know how to fix this but at least I know where the problem lies. (update) I learned that the Bezier curve has resolution and the higher the resolution, the more tris. What I did to get the least tris was simply make the resolution to 0, this doesn't affect the final product in any way from what I've seen.


text:
Problem with white color in material
I have problem with white color. If selected white color I got gray color.
What can be problem?

maybe your light isn't strong enough?

Your picture does not provide sufficient info for us to help you. Could you at least show us a full screenshot of your scene and a picture of your material setup (in the node editor)?


text:
Installed latest version of Blender now computer won’t boot up
I installed the latest version of Blender. When first opened it all I got was a black screen with a cursor. I closed that down then shut my computer down to see if a restart would work, now my computer won’t boot back up. Any thoughts or suggestions.

I wonder how Blender should get your whole computer to not boot anymore... could you provide some details please? Like OS, hardware specs (GPU!), Blender version, etc.?

Did you install blender to an unusual, system-protected directory?


text:
Custom float property used in a driver need manual UI modification to work
I'm currently creating some script to automate a cloth rig setup.
In the process I'm adding a custom float property to an empty and use it in a driver. It's a concept I wish to reuse for other purposes but had not figured out how to have that completely (and automatically) working yet. Unless I manually modify the custom property value in the UI and then update the driver dependencies, the driver will not pick the custom float property.
Here is an example that assume you have a Cube and a Sphere in the scene.
import bpy
source_obj = bpy.data.objects["Cube"]
source_prop = "influence"
source_obj[source_prop] = 1.0
target_obj = bpy.data.objects["Sphere"]
target_prop = "location"
axis_index = 2
driver = target_obj.driver_add(target_prop, axis_index).driver
v = driver.variables.new()
v.name = "var"
v.type = "SINGLE_PROP"
v.targets[0].id = source_obj
quote = "\""
v.targets[0].data_path = "[" + quote + source_prop + quote + "]"
driver.expression = "var"

If you run that you will see that the driver don't work.
If you then go modify the value of the custom property through the UI by selecting the Cube and setting the influence value to 0.5 for example.

Then go update the Sphere driver dependencies (and I really just mean pressing the Update Dependencies button), it then work as intended.

Does anybody know what I need to do to have that working programmatically without having to touch the UI? (In the case I want to add, let's say 300 custom floats).
bpy.ops.wm.properties_edit() is what is triggered when you edit the property, but if you try to add that to your script it will give you an error: Direct execution not supported.
You can apparently add properties to a whole class, but it's not what I want to do. I want to add custom property to specific empty only.
I'm using Blender 2.8 by the way
Thanks
H.

Ok I have figured out a solution.
If I save the file and reopen it, the drivers are working perfectly fine with what I have done with my script.
Might be an update issue with the property UI I don't know.
I could add a save/reopen at the end of the script, that would be an easy work around for now.
If anybody know how to instantly make it works please do tell so. Posting my answer anyway in the case someone else is encountering the same driver issue.


text:
How to resample a video clip?
I have 30fps, 1440dpi car Dashcam footage but desired action is far away. Would like to resample to 720 or 360dpi 30fps, w/o loss of pixels & only use part of resulting video (crop?) that contains action.
Searched resample & zoom but couldn't understand if any applied to my situation.

So you want to crop the video and let the result be the total width/height for the output video?

Yes. I want to zoom (resample?) so the desired action is in the forefront. Have that take up most of the width/height of video & remove (crop?) the insignificant excess surrounding the action. IOW, as if the camera was closer to the action.

Load your video clip into VSE (I'm using an image here, but it is the same for videos)

Set the resolution to your output requirements.
Add an Effects Strip -> Transform
Change the Scale parameters and recenter with the Position X/Y

Render output resampled.
I spent sometime trying the Clip options in the Transform strip but they did not work when changing the output resolution.

Tried your method, (thanks for suggestion), but moving X & Y distorted frame, not moving w/in image. Having some luck w/ transform effect. Will post when finished testing w/ what, if anything worked.

https://blender.stackexchange.com/questions/42094/rescaling-in-the-vse-yields-low-resloution-blurry-images


text:
How to render from multiple cameras in one go?
I have a scaffolding setup with multiple cameras locked on to a target. I plan to use this to render a model from various positions. This loop has worked for everything else such as changing name and adding constraints but I can not get the logic to work for renders.
The filename changes just fine, running context.view_layer.objects.active will report the camera is changed correctly, as does the UI, however, the render output is simply multiple renders of the same camera...it never changes. Is there a different way to force each camera to actively render other than what I have tried here?
obj_in_scene = bpy.context.scene.collection.all_objects

for cam in obj_in_scene:
    if cam.type == 'CAMERA'
        bpy.context.view_layer.objects.active = cam
        file = os.path.join("/home/jruch/", cam.name)
        bpy.context.scene.render.filepath = file
        bpy.ops.render.render(write_still = True)

I have also tried building a dedicated list object to iterate through, but it would not cycle the camera's active status as well the filtered "all object" context I used about. What am I missing here?

You're setting the camera object as active object, but not as active camera.

Assign the camera object to Scene.camera to make it the active cam of the scene:
import bpy

scn = bpy.context.scene

for obj in scn.objects:
    if obj.type == 'CAMERA':
        scn.camera = obj
        scn.render.filepath = obj.name
        bpy.ops.render.render(write_still=True)

Holy flippin' crap!!!! I can't believe it was that easy...Context is indeed everything, thank you so much, this definitely fixed it :)


text:
How to interrupt a rendering which is not displayed in the UI to interact with?
I created a script that renders and saves the selected objects. The script is quite large and I don't think it is necessary to post it completely.
def myRenderFunction(self,context):
    for o in context.selected_objects:
        ###some coordinates for camera position
        ###some functions to hide
        myPath = "C\:blah blah" + os.sep + o.name
        data_blocks = {o}
        bpy.data.libraries.write(myPath+".blend", data_blocks)
        bpy.ops.render.render(write_still=True)
        context.scene.render.filepath = myPath

My issue is that I can't find a way to stop it once executed because Blender's Interface is completely frozen while rendering the images.
Q: How can I allow the user to stop the rendering process at any given time?

@RayMairlot  Thank you very much for reporting, I was looking at this link first, but in fact my script is inside a for loop, and I found that the situation is slightly different

You want to allow the user hitting a button to abort the rendering process right? If that's your goal, you have to use a modal operator, which leads directly to the linked answer (it's is a hack anyway). Try to understand the answer and also have a look into the modal operator template... Or is there something I didn't understand? @Pastrokkio

@brockmann Ty , The problem is that I tried with the modal operator, but I don't know how to place the exit from the loop, I tried to insert the for loop inside the modal, but it remains frozen anyway, for days now I have stopped at the pole of the questions, I'm really frustrated because all the questions and answers I found don't solve my problem, I just want to understand how to place that for loop inside a modal operator correctly. This is not explained in any answer (or at least I have not found) For me these concepts are still little known, so I asked the specific question

Yeah, but it's a really broad question and takes a lot of effort to make it work (and testing all that stuff, also your question is incomplete IMO). I'd suggest split up the process into 2 operators, one for rendering (based on the linked code) and another one for loading the objects and to execute the rendering operator (the linked operator is basically a wrapper for render.render() allowing the user to exit).

@brockmann I guess it's not easy, and I thank you for the answers, I can put that function where I want, I can even insert it completely in modal uperator (which I've already done without success) my code is really too long to be posted here, basically the crucial point is this that I posted, I can handle it in any way, the important thing is that itineri on those objects, as they are manipulated during the loop for. I apologize for the headache question.

Minor code changes to make it work: https://pastecode.xyz/view/e10a812a However, it's just a starting point @Pastrokkio

@brockmann Thanks, I saw this link today, but I really don't know how to integrate my script into those scripts, I tried this afternoon with modal time operator, but I don't really understand how to integrate it, and then I noticed that the time only acts as a loop, so until the loop is finished you can't get out of that event (from what I've tried)

Minor code changes are required to make the code from the linked answer work for objects in selection.
Following modal operator is just some kind of barebone code, a good starting point using the timer though. Edit the render path according to your Operating System, run the script, select the objects in 3d view, press F3 and type Render multi...
import bpy

class Multi_Render(bpy.types.Operator):
    """Docstring"""
    bl_idname = "render.multi"
    bl_label = "Render multiple times"

    # Define some variables to register
    _timer = None
    shots = None
    stop = None
    rendering = None
    path = "/tmp/"       # Linux
    #path = "C:\\tmp\\"  # Windows

    # Define the handler functions. I use pre and
    # post to know if Blender "is rendering"
    def pre(self, dummy):
        self.rendering = True

    def post(self, dummy):
        self.shots.pop(0) # Remove current object from list
                          # Render next Object
        self.rendering = False

    def cancelled(self, dummy):
        self.stop = True

    def execute(self, context):
        # Define the variables during execution. This allows
        # to define when called from a button
        self.stop = False
        self.rendering = False

        # One shot per selected object
        self.shots = [o.name for o in context.selected_objects]

        context.scene.render.filepath = self.path

        bpy.app.handlers.render_pre.append(self.pre)
        bpy.app.handlers.render_post.append(self.post)
        bpy.app.handlers.render_cancel.append(self.cancelled)

        # The timer gets created and the modal handler
        # is added to the window manager
        self._timer = context.window_manager.event_timer_add(0.5, window=context.window)
        context.window_manager.modal_handler_add(self)

        return {"RUNNING_MODAL"}

    def modal(self, context, event):
        if event.type == 'TIMER': # This event is signaled every half a second
                                  # and will start the render if available

            # If cancelled or no more shots to render, finish.
            if True in (not self.shots, self.stop is True):

                # We remove the handlers and the modal timer to clean everything
                bpy.app.handlers.render_pre.remove(self.pre)
                bpy.app.handlers.render_post.remove(self.post)
                bpy.app.handlers.render_cancel.remove(self.cancelled)
                context.window_manager.event_timer_remove(self._timer)

                return {"FINISHED"} # I didn't separate the cancel and finish
                                    # events, because in my case I don't need to,
                                    # but you can create them as you need

            elif self.rendering is False: # Nothing is currently rendering.
                                          # Proceed to render.
                sc = context.scene

                # I'm using cameras named just as the output files,
                # but adapt to your needs
                #sc.camera = bpy.data.objects[self.shots[0]]

                sc.render.filepath = self.path + self.shots[0]
                bpy.ops.render.render("INVOKE_DEFAULT", write_still=True)

        return {"PASS_THROUGH"}
        # This is very important! If we used "RUNNING_MODAL", this new modal function
        # would prevent the use of the X button to cancel rendering, because this
        # button is managed by the modal function of the render operator,
        # not this new operator!

def register():
    bpy.utils.register_class(Multi_Render)

def unregister():
    bpy.utils.unregister_class(Multi_Render)

if __name__ == "__main__":
    register()

    #bpy.ops.render.multi('INVOKE_DEFAULT') # Test call

Note: You don't necessarily have to use a for-loop, the post method removes each item from the list in case the rendering is finished. Also I suggest split up the process into 2 operators, one for rendering only and another one to manage the whole process.

In case you don't want the render window to show up for whatever reason, you can either set the display_mode to 'NONE' temporary:
    elif self.rendering is False: # Nothing is currently rendering.
                                  # Proceed to render.
        sc = context.scene
        sc.render.display_mode = 'NONE'

        sc.render.filepath = self.path + self.shots[0]
        bpy.ops.render.render("INVOKE_DEFAULT", write_still=True)

        # Reset display mode
        sc.render.display_mode = 'WINDOW'

and add a check for the ESC event to remove the timer:
def modal(self, context, event):

    if event.type in {'ESC'}:
        context.window_manager.event_timer_remove(self._timer)
        bpy.app.handlers.render_pre.remove(self.pre)
        bpy.app.handlers.render_post.remove(self.post)
        bpy.app.handlers.render_cancel.remove(self.cancelled)

        self.report({'WARNING'}, 'User interuption')
        return {'FINISHED'}
    ...

Or you can call render.render() without INVOKE_DEFAULT to execute the operator directly (without the UI), e.g. based on a given variable (notice that the progress bar does not show up):
        if render_window:
            bpy.ops.render.render("INVOKE_DEFAULT", write_still=True)
        else:
            bpy.ops.render.render(write_still=True)

Also you can add an invoke() method along with a BoolProperty() to the operator so the user can decide whether or not displaying the render window:
render_window: bpy.props.BoolProperty(
    name="Show Render Window",
    description="A bool property",
    default = False
)

def invoke(self, context, event): # Used for user interaction
    wm = context.window_manager
    return wm.invoke_props_dialog(self)

and add a condition for that within the modal method (before rendering):
    elif self.rendering is False: # Nothing is currently rendering.
                                  # Proceed to render.
        sc = context.scene

        if self.render_window == False:
            sc.render.display_mode = 'NONE'

        sc.render.filepath = self.path + self.shots[0]
        bpy.ops.render.render("INVOKE_DEFAULT", write_still=True)

        # Reset display mode
        sc.render.display_mode = 'WINDOW'

However, it is indeed tricky to make it work properly...

I thank you for your time, how can I stop this with the esc button? because i not need the preview render windows

Thank you very much for the great effort, however I have taken inspiration from your phrase "It is not necessary to use a for loop" and in fact that was the trick, when you used the list of objects with the append function, I solved the blocking of the loop for. But I see that it's not easy to get out of the modal, sometimes it comes out and sometimes it's not a known blender problem?

Not sure what you are talking about: You've got a list with all objects in selection right? Why appending something to that? It's already there and good to go. Anyway, to solve your second issue (1 out of 100 issues here) you can try to decrease the timer value, should make it easier getting out of my modal (not the loop) @Pastrokkio

The object selection context was just to simplify the question, in reality I have several variables that decide which items to put on the list, I think this doesn't change things much. The fact remains that getting out of the modal is always a bet ... I have to understand the context as I deal with different scenes.

Working here without any issues. You should have things sorted before rendering, maybe that's your issue... All I could imagine from reading your post plus some extra bits is already part of my answer so I don't know how to improve it even further  @Pastrokkio

Well, thank you, I confirm that I will proceed with the improvement of my script, if there will be further questions I will post new ones, I thank you very much and not "Dilago further" so this question has been answered.

Great example, thanks. I got it to work properly in Blender 2.8. ESC button event works as should be. But, now I'm struggling with: how I can stop render from another Operators button/function? So I want to stop rendering process by pressing custom button in Blender UI.

I think one simple way is adding a global boolean e.g. to the scene and ask for its current state in the same line as checking for the event like if event.type in {'ESC'} and C.scene.your_bool_prop: @SakariNiittymaa

@brockmann Yes! Thanks. Im still learning this. I solved this problem by creating stop_rendering: BoolProperty() and changing that property with other buttons operator scene.render_settings.stop_rendering = True, then just check its state same time with ESC event scene.render_settings.stop_rendering is True

Note that in newer versions of Blender you will need to add depsgraph as an argument to the handlers, eg.
def post(self, dummy, depsgraph):


text:
How to enable denoising for my final render?
I have been fiddling around with the LuxCoreRender rendering settings, but both denoisers do not seem to be having effect on my frames that I have rendered.
I have re-installed LuxCoreRender multiple times, and used the default settings + my own custom settings to try to get it to work, but for some reason it will not. The viewport denoiser is working perfectly, however. Also, if I set the denoiser settings to be heavier on denoising, Blender will quit, running out of memory.
Q: Is there some way I can use the same settings for the viewport rendered view, and somehow apply them to the rendered frame settings?

When viewing the render make sure the dropdown on the top right of the Image Viewer is set to the correct pass. You can also render to exr multilayer to get both passes (denoised and beauty) in one file for comp.

Nope, was a comment to this question (before you changed title and the whole content https://blender.stackexchange.com/posts/159746/revisions) I'd suggest ask a new one.

Does it save the rendering as the image editor view type then? Because I rendered a luxcore animation, and it was not denoised.

Your settings worked by the way, thank you.

Make sure the dropdown on the top right of the Image Viewer is set to the correct pass (DENOISED):

I'd suggest render to OpenEXR Multilayer to get both passes (beauty and denoised) in one file for comp:

Alternatively you can add a Render Layer node in the Compositor to get the DENOISED socket and connect both passes to a File Output node or even blend between both passes before saving:

Note: The Composite Node has only one input socket so this approach does not store any raw data.


text:
Texture Paint doesn't work
I'm new to Blender and I was painting the texture of my model but I accidentally clicked on F mask brush and now I can't paint anymore. I do not know how to remove this I tried to restart Blender but it doesn't work.

Also when I start a new file it said that "Missing Data" something about texture slots.

edit: I have this brush selected.

edit2: the first three are of the brush I want to paint, the other three are of the F Mask brush

Your blend file might be helpful to make sure, but my theory is, that by removing the fake user (when you clicked the F-Button) the texture file got flushed. Try clicking on the dropdown that says "Add new Paint Slot". That should give you a fresh one with which you can continue to work.

When I tried this on my end just now, after unchecking the F-Button, the Stencil for the brush had been removed. So I simply re-assigned it from the Slots Tab in the Tool Palette (Press T to toggle it on/off)

yes doesn’t look easy to come back to the basic texture brush once you’ve selected the mask brush, but in the Tools tab, if you select a Stencil Image under the Missing Data message, then choose back the F TexDraw, then in the Slots tab, in the dropdwon menu, switch from Painting Mode > Image to Painting, choose a Canvas Image, and uncheck the Mask option, it works back. Don’t ask me what I’ve done though, if someone could explain all this it would be great  :)) Also, when you create an image in the UV/Image Editor, don't forget to save it (Pack as PNG if you want to save it within the file)

In that first image, you do not show what tool you are using - cannot see the error here, other than you need to be sure you are using the correct paint tool.
Second image, you have to assign a new image texture to get a slot before you can paint - simply add one and you can begin painting so long as your canvas object has UVs.

I add a photo of the brush i have selected, but it dosen't work

Get me a closer look at the whole tab with the brush texture and brush mask settings as well

yes, took the picture. Just in any case, I leave the link of the file
[link] (https://drive.google.com/file/d/1_rgF4xvkoh-wq5X0N926i1fwQBj6HMuO/view?usp=sharing)

Turn off the Mask in the Slots tab - with the texture used there, it is negating any use of the brush.

thank you! it works!!


text:
I'm having trouble doing basic transforms in 2.82
Transforming objects in Blender causes the origin to move and an "outline" but that's the only thing it seems to move until I switch to edit mode and everything is together.
Not entirely sure what happened, but I just cleared all preferences and uninstalled and reinstalled blender and it still does it.

Video Here
This issue does not persist in blender 2.79 only in 2.80, 2.82, 2.83b
EDIT: As it turns out my graphics driver needed to be fudges as the one that is for the card has this issue. The driver for a card 2-3 models newer works just fine AFAICT.

HI, welcome. It should not, for sure. It could be a glitch with your pc video card drivers, try to update them to the latest stable versions. Also you could try to download a blender .zip version, extract it in a folder and run blender directly from that folder. Sometimes it is different, since this zip version is not "installed", and sometimes the "installer" may introduce issues of its own due to several reasons. It could work better.

I just tried that and also reinstalling my graphics drivers and neither of those things changed anything for the portable version or the install. It doesn't glitch or anything, it almost seems like something's just set wrong or selection is just set wrong but I'm too new to the new interface to tell.


text:
In Blender 2.8, 3D Viewport shading render mode is missing. How do I get it back?
I've gotten to a state where my render option in the 3D Viewport is missing. I can render just fine using EEVEE. The screenshot is missing the camera and light, but I've added those and it makes no difference.
I've been able to use the render mode by creating a new file, and appending the old blend into that new file, but I'd really like to know how to fix it when it happens. Does anyone know what might cause this, and how to correct it?

For other users this one helped: Under Preferences > Add-ons, search for Cycles and make sure that the Cycles Render Engine entry is checked.

Same thing happen to me. Try switching to LookDev and under the Lighting (drop down menu next to the Viewport Shading Button), tick Scene Lights and Scene World.

I encountered the same issue and found a solution. You need to change the render engine to Eevee or Cycles, instead of Workbench.

The same thing happened to me some time ago. My guess is that Blender may lose access to the GPU and thus can't render properly in the viewport. As evidence of this theory, I saw no GPUs listed in Preferences > System > Cycles Render Devices.
However, for my case, restarting Blender was sufficient. Perhaps it depends on the severity of the GPU issue.


text:
Setting up an isometric view
I want to use Blender as a sort of reference for making isometric pixel art. My game tiles are 64 x 32:

I'd like to create an object in blender using this same view. I know I can move the camera manually with the mouse, but is there a way to position it so that it matches the view of the game world above? That is, so that each tile in the grid is twice as "wide" as it is "high"?
I will be using this view for everything I make, so it would be good if there is a way to quickly set it up like this instead of having to do it by eye.

Set your Camera to Orthographic then edit the Camera Rotation to be 45,0,45 (X,Y,Z)

related https://www.blendernation.com/?s=isometric

Thanks, I got the orthographic part but setting the camera rotation doesn't do anything for me. I clicked on the camera in scene tree thingy and pressed N to open to the Transform editor, but entering those values doesn't affect the camera's rotation. The first result (video) on the page you linked just installs some add-ons, which is fine, but surely there's a way to do this without add-ons?

I opened up a new Blender, went to Camera view, selected the Camera, opened the Transform editor and entered those values and it worked as expected. If you do all that and press 'r' to rotate the camera do you see the values change and does the camera angle change?

I tried that and it almost looks right, but when I go back out of Camera View (I assume that's what's shown in the screenshot) it looks like the tiles are slightly too "tall": https://i.imgur.com/dlXQyiM.jpg

Related https://blender.stackexchange.com/questions/65425/how-do-i-achieve-the-traditional-3-4-perspective-of-jrpgs-using-the-camera https://blender.stackexchange.com/questions/64914/setting-camera-to-position-where-it-can-render-a-seamless-repetable-orthographic and the wiki for some theory https://en.wikipedia.org/wiki/Isometric_projection

I appreciate the links, but they're not helping in this case. I followed @rob's advice, but when I leave Camera View (assuming that is the mode where a section is greyed out and it uses perspective - my earlier comment probably incorrectly referred to it as the one shown in the screenshot, but I can't edit it) and go back to orthographic, it's not correct: https://i.imgur.com/dlXQyiM.jpg

I think I got it. I was confusing the orthographic view with the actual orthographic property in the Camera property editor: https://blender.stackexchange.com/a/42512/71058. When I set it to orthographic that way, the camera is orthographic even in Camera view, which is where I was going wrong. If I press R and then press X twice to get to the correct axis, I can then rotate the camera. Now it's just a matter of finding the correct angle... which I think is 60 degrees.

Is there a way to force the "User Ortho" to be the same as "Camera Ortho"? Camera Ortho has the correct view, but it has that annoying greyed out background. I know I'm missing something fundamental here... maybe there is a way to increase the size of the rectangular viewport in Camera View instead?

I can use Orthographic Scale to zoom out and show more of the scene as that answer describes, but it still leaves the greyed out background with the orange marquee. Good enough though. :) @rob, do you want to answer this or shall I?

Be my guest and you can change the "greyed out" with passeportout in the camera settings.

You can simply use the CreateISOCam addon: https://www.reinerstilesets.de/blender/createisocam.py

Should this question be tagged with pixel-art tag?

I can add it, sure.

Thanks to @rob for nudging me in the right direction, I found out that this answer contains much of what I needed to know:
How do I make Front Ortho the Active Camera?

Click on the Camera in the scene tree thingy, then under Lens (Screenshot of Lens settings in 2.8), select Orthographic. While I was there I played around with the Orthographic Scale too, which zooms in and out.
Then I set the X rotation of the camera to 60 degrees, which seems to result in the tile widths being twice as large as the height (feel free to correct me on that number - edit: Rodrigo corrected me; it is actually (54.736, 0, 45)):

The end result:

@rob also pointed out that the greyed out area outside of the camera viewport is called "passepartout". I disabled it so I can see stuff outside of it properly:

In order to get an exact isometric perspective you shoud actually set as folllows:

Here's a comparison between (60,0,45) and (54.736,0,45) rotation:

Thanks to blender3darchitect.com: How to create a true isometric camera for architecture?

Thank you Rodrigo! I've updated my answer with a link to your correction.

While these settings produce a "correct" isometric projection, the OP was asking about fitting the tiles in 64x32. For that, 60 degrees is more convenient, even if it's less accurate.
If you analyze some of the classic isometric video games (e.g. Diablo 1, Fallout 1) you will see that they use the 60 degrees projection to achieve tiles that are 2x1 too (presumably to make the most out of the usual power-of-two texture requirements of the time).


text:
Extrude edge along normal by a specified distance
I'm trying to create a roof on an existing building mesh. I thought I would do this by extruding this edge:

So I extruded it down the Z axis:

But I need it to go "inwards" a bit on the Y axis, like the edge of a roof does; like this:

So I tried changing the orientation of the extrude operation from Global to Normal:

But for some reason it moves the edge on the X axis:

I've verified that the normals are correct for the edge by turning on Display Split Normals in the Viewport Overlays menu. Here's a screenshot of that, from the Y/Z view:

How can I get it to extrude along the normal of the existing edge (so I guess along the Z and Y axis), without any movement on the X axis?


text:
Moving vertex to the X/Y intersection of two others
I am trying to find the fastest and easiest way to move the selected vertex in the screenshot below to the exact X/Y intersection of the two vertices closest to it.

I drew the blue and green lines in to indicate what I'm trying to do.

The only way I know of is to:

Select the top vertex, copy its X position and paste it into the X position for the target vertex.
Repeat above with the bottom vertex, except with Y position.

This works, but it's slow (even with Blender's great feature where you can copy and paste without the text fields having focus).
Is there a better way? I tried to mess around with snapping but couldn't make it work.

Why? What's the context? What are you trying to do? Is this only for a plane aligned to the global axes?

https://blender.meta.stackexchange.com/questions/2387/can-a-punishment-be-implemented-for-using-the-word-vertice-in-a-q-a?r=SearchResults&s=1|22.0547  (Esp for @lemon)

@MartynasŽiemys I'm recreating a building based on a satellite image by starting off with the roof. I'm using a plane and I'm at a section of the building where the walls go in and meet each other, as pictured in the second image. batFINGER, hah, thanks. I'll fix that. :)

Snapping does work, but it has to be in 2 constrained moves, I think.

Snap set to 'Vertex' and 'Active'
G X, and then G Y to the relevant vertices, with the snap active.

The first move could be G G, a slide, no snap, as far as it will go.

Thanks for the answer. In this case I can't see a difference in snapping behaviour between the default "Closest" target and "Active"; both work for me. I didn't know about the G G trick... that could be useful.

@Mitch In this case, there probably is no difference - 'Closest' takes you to the closest target before the move, not continuously during it. I just have my snap set to Vertex (which is the static target) and Active (the moving source element, edge, vertex, or face) the vast majority of the time..I find it gives me the most specific control.

Use the snapping magnet.
Assuming you're using Blender 2.8+ it's at the top middle of your screen:

Then click the little downwards facing arrows next to the magnet icon, select Edge / Vertex from the menu:

Now click the magnet icon so it becomes blue (Shift + Tab to toggle quickly):

Now move the smaller cube and with your mouse hover over the edge / vertex(depending on what snapping mode you selected) of the bigger cube you want it to intersect with and it should snap. If only one edge snaps simply move the cube along the axis of the other edge until it also snaps.

Thanks for the answer, but I don't understand what you mean by smaller cube and bigger cube.

These cubes. But that's really not the point of the answer, basically use the snapping tool, if you don't understand what it is or how to use it from my and Robin's explanations then look it up.

It's all one mesh, I just drew those green and blue lines in to indicate what I was trying to do. I will update the question to make that more clear.

Snapping to vertex should still work there, snap it to the z axis of the lower vert(the one on the lower right) then snap it to the x axis of the higher vert.


text:
Adding a skirt / border to object with sharp corners leaves gaps
I have an SVG that i made into an outline of an object (shape of Texas), but when i go to add a skirt / border to it the shrink/fatten leaves gaps in the border. Is there a way to expand a face evenly to where I get a smooth border.
Here are the steps I have taken

Import SVG and create mesh object
extruded the object so it has height
selected the top faces so i can extrude again to have a smaller face
for the border
selected the smaller face from the step above and selected Shirnk/Fatten

Expected results:
I would like a smooth lip on the outside of the very top portion of an outline of an object
As you can see on sharp outside corners there are gaps and on sharp inside corners it expands into the interior of the shape.

The SVG is flat though. I need to give it height and then add a lip / skirt  to only the top of it.

Thank you for the new knowledge about the 2d curve. However, beveling it just makes it fat and not the cross section I'm looking for. The cross section at any given vertical part should be like an upside down L not like a <> shape

do you have pictures of the kind of shape you want? Won't you have what you want with array + curve modifiers?

I'm a noob so I don't know all the options or the terminology of whats available. I'm learning fast but I'm still not up to speed with all the lingo or methods available. Imagine a cookie cutter of texas but with a lip around it so it adds support to the shape and allows the person to hold it better. I'll find a picture of an example.


text:
copy cursor rotation to geometry in edit mode with python
using bmesh I want to use cursor matrix to rotate some selected geometry (edges or faces).
using just cursor rotation, and using rotation and location to rotate around cursor

I found the answer in API, right after asking the question, using bmesh.ops.rotate(bm, cent, matrix, verts, space, use_shapekey).
To rotate around it is important to use "space"

import bpy
import bmesh
from mathutils import Vector

class MESH_OT_curs_rot_2_geo(bpy.types.Operator):
    """geo rotation from cursor rotation"""
    bl_idname = "mesh.curs_rot_2_geo"
    bl_label = "geometry rotation from cursor rotation"
    bl_options = {'REGISTER', 'UNDO'}

    around_curs: bpy.props.BoolProperty()
    use_shapekey: bpy.props.BoolProperty()

    @classmethod
    def poll(cls, context):
        return context.mode == 'EDIT_MESH'

    def execute(self, context):
        cao = context.active_object
        mw = cao.matrix_world
        me = cao.data
        curs = context.scene.cursor
        mat = curs.matrix @ mw.inverted() #if cao has rotation...
        #R = mat.to_3x3().to_4x4() #cursor rotation value
        #previous line not ok, if scale not applied. prefer this
        R = mat.to_quaternion().to_matrix().to_4x4() #cursor rotation
        bm = bmesh.from_edit_mesh(me)
        sel = [v for v in bm.verts if v.select]
        sk = self.use_shapekey
        if self.around_curs:
            loc = curs.location
            bmesh.ops.rotate(bm, cent=loc, matrix=R, space=mw, verts=sel, use_shapekey=sk) #rotation around cursor
        else:
            loc = sum((v.co for v in sel), Vector())/(len(sel))
            bmesh.ops.rotate(bm, cent=loc, matrix=R, verts=sel, use_shapekey=sk) #just rotation
        bm.normal_update()
        bmesh.update_edit_mesh(me)
        return {'FINISHED'}

def register():
    bpy.utils.register_class(MESH_OT_curs_rot_2_geo)

def unregister():
    bpy.utils.unregister_class(MESH_OT_curs_rot_2_geo)

if __name__ == "__main__":
    register()

 [1]: https://i.imgur.com/AFJ4VY1.gif


text:
How to handle UV seams in generated textures?
I want to create textures for an existing model.
I use material nodes in blender to do so, but I cannot get the UV seams to line up correctly.
Examples:

It's either a visible shift at the seam or it just looks warped from one side.
Is there a way to use UV mapping and line up the textures correctly?
I cannot change the UVs, because the textures wont fit to the in game model (at least I think it is that way)
Things I tried:
Seperating XYZ so I can replace the distorted part with a generative Texture rotated by 90° (didn't work)

Generally, when using generated textures, you would set them up, then "bake" them into an image texture which can be used as a material for a game model. This is why generated textures are usually seen connected to "Generated" (as opposed to UV) texture coordinates. Moreover, even if you use UV coordinates, it is unlikely blender's shader system is compatible with that of whatever game engine you plan to use, so you would have to bake anyway.

For generated textures, using unseamed coordinates (like object, generated, or geometry/position) is a better idea.  As mentioned above, you can then bake to UV textures as desired.

@ChristopherBennett I do know how to bake the textures, my Issue is, that I am not able to get the seam to line up correctly

@Nathan my problem with generated coordinates is, that it gets warped on the side (see the second picture)

I'm not sure there's any magic solution for your texture, maybe make it as good as possible, bake the diffuse, use the result in an Image Texture, try to fix the seam playing with the UVs and/or the image

If it is possible to bake textures from one UV to another that would solve my problem :/


text:
How do I simply close a few widget windows?

I am losing my mind trying to figure out how simply close widget that was so easy to open to begin with.
[x] close button doesn’t seem to exist in this program so what’s a guy gotta do to close a window in blender 2.8? I also can’t close the widget with “transform | View | 3d cursor | annotations” window either.  I’m extremely frustrated and I’d really appreciate the help

Hit the 'T' button on your keyboard. Please watch any of the numerous Blender 2.80 UI videos on youtube.

Thank you very much, and honest to god I’ve watched three tuts and not one has mentioned it.Albeit I’m not the best listener either. thanks again

The Blender UI has always been a little confusing at first and you have to get used to it. But after a while everything makes a lot of sense, because it's faster to work with.

You can also slide the right border of the window, to the left (=resize the window to 0).

Press T on your keyboard to open/close the Toolbar on the left, and N to open/close the Sidebar on the right.
https://docs.blender.org/manual/en/latest/interface/keymap/blender_default.html#common-editor-keys


text:
Does Blender Have an equivalent to Xview in 3Ds Max?
In Max, it was relatively easy to detect mesh errors. You could simply go to the viewport settings and click on the Xview button and see several options that would highlight all kinds of errors, such as overlapping vertices and face orientation, etc.
Is there an equivalent to that in Blender? I haven't been able to find one, probably due to some terminology being a slightly different from 3Ds Max to Blender.
I'm not planning on 3D Printing, this is for a game-ready asset.

There's an addon called Mesh: 3D-Print Toolbox that gathers several tools of Blender in order to check your mesh. Enable the addon, select the object, open the N panel > 3D-Print then click on the Check All button. Under Result you'll see the errors, click on the one you want in order to hightlight it in your mesh. You can also click on the Make Manifold button to fix some issues:

There is a paid addon called Mech Check GPU Edition that can display in viewport  n-gons, E and N poles, isolated vertices, non-manifold edges, and so on. Except it doesn't have UV-related functionality like in 3Ds Max.


text:
How can I make it so that material keyframes appear in the graph editor?
I have been trying for a while how to get this material animation working but I can't seem to figure out how to get my keyframes to show up in the graph editor. They appear in the Dope Sheet editor but they don't appear in the graph editor.
I posted some screenshots to show what I mean.
AS you can see, the plane with the material applied is selected as well. But still, no keyframes.


text:
How do I configure Blender 2D view?
I had a previous version of Blender in which I was able to configure it to Alt + Right Click and it would activate 2D View and which ever direction I would drag to, it would snap the camera to that side of the model (X axis, Y, -X, Z, and so forth...).
However I downloaded the latest version of blender and uninstalled the previous version, forgetting to export my key configurations.
I've been looking everywhere to reconfigure it back the way it was but I can't remember how I did it and I am having a lot of trouble. Any help would be appreciated

What do you mean by "2D view"? If you mean front, side or top view of your 3D object just use the numpad keys or click one of the gizmo letters in the top-right corner of the 3D view. You can also ALT-MMB drag to change the view.

By 2D View, I meant exactly what you described. Is there a named for that? I'm sorry, I am a 3ds Max user and I'm not too sure of the terminology in the Blender community.
The problem is that I already mapped ALT-MMB drag to be the camera rotate and MMB to pan camera, as it is the default key-binds on 3ds Max, which I am most familiar with.
I know I was able at some point to configure it so that I could used ALT-RMB drag to activate this front, side, top viewmode. I just really don't remember where to find this category in the key-bind menu.

It's just the navigation hotkeys as far as I know. See https://docs.blender.org/manual/en/latest/editors/3dview/navigate/navigation.html#orbit

I figured it out. Go to Keymap > 3D View > 3d View (Global) > View Axis.
There are many drop-downs that say View Axis but look for the ones that are bound to Alt drag-Middle Mouse. There should be four of those and they all should be right next to each other. Click on them and they should have a little tab that says Direction and a dropdown list North, South, etc. That's how you know you have the right ones.

Ah ok. Your camera rotate hotkey addition must have reset those because they're normally the default settings.


text:
Is it possible capture the image result of a compositing and add directly, as a material, to a plane?
I made a simple compositing that I'd like to use directly as a material of a plane. I created a new material and in shading editor I put a texture coordinate node connected to a viewer node. In browse image to be linked of viewer node, I've chose Viewer Node. I connected the viewer node to a Princlipled BSDF in Base Color socket. In material preview I see the result of compositing, but the plane is showing an solid pink. What is it wrong? I'm using Blender 3.3.2.

Hello and welcome. It is recommended that you add some screenshots for better visualization and understanding of the issue at hand. Can you share your blend file https://blend-exchange.com.

Not directly, but if -1 frame is OK for you https://blender.stackexchange.com/a/220499/2214 or here https://blender.stackexchange.com/a/224329/2214 ... btw How could you connect Viewer node to BSDF since Viewer node doesn't have output socket? +1 HarryMcKenzie

I made a mistake with the node label. Sorry, rectifying,  In fact I used a Texture Coordinate node with a Generated socket connected to the Vector of Image Texture node and, in browse image to be linked of this node I've chose Viewer Node. This node was connected to a Principled BSDF in Base Color socket.


text:
Question regarding Collection hide
I want to ask the community how to hide collection or grouped objects.
My attempt in creating this function was to close the eye icon on the layer panel. I didnt have any luck with this method. The eye is closed for the collection and group.. yet the objects are still visible in the viewport.
The only thing that seems to work is closing the eye for each individual object.
Im wonder if the community might know of a better way as this method takes a lot of time.

Can you add a screenshot showing the complete Blender window via the Window > Save Screenshot menu. https://meta.stackexchange.com/questions/75491/how-to-upload-an-image-to-a-post

Talking about collections, why don't you simply untick the checkbox Exclude from View Layer?


text:
Using Pose Library for NLA (non-linear animations) causing distortions
I've saved a few hand poses using Blender's Asset Library and hoping to use them in some animations. But when I use them as keyframes and Push it down to an NLA, the fingers become distorted and I can't figure out what is causing the problems.
I've included a video of the process here. Here's also what I did along with screenshots:

From the Pose Library when I click "Apply Pose", I can see that it applies normally on the model.

I then "Select Pose Bones" to only select the ones I want to affect and add a Keyframe > Rotation. You can see it's added in the Action Editor as well.

I push down the track into a new NLA and rename it as hand_fist.

When I play the action, the fingers come out messed up.

I've tried re-doing this a few times with no luck. Hoping someone can help me out!!! Thanks so much!

So as a different experiment what happens when you save all the bones at once?  Do you have any intuition that you may be combining old data and new data in ways that you did not intend?

If you have only a small investment of time previously,  I would also consider deleting all actions and trying a new fresh experiment.  Technically, I cannot see that all fingers are well placed in the first image.  Fist is a difficult position to see.  Needs a few views to see all.


text:
Why my exported UV map is different in size?
I did unwrap my mesh which consists of several parts. I did an export using EPS file format, then I applied several images to all the faces in Adobe Illustrator.
When I try to import the texture back into Blender the map is slightly off or just out of scale:

Q: Why the export is different in size? What am I doing wrong?

Hello :). Your canvas in Illustrator isn't perfectly square. That's why the UV doesn't perfectly align. You exported the UV from Blender as curves, right?

Hi Jachym yes i exported as an eps and opened in illustrator did not move and exportes as a jpeg?

Hi Jachym, i exported UV as an eps. Opened it in illustrator. Did not alter in any way exported as jpeg and applied. So not really sure it could be that?

Hey, it must be a bug  :). If you export it as SVG, it works just fine. But EPS is buggy.

Ok let me try that :)

Sir you are 100% correct

If you think that's a bug consider to file a bug report @JachymMichal

@brockmann Not sure yet, might be because EPS doesn't support canvas :)

Don't use EPS to transfer UV maps - it only exports the occupied area.
Use SVG instead, it exports the whole UV canvas.

Thank you yes this has solved the problem. Phew every step along the way is a new school day but its good fun.

I feel the same way sometimes :). Good luck with your project, feel free to ask more questions if you get stuck anywhere.

@XxSTxRMxNxX consider to mark answer as accepted, it keeps site organised https://blender.stackexchange.com/tour Thank you

Not sure how to mark as accepted :(

Ha big green arrow. Done


text:
How to determine whether a node_tree is a material or a node group?
I'd like to know whether a given node_tree is either a material or node group as dynamically as possible. The following function works somehow but I don't want to specify the any additional argument for a fundamental reason:
def my_function(node_tree):
    #Incomplete example:
    #if node_tree is from material:
        print("It is a node_tree of a material")
    #elif node_tree is node_groups:
        print("It is a node_tree of a node_groups")

# Use case 1:
mat = C.object.active_material
my_function(mat.node_tree) # Returns a node_tree

# Use case 2:
group = D.node_groups["My Groups"] # Returns a node_tree
my_function(groups)

node_tree.id_data returns a node_tree in all my tests so I guess you can use something like isinstance() in conjunction with id_data? Is there any way to test the actual type like isinstance(node_tree, bpy.types.???) ?

How it represents itself.
In as much as it aint pretty have had to rely on this before, may be for same can't remember.  Noticed in console that the representation  "knows". (echoing in the console uses repr(ob) printing uses str(ob))
>>> D.materials['Material'].node_tree
bpy.data.materials['Material'].node_tree

>>> D.node_groups['Foo']
bpy.data.node_groups['Foo']

as a string is also of little use
>>> print(D.materials['Material'].node_tree)
<bpy_struct, ShaderNodeTree("Shader Nodetree") at 0x7f6bd0a86e08>

whereas looking at types et al kept coming up as same.  Hence can use this in your method
>>> def from_material(nodetree):
...     return repr(nodetree).startswith("bpy.data.materials")
...
>>> from_material(D.materials['Material'].node_tree)
True

>>> from_material(D.node_groups['Foo'])
False

alternatively endswith("node_tree") is possibly a quicker option.
Extra,

Nice solution. But so how can I get that material into a variable in
this function?

Once we know it's a material, can slice off ".node_tree" and evaluate it.
>>> repr(D.materials['Material'].node_tree)[:-10]
"bpy.data.materials['Material']"

>>> eval(repr(D.materials['Material'].node_tree)[:-10])
bpy.data.materials['Material']

Similarly could slice "bpy.data.materials['" from the start and "'].node_tree" from the end to just keep the name.
>>> matname = repr(D.materials['Material'].node_tree)[20:-12]
>>> matname
'Material'

>>> D.materials.get(matname)
bpy.data.materials['Material']

Nice solution. But so how can I get that material into a variable in this function?

Speaking of your very useful "Extra", I wonder why there isn't a simple API similar to id_data that would make things a lot easier. But maybe my approach is wrong and that's why there is no API by the way

This is one where the assumption that mat.node_tree.id_data is mat  isn't so. Possibly since a nodetree is an ID object if in D.node_groups


text:
How can I select all objects with the box select tool in blender 2.8?
I entered Edit Mode, and try to use selection box to drag and select multiple objects, but the selection box can only select some surfaces that facing me, the inside surfaces and the surfaces at the back can not be selected.
What am I doing wrong?

Just to illustrate the function of X-Ray Mode.

Available selection methods:

The answer of @ObscureGuy was correct, but just to make sure: You can only select mesh parts in Edit Mode, not objects. You can select every part of an object's mesh/data, but technically you cannot select objects.

press w to change the selector method

Alt+Z to enable X-Ray mode. 'Box/Circle/Lasso Select' then picks up everything.

what is Box/Circle/Lasso?

Refer to Frederik Steinmetz's response :)