Materials – Rust / Kiss3d: How do I color a mesh in Kiss3d? (Code sample request)

This is a question about the sebcrozet / kiss3d graphics engine for the Rust programming language. I managed to create a network with group.add_mesh(). Now I want to color my mesh with a specific color for each vertex (or face). Does anyone know how I do it?

A possible approach seems to be to define a RgbImage Turn that into all of my different colors somewhere in the picture DynamicImage, turn that into one TextureLink the texture to the mesh somehow, set up a UV map, and set the UV position for each vertex to be associated with the corresponding color.

The documentation is not detailed enough or gives no concrete example. Does anyone have a sample code that works?

Automatic assignment of materials when importing FBX from Blender to Unreal

I have a model in Blender and have assigned placeholder materials to its faces. I can export it from Blender to FBX and import it into Unreal Editor. After importing the mesh, I can manually assign unreal materials to it in the Unreal Editor.

Is there a way to do this automatically? I tried to name my materials in Blender the same as in Unreal, but it didn't seem to work.

Unity: Under iOS, materials with normal cards look completely wrong

We are creating an AR-enabled app with Vuforia and Unity 2019.3 using the Universal Render Pipeline.
The problem is that our models on iOS, whose materials contain normal maps, look completely bad, as you can see. Image of bad graphics

When we remove the normal cards, the models look good, but since the normal cards add a lot of detail and depth to the scene, we'd rather not drop them.
We tried to change the normal map import settings, compression formats, etc., but it didn't make any difference.

Is there any other solution to fix this?

By the way, there is no problem on Android.

Soundproofing materials

Our acoustic sound-absorbing ceilings are used for high-quality sound and external sound insulation. This product structure consists of a flexible MLV barrier with anti-UV PVC and glass fiber fabric on both surfaces. The middle is the quilted sound absorption. The main application in chain link fences, the construction site barrier, the noise barrier, etc.
Acoustic Barrier Fencing
Finish MaterialPVC & fiberglass fabric
Inner material sound absorption + sound absorbing felt
Size 1000 * 2000 mm or customized
Color green, gray, black, blue etc.
Weight5-7kgs / sqm
Design rhombus, vertical line, square
Insulation coefficient 17-27DB
design
Project case soundproof materials
Website: http: //www.goodsoundproof.com/soundproofing-material/

Group Theory – Using Mathematica to prove that isotropic materials have only two independent parameters

You can find contributions on related topics here or here.


Index symmetries:

A stiffness tensor $ C $ is a fourth order tensor with components $ c_ {ijkl} $ which maps symmetrical second order tensors into symmetrical second order tensors, i.e. $ sigma_ {ij} = c_ {ijkl} varepsilon_ {kl} $ (linear elastic law), $ sigma $ (Stress) and $ varepsilon $ (Elongation) are any symmetrical second order tensors. Because of the symmetry of the second order tensors $ C $ may be slightly symmetrical, i.e. $ c_ {ijkl} = c_ {jikl} = c_ {ijlk} $. The not insignificant symmetrical part of $ C $ is irrelevant to the elastic law and is dropped. When the stress $ sigma $ is related to an elastic energy potential $ W $ (referred to as hyperelastic behavior), i.e. $ sigma = partial W / partial varepsilon $then, due to Black's theorem, the stiffness tensor $ c_ {ijkl} = partially ^ 2 W / partially varepsilon_ {ij} partially varepsilon_ {kl} $ must have the main symmetry, i.e. $ c_ {ijkl} = c_ {klij} $.

Material symmetry:

A material with stiffness $ C $ should have the material symmetry group $ G $ (e.g. triclinic, orthotropic, transverse isotropic, …) if

begin {equation}
C = Q star C qquad Q in G.
end {equation}

stops where $ Q $ are second order tensors, which are called symmetry transformations of $ C $. The product $ has {C} = Q star C $ (referred to here as the Rayleigh product) is defined in components as

begin {equation}
hat {c} _ {ijkl}
= Q_ {im} Q_ {jn} Q_ {ko} Q_ {lp} c_ {mnop}
end {equation}

For solids, $ G $ is a subset of the orthogonal group. In solid-state mechanics, it is sufficient to take rotation matrices into account $ Q $ from the rotation group $ SO (3) $. If $ G = {I } $, $ I $ so be the identity matrix $ C $ should be triclinic. If $ G $ has more than the identity transformation, then different material classes can be defined (different anisotropy types). If $ G = SO (3) $, the $ C $ should be isotropic (no directional dependence).


I want to use Mathematica to get the number of independent parameters that the fourth order tensor needs $ C = Q asterisk C (Q in SO (3)) $ under the rotation of the group $ SO (3) $.

Currently, I can only get 30 independent variables using the following method:

SymmetrizedIndependentComponents({3, 3, 3, 3}, 
  Symmetric({1, 2, 3})) // Length

I still can't use the group's rotation $ S0 (3) $ to further reduce the number of independent variables. What should I do?

4 go-to apps for revision and exam preparation

After so many weeks of writing essays, reports, homework and other academic assignments, it is high time to start revising for exams. This time of student life is really difficult, especially for those who weren't serious enough about classroom activities. Students who did not take notes during the lectures have great problems preparing for the exams. As a rule, her memory is not sharp enough to take into account all the details that her professor said. The learners have big problems before their exams. You need to spend long hours in libraries reading a stack of sources and doing thorough research. Wouldn't you like to be one of those students who have their hands full? Benefit from the most popular academic help apps that make revision more effective and stress-free. Download them to your phone and revise them like a pro for college exams.
Study blue
If you're a fan of flash cards, consider a Study Blue study application. It's a free app that you can use to download it to your device and get help quickly from the crowdsourcing materials library. This app can be used to create and share flash cards, to add audio and visual material to your learning materials, to test the subject's knowledge, who is testing and making progress. After downloading this app, you will have access to an impressive library of study materials and helpful guides created by students.

Speedy Paper consultant
Another useful application for all students is SpeedyPaper Adviser. This writing app helps you improve your grades and prepare you for exams more effectively. When you have SpeedyPaper Adviser on your phone, you have unlimited access to the huge database of college and university newspapers. You can see examples of various academic tasks. Find necessary essays, reports, research papers, coursework and improve your grades. Students know how to create, structure and cite tasks. Customer support is available around the clock. So if you have trouble finding a paper you need, you can contact the managers and ask all your questions. Numerous positive reviews of this app prove that it is really great and worth trying. To get to know all the functions, download an app on your mobile phone or visit their website.

Gojimo
This application was created to allow students a smooth revision. Students can use Gojimo both online and on mobile devices. An app contains helpful content for learners and some quiz questions. You can choose an exam for which you want to review, and it includes a list of questions you may be asked. If you haven't found a required topic, you can contact support via instant messaging.

Quizlet
It is another helpful application for students preparing for exams. It's free, easy to use, and a great choice for self-study. If you have Quizlet on your device, you can use flash cards to learn, share with your colleagues, learn foreign languages, and learn more about coding, math, science, history, and other college subjects. Many students benefit from Quizlet and leave their positive reviews for this study app.

Unit – Do you automatically assign 100 materials from different shaders with their respective 2D textures to a shader?

Is there an editor script that can be used to assign all materials to a shader, including copying the texture? I found an editor script that changes the shader but doesn't copy its texture. How can I achieve this?

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;


public class MAT_Change : MonoBehaviour
{
    (MenuItem("Editor/Material/Change Shader to ShaderTest"))
    static void Change1()
    {
        Shader newshader = Shader.Find("Custom/ShaderTest" );
        ChangeShaders(newshader);
    }


    static Object() GetSelectedMaterials()
    {
        return Selection.GetFiltered(typeof(Material), SelectionMode.DeepAssets);
    }


      static void ChangeShaders(Shader newShader)
   {
      int counter = 0;
       if (Selection.objects.Length > 0)
        {
            Object() materiales = GetSelectedMaterials();
            if (materiales.Length > 0)
            {
                foreach( Material mat in materiales )
                {  
                    mat.shader = newShader;
                    counter++;
                }

            }
        }
      EditorUtility.DisplayDialog( "Message", "materials changed: " + counter, "OK" );
   }
}

MeshBatcher for XNA always materials wrong

I'm trying to write a mesh batch for XNA.

