Hi,
It is not necessary that function visibility of function blocks should always be global. In fact, when they are created, by default, the visibility is “scope”. Scope visibility means, they are accessible only inside a subsystem or model hierarchy.
To answer the second question as to if there are any other options available, the answer is yes. Namely,
- Scoped
- Global
- Port-Scoped
To give more clarity on the answer, refer to the MathWorks documentation regarding Scoped and Global Simulink Functions attached below:
Hope this helps.