Scouts, Vertices and Area

Hello Brainstorm forum,
In the process of trying to find out the areas of scouts, I have consulted the below two forums.
Through these forums, I understand that the "area associated with a vertex in surface is the second returned value of tess_area.m" (i.e. VertArea) and that "The area of a scout is the sum of this 'vertex area' for all the vertices included in the scout."

As a process of doing this, I would like to use tess_area.m which requires Vertices and Faces.
I understand that if you export a scout the field named "Vertices" is one of the requirements of tess_area.m. However, I am not sure where I can get Faces information. What can I do in this situation? Is this the correct way to calculate scout area?

The contents of the field Vertices in the Scout, are not the vertices' XYZ coordinates (which are needed to compute area) but indices to point to the vertices in the surface file where the Scouts (and their Atlas) are defined.

To get the Scout area, you need to load the Surface file where they are defined.
This surface already contains the area per vertex, thus just sum over those vertex areas:

With the 3D figure of the sources open, you can do:

% Get current Surface file, where the Scouts are defined
% (This surface has already the field VertArea)
[~, sSurf] = panel_scout('GetScouts');

% For a given scout `sScout` with X vertices, its area in cm^2 is:
scoutArea = sum(sSurf.VertArea(sScout.Vertices)) * 100 * 100;
2 Likes

Thank you @Raymundo.Cassani this makes sense and it is working nicely! :slight_smile: