Search the Community
Showing results for tags 'decals'.
-
Hey there, I am working on a scene right now and wanted to place a few Manholes with decals and noticed that the Ambient Occulsion from the texture below the decal is still visible. With Ambient Occlusion: Without Ambient Occlusion I tried changing blending modes, rendering order, mask settings, visibility settings an so on and couldnt find a way to fix the problem except for turning of the AO texture in the Pavement Material. Is this a bug or is there a option that I am missing?
-
Hello, Is there a way to use decals through the C++ API? The samples that use UnigineScript look perfect for my needs, but I need these to be loaded/generated dynamically. A little more context: I'm building an interface specifically for real-time decaling. I'd like to be able to load a model (e.g. fbx), load an image/video texture, and then interactively place the texture on the mesh. Thanks for your help! Kevin
-
Is there a way to update decals in .node files using Generate Decals utility? It looks like it finds decals only in .world file. We had to re-generate all decals after we applied an engine update (unigine-sdk-2011-07-21). Many decals were not found. We are getting a lot of these messages: "Decal::loadWorld(): can't load ObjectDecal"
-
Hi guys, I am new to unigine and this forum, sorry if I am duplicating topic. I am working on selection decals ( selection ring around unit(s)/structure while they are selected ). What I want is to create lots of decals from one base material with different ( random ) colors using "color_scale" parameter to distinguish each of them. I mean unit selection ring according to player color. This is what I did till now but it's not working : strMaterial is base material. string strMaterialWithColor = format("%s, %.2f, %0.2f, %0.2f, %0.2f", strMaterial, vColorModifier.x, vColorModifier.y, vColorModifier.z, vColorModifier.w); int idLibrary = engine.materials.findLibrary("world1.mat"); if(idLibrary == 0) { idLibrary = engine.materials.addWorldLibrary("world1.mat"); } if(idLibrary == 0) { strMaterialWithColor = strMaterial; } if(idLibrary != 0 && engine.materials.findLibraryMaterial(idLibrary, strMaterialWithColor) == -1) { int idMaterial = engine.materials.cloneMaterial(strMaterial, "world1.mat", strMaterialWithColor); Material mat = engine.materials.getMaterial("world1.mat", idMaterial); mat.setParameter("color_scale", vColorModifier); } else { strMaterialWithColor = strMaterial; } DecalOrtho decal = new DecalOrtho(vPos.z + DECAL_PROJECTOR_OFFSET, 2, 2, strMaterialWithColor ); Please help me.