The value of TextBox cannot be obtained and an error occurs I wrote the following code.
This is just the code to get the value from the textbox and print it.
But this doesn't work.
When I run this code, blender crashes.
What's wrong with this code?
import bpy

bl_info = {
    "name": "test addon",
    "author": "taichi suzuki",
    "version": (1, 0),
    "blender": (2, 80, 0),
    "location": "3DView",
    "description": "test addon",
    "warning": "",
    "support": "COMMUNITY",
    "wiki_url": "",
    "tracker_url": "",
    "category": "test"
}

class QueryProps_query(bpy.types.PropertyGroup):
    query: bpy.props.StringProperty(default="aaa")

class TestAddon_PT_Panel(bpy.types.Panel):
    blidname = "TestAddon_PT_Panel"
    bl_label = "TestAddon Panel"
    bl_category = "TestAddon"
    bl_space_type = "VIEW_3D"
    bl_region_type = "UI"

    def draw(self,context):
        props_query = bpy.context.scene.QueryProps_query
        layout = self.layout

        row = layout.row()
        row.label(text="test textbox")
        row.prop(props_query, "query", text="")

        vis_box = layout.box()

        vis_box.operator(TestAddon_OT_Operator.bl_idname,text ='modal start')

class TestAddon_OT_Operator(bpy.types.Operator):
    bl_idname = "wm.modal_testaddon_operator"
    bl_label = "Modal testaddon Operator"
    _timer = None

    def __init__(self):
        self.test = None

    def modal(self, context, event):
        if event.type in {'ESC'}:
            self.cancel(context)
            return{'CANCELLED'}

        if event.type=='TIMER':
            print(self.query)

        return{'PASS_THROUGH'}

    def execute(self, context):
        wm = context.window_manager

        if TestAddon_OT_Operator._timer is None:
            TestAddon_OT_Operator._timer = wm.event_timer_add(1.00/60.00, window=context.window)
            wm.modal_handler_add(self)
            print(self.query)

        return {'RUNNING_MODAL'}

    def cancel(self, context):
        wm = context.window_manager
        wm.event_timer_remove(self._timer)
        TestAddon_OT_Operator._timer = None

classes = (QueryProps_query,TestAddon_PT_Panel,TestAddon_OT_Operator)

def register():
    from bpy.utils import register_class
    for cls in classes:
        register_class(cls)

    bpy.types.Scene.QueryProps_query = bpy.props.PointerProperty(type=QueryProps_query)

def unregister():
    from bpy.utils import unregister_class
    for cls in classes:
        unregister_class(cls)

    del(bpy.types.Scene.QueryProps_query)

if __name__ == "__main__":
    register()

You are trying to access a member named query of your operator on lines 53 et 63, but it doesn't exist. Instead you want to access the property group you created in your register method : context.scene.QueryProps_query.query.
Side note : Don't use bpy.context in an operator, because it is not always the right context. (L.28) Use the provided context parameter instead.
import bpy

bl_info = {
    "name": "test addon",
    "author": "taichi suzuki",
    "version": (1, 0),
    "blender": (2, 80, 0),
    "location": "3DView",
    "description": "test addon",
    "warning": "",
    "support": "COMMUNITY",
    "wiki_url": "",
    "tracker_url": "",
    "category": "test"
}

class QueryProps_query(bpy.types.PropertyGroup):
    query: bpy.props.StringProperty(default="aaa")

class TestAddon_PT_Panel(bpy.types.Panel):
    blidname = "TestAddon_PT_Panel"
    bl_label = "TestAddon Panel"
    bl_category = "TestAddon"
    bl_space_type = "VIEW_3D"
    bl_region_type = "UI"

    def draw(self, context):
        props_query = context.scene.QueryProps_query
        layout = self.layout

        row = layout.row()
        row.label(text="test textbox")
        row.prop(props_query, "query", text="")

        vis_box = layout.box()

        vis_box.operator(TestAddon_OT_Operator.bl_idname,text ='modal start')

class TestAddon_OT_Operator(bpy.types.Operator):
    bl_idname = "wm.modal_testaddon_operator"
    bl_label = "Modal testaddon Operator"
    _timer = None

    def __init__(self):
        self.test = None

    def modal(self, context, event):
        if event.type in {'ESC'}:
            self.cancel(context)
            return{'CANCELLED'}

        if event.type=='TIMER':
            print(context.scene.QueryProps_query.query)

        return{'PASS_THROUGH'}

    def execute(self, context):
        wm = context.window_manager

        if TestAddon_OT_Operator._timer is None:
            TestAddon_OT_Operator._timer = wm.event_timer_add(1.00/60.00, window=context.window)
            wm.modal_handler_add(self)
            print(context.scene.QueryProps_query.query)

        return {'RUNNING_MODAL'}

    def cancel(self, context):
        wm = context.window_manager
        wm.event_timer_remove(self._timer)
        TestAddon_OT_Operator._timer = None

classes = (QueryProps_query,TestAddon_PT_Panel,TestAddon_OT_Operator)

def register():
    from bpy.utils import register_class
    for cls in classes:
        register_class(cls)

    bpy.types.Scene.QueryProps_query = bpy.props.PointerProperty(type=QueryProps_query)

def unregister():
    from bpy.utils import unregister_class
    for cls in classes:
        unregister_class(cls)

    del(bpy.types.Scene.QueryProps_query)

if __name__ == "__main__":
    register()


How to make a tetrahedron solid and grid? I'm working on a build-up animation. See images. All the balls and cylinders have to follow a global equilateral triangle grid. But I don't have this grid and the result is not precise, it doesn't fit. My best solution would be to make a perfect equilateral triangle solid (4 equal faces - 3 verts each). But I can't find such a primitive in Blender, even in the extra objects add-on. Can someone help me out, how to build this solid, so I can replicate it further and make myself a 3D grid from it? Or maybe there is a clever way to make a grid like this directly, something I can snap to?

Ok. I got a "perfect" tetrahedron thanks to Grimm. But it is not perfect. I began making a grid, see 3rd image. But it is inaccurate. It doesn't fit. I need a perfect grid. Somebody knows how to achieve a perfect tetrahedron grid? Maybe there is a script somewhere that does it? All ideas welcome.

This is fundamentally impossible because (surprisingly!) the platonic tetrahedron is not space-filling.
The dihedral angle of two adjacent faces of a regular tetrahedron is arccos(1/3) ≈ 70.53. So if you put 5 regular tetrahedrons together it makes 70.53*5=352.65 which is not quite the 360 you would need to fill space.


Some sculpting brush hotkeys change the view rather than the brush Hey everyone I am new to Blender and I've been watching sculpting tutorials on hotkeys for the sculpting brushes. A few of the brush shortcuts that involve pressing shift and a number for example (SHIFT+4 which I've read should be the scrape brush) change the view of the object instead of selecting a brush. I'm Curious is this some sort of setting that needs to be changed for the hotkey to work?

It seems like you pressed Shift+Numpad 4 which is shortcut to rotate / roll the viewport camera.
Brush shortcuts are numbers on keyboard, not on Numpad. So to activate Sculpt brush from 10 to 20 you press Shift+number on the row of keys above letters on the keyboard. In case of Polish brush this will be Shift+4.

See for more brushes shortcuts Switch between sculpting brushes


How do I open JSON files using the Text Editor I've been working with Sverchok (awesome add-on), which allows you to import/export data in a few formats, including JSON. The import function in Sverchok's node editor only allows you to utilize text files that are pre-loaded in the Text Editor window, but the problem is that the Text Editor can't "see" JSON files, and none of the filter buttons seem to make this possible. Am I missing something pretty basic?

The easiest way to see files of any unexpected format (including JSON) is to disable filtering (click on the funnel!)


Blender Texture Maps to Unity Translation Blender has these options for baking texture maps:
Combination
Ambient Occlusion
Shadow
Normal
UV
Roughness
Emit
Environment
Diffuse
Glossy
Transmission
Subsurface

Unity has these options under Material for texture maps:
Albedo
Metallic
Normal
Height
Occlusion
Emission
Detail Mask

Would someone clear up the confusion for me?
(Unity = Blender)
Albedo = Diffuse
Metallic = ?????
Normal = Normal
Height = ?????
Occlusion = Ambient Occlusion (If I create these for my assets, does that mean less time baking light in Unity?)
Emission = ?????
Detail Mask = ?????

Thanks for your help with this. I'm having a hard time finding any reference. I might not be searching the correct key terms.

Well, I can help with some of these.  the Metallic shader is a mask between what you want to be metal and what you don't.  Height map is the same as a bump map, Emission acts like the Metallic, except seperating emission instead of metal.

I hope this is useful.


Hidden hotkeys in the 2.8 I can not find many hotkeys in the "Keymap", but they are searchable. I need find where they are, because I want to add more variants.

Is it bug or it is hidden somewhere?

For example "Time scub" or "Gizmo":

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


Animation Loop Add-On Problem So I've worked on a local add-on that would allow me to adjust the start frame and the end frame of the playback loop. I created an enum list with three options: default, A, and B.
Basically want I want to do is:

Adjust the start and end of the playback by selecting either default, A, or B on the add-on
A's playback would loop from 60-180 in the first time and then loop from 120-180. Same with B starting from 180-300 the first time and then from 240-300

If I select 'default' and play the animation it would work perfectly. But if I select 'default' again after I select either A or B, the first playback loop will go from 0-60, and then both start and end are at 120. Every time the animation will go from 0 to 120. Then clicking on A or B is even worse, the animation will run the desired range in the first time, then run from 0-120.

It seems like something is being overridden here. I'm not exactly sure how and why. Can anyone please help?

 def execute(self, context):
    # execute() is called by blender when running the operator.

    ## helper function used to modify the start keyframe of the second loop
    def keep(command):
        scene = bpy.context.scene
        if scene.frame_current == scene.frame_end:
            if command == 'A':
                scene.frame_start = 120
            elif command == 'B':
                scene.frame_start = 240
            else:
                raise TypeError("Invalid Input Command")

    def handlerA(scene):
        keep('A')
    def handlerB(scene):
        keep('B')

    if self.options == 'default':
        bpy.context.scene.frame_start = 0
        bpy.context.scene.frame_current = 0
        bpy.context.scene.frame_end = 60
    elif self.options == 'A':
        bpy.context.scene.frame_start = 60
        bpy.context.scene.frame_current = 60
        bpy.context.scene.frame_end = 180
        bpy.app.handlers.frame_change_pre.append(handlerA)
    elif self.options == 'B':
        bpy.context.scene.frame_start = 180
        bpy.context.scene.frame_current = 180
        bpy.context.scene.frame_end = 300
        bpy.app.handlers.frame_change_pre.append(handlerB)

    return {'FINISHED'}            # this lets blender know the operator finished successfully.

