Documentation for Axxon Next 4.5.0 - 4.5.10. Documentation for other versions of Axxon Next is available too.

Previous page Next page

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Current »

To get the identifier of the detection tool mask, it is necessary to run a query of the following type:

{
    "method":"axxonsoft.bl.config.ConfigurationService.ListUnits",
    "data":{
        "unit_uids": ["hosts/Server1/AppDataDetector.1"]
    }
}

where unit_uids is the name of the required detection tool (see Manage devices using gRPC API methods (ConfigurationService)).

Find the units parameter group in the query response:

  "units": [
                {
                    "uid": "hosts/Server1/AppDataDetector.1/VisualElement.76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
                    "display_id": "76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
                    "type": "VisualElement",
                    "display_name": "Polyline",
                    "access_point": "",
                    "properties": [
                        {
                            "id": "polyline",
                            "name": "Polyline",
                            "description": "Polyline.",
                            "type": "SimplePolygon",
                            "readonly": false,
                            "internal": false,
                            "value_simple_polygon": {
                                "points": [
                                    {
                                        "x": 0.01,
                                        "y": 0.01
                                    },
                                    {
                                        "x": 0.01,
                                        "y": 0.99
                                    },
                                    {
                                        "x": 0.99,
                                        "y": 0.99
                                    },
                                    {
                                        "x": 0.99,
                                        "y": 0.01
                                    }
                                ]
                            }
                        }

where 

  • uid - the mask identifier from the response to the previous request.
  • x, y - the coordinates of the point apex.

To change the points of the mask, it is necessary to run a query using the obtained mask uid:

{
    "method": "axxonsoft.bl.config.ConfigurationService.ChangeConfig",
    "data": {
        "changed": [
            {
                "uid": "hosts/Server1/AppDataDetector.1/VisualElement.76c7fadf-7f96-4f30-b57a-e3ba585fbc6f",
                "type": "VisualElement",
                "properties": [
                        {
                            "id": "polyline",
                            "value_simple_polygon": {
                                "points": [
                                   {
                                        "x": 0.01,
                                        "y": 0.01
                                    },
                                    {
                                        "x": 0.01,
                                        "y": 0.99
                                    },
                                    {
                                        "x": 0.99,
                                        "y": 0.99
                                    },
                                    {
                                        "x": 0.99,
                                        "y": 0.01
                                    }
                                ]
                            }
                        
                    }
                ]
            }
        ]
    }

You can also add and remove the polygon points of the mask using this query.

  • No labels