# sec_interp.core.services.structure_service module

class sec_interp.core.services.structure_service.StructureService

  Bases: `object`

  Service for projecting structural measurements onto cross-sections.

  This service handles the filtering and projection of structural measurements (dip/strike) onto a cross-section plane to calculate apparent dip.

  project_structures(line_lyr: qgis.core.QgsVectorLayer, raster_lyr: qgis.core.QgsRasterLayer, struct_lyr: qgis.core.QgsVectorLayer, buffer_m: int, line_az: float, dip_field: str, strike_field: str, band_number: int = 1) → list[StructureMeasurement]

    Project structural measurements onto the cross-section plane.

    This function returns the profile data as a list of StructureMeasurement objects.

    Filters structures within a buffer distance of the section line and calculates their apparent dip in the direction of the section.

    Parameters:

      - line_lyr – The cross-section line layer.

      - raster_lyr – The DEM raster layer for elevation sampling.

      - struct_lyr – The structural measurements layer (points).

      - buffer_m – Buffer distance in meters to include structures.

      - line_az – Azimuth of the section line in degrees.

      - dip_field – Field name for dip angle.

      - strike_field – Field name for strike angle.

      - band_number – Raster band to sample (default: 1).

    Returns:

      List of StructureMeasurement objects.

    Raises:

      ValueError – If line layer has no features or invalid geometry.