Never mind, apparently changing the start and end key frames in handlers were messy and it would only be changed once. Make the script changes the current key frames and avoid abstracting the handler methods would solve the problem.


Scaling a math function from a specific vertex I have a model developed through a math function as shown below in the figure. I would like to scale the figure as shown in the figure without changing the vertex position.

Explanation of the figure:
The model seen is according to the function implemented. Now, the two vertices on the Y-axis remain where they are originally present and the surface of the model needs to be scaled proportionally in x,y (that is if scale factor of 2 along x, then the same scale factor 2 along y from the vertex) shown in red.

My guess is that the positioning of the origin needs to be changed but not sure how?

Any hacks to do address this?

Thanks.

I'm not sure what the best way to scale that with Blender would be, but I'd look at just adjusting your equation. Here's your $y$ equation:

$$y=\begin{cases}
0.5 & \text{if } u < 0 \\
\frac{u^2}{u^2+(1-u)^2}+0.5 & \text{if } 0 \leq u \leq 1\\
1.5 & \text{if } u > 1
\end{cases}$$

Notice that the main part of the middle equation, $\frac{u^2}{u^2+(1-u)^2}$, normally has a range of $[0,1]$ on the interval $[0,1]$. You are offsetting it by $0.5$. If we scale it, and change the offset of the third piece, we can place it wherever. Use this equation instead:

$$y=\begin{cases}
0.5 & \text{if } u < 0 \\
k \cdot \frac{\left(\frac{u}{k}\right)^2}{\left(\frac{u}{k}\right)^2+\left(1-\frac{u}{k}\right)^2}+0.5 & \text{if } 0 \leq \frac{u}{k} \leq 1\\
k + 0.5 & \text{if } \frac{u}{k} > 1
\end{cases}$$

where $k$ is your scalar. You can try it online using Desmos here. (Thanks to Rich Sedman for help with scaling horizontally).

In a Python expression, it would be this (substituting in whatever value for k):

(0.5 if u<0 else (k*((u/k)**2/((u/k)**2+(1-(u/k))**2)+0.5) if (u/k)<=1 else k+0.5))*v


How to make a sharp shadow? In the picture the sun makes a diffuse shadow on the interior wall of the poolhouse. I want this to be a sharp shadow (as would be the case in real life, with a full sun). Don't know if and how I have to change the wall material and/or the lighting (or whatever).

(the material of the wall is shown on the right panel, as "concrete")

A sun lamp with size 0 will give you a very sharp shadow:

As you increase the lamp's size it will give you much softer shadows.

related: Meaning of Sun Lamp Size?


How to clone a texture from other UV Map Image in the Texture Paint Mode in Blender 2.77a? I am following this YouTube video to clone a texture from another UV Map in the Texture Paint Mode. However, I cannot find out the locations of Tool and the Clone option bar. It seems that the locations are changed in my version of Blender. I am now using Blender 2.77a. How to find out the locations of them?

The left-hand side is captured from the video. The right-hand side is captured from my Blender.

I finally found out how to set the Clone.

Steps

The following step is under Blender 2.77a in Ubuntu.

Go to Texture Paint mode.

According to the following image, you can click Brush -> Image Paint Tool -> Clone.

Set the Brush to clone.

Go to Option and configure the setting like the following.

Go to Slots and select the Paint Mode as Image.

Create a new Canvas Image and rename it as what you want. e.g. Casper Texture.

Set the UV Map you want to paint it to.

Check the checkbox Clone from image/UV map.

Select the Source Clone UV/Map.

Select the image of the UV/Map you want to clone.

Paint it.

Save your painted UV/Map image.

References

Blender - "Micky" Ch.1 - Pt. 9 - Texture painting with Clone Brush


Can't get background image to show in cycles render https://www.youtube.com/watch?v=wjWoglMYXBE

I've followed this tutorial to the T and my end result is not showing properly for some reason. Any idea why this could be?

I have looked at the numerous times this has been asked on here and google but I'm at a loss now.

My end result is image 1, what I'm aiming for is number 2 and my compositor node setup is 3.

If I hook the last node up to viewer instead of composite it just displays a solid colour..

I don't know if I got what you wish, but for a simple object-over-background you could use something simpler like this:

[edit: I added another node setup, as suggested by cegaton, you can see both give same result in the two UV/image panels above/right]

note: without linking to the compositor node, imho you get no compositing in the final render...


Export selected objects Does anyone know an add-on to export only the selected object to e.g. .stl format?

The .stl exporter already has the option Selection Only to export the selected objects. In Blender 2.80 the exporter options can be found in the lower left area of the file browser. In Blender 2.81 you may need to click on the cogwheel icon to show the options.

Blender 2.80

Blender 2.81 and later


Composite node/ Viewer node preview not showing I am trying to get a depth map of my imported model for which I found out this tutorial. So far here is the picture of my work. As you guys can see there is no preview in the backdrop or the nodes of the node editor, I read in a couple of places to render my model to make these preview appear but that didn't work for me too.

Edit:

The updated image to find the depth map using mist. Mist is checked in the camera and render layer settings also.

The Z pass outputs a value, measured in Blender units, from each pixel to the camera: if your object is far more than 1 BlenderUnit, the viewer of this output will be totally white, treating every value bigger than 1.0 as 1.0.
I think the best way to use the Z output is inserting a "normalize" node, wich will assign 0.0 to the minimum value and 1.0 to the maximum, scaling all others values accordingly.
You can follow the normalize node with a color ramp, to fine tune the new Z signal.
In my image the color ramp node is used only as "inverter", so 0.0 value becomes "white" and means minimum distance from the camera, and 1.0 values gets black (maximum distance from the camera).
Note that the upper angle of the cube is black.

For a quick udersranding of nodes, use the combination ctrl+shift click on a node to instantly show his output on the viewer.


Cancelled extrusion of a face, now its a different color? I extruded a face then cancelled it (its the darker face). Now its behaving differently, and I can see a color change too. How do I remove it?

You now have two faces occupying the same space. If you haven't done anything else you can step backwards by pressing Alt + "Z". Otherwise, in Edit Mode select one of the faces and delete it by pressing "X" and choosing "Only Faces" from the drop down.


Workflow Question: How to get from a 3D scan to Aurasma Augmented Reality I'm trying to get a model taken from 3D scan using the Autodesk 123D Catch app into Aurasma. According to their FAQ, this needs to be exported via OpenCOLLADA and that's why I've installed Blender for the first time. I've downloaded my model as an .stl and also a .obj and have managed to open it up in Blender and that's as far as I've got.

According to the Aurasma instructions I need to, "Upload the following files to Aurasma Studio as a .TAR file (Windows use 7zip and on Mac use GUItar).
• DAE file created in 3D using Collada exporter
• PNG’s for textures
• PNG thumbnail named ‘thumbnail’ with .PNG extension

