Filling regions of a texture before projecting
Hello everyone,
I'm trying to project a single texture using two different materials for extracting portions of the image. For example, let's say I have a texture with two left to right squares of blue and orange colors, respectively.
Let's also say I have two different 3D objects and I want to project the left portion on the first 3D object, and the right portion on the second 3D object. In order to do so, I create two materials, MA and MB with the following settings:
MA: Tiling (0.5, 1) Offset: (0, 0) MB: Tiling (0.5, 1) Offset: (0.5, 0)
This results in the following division:
So the red frame contains the area to be projected on the first 3D object using material MA, and the green frame contains the area to be projected on the second 3D object using material MB.
This is working nicely so far. What I'm intending to do now is to add a black region to each side of these blue and orange regions without having to change the image texture at all. The analogous result to previous image would be the following:
This means that not only the blue area will be projected on the first 3D object, but also the black region. The same thing would happen to the orange area.
Is there any way to do this without changing the texture image?
Thanks in advance.
You could create new Texture2Ds and copy your existing images. Then draw on the copies and use them until you need the originals again.
Thanks for your reply! The problem is that the texture is being loaded from a video using Easy$$anonymous$$ovieTexture. Even if I could modify them that would have a bad impact on performance. I was thinking more about doing it with a custom shader or something similar. Any ideas?