Unity 3D Image ending points - unity3d

I'm trying to make a 3D tour for cardboard. I'm putting my 3d image inside a sphere with a shader but I've noticed this problem. The ending point of image is very visible and disturbing.
And middle of the image is looking kinda wavey and distorted.

Just use a seamless texture or make one with Photoshop. for more info search seamless textures in google.

Related

I want to apply textures to face using the augmented faces example in arcore for unity

At Google I/O'19 for Augmenting Faces and Images, they said about reference_face_texture.PNG for painting or apply texture to specific areas in a face for example lips, cheeks etc. but i am unable to find this reference face texture, so that i can use it in Photoshop to apply textures to exact area i want to apply, and then apply the new created texture using the face tracker in augmented-faces arcore. Can somebody please highlight it. Thank you.
i did tried downloading facial mesh images from online, but it is not perfect match after applying the textures to mesh image.
I could not find reference_face_texture as well, but you can open a reference 3D model and make a UV texture. To save you time: here is the texture

unity3d: Adding half-transparent video with shadows

I'm struggling with an issue that might seem a little bit awkward.
I have some black & white 2d animation (1440x1080px) that I'd like to be played in in a 3d environment in unity3d. Therefor I added a video player to a plane. Now comes the tricky part: I want to make the black areas of the video transparent while the white areas remain visible AND the white areas shall cast shadows on the surrounding. Using the particles shader "additive" does half of the job. But I just can't manage to let the video cast a shadow.
If it worked you would get some 2d "antagonist" (you can't interact with) that looks kind of 3d. Alternatively you could interprete it as some half materialzed holograph that casts shadows.
Is there any (simple) solution I just don't know?
Here some schematic drawing of what I would like to achieve, for better understanding.
The problem right now is: In contrast to my drawing, the desired shadow on the wall doesn't appear... :-/
So, I did never try this but you can maybe add a light in the scene just in front of the video player, that way the light will cast shadows.

Implement Zoom(using UI Canvas) in Unity 2d game

I want to implement as showed in the below image in 2D game, I can find so many tutorials for 3D like mini map concept but for 2D i couldn't find anything. In my game i want to show a secondary
camera as in below image and also i need to zoom the content that will show through it. I developed one concept but it can be done with sprites or with Canvas in World Space mode. So you can see
they won't resize or positioned according to the screen resolution. If you guys have any idea how to do this task,it will be very helpful for me. And i also tried with depth mask shader .Thanks in advance.
Use a camera with target texture
Follow my tutorial here: Particles with Dynamic Text but disregard the parts about the particle system, they are irrelevant for you.
Once you've made a material, stop following the tutorial, and instead:
Create a sprite renderer on a canvas that is "Screen Space - Overlay" and set the material to be the one that you created.

How to achieve Terraria/Starbound 2d lighting?

I am making a 2d game in the perspective of Terraria/Starbound. I want the lighting to look similar to this:
Ive tried to get lighting like this by adding a material on all the sprites in my game and then giving them a sprite diffuse shader. Then I made a point light wherever I needed light. There where two problems with this though: 1) Where the light was most intense, it was draining the color of a sprite and made it lighter. 2) I noticed a big FPS drop (And I only had 1 point light!).
Is there any way of achieving lighting like this without having to write my own lighting engine? Ive search the asset store and Ive searched to see if unity has any way of handing 2D lighting from this angle but I have found nothing.
If I do have to write my own lighting engine, would that be to complex for someone who is relatively new to unity and has only had ~ 8 months experience?
Assume you are using tile map.
You need to have a field of view map, which can be achieved by reading this: http://www.redblobgames.com/articles/visibility/
Using such map, you know exactly the color tinting for each tile. Now, just blend the color to the SpriteRenderer of every tile on the map.
Somebody already created a line of sight plugin:
http://forum.unity3d.com/threads/light-of-sight-2d-dynamic-lighting-open-source.295968/
Here's my hacky solution on GitHub
There's 2 cameras.
Empty tiles on the tilemap are filled in with white blocks (only one camera renders this)
A gaussian blur is applied to the camera rendering the white blocks
Then, blend the two cameras, darkening everything not covered by the white blur.
You can adjust the "light" penetration by changing the white tile's sprite's Pixels Per Unit.

Creating cleaning effect in unity3d

I'm trying to build some simple game(learning) where you will have to clean objects.
That means for example you have a monitor with dust on it so you can't see the image. You then uses mouse or finger to move arround monitor to make image visible.
So what I've got so far is 2 images first being the monitor image and second being the dust before it. I've managed to realize when user swipped all image down. But what would I like to do is when user tap the screen somewhere only in that radius r the front image disappears.
I'm guessing I should be using layer mask, but I have no idea how to do it.
I basicly managed to write my own shader that only shows layer with correct image but no idea how to do that you can accualy get some cool effect from it.
Any ideas will be apriciated!
I would use render texture for this. It allows you to use image files as a brush. And it's quite fast. The idea is to use render texture as a mask. You start with black texture. Whenever player touches the screen you render your brush image to this texture. But this feature (render textures) is available only in Unity Pro.
You can still use texture as a mask if you don't want to buy Unity Pro. But this will be definitely slower than render textures. How much slower I don't know. The options are:
Create ordinary texture (Texture2D) and use SetPixel or SetPixels to update mask when player touches the screen. If you want to go this way, I would recommend to use much smaller texture than the screen size (4x, 8x depends on the quality you want to get). Otherwise it will be damn slow.
Create ordinary texture (Texture2D) and use ReadPixels. This works pretty much the same way as render textures but it's slower. This technique is explained here.
Using render texture (requires Unity Pro)
Ok. I've made an example: https://drive.google.com/folderview?id=0B60e_iFEZd1-RlB4LVN6NE84clU&usp=sharing
There are:
Image that player needs to clear from dust: Image.jpg
Image of dust that we draw on top of it: Dust.png
Image that we use as an erasing brush: Brush.png
Our render texture that we use as mask for dust: Mask.renderTexture
Shader that we use to update the mask: MaskConstruction.shader
Shader that we use to render dust (it combines Dust.png and render texture): Masked.shader
Script that brings everything to life: MaskCamera.cs
Main scene: Main.unity
I think this might be helpful. The Main objective of this Code sample is to create a dust/fog removing effect using Unity. Using, Texture Masking shader, Mask Construction Shader, Render Texture, Camera Masking Script and masking camera, you can create your own effect. Read on to know how and download the source code. It’s free!!
http://studio.openxcell.com/remove-dustfog-object-unity-swipe.html