Messing with vertices/tesselation seems rather overkill to me. I'd animate the UV's ever so slightly instead, perhaps by scrolling a monochrome displacement texture across the bubble and using the values to offset the UV values for the fragments.
Here's something I threw together quickly:
I assumed you wanted this to be a UI sprite, so my material/shader has been written with that assumption in mind. The inspector for the material looks like this:
It is then applied to the UI image like so:
Make sure the bubble sprite has an edge of transparent pixels or the edges will look weird. Here's the bubble and the displacement map (scaled down in the BBCode but at full size if you save them):
The first is set to a sprite and the latter is left as a regular texture and dragged to the material. The sprite's wrap mode is clamp and the displacement map's is repeat. My displacement map is just tiling difference clouds i generated in GIMP.
Finally, the shader:
Shader "Custom/UI/Bubble"
{
Properties
{
_MainTex ("Texture", 2D) = "white" {}
_DispTex ("Displacement", 2D) = "white" {}
_Speed ("Speed", Float) = 0.5
_Intensity ("Intensity", Float) = 0.025
}
SubShader
{
Tags
{
"RenderType" = "Transparent"
"Queue" = "Transparent"
}
Pass
{
ZWrite Off
Blend SrcAlpha OneMinusSrcAlpha
CGPROGRAM
#pragma vertex vert
#pragma fragment frag
#include "UnityCG.cginc"
struct appdata
{
float4 vertex : POSITION;
float2 uv : TEXCOORD0;
fixed4 vertexColor : COLOR;
};
struct v2f
{
float2 uv1 : TEXCOORD0;
float2 uv2 : TEXCOORD1;
float4 vertex : SV_POSITION;
fixed4 col : COLOR;
};
sampler2D _MainTex;
sampler2D _DispTex;
float4 _MainTex_ST;
float4 _DispTex_ST;
float _Speed;
float _Intensity;
v2f vert (appdata v)
{
v2f o;
o.vertex = UnityObjectToClipPos(v.vertex);
o.uv1 = TRANSFORM_TEX(v.uv, _DispTex);
o.uv2 = TRANSFORM_TEX(v.uv, _MainTex);
o.col = v.vertexColor;
return o;
}
fixed4 frag (v2f i) : SV_Target
{
float t = _Time.y * _Speed;
fixed disp = tex2D(_DispTex, i.uv1 + fixed2(t, t)).r;
fixed4 col = tex2D(_MainTex, i.uv2 + disp * _Intensity);
return col * i.col;
}
ENDCG
}
}
}
Just mess with the values exposed in the material and the look of the displacement texture to fine-tune the effect! c:
You can also modify the direction of the scrolling. Right now I'm just moving it diagonally with equal amounts on both axes.