Vertex displacement and object mesh question

Hi. I am using a vertex displacement shader which is working fine. What I am unable to do, however, is access the new position of the mesh vertices within my MonoBehaviour class. Using the below code, I can get at the mesh vertices no problem, but when I look at their positions it never shows any change despite visually changing in the app. I’ve tried using the snippet below in the various update methods and no luck.

Is there any way to get at this information from within the MonoBehaviour script? Thanks.

List<Vector3> vertices = new List<Vector3>();
gameObject.GetComponent<MeshFilter>().mesh.GetVertices(vertices);

for (int i = 0; i < vertices.Count; i++)
{
    nextVertex = vertices[i];
    // Check vertex position for change
}

Get vertices position that is modified by shader?
Since shader don’t actually modify vertex position at CPU side.
So you can’t get displaced vertex position with script.
You may need calculate displaced vertex position with same function at CPU side.
I know some project do so like Boat Attack.

Boat Attack’s water shader use vertex displacement function.
However they want boat float on water surface. So they need know water surface’s vertices around boat.
So they calculate displaced water surface’s vertices with same function like theirs shader do with script.
Maybe have some alternative ways like computer displaced vertex position first by compute shader.
But I’m not sure.

Thanks for the reply. I’m still coming to terms with shaders and at this point I’m not aware of what the limitations are, but it sounds as if what I’m attempting just isn’t possible, at least not directly.