I have managed to export the model as a DAE file but it ends up being over 100mb because of the complexity of the mesh (I'm guessing). I've tried using Decimate to reduce the model complexity but this seems to cause issues with the textures no longer matching the model's topography.

I have no idea what I'm doing here or how to go about getting the texture PNGs etc, so if someone could talk me through step by step I'd be really grateful. Bear in mind I've never used Blender or anything comparable!

Many thanks

Decimate modifier doesn't take in account UV maps.

With the collapse option enabled it:

  ...merge (s) vertices together progressively, taking the shape of the mesh into account

While mergin vertex, it likely happens that the UV mess up. You should create a new UV map for the decimated object and stick the original texture to it.

Start from duplicate (Shift+D) your mesh. Rename the source object
"Highpoly"    and the duplicated one "Lowpoly" (keep them in place,
overlayed)
Add and apply a Decimate modifier with the wanted settings on the Lowpoly object
The UVmap of the Lowpoly has now been destroyed in the decimation, you must re-unwrap your model.
Bake the original texture from the Highpoly to the Lowpoly as shown for example in this video (the only difference is that you should bake "textures" instead of "normals")


Is it possible to mass enable adaptive subdivision checkbox? i would like to assign adaptive subdivision to many meshes. Doing it by hand will take a'lot of time.

It seems transfer modifier does not transfer adaptive settings for now. Maybe it is because the feature itself is new.

Is it possible to somehow enable "adaptive" checkbox on many meshes at once? Maybe some script can do it?

To enable the adaptive checkbox(as well as many other options) on multiple objects modifiers, select all the objects and make sure one is active. Then in the objects modifier, hold ALT and select the checkbox.


Need help Animating water So I am trying to animate some tectonic plates for my geology class and I want to make the water fall as the plate moves  and then go back up, creating some sort of waterfall loop, but I dont want it to spill to the sides. Any ideas of how I can do It?

If I understand the question, this is fairly easy to do.  In Blender 2.79-2.81 you need three different types of features for water.  These are all selectable in the physics tab under the fluid button.  You need the Domain of the problem which limits where the blender physics engine calculates the water interactions.  This needs to be a rectangular block.  Then you need your water (the ocean in your case) which can be larger than the domain, but only that part in the domain will be animated.  Then you need a fluid obstacle which in your case are the tectonic plates.  When you run the simulation by hitting 'bake' the water will not flow out of the domain unless you put a drain or an outflow in it. You can put an outflow between the plates and set it to drain only when the plates pull apart.

Hope this helps.


Problem with Texture Opacity I'm a complete beginner and I'm having some problems with my textures.

If you look at the image below, you can see that the texture appears to be transparent.

What can I do to make it look like the texture in the original image?

Blend File

If it really is a transparency problem, which I'm not sure that it is, then all you have to do is uc-check the box that says Transparency under the materials tab.

However! the real problem lies within your Fresnel shading, where you have the ramp pushed aaaalll the way over to the right. you want some breathing space between the two pushey-guys or the reflective effects are super dramatic. You might also want to change Fresnel to lambert. Fresnel has effects go further without dissipation so I think that's your problem.


Freestyle: control the Thickness of stroked curve using Radius? (My english isn't very good, do not hesitate to edit my question)

I'm currently searching the best way to draw some 2D filled shape using Blender.

For example:

This image is a render from Freestyle, the variable stroke width is automatically generated which isn't what I want.

For the moment, I've found some interesting methods. One of them consists to play with a Bezier Curve in 3D mode that is extruded a little bit (with Tilt at 90°) then I can use ALT+S for change the radius of my extrusion. I really like that way of working and it give me that kind of result which is good:

The Problem is that I can't easily fill the shapes...
Lets see with this example:

If I want to fill that shape, I need to:

Duplicate my Bezier curve
Change the Z position of the duplicated curve to put it behind the original shape.
Change its mode to 2D so as fill it.
And finally, change its material to the color I want.

That's a bit annoying to do and when there is a lot of elements on my stage, it becomes a mess, even using Groups.

It would be easier to use Freestyle for that, but how could I control manually the thickness of the stroke like I do with those bezier curve when I'm changing the Radius ? Does a similar way exists (like weight for example) ?

I searched for a modifier of Freestyle Lineset but no luck. I've saw that it is possible to use Python, do you think it is possible to use that mode ? I tried a few, but the data input don't seems aware of a parameter like the Radius of the vertex...

Animation Nodes can be used here. Essentially, if you add a 2D curve and copy the 3D spline to it using this simple node tree, you will get what you need:

It also works for multiple splines:

But what if we have multiple spline objects? In this case we append all splines from all objects into a single list and use it instead, and the 3D spline objects can be sourced from a blender object group that the user will add:

What if we want the fill objects(2D Curves) to be separate objects so that we can add different materials for instance. In this case, the 2D curves can be dynamically generated using the Instancer Node:


Why does my hair particles look so thick in cycles I exported a genesis 8 female character as .fbx to blender bald. So I decided to create hair for my character in blender but it's looking very bad in cycles. I'm using blender 2.92. I've tried everything I could but I don't seem to find the solution. Please help guys.

It's probably the Hair Shape settings that are set too high (default values) and it looks like this:

To better see what's going on, go to Eevee, and set the Hair → Hair Shape Type to Strip. This gives you a better idea in Material Preview/Look Dev mode of how the hair actually looks like when it's rendered in Cycles. The hair particles now will look thick. Don't worry, we will fix it in a moment. Switch back to Cycles.

Let's make the hair thinner:  In the Hair Particles → Hair Shape settings you can adjust the thickness. Go to Hair Shape section, and try these values (for example): Strand Shape: -0.850,  Diameter Root: 0.05 m, Tip: 0.03 m.
These values works best when your model is in real-world size and the scale is applied (Ctrl+A).


There is no Film color management in blender 2.8. Why? It's a pity but there is no Film (not Filmic) color management in blender 2.8. I wonder why it was removed? Also all camera presets also were removed. If anybody knows the reason why it was removed and will it be in final 2.8 release, please explain. Thanks.

The "Film" options was removed because it wasn't proper color management and the "Looks" because they were more of a post-processing filter to achieve a certain appearance. You can still achieve similar results by using the compositor to color grade your renders.

See: Combine Filmic Blender and "Standard" Film Emulation


How can I get a straight UV map when I unwrap? I modelled this little wall in Blender and I dont know how to get the curve straight.
Can somebody help?

http://prntscr.com/g2ljc6

I changed a few things with my model and Im not sure how to get the x-scale of the selceted faces of the UV exactly like the x-scale of the faces underneath...

Does somebody know how to fix this?

Screenshot

A simple way to do this, if you don't want to unwrap again, is to select and scale the edges. Select the top edge of your curve like this:

Then press:

S
Y
0

The scaling result: (Repeat for the bottom edge)

Lastly scale the bottom edge along the X axis. The final result:


How to stop "Rogue" Particles I have just finished making a particle simulation to make laser fire but occasionally a "rogue" particle gets out and goes of in a random direction as you can see here.

How do I stop it doing that?

Gun Turret -

Blend file - Gunturret.blend

Not to take from Batfinger's comment above, this has been a common albeit minor problem for myself when emitting lines as particles.  Thanks to your
question I sat down and think I've cracked it at least for the gun projectile situation.

When using the generic "Line" particle for gun projectiles, reducing the emitter's vertices to just 1,  forces the launched lines along the correct trajectory.    There are no strays.  (Blender Vers 2.77a)

The emitter must be parented to the gun barrel if it's to be aimed or moved about.

Halo effect -  Rendered with Blender Internal

If using "Halo" in the Material slot, (e,g, for a space cannon) the emitter should be moved at least one line length from the end of the barrel.  When it's too close, the halo effect looks as though the plasma bolt (?) is being emitted from the turret and not launched from inside the barrel.

Emitter Object -

Using an Emitter Object for projectiles, comes up against the problem of rotating those previously launched when the barrel is aimed elsewhere.  They continue on their own trajectory but are pointing the wrong way!  Great for comedy!

Details -

The Particle plus Material settings are too numerous to list here but if you use the same as in the attached Blend file, none should stray from their intended trajectory.

Be mindful of BatFinger's mention about vertice normals.  Your single vertice may well be pointing elsewhere, not in line with the cannon.


How to scale along a spline Ik rig I was curious if it was possible to scale this along the spline of a spline IK rig almost like it was growing along the spline.

Below is how it scales now but I do not want it to look like this

I would like it to stick to the spline and look like the picture below.

I appreciate any help. It is a little hard to explain with text if you have any question please let me know.

I figured it out. You Change the spline constraint under Y Scale Mode: to "Bone Original"

Thanks for the help!


How to reduce poly number when you start creating object in 2.8? In Blender 2.79, there's an option to reduce poly number of your object, the option appears when you first create it.

But now I've moved on to Blender 2.8 and can't find it, Where is it?

Here you go:

Hope you can see it there.


How to twist multiple objects How would you go about making these kind of twisted objects. The twist consists of multiple objects. Somehow I can't get the result using the Twist modifier.

Just for fun you can do this procedurally :)
Start with five circles and a bezier curve and add modifiers...

Screw modifier
Array modifier
Curve modifier and target the Bezier curve
Simple deform modifier > Twist
Simple deform modifier > Bend


remove vertices in blender I'm a beginner and I have a problem with merging vertices or removing them, I cant find remove by distance or I can't remove them with merge by distance.

It shows 0 vertices removed, if i increase the merge distance its happening like this.

Although, now, you can edit multiple objects simultaneously, you can't merge vertices between them. In this case, I suspect you will have to CtrlJ join the objects in Object Mode, before merging vertices in what would then be a single mesh.


No particle button available (EVEN WITH MESH) created a brand new mesh object, still can't use particles. I've tried every mode and such and it WONT let me use particles. Please help.

Your particle button is off the side of the screen due to the size of your properties window. You can reach the particles button by scrolling over the properties buttons, or expanding the properties window so the entire thing fits at once.


How to project an image from a Cycle's Sun light I'm trying to project a caustics texture from a light in Cycles. It works with Point or Spot lights, but I'm trying to emulate the sun projecting caustics underwater, so I need the shadows and light rays to be parallel. Here is an image from the test scene, note that the shadows are not parallel.

And here's the light's material setup:

The question is if there's a way to project from a Sun light. I know that an option is to take the light far, far away (that's why the Light Falloff Node is there, for controlling the strength).

Short answer:

No.

Long answer:

  Their position is not taken into account; they are always located outside of the scene, infinitely far away, and will not result in any distance falloff.

Which leads me to believe that it would not be possible, as there would be no way to map the texture to a source set up like that. The exact reasons you want to use it makes it an impossibility I am afraid.

Alternative answer:

You can project an image from a plane with a simple Transparent BSDF setup between any light and your subject.

And it also works with volumetrics:


Use Blender game engine with bpy, is it possible? I am new to blender, I want to use bge with bpy as normal scripting. I intend to use scene graph and actuators also mouse events and stuff like these from bge, however importing bge into my standard file does not work. Can I write an operator that uses features from bge, or that is not possible?

No the bge module is only available when the game engine is running. Similarly, the sensors and actuators that you setup with logic bricks will also only work in the game engine.

To write an operator that responds to events you want to look at a modal operator. You can also find a few examples in the script template files that are available in blender's text editor.


Shortcuts don't work after restart I'm new to blender and have this issue: I'm using the "Industry Compatible" keymap. In "Edit Mode" the keys 1, 2 and 3 swap between vertex, edge and face select - Great!

Now i want to customize it, so i'm adding a new preset "My keymap". As far as i understand this now is based on the "Industry Compatible" keympap and everything works accordingly. But if i close and start blender again, the 1, 2 and 3-key aren't working anymore. I need to go back to the preferences, set the "Industry Compatible" keymap and then set back to "My keymap". Then the 1, 2 and 3-key work again as expected.

This is reproduceable on the last Blender 2.8 version on several different machines. Am i doing something wrong? Is this a bug?

Update: In Blender 2.81 you will be able to use 1, 2 and 3 for switching vertex, edge and face select even when your keymap is based on the Industry Compatible keymap. The operator is now decoupled from the specific keymap. It's using object.mode_set_with_submode as operator instead of ic_keymap.mesh_select_mode. This change was added with commit rB23d19c2b0dd3f47339ef07be39d47c41848be39b.

The reason this issue occurs is because the industrial keymap registers an operator called IC_KEYMAP_OT_mesh_select_mode which provides the functionality to switch between selection modes for vertices, edges and faces. However this registration happens only when the industrial keymap is loaded / selected in the preferences. A custom keymap based on the industrial keymap doesn't trigger this, resulting in a shortcut referencing an operator that doesn't exist. However if you open your preferences after restarting Blender and switch to the industrial keymap and then back to your custom keymap, it will have the operator registered because you have loaded the industrial keymap before.


BGE: How to apply colour to a certain face with python? Lets say i have a xy plane that is subdivided 10 by 10.  Now, how can I apply a colour to a, for instance, 5x6 set of faces on the plane using python in the game engine?

If you don't need to apply coloir to that face in-game you can add different material to it without python- in materials tabe add ne material to mesh on the left of the list of materials. Than set that material to the color you want and go in edit mode. Than select the face you want to be colored in that color and select it(only). After that stay in edit mode and go to materials tab. Selec the material you want to apply on your face and than press assign under list of materials in materials tab!


The units don't change when I am zooming When I select metrics in the units toolbar, the units on the top left of the view screen are supposed to change as I zoom in and out. That does not happen for me. It just stays at meters. Also the graph ends at a certain point. Can I make it infinite?

The measurement indication on the upper left is in reference to the grid.

If you are in perspektive view or rotated (custom) orthogonal view, then the grid is going to remain the same size, and hence the displayed text will say meters. (The grid is space in meters.)

In orthographic top, side, bottom, front and back view, the grid updates according to the zoom level.


How to auto merge faces? i apologize in advance because im sure my question isn't very clear.
Basically when I extend these faces out:
i want this face:
and this face:
To be merged so it would look something like this:
Except i did that manually is there a way to have that happen automatically? Also its probably important to mention that im new to blender, and not very good at explaining. Any help would be appreciated!
Edit: When i say new to blender i mean you might have to explain more than usual.

Use Extrude Manifold tool (instead Extrude) just select front face and move forward with Snap to Vertex ...

... than move it up.

Since faces around becomes non-plannar and internally a triangulation happens in unexpected direction it is better to search for Quads to Triangles operator (that does tris in shorter distance) ...

... or you can use Knife tool to triangulate manually by longer edge.


How do I combine an animation with two different fps'? I have two separate motion capture fbx's, one being the body which is 100 fps and the face being 24 fps. I just brought the both of them to blender 2.9 however since they both are two separate fps' and I'm trying to combine them to one character I don't know how to do so without one being faster or slower.
I did some research beforehand and was fiddling around with the time remapping but it didn't do any good since the body and head just animated at different fps. I wish to get my head motion capture data to be at the same speed as my body motion capture which is 100fps. Can somebody help?
Thank you.
Update: I did what was suggested by scaling the x axis of the face motion capture in the graph editor and reducing  it by 0.24. My results where that the face animation went faster when the fps was set to 100fps which is the opposite of what I need it to do. I'm going to test out the inverse of what I input and see if it will fix the issue
Update 2: I rescaled the body animation so that it is at the same speed as the face animation by reducing it by 0.24. When I change the overall animation fps to 24fps then both the animations move at the same speed. However since I want both the animations to be at 100 fps I switched the frame rate back to 100 fps and I am trying to figure out how to remap 24fps to 100 fps in the time remapping.

The NLA Editor
Could consider dropping the actions into the NLA editor and scaling them to match.
For example sake have two actions 100 frames of an 100 frame per second action  and 24 frames of a 24 frame per second action. At there designated frame rates each would last one second.
As noted in question if scene frame rate is 24 FPS the 100 frame action goes for 100 / 24 (approx 4 seconds), or conversely if at 100 fps the 24 frame per second lasts 24 / 100 seconds.

Among a few ways to animate time in the NLA editor can simply scale the length of one to match the other.
Drive the strip scale.
Better still can add a driver using the scene frame rate
Setting up the driver, right click in the scale property box and choose add driver

Add a single property variable, name it "fps" and point it to scene.render.fps by choosing scene and crunching render.fps as the data path. Now for the 24 frame per second action make the driver expression
24 / fps

copy the driver, paste into the 100 FPS strip scale property. Change the expression to
100 / fps

Now the two strips will match length, eg at 24 fps the 24 fps is 24 frames long and taking up 1 second, as is the 100 fps and vice versa.

Please note, could associate an fps with the action and use it in driver expression.  Also for the correct fps the scene.render.frame_base property should be taken into account, eg at 23.98 fps the fps is 24 and the base is 1.001, ie actual frame rate = scene.render.fps / scene.render.fps_base.


How would you sculpt/model absimple character like this one? I do not have much experience with Blender and zero sculpting skill. But i really want to make character like this. Where would you even start? What's the first step?

Is that all the references you got?:) It’s ok, it looks like the character is symmetrical enough. My advice is to analyze the form.

To give a few examples, the head is just an elongate sphere (not cylinder), the hat is basically a section of that sphere. The eyes are squashed spheres with the eyelid being squashed sphere sections. The teeth are a combination of a cylinder stretched in one axis with a spherical end. The mouth is a cut of irregular contour that sits on the top of the spherical head. You have to learn to obtain those forms from simpler forms.

I think the most important parts are the textures and the rendering.


How to perfectly align UV coordinates automatically? I have this setup:

The mesh is only the visible top side, with a mirror modifier for the bottom part.
Now I want to unwrap it like in the picture. I want the inner circle (red) to go to the top of the UV map...

The problem is that no matter what automatic unwrapping I use, it never works as intended.
The closest I've gotten was by using "follow quads", but that skewed the UV map a lot:

I used the result from the second image and manually adjusted the vertices with a lot of scaling and "align auto", but its very far from perfect as you can see in the first image.

Here's what I want exactly:

The uv vertices should be distributed evenly (horizontally)
The middle line (yellow) should be on a "natural" y height (so there's no stretching)

I hope it's clear what I want to achieve. I'm sure there must be some automatic way to perfectly align and distribute the UVs in this way.

By the way: If you look closely you can see that I already placed a uv seam (aligned with the green y axis in the screenshot) but that didn't really help.

Follow Active Quads is indeed the best automatic preset to use in this situation, however its use is slightly nuanced, and until recently I didn't know how to properly use it myself.

Start by erasing your existing UV Map from the Properties Window > Object Data > UV Maps, so you can start afresh.

Select one random face, any four sided face will do, and unwrap it using the basic U > Unwrap > Reset option so it is unwraped as a perfect square.

This will also make it the nominal active quad, only then can the Follow Active Quads option be used since it will use the active face's coordinates to unwrap the remaining mesh.

Now select all faces and unwrap them using U Unwrap > Follow Active Quads, should yield an even quad orthogonal grid.

Afterwards if you wish to make it fit inside de [0,1] UV space then either scale it down until if vaguely fits inside the image area, turn on UV > Constrain to Image Bounds and scale it up manually; or use the operator UV > Pack Islands to automatically fit maintaining proportions.


Circle select modal in addon? I want to add "C" release circle select to my hotkeys and keep it in a portable file/addon. This seems to work when I run the script in blender, but the modal doesn't work when I start up blender.

bpy
import os

def Keymap():

    wm = bpy.context.window_manager
    kc = wm.keyconfigs.addon

    km = kc.keymaps.new('3D View', space_type='VIEW_3D', region_type='WINDOW', modal=False)
    kmi = km.keymap_items.new("view3d.select_circle", "C", "PRESS").properties.radius=1

    km = kc.keymaps.new(name='View3D Gesture Circle', space_type='VIEW_3D', region_type='WINDOW', modal=True)
    kmi = km.keymap_items.new_modal('CANCEL', 'C', 'RELEASE', any=True)

def register():
    Keymap()

def unregister():
    Keymap()

if __name__ == "__main__":
    register()

Script below, named "km.py" and registered, works as expected for me on blender 2.8. It circle selects with set radius on C pressed and finishes on release.

Assumed the missing import bpy in question script was a copy paste error, but it may be your issue.  Always check the system console for errors.

Script:

import bpy

def custom_keymaps():
    wm = bpy.context.window_manager
    kc = wm.keyconfigs.addon

    km = kc.keymaps.new('3D View', space_type='VIEW_3D', region_type='WINDOW', modal=False)
    kmi = km.keymap_items.new("view3d.select_circle", "C", "PRESS")
    kmi.properties.radius = 10

    km = kc.keymaps.new(name='View3D Gesture Circle', space_type='VIEW_3D', region_type='WINDOW', modal=True)
    kmi = km.keymap_items.new_modal('CANCEL', 'C', 'RELEASE', any=True)

custom_keymaps()

Only aesthetic changes re setting kmi after creating a new item.  (otherwise kmi is set to the radius which is a little misleading) and calling the method directly rather than via register method. Script in question also works as expected with the import and calling register() at level 0.

Given a py extension and register checked

How to auto-run a simple script?

If you are executing this  in a registered script (sane text block name with  .py extension and the register script checkbox ticked on text editor header) then same as answer here https://blender.stackexchange.com/a/134416/15543 also applies.

__name__ will be the sane textblock name without the python extension. When imported on register. Prob simpler to put register() as the last line of script in this case.

Currently your unregister method is also registering, however loading script this way will probably not trigger any unregisster activity.

You can import these into the python console. Let's imagine your script is called "foo.py" in the text editor then

import foo
foo.register()

will register it similarly to an addon. Later you can call

foo.unregister()

to unregister while seeing any errors printed into the python console.

PS if this is the case could possibly mark this q as a dupe.


Geometry of one object changes (doesn't update) when I render the image I have a problem, I'm finishing a project and suddenly I have a strange problem.
Geometry in viewport looks like that:

And in viewport preview render like that:

But as I hit render, it changes a geometry of one of the objects to what it was many many hours ago before I edited it (Those brick-like things are longer):

Does anyone know what is happening?

Nevermind... I must have duplicated an object in a few hours ago and it was invisible in viewport, but visible in render. I deleted it and it's ok now.


PVRGeoPOD add-on is not found from preference after installation I downloaded the add-on, PVRGeoPOD (Mac) from here. Then I double-clicked the downloaded .pkg to install on my Mac.  But when I want to activate it from the Preferences in Blender, I can't find the add-on.  Could anyone tell me how to install the add-on please?

https://www.cgchan.com/static/doc/sceneskies/1.1/installation.html
That's how to install an addon. It seems like software that has a business behind it, and this question is toward that software. I would ask them how to install.


Why can't I make a vertical loop cut on this object? I'm very new to Blender. I've got a cube object which I've manipulated with intrusion and extrusion. I'm now trying to make a vertical loop cut, but it is only being applied to the inside of my object. Horizontal loop cuts work as expected.

I've had a look at other answers and tried removing doubles, recalculating normals and had a look for any N-gons, but as far as I can tell, everything looks okay.

What can I do to make the vertical loop cut work?

To answer my own question. There were hidden doubles in the object. Even though the original post says that this was already checked, I removed doubles again and that time it worked.

In edit mode I deselected, then reselected all and used the remove doubles tool.
A, W, Remove Doubles.

Making sure to set my Merge Distance greater than 0. After that, I was able to add a vertical loop cut.

The other SE questions I used to help fix this were:

why does loop-cut-and-slide ignore some faces but not others?
Loop-cut won't go all the way around
Loop cut interrupted


How to un-mirror an objects sides? Apologizes for the terrible wording in this! I am unsure how I got to this point but my garment seems to be mirrored on both sides. I've tried to texture one side different so that maybe that will give me both sides of the garment in the UV map area- but it seems to paint on both sides when I do this.

I'm very new to blender so perhaps I have something turned on that is doing this? Any ideas or assistance would be greatly appreciated. Thank you so much!

You most likely have "X" Symmetry enabled in the tools panel if you are experiencing this issue while texture painting in Blender.


How to pause the BGE and then resume With the logic setup below I'm trying to pause the game, then on any key stroke resume where it was paused. Trouble is when the BGE is Paused it seemingly can't listen for any input.
click image for full size

It does appear that a suspended scene does not respond to any events, which sounds right when you think about it.

A solution is to use a second scene to control the play. When starting game play connect a scene actuator that sets a second scene as a scene overlay. This second scene only needs one object, which can be an empty, and contains the pause/resume pieces as you have shown, just with the pause/resume scene set to the first scene not the second that has the pause controls.

If you have setup a scene as an overlay to display scores etc then you can just use one of these objects.


Trouble replicating the animation where the colour only spreads onto a specific area I'm trying to achieve this effect in this video: https://www.youtube.com/watch?v=2-6Xz4tWigM&t=49s

Animation is at 0:47.

I'm reletively new to the node editor but understand its mechanics but a noob to masking.

I believe a mask could be used to affect only the two characters in the image but i don't know how to achieve it in the node editor.

My process so far: add image node, which ive cropped and transformed to get the image in position so i can see it in the viewer.
Create Mask of boy on the left in the UV image editor using ctrl click and ctrl c to finish making the mask. Add mask node and select mask.
Add Movie clip of an ink drop and changed its colour to red.

That's it so far, completely stumped

Any help would be greatly appreciated.

Even though you have part of the process completed, I will give an overview of the steps.
You could transform all images in the node editor, but since Blenders transformation nodes are inefficient to handle, I will suggest the 3D space.

Load your image into the compositor. Set the project size to match it's dimensions.
I will use the images as planes addon to quickly get my ink movie clip into the 3D view. Import it with the options Auto Refresh and Shadeless.
Then I added an orthographic camera. The movie clip should play, if you selected auto-refresh.
Set the image as a background image in the 3D view. Transform the movie clip plane in camera view.
Set the World Background to black. The render will be used as a mask based in the luminance.
Mask the image in the Movie Clip Editor.

Load your Renderlayer and Mask into the compositor and multiply them with a ColorMix node.
To color the masked portion red, use a ColorMix node. Connect the multiplied masks with the Fac input.

Rendering it results in the desired effect.

Further notes.

If you change your scene size (using the percentage slider), you will need to add a scale node to the Input Image.
If the ink movie clip mask is not white, the effect will not be 100% opaque. You a RGB Curves node or a colorramp to shift its whitepoint.
You can use the mask with many other nodes other than a MixRGB node.


How to join two objects so that one conforms to the shape the other? I am modeling a bottle of 2 parts that need to be joined, however the bottom of the cylinder neck needs to conform to the shape of the bottle's body section. Is there a command that allows wrap these polygons to the polygons of another object's polygons? See below image and you'll see what I am trying to do. Or any suggestions as to the best method to wrap it accordingly?

One way you could get the top to fit to the bottle is with the Shrinkwrap modifier. Here are the steps.

Start by adding a shrinkwrap modifier to the bottle neck. However, that will crush the entire neck on to the bottle, to get around that problem use a vertex group.

Select the bottom edge loop on the bottle neck and assign a new vertex group to it with a weight of one.

Now use that vertex group in the shrinkwrap modifier (pictured above), and you will get the bottom of the neck to match the bottle.


How to make an empty follow a rigged mesh's movement? I am trying to animate a bug plushy. I have made a rig to my liking, but as I maneuver the rig the facial features (which are separate objects) don't follow along. I have tried parenting these other objects to the mesh I have already rigged and the armature itself. Is there a way I can make the empty follow the transform of a bone tip? I'm not sure how to go about this.

Screenshots:

Blend File

To fix this:

Select your main mesh object.
Then shift+right click to select the small facial features.
Hit ctrl+J to join them together.
Re-Parent the mesh with the armature then they will move with the mesh.


Moving hook stretches edges in cloth sim I attached two vertex pins and then two hooks for a cloth simulation on a plane. When I move the hooks, the cloth stretches the vertex's connected edges to the location of the hook, making the cloth look stretched. How can I stop the hook from stretching the edges?

This a screenshot of the first couple frames of the cloth simulation. The left hook is unmoved and correct. The right hook has been translated left.

This is likely related to https://blender.stackexchange.com/a/83096/29586 - ie, the sequence of the modifiers in the modifier stack. Ensure the Hook modifiers are above the cloth sim modifier - otherwise the cloth will apply first (to the unmoved vertices) and then the hook modifiers will move those vertices after the sim - rather than the sim taking account of the new location of those vertices.

EDIT I've put together a test and this is working as I would expect - ie, with the hook modifiers 'above' the cloth simulation. Here's the setup :

The 'cloth' consists of a subdivided plane. I have added a Vertex Group named 'pin' and assigned two vertices on the top edge to it. I selected each of these same vertices in turn and used Ctrl+H to 'Hook to New Object' to create two new empties hooked to those vertices. Note : It's important to use the exact same vertices for the vertex group as is assigned to the hook.

Using keyframes I animated the right-hand empty.

This produced the following animation :

This only works with the hooks above the cloth simulation in the modifier stack.

Blend file included


Polar slot in cylinder Does anyone know how to make a precise curved polar slot in a cylinder?
All solutions I have tried in Blender do not have a constant width.

And should be theoretically possible to mill on a turn milling machine!
I do not want a cad but I would like it to be as realistic as possible, as I later want to animate a pin that is gliding through the slot.

1.pic: Make a cylinder like this (hit Ctrl+R to make edge loops)

2.pic: Turn on proportional editing (sphere), select the marked verts and move them apart with scaling "s key" use the mouse scroll to adjust ray of the proportional editing.

3.pic: Switch to smooth the proportional editing, select the marked faces and rotate them around the z axis R key and then Z key.

4.pic: Go to object mode and add a solidify modifier

5.pic: Click on smooth shading, turn on auto smooth and adjust it

6.pic: If you go to edit mode, select all faces by A key then hit Ctrl+T to triangulate the faces the surface will be smoother, but the topology will be worse.


How to inset a curve into section of circle? I apologise if this is a duplicate, I have no idea what to google.

Here is my circle section:

I have used an array around a rotated empty axis to retain symmetry.
How would I inset a curve into this section, so a circle is inset into the whole object? Here is an example image because I am bad at explaining things:

One way to obtain the result you want could be to select the edges in the mesh I selected in the image below and simply click on "Subdivide" in the Tools panel on the left. You should obtain something like the second image, which looks similar to the one you posted in the comments. Remember that you have to do this before using the array modifier, so either hide it by clicking on the eye icon in the modifier panel or delete it and make a new one from the beginning, after you obtained the result you want with the original mesh.


How to animate a opening lid? How to rotate an object like a notebook lid? Using R does not rotate around the bottom of the object.

You can see the exact example here.

Position your cursor at the point you want your object to rotate around and snap the objects origin to the cursor.


Blender keeps crashing/closing without log entry I have a problem with blender now and I don’t know why.
It keeps crashing constantly. I can work sometimes only 2 mins and sometimes upto 20. Then it closes without anything.
I reinstalled it with no success and even if I start it through the cmd in Windows with --debug-all nothing is shown other than the last command.
I installed Windows fresh and formated everything, but the problem still exists.

My system:
Windows 10 Pro
AMD Ryzen 7 3700X
16 GB RAM
Geforce 1070 GTX
~100GB free space on SSD
Tried with Blender 2.8 and 2.9
I tried to find the crash log file but apparently the feature is disabled at the moment for windows.
If anyone can help, I would be glad!

So if found out what the problem was:
My new G502 Logitech mouse.
I tried my old one and Blender never crashed again.
This post is closed.


Can I temporarily replace an object with a "placeholder" to help with multiple high-detail objects? I have an object with a great many polys, so many it causes significant slowdown in the viewport.

I need to arrange several of these objects for my final render, but this would be awkward, given how slow they make my computer.

Is there a way to temporarily de-polyify the objects, or replace them with a low-detail object (with roughly the same size and shape), so that I can arrange the low-poly objects, then easily switch them out for the high-poly objects?

Select your high poly object
Go to Object Properties panel
Under display tabs, look for "Maximum Draw type"
Choose "Bounds" in the selection drop down.

Now your high poly mesh will be displayed as a simple box in the viewport.

Alternative Method

Or you could add a decimate modifier on the high poly object which would let you pull down the mesh count considerably. When you have finished positioning all the mesh all you need to do is to remove the modifier so the high poly object is restored.


How to distribute overlapping objects? Let's say we have many overlapping objects. Why are they overlapping? Could be any number of reasons, but most likely because they were generated from a script and the script put them all in the same spot. They are each a little different, so rather than generating new objects we need to clean up our existing ones.

How can we write a script (or use some other method) to distribute these objects in a straight array-like line?

Sure, we can select any individual object by Alt-RClicking, but we would still need to place each one manually.

In the end we want something like this:

Not so difficult to manually place a few of these, but when you have hundreds of objects that's a different story.

There is a question similar to this one, but the answers provided did not work for me. One answer was to use a particular add-on (Oscurart Tools), but when I tried it the Distribute button did not work, so I suspect the add-on is not functioning properly in more recent versions of Blender. The other answer was basically "repeat the last thing you did using Shift R" but obviously that only works at the time of creation, and is of no use when faced with an existing heap of overlapping objects.

Any help appreciated.

The Distribute operator from the OscurArt Tools addon works fine, however it expects one object from those to be distributed put at the end of the distribution area. This means one should select one object of those overlapping ones, move it away as desired, then select all the others, make the standalone one as active and run Distribute.

There are 5 monkeys overlapping in one spot in the first frame on the image below; one is moved to the right on the second, and then the rest of them are distributed with addon.


How to make Higher bump I'm trying to make this planet

in a blender with only 3 textures, Altimetry(Bump), Slope and biome, so I created this material(It's not done yet)

But the problem is that the result is this

My question is, is that possible to change bump intensity without changing distance ? Because distance just make the material look noisy. Also, here's the textures I am using https://imgur.com/a/WBYO9tD EDIT: I tried to edit the altimetry map and few settings but the best result I could get is this

there's are lakes at random place

The picture of your node organization is too small to understand, so it's not easy to guess why you failed. If you want to fake the bumps, i.e. if you don't want to use real displacement, it seems like a simple node chain like this one works fine. If you don't want too many details, decrease the Noise Detail value. I put a ColorRamp to create the flat surface.


Why does the lighting do not work? it worked before but I decided to turn up samples and turn on denoising and such because it had to much noise/ white pixels and then after that the render is so dark. Here is the blender file

I am not sure, but i think you clamped the light too much.
I got this:

if i increase your clamping (clamping direct and indirect light) from 0.03 to 0.2


Error AL lib: UpdateDeviceParams: Failed to set 44100hz, got 48000hz instead. What can I do? I have Win 10 and when I open Blender I have the error:

  AL lib: UpdateDeviceParams: Failed to set 44100hz, got 48000hz instead

While this is a harmless error, this is how you can fix it:

Open user preferences with
Ctrl+Alt+U and go to the System tab
In the sound settings  below, change the sample rate to 48000 kHz and
save user settings
Restart Blender


can you add subdivision surface modifiers to specific vertex groups i want to make parts of my model seem more smooth but others i want to stay flat.

No, you can't use Vertex Groups for Subdivision Surface modifier.

What you can do is select region you want to have smoother and use W > Subdivide Smooth.

Be aware that this method will create ngons and/or tris (when Quad/Tri Mode is checked).


bevel modifier is not working properly I am watching from a tutorial but I am not following it exactly so I can do it myself but I ran into the bevel modifier issue which did not yield the same result as shown in the tutorial.
this is the tutorial's result

as you can see the guard of the sword has bent edges mine however do not

here is a link the tutorial
https://www.youtube.com/watch?v=saxpjudV_88&t=1091s
he did the bevel modifier at around 36:03
I am uploading the link of my project in the comments

There are duplicated vertices: in edit mode, select all and use M to merge then "by distance".


Textures appearing different in Edit and Object mode I have never created a texture before, so I'm learning as I go. I created a texture map to edit in Photoshop, and for the most part, it's looking pretty good while I'm in Edit mode.

A few things are on the wrong sides (like the trace of white on the back leg) but that can be easily fixed.

When I go into object mode, however, the texture looks quite different:

The rabbit's chest is no longer white, and it has strange bands appearing here and there.

What am I doing wrong?

Also, is there a way to mirror textures from one side to the other in Blender instead of trying to guesstimate in Photoshop?

Thanks!

Here's my .blend, in case that will help diagnose:
http://www.pasteall.org/blend/29307

You have a Decimate modifier which is removing some geometry in flat areas, messing up the UVs.

Remove (by pressing the X icon) or disable it (by pressing the camera and eye icons) and then everything will work properly:

As for mirroring, delete half of your model and then add a mirror modifier:

Note that the object origin has to be at the point you want to mirror around, so select the central loop and press ShiftS>Cursor to selected, then in object mode press CtrlShiftAltC>Origin to 3D cursor:

What this does is map mirrored faces on top of each other in the UV map (if you apply the modifier you get your complete rabbit and you can see the resulting UVs in the UV editor).


Why are particles are missing, when using Volume/Grid Emission? I'm having an issue filling a cube with objects using a ParticleSystem.  It's as if a diagonal plane has cut through the cube and eliminated particles.  This doesn't happen to the front plane of particles though, which can make it difficult to tell that it's happened from that view.

I only added the UV Spheres to help visualize the problem.  They don't have any affect on the missing particles.

I've tried many setting, including, but not limited to;
Changing the particle size, Cube Scale, Resolution, etc...
I also tried double clicking Hexagonal Grid (I heard that will sometimes set things straight).

Thanks for any help.

One way to solve this is to bevel each vertex of the cube very little. Tab into edit mode. A to select all vertices. Press Ctrl+V and select "Bevel". Then give it a very small amount of Bevel Offset (I used 0.001 here). Then Tab out of edit mode and it'll work.

Another simpler way to do it is to select all the faces and hit Ctrl+T to triangulate the faces.


Why do the keyframes show up in the dopesheet but not in the timeline and the graph-editor? I'm pulling hairs over this. The keyframes for my object show up in the dopesheet but not in the timeline and the graph editor. I have selected the object, tried every other options like view selected frames, the home key, the period key, zoomed out, the little arrow button that show only selected. Nothing. It doesn't even make sense how the keyframes appear only in the dopesheet and not others for the same object.

The keyframes you're looking for are Grease Pencil Keyframes, and they have their own interface, which is the dopesheet grease pencil panel.
In the timeline, ordinary dopesheet and graph editor will appear only for keyframes related to the Grease pencil object as a whole, while those of yours are related to every single vertex of GP strokes, and they are not editable in the graph editor.
When you create the interpolation between two extremes, you can choose between linear, the preset of easing in and out, or even define a custom curve of interpolation.


What causes black shading errors? As the picture shows, the bottom part of the hospital is covered with shadow and I don't know why. The face normals are not flipped. This happens in both solid view and rendered view.

What causes these black shadows?

You use smooth shading on a non-manifold mesh, which does not work properly.

Non-manifold means e.g. that some edges have more than two faces, and therefore the surface is not closed but has forks. It is impossible for Blender to tell how to shade these faces properly.

For your mesh, one way is to seperate the floors into a new object. This way the mesh will be manifold again, but unconnected.

Another option is to assign hard edges, e.g. using the Edge Split Modifier. This way some edges are shaded flat and others smooth. Flat shading works with non-manifold mesh the same as with manifold mesh. Because in this case the non-manifold spots have large angles, shading problems will be solved.


How to draw a flat ellipse surface in Blender with the following known dimensions? I'm trying to produce the following ellipse as a surface or curve within blender with the following specifications.

The following dimensions, including the position of the origin in x,y,z coordinates will be known. For this image, it will be a flat plane in the x,y direction.

What's the best way or how do you go about coding this?

thanks!

some minor clarifications - the width is a + b = 12.

How about if this was the scenario instead, when it's more skewed and doesn't look like a circle?

I found a solution!
Use this code in the blender text editor:

import bpy
import math

#IMPORTANT : set 3d cursor to world origin
bpy.context.area.spaces[1].cursor_location = (0.0, 0.0, 0.0)

#Add circle curve
bpy.ops.curve.primitive_bezier_circle_add(view_align=False, enter_editmode=False, location=(0, 0, 0), layers=(True, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False, False))

#define variables
a = 10
b = 2
c = 3 # I use the half of c
d = 5

#Calculate width
width = a + b   #or width = a + d + b?

#Calculate horizontal distance from world origin of c
distance = b / 2

#Calculate height c for the circle
#x^2 + y^2 = 1, see Unit Circle
x = (distance / (width / 2)) * math.pi * 0.5

cCircle = math.sqrt(1 - x**2)

#now we have to scale the height of the circle, so cCircle becomes c. And give its width.
factor = c / cCircle

bpy.ops.transform.resize(value=((width)/2, factor, 1), constraint_axis=(True, True, False), constraint_orientation='GLOBAL', mirror=False, proportional='DISABLED', proportional_edit_falloff='SMOOTH', proportional_size=1)

#Calculate location origin
originX = -((width) / 2 ) + b
originY = 0
originZ = 0

#Set 3d Cursor at Origin location
bpy.context.area.spaces[1].cursor_location = (originX, originY, originZ)

#Set origin to 3d cursor
bpy.ops.object.origin_set(type='ORIGIN_CURSOR')

#Move object to world origin
bpy.ops.transform.translate(value=((width/2) - b, 0, 0), constraint_axis=(True, False, False), constraint_orientation='GLOBAL', mirror=False, proportional='DISABLED', proportional_edit_falloff='SMOOTH', proportional_size=1, release_confirm=True)

#Voila

I hope this helps!


How to detect and repair errors in mesh? I downloaded a video game model. The problem is that although it appears to be a valid mesh, there are many many errors. For example, the mesh is not intact or manifold, or sometimes there's double faces, and double edges. There's many types of errors here, I think. Again it's not detectable by glancing at it. Just manually seeing what's wrong with a particular vertex, edge, or face would take forever, let alone repairing it individually. Is there a more efficient or systematic way to fix this mesh? I have attached pictures of 2 errors in the mesh. Thanks very much guys.

The operator is called Select Non Manifold in Mesh menu. It should help you  to find out weird mesh. With further configuration, you can choose what you want to inspect.

After you select those vertices, you still need to clean up them by hand or using operator again:

But don't rely on these method to fully fix your mesh since if your mesh is broken in some degree, that mesh will probably been so weird that algorithm can not figure how to fix it.


Sorting wrong when sorting Vertices and Faces I'm new to Blender, but I've used Max & Maya in the past, both of which I've never had this problem with.

The issue I'm having is when exporting a simple mesh as .obj the vertex ordering is all messed up.  I have tried sorting the vertices using the Sort Elements in the Mesh menu but it is not working as expected, see below...

v -10.000000 5.000000 0.000000
v -10.000000 6.000000 0.000000
v -10.000000 7.000000 0.000000
v -10.000000 8.000000 0.000000
v -10.000000 9.000000 0.000000
v -10.000000 10.000000 0.000000
v -10.000000 -2.000000 0.000000
v -10.000000 1.000000 0.000000
v -10.000000 -1.000000 0.000000
v -10.000000 2.000000 0.000000
v -10.000000 3.000000 0.000000
v -10.000000 4.000000 0.000000
v -10.000000 0.000000 0.000000

As can be seen the ordering is jumping all over the place instead of sorting properly.
I have tried with 'Keep Vertex Order' and without, it makes no difference.

The only way I can get the sorting to work properly is if I select each Vertex individually and sort it using Selection on that one Vertex to push it to the front, then select the next, repeat, etc..  Obviously this is a ridiculous way of doing it and will take a very long time!!
Am I missing something here, as it seems to me that the sorting is broken?

Is there a way that I can write my own script or rewrite the current sort script to sort the Vertices properly from within Blender, Or am I going to have to write a program to parse through the .obj afterwards to fix this? i.e. ascending X, then ascending Y, like this...

v -10 -10 0
v -10 -9 0
v -10 -8 0
v -10 -7 0
...
v -9 -10 0
v -9 -9 0

etc...

Reason for this being to read the .obj and create a continuous triangle strip for rendering which, in the current format, is impossible without sorting first.

I have searched many forums and found a few similar cases, but with no answers, at least none that have understood the question.

I should point out that the mesh is a plane, x & y coords all at integer values, basically a grid. It's a basic floor mesh!

partly solved!!  (see comments below)

OK then....

Just updated Blender from 2.71 to 2.72.... everything works as it should now, weird!!  The vertices and faces are sorted properly.

Had 2.71 on PC and laptop, still got 2.71 on PC and it doesn't sort the vertices properly, now that I've updated laptop to 2.72 that works fine!!

Some weird bug that they've fixed?  Either way, I'm good now.

Thank you stacker and G.Rassovsky for your responses.


- Fail Error on FBX Export, Cannot Export Model Keep getting this error when I attempt to export the FBX, this model doesn't have any UV's. All it has are basic materials assigned (no textures) and rigging. I tried removing parts of the model and when I remove the highlighted segment type (in orange in the SS) the export works. But I don't understand why that segment is causing a problem. I have never had an issue like this before. This is on Blender 2.91. Does anyone know how to fix this?

Just a guess here:
I suspect this was based on something like the cube mesh, which comes with its own UVs even if you don't do anything with them, and that is what's causing this. Or maybe you built that side from scratch so it really doesn't have any UVs but everything else does, and FBX export is looking for a UV even though it won't end up being used.


symmetrical selection of meshes I deliberately made random loop cuts on a plane. And in between the annotation lines, I'm trying to select 2 meshes (faces) which are the same width. As seen in the example, one is wider than the other.And it's a tedious task to try match the width. So is there a method in blender which can even the widths of the selected mesh?
Thank you.

Yes: Go into Edit mode. Change your transform pivot type (top of screen) to Active. Select all the vertices to the left of and including the leftmost vertices of the left rectangle that is too narrow (all the vertices to the left). Now SHIFT+CLICK any one of the left-most vertices. This will make that vertex "active" (doing this again will deselect it--but you want it to be active).
You are going to scale all of those vertices along the X-axis towards that active vertex.
Type S, X, and drag the mouse a little to the left until you are satisfied with how thick the red region on the left in your image is.
This is not the only way to do what you are tying to do.  You also could have moved the cursor and used that as your transform registration point. You also could have used Proportional Editing.


Best practices for learning Blender When I get an idea for something I'd like to make in Blender, I hit up Google for specifics, then blender SE when I get stuck.

I'm very overwhelmed by the immensity of Blender and I'm a little afraid that this self-directed approach is going to lead me to develop bad habits. Is there a "best practice" way of learning to use Blender?

You may wish to check out the Blender wiki. For instance, it has a series of articles on starting to use Blender for the first time, and it has many articles for specific topics.

Some tutorial websites you may find useful include:

BlenderCookie and their Blender Basics tutorial series
BlenderGuru, offering a tutorials of varying difficulty for specific tasks with general lessons
BlenderDiplom, another similar website

You can also ask for critiques on the BlenderArtists forum.

I would recommend checking the regular contests on websites like BlenderGuru and BlenderCookie. Even if you don't feel qualified to enter, give it your best shot – you may learn something along the way.


Matter of Sorting element - What is Custom Sort? I am investigating this Sort node in Animation Nodes. I found it to be confusing especially with Custom sort and Key List. I cannot guess what this is for.

Is there a documentation or can anyone help me to understand this Sort node a little better.

NOTE: Btw, I think the sorting of Text Sequence Script in VSE has issue. I have it happening on my latest live noding video.

Thanks.

Custom Sort: In general, you can sort a list of objects by key. E.g. if you have a list of customers, you can sort them by various keys such as first name, last name, customer number, etc.

Key - a key for a custom sort, which can be written as an expression using the attributes of your list element e. For example, you can enter e.location.x as as a Key to sort the list of objects based on their x location.

Key List - list of sorting keys. If your sorting key is not an attribute of the objects in the list, you can plug the list of key into the Key List Node. For example, look at this answer, where the polygons are sorted according to the distance to some point using Sort List node. Computed distances are used as a Key List.


How can I add a new socket to a node and then make that socket connected to a property In my script, and thanks to brockmann!..  I have added a texture (in the Texture Editor) and also added a Texture Node (in the compositor). The Texture is connected to the Texture Node and that works great. I would like to add two new sockets to change the values of one of the Nodes in the Texture editor

For example,

I have a blend Node in the Texture Editor, and I want to be able to change the colors of the blend.

I figured out how to add a socket (which was pretty simple) but they do not control the colors,  I am not sure how I would now connect the new sockets to the texture blend node..

I added the sockets to my Texture node like this

    comp_node_texture.inputs.new('NodeSocketColor', 'Color 1')
    comp_node_texture.inputs.new('NodeSocketColor', 'Color 2')

But I now need them to be connected?

If I understand the question correctly, you want to set node inputs values.

Say you have added texture node so that it can be accessed like so, for instance:

node=bpy.data.textures['Texture'].node_tree.nodes['Texture']

Then input slots are already created and you don't need to create the slots.

You can for instance:

node.inputs[0].default_value = (0,0,0,1)
node.inputs[1].default_value = (1,1,1,1)

An easy way to identify Python accesses is to use the tooltips:

To connect texture node output for blend node first input:

import bpy

tree = bpy.data.textures['Texture'].node_tree

texture_node = tree.nodes['Texture']

blend_node = tree.nodes['Blend']

tree.links.new( texture_node.outputs[0], blend_node.inputs[0] )


Volumetric light rendering a hard cut-off in the scatter rays I'm using Cycles in Blender 2.79

I have got a volume scatter material set up on a cube (0.2 density ) and a spot lamp (20000 intensity) above the volume (though I have the same problem if it's within the volume too) I'm getting a weird hard cut-off in the volumetric lighting and neither moving the lamp nor changing the intensity of the lamp changes where that hard cut-off is.

The only thing that seems to change the height of the cut-off is moving the volume itself and it doesn't move by an equal amount. Any ideas what my trouble might be?

I figured out that the hard line is the edge of the volume out of camera clipping range. If I reduce the size of the volume then it renders correctly

Volume within camera clipping

Volume larger than camera clipping

I guess this is just how Blender works?

The problem was the camera clipping distance was less than the size of the volume.
By reducing the size of the volume so that the far side of the volume is within camera clipping distance the artifact (mostly disappeared)

A second problem I then had was the top of the volume I had given a surface shader (and a separate material) which caused lesser artifacts on top of any objects. Removing the surface shader fixed this.


Blender not loading properly I have installed Blender 2.76b in my computer. But when I open blender, it does not load fully and only icons are visible. This is how it looks:

I have installed Unity 5 in my system and that is working fine.
Can anyone give a solution to this problem?

Thanks in advance.

This is commonly because you installed Blender as one user (administrator) and are running it as a different user.

From http://blenderartists.org/forum/showthread.php?196976-My-Blender-2-5-Interface-is-Mostly-Empty

  Happens when you run Blender as a different user as who installed it (Windows).
  Reason: The blender folder in User-Folder / Appdata /Roaming is required but only there for the user who installed it
  Workaround: Always run Blender as the primary user (Run as Administrator) or: Copy the Blender Foundation folder from Appdata/Roaming of the primary user to your account's folder.

So, Blender doesn't have access to some of the folders it needs because they are on another user's account. This could also apply to some Python scripts. If Python was installed by another user, you might not have access to it on your account.

Hope that helps!


World background is not being rendered I cannot seem to render the world background even though I have set the transparency and the alpha channel.

How can I solve this?

I have uploaded a blend file:

By checking the Transparent checkbox you effectively make the world background invisible. If you want to have the background visible in the render it must be unchecked.


How to create inward curve with edge crease? I build the hull and use a subdivision surface modifier.
I know that if I want to sharpen an angle on the outside, to use Shift + E.
But how can I sharpen that angle so that is inward?
As you can see in the picture, there is a curve. I have tried but can't find a solution.
I would like to remove the curve in the picture and turn it into an angle.
I am grateful if anyone can tell me how to do it!

This face is an N-Gon which notoriously doesn't bode well with subdivision surface, and it is concave, meaning there is an interior angle > 180°, which also can create artifacts.
By joining the 2 vertices with J or Vertex > Connect Vertex Path and increasing the crease on the new edge, you will be able to make the subdivided mesh adhere more to the base mesh.

Although you now have a triangle to get rid of, but this is another topic :)


Play midi alongside animation my goal is to play exact midi note in a certain frame, so i thought the only way is to use a midi in/out python library, and execute a certain python command line or script in the required keyframe, so from here my question becomes: is there any way to keyframe a python script?
of course if there are any other easier ways for my goal, it would be better

I don't know if you can do that, but you shouldn't need to. Try simply exporting the MIDI to a sound file, and using the Video Sequence Editor (I think) to align it with your animation.


BMesh: Accessing edges of created mesh Let’s say I created a bunch of these cones in my_bmesh object:

c = bmesh.ops.create_cone(my_bmesh, segments=8, diameter1=1, diameter2=1, cap_ends=True)

Is there a way to access a cone’s edges (preferably right after I create it) so I could connect it with other cones using bridge edge loops?

Solved it:

(prev_edges -> edges from previous cone)
c = bmesh.ops.create_cone(my_bmesh)
verts = list(c.values())[0]
curr_edges = verts[0].link_faces[0].edges
total_edges = [e for e in prev_edges] + [e for e in curr_edges]
bmesh.ops.bridge_loops(my_bmesh, edges=total_edges)
prev_edges = verts[-1].link_faces[0].edges


Transparency only rendering on one side? So for context I'm using Cycles Render. As you can see in the image below, when I go to render my transparent cube it renders as transparent on one side and then the other sides are left a solid color. I thought it was a lighting issue so I added multiple light sources, specifically to that side but no luck. Any help would be greatly appreciated!

Try turning up your transparency bounces.


Reliable way to find out the required context for an operator? Seems that this question was asked before but was not answered.

I already found this answer, where it was suggested that if you send an empty dictionary as override, it's supposed to show you what context elements are required to run the operator.

But this didn't work for the operator I'm interested in:

bpy.ops.cycles.use_shading_nodes({})

Traceback (most recent call last):
  File "<blender_console>", line 1, in <module>
  File "C:\Program Files\Blender Foundation\Blender\2.74\scripts\modules\bpy\ops.py", line 187, in __call__
    ret = op_call(self.idname_py(), C_dict, kw, C_exec, C_undo)
RuntimeError: Operator bpy.ops.mesh.select_all.poll() failed, context is incorrect

So my question is, is there a reliable way to find out what the required context is for an operator? (The docs are no help here. Source might be, but I'd rather avoid that search for a needle in a haystack unless I'm really desperate...)

Asking for a way to find the context for all possible operators that need such an override is at the same time ignoring all the responses to people looking for their specific override for their needs.

As is often the case with 'context is incorrect', there is a solution that's much simpler and (more) logical than the potential workaround using context overrides. While most operators can take an override context, you will invariably (if you dig deep enough) find several that can't. You will also find operators which are the only way to achieve some goal.

For all other cases where there's a better way to do it without the operator in question, you simply use the lower level bpy code. Ask, we will always give an answer, or dig using the Info console and track the changes in bpy.data to see what got added and which parameters are adjusted after a manual Operator invoke (ie you click a button, and that calls the operator in question).

(Sometimes a context override is the only way, but not this time)

Make a new world material.

>>> m = bpy.data.worlds.new('amazon')
>>> m.use_nodes = True
>>> m.node_tree
bpy.data.node_groups['Shader Nodetree']

>>> m.node_tree.nodes['Background'].color
Color((0.608, 0.608, 0.608))

# setting current scene world
>>> bpy.context.scene.world = bpy.data.worlds['amazon']


What is the ideal topology for a shoulder joint? Modeling the shoulder joint of humanoid models is often a sticking point for me, due to the many degrees of freedom a shoulder has, and when rigged, my shoulders often pinch badly. What sort of edge loops and placement is best for that complex joint? Or is this more of a rigging/skinning issue than a modeling issue?

The key with shoulder topology is to represent the deltoid muscle well and to separate the arm mesh from the body. The exact topology will depend on your subject. Most of the time every model will have slightly different topology.

For example, a muscular male will need far more dense and defined topology than a slim female.

The general rule of thumb with topology is to follow the muscle flow. Here is a front, side,, back, and top view of a fairly typical shoulder topology layout.

Things to notice:

The vertical face loop roughly follows the inside and top edge of the deltoid, on both front and back.
The horizontal loop is placed roughly where the deltoid, bicep, and triceps meet.


Add a color input and output to OSL shader I'm trying to wrap my head around making shaders but I have no real coding experience. I've tried looking for a solution to my problem but I haven't found anything. Maybe I'm not phrasing it right? The problem is this:
I have a script that looks like this, which takes a texture with values in a certain range and then changes the range of the values while keeping their relative positions.

shader Exp_Shader(
    float tex = 0,
    float OldMax = 1,
    float OldMin = 0,
    float NewMax = 1,
    float NewMin = 0,
    output float Result = 0,
)
{
    Result = (((tex - OldMin)*(NewMax-NewMin))/(OldMax-OldMin)) + NewMin;
}

The problem is, that this works on greyscale textures but not on color. How can I add a color input and output to make this work?

In OSL, you can use color as type of parameter. For example see here your script. I changed the tex parameter and the Result parameter

shader Exp_Shader(
    color tex = 0,
    float OldMax = 1,
    float OldMin = 0,
    float NewMax = 1,
    float NewMin = 0,
    output color Result = 0,
)
{
    Result = (((tex - OldMin)*(NewMax-NewMin))/(OldMax-OldMin)) + NewMin;
}

After doing this and pressing the refresh button the Script node will look like this:

Hope this answers your question.


Single track with bundle should be selected to define axis I keep getting this error when I select a point and another one to set X or Y axis when tracking.
I DO have my camera solved I tried a few tutorials and I don't think I'm missing any step, yet I can't set up my axis. What's going on? Any ideas? It's been showing up on two different clips now.

Longwinded and rambling answer:
The scene has to be solved first.
Then the slected tracker has to be part of the ones used for solving the scene.
A bundled track is one that has a reprojected point.

Bundles makes sense after solving the movie clip, and it works in the following way: the solved position of each track gets projected back to the movie clip and displayed as a small point. The color of the point depends on the distance between the projected coordinate and the original coordinate: if they are close enough, the point is green, otherwise it'll be red. This helps to find tracks which weren't solved nicely and need to be tweaked.

(What does "three tracks with bundles are needed to orient the floor" mean?)
Reprojected points can be viewed as an overlay by enabling Marker Display > 3D markers

A green reprojection dot means that the tracker and reprojection have an acceptable error, a red dot means that the error is too high.

So to set an axis or origin or scale use a tracking point with a green dot.
Then the origin has to be set. To do that then you select a single tracker and that will be the 0, 0, 0 coordinate for the reconstructed scene.
Once you have the origin. Select a second tracker that is in the direction of the axis you want to determine. Then Click on the Set Axis option. The axis is thus determined using the selected tracker and the origin.

Note that you can bypass all of this steps ans manually orient and scale the scene any time you want later.
read: Correct tracked camera orientation


Render with same output as "solid" viewport I'd like to know how I could render a picture that looks the same as what I get in the main viewport (the "solid" view). I tried to play with "Shadeless" and "Toon" color, but I'm not convinced by the result. Indeed, "shadeless" renders the 3 faces with the exact same color, while I'd like to make a difference between faces (like in the solid viewport).

How could I do that? Thanks!

-- EDIT --
I saw this question that proposes to use the "OpenGL render active viewport" in the 3D View window header at the bottom , and it's quite a good idea. However, I'd like to know if I can go further and customize a bit this render (because for now I've zero choice on the render), plug it in composing nodes, customize the background... For instance, with the current method it's not possible to have complex materials with pictures, gradient… And also the background can't be set to transparent. One of the possible applications would be to do something like the picture page 4 of this article for example.

Not a complete solution, but perhaps a hint: in the 3d "solid" viewport there's a default (hidden) lighting that heavily influences how the scene is rendered by opengl. The user preferences have settings about diffuse/specular colors and direction for 3 lights, and you can also edit them interactively:

So, you could try a lighting setup that acts in the same or similar way, to render it, perhaps: the position of those lights is not accessible, though through the blender user interface (it could be possible to read those light position/direction through python, perhaps, but I'm not sure at all)


Why does the water becomes gray when I move the viewport? From above works properly

When I move the visual down, it appears gray even in the render

Until it appears all grey

The plane fills the pool entirely, maybe there's some problem with FOV or something like?

It looks like you have your Normals pointing in the wrong direction. Check your normals and ensure they are pointing ‘out’ of the water.
With the normals pointing into the body of water it will be rendering as if the fluid is outside a cavity of air. What you’re seeing is Total Internal Reflection as the light is refracted at the surface - the wrong way to what you’re expecting.


Why is my cloud explosion white? Please find the blend file attached.  I've been looking at tutorials for making cloud explosions (regular explosions are something I'm also using in the project, but I want the specific look of the explosive cloud).  No matter what I do it renders white rather than the "gray with sullen red glow" look that the tutorials say the Explosion option for the Cloud Generator is supposed to produce.  There is a light in the scene.  What am I doing wrong?

Later edit:

thanks for your response!

So it's just not possible to get this:

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

Or is that a result of directional lighting plus a change in scatter color? Doing what he did definitely didn't give me his result.  His looks like there's only light coming from deep inside the cloud, not all over it.

If anyone else ends up having the same question, I never did get the effect I wanted with this, so I ended up instead going with a more complex three-mesh setup using quick smoke: a domain, a smoke mesh, a flames mesh, and a flame particles mesh, where the flames and particles meshes fit inside the smoke cloud mesh and were slightly different in shape to get that irregular flames-inside-smoke look I wanted.  This is reliable enough when the meshes are hires enough to sculpt, which also adds a look of more detail to the billows of smoke. It means the cloud shape is more artificial than generated, but it does give the level of control I wanted for the specific application I needed it for.

I'll attach that blend file too, in case anyone searches the question and is equally confused/frustrated with their attempts.

As You could see on the picture below, the Scatter Color value (green circle) is the point of your interest. Changing this values leads to different cloud scatter colour. Please keep in mind that scatter colour settings is reversed so if You want a red clouds You have to lower the red value.

(values used on the image: R=0.55, G=0.62, B=0,65)

Hope it helps You, Buddy.


Is a camera required for animation in blender 2.83? Do I need to add a camera to create animations?
Currently I have no camera.
If I don't need one, how is the character viewed later?

As long as you don't need to render (image or animation) you don't need any camera. If you need to render, of course you need a camera, Blender can't guess what point of view it is supposed to render.


Blender - How can I create proper lighting using Radeon ProRender? Is there anyone that could tell me or point me in the right direction on how can I use/create proper lighting with Radeon ProRender.

I want to create objects that will be emissive/emission ,I'm kinda not sure how to do it properly ,so again I am asking for some helping hand

I guess you should refer to Radeon ProRender user guide, for a start...

The RPR EMISSIVE material should be what you are looking for...

To get RBR support, I suggest to refer to the specific RBR for Blender support page


Bendy Bone: Ends of mesh doesn't curve The bendy bone is connected by automatic weights but the end of the mesh doesn't curve with the rest of the mesh.

By default all bones will deform the mesh.

The simplest way is probably to unparent the mesh, uncheck "deform" in the bone properties for the handle bone and parent it again with automatic weights.

You could also remove the weight for this bone manually with weight-painting.


Weight Rigging Different for Mesh Thank you in advance to anyone who assists me with this, I have been stuck on this problem for two days now. I have the same bone armature along with identical hand meshes, one just mirrored. When I automatically weight the objects the left hand works perfectly while the right hand is attached to multiple fingers.
I tried searching for ways to fix this without manually weighing every finger as its very tedious, unfortunately I couldn't find a post with a way to fix this.
Left Hand that is working correctly:
[ https://gyazo.com/4b0aa45edfefcf9a3d083ab616887887 ]
Right Hand, which is copy, pasted and mirrored to the correct direction:
[ https://gyazo.com/ec044e1b62b559bcd2f65a68759bc04a ]
Here are the weights. Once again, an exact copy and paste. Yet automatic weight caught different sections of the hand.
Left Hand

Right Hand

Thank you to Nathan for mentioning normals. [ https://blender.stackexchange.com/users/24636/nathan ]
For anyone who may have this problem, you select your mesh and recalculate inside normals.
I used this video for reference [ https://www.youtube.com/watch?v=clzstqtN6YQ ]