Added two new generic optimized by performance functions that should be used in all projects further,
One is for countnig materials by specified structures,
Another is for getting materials by strucutures and other filters