In the test scenario, I use 3 network entries and 2 materials. However, only the last material is drawn.

sealed class MeshBatch
{
    private readonly List> items;
    GraphicsDevice GraphicsDevice { get; }
    private VertexPositionNormalTexture() vertexArray = { };

    private int() triangles = { };

    public MeshBatch(GraphicsDevice device)
    {
        items = new List>();
        GraphicsDevice = device;
    }

    private void EnsureCapacity(int vertexCount, int triangleCount)
    {
        vertexArray = 
            new VertexPositionNormalTexture(vertexCount);
        triangles = new int(triangleCount);
    }

    public void Draw(Mesh.MeshEntry entry, Material mat)
    {
        items.Add(new KeyValuePair(entry, mat));
    }

    public void Draw(GraphicsDevice device)
    {
        if (items.Count == 0)
            return;

        int itemCount = items.Count;
        int vertexCount = 0, triangleCount = 0;

        for (int i = 0; i < itemCount; i++)
        {
            Mesh.MeshEntry item = items(i).Key;
            vertexCount += item.renderBuffer.Length;
            triangleCount += item.indices.Length;
        }

        EnsureCapacity(vertexCount, triangleCount);

        vertexCount = 0;
        triangleCount = 0;
        Material lastMat = null;
        bool flushed = false;
        for (int i = 0; i < itemCount; i++)
        {
            Mesh.MeshEntry item = items(i).Key;
            Material mat = items(i).Value;
            int itemBufferCount = item.renderBuffer.Length;

            if (lastMat != mat ||
                vertexCount + itemBufferCount > short.MaxValue)
            {
                flushed = true;
                Flush(lastMat);
                vertexCount = 0;
                triangleCount = 0;
                lastMat = mat;
                Array.Clear(vertexArray, 0, vertexArray.Length);
                Array.Clear(triangles, 0, triangles.Length);
            }

            for (int ii = 0, t = triangleCount;
                ii < item.indices.Length;
                ii++, t++)
                triangles(t) = (item.indices(ii) + vertexCount);
            triangleCount += item.indices.Length;

            for (int ii = 0, t = vertexCount;
                ii < itemBufferCount;
                ii++, t++)
                vertexArray(t) = (item.renderBuffer(ii));
            vertexCount += itemBufferCount;
            if (!flushed && i == items.Count - 1)
                Flush(mat);
            flushed = false;
        }

        items.Clear();
    }

    private void Flush(Material mat)
    {

        if (vertexArray.Length == 0 || mat == null) 
            return;

        foreach (EffectPass pass in mat.Effect.CurrentTechnique.Passes)
        {
            pass.Apply();
            GraphicsDevice.DrawUserIndexedPrimitives(
                PrimitiveType.TriangleList,
                vertexArray, 0, vertexArray.Length,
                triangles, 0, triangles.Length / 3,
                VertexPositionNormalTexture.VertexDeclaration);
        }
    }
}

Any help is appreciated.

Animated Unity materials will not be previewed

I am looking for help because I have just dealt with this topic Unit 2019.2.8f1 and I do not know how to fix it (if possible).

I should mention that I have updated this project from Unity 2019.1.0f2 and in this version the animated material preview worked flawlessly. Instead, the material in Playmode works as expected, but is not animated at all outside. The animation will only start when the editor window is refreshed, d. H. When I make changes in some editor windows.

If you're wondering, you've enabled "Animated Materials" in the Sceneline, so that's not the problem.

I hope someone knows a solution to this problem. If it does not exist, thank you anyway for your time 🙂

Unity 3D – materials are stretched and tiles do not help

I am a programmer and work with Unity 3D, version 2018.4.6f1 for this class. I wanted to add some materials to my wall, but this results in a pretty ugly result, as my walls are different in size.

Notice the brown walls.

This also happens with actual textures.

Notice the red lava.

However, editing their "tiles" as suggested does not lead to something pretty, given the size of the objects. (In the example shown, both tiles are x: 3 and y: 4.) I also can not edit the individual tiles for each object.

The tiles are x: 3 and y: 4. Note the lava and wood.

How can I fix this and make everything look good? Of course, I do not want to create a gazillion with the same texture / material so I can tile it differently for each object.