{
    "camitk": {
        "extensions": {
            "actions": [
                {
                    "classification": {
                        "family": "Python",
                        "tags": [
                            "Action Parameter"
                        ]
                    },
                    "componentClass": "",
                    "description": "Simple test of the interaction between python and the CamiTK application using action parameters. \nThis is a simple test where a counter is incremented in the process() method. \n\nIt demonstrates how a value computed in python can be saved in the action parameters between two calls to 'apply()' using an action parameter. The process() method increments the value of the parameter (the user can also modify the value in the CamiTK interface before clicking on 'Apply')",
                    "gui": "Default Action GUI",
                    "name": "Test Parameter Interaction",
                    "parameters": [
                        {
                            "defaultValue": 0,
                            "description": "This counter is retrieved, incremented and updated in the process() method",
                            "group": "",
                            "maximum": 2147483647,
                            "minimum": 0,
                            "name": "Counter",
                            "readOnly": false,
                            "singleStep": 1,
                            "type": "int",
                            "unit": ""
                        }
                    ]
                },
                {
                    "classification": {
                        "family": "Python",
                        "tags": [
                            "Action __dict__",
                            "Self"
                        ]
                    },
                    "componentClass": "",
                    "description": "Simple test of the interaction between python and the CamiTK application using 'self'. \nThis is a simple test where a counter is incremented in the process() method using an attributes saved in the action's self dict. \n\nIt demonstrates how state can be preserved between action 'apply' calls using internal variables. Note that the parameter is set to read only for this action as a way to prove the internal self.counter increments properly.",
                    "gui": "Default Action GUI",
                    "name": "Test Self Interaction",
                    "parameters": [
                        {
                            "defaultValue": 0,
                            "description": "This counter is updated using the action self.counter attribute, added and manipulated directly in python.",
                            "group": "",
                            "maximum": 2147483647,
                            "minimum": 0,
                            "name": "Counter",
                            "readOnly": true,
                            "singleStep": 1,
                            "type": "int",
                            "unit": ""
                        }
                    ]
                },
                {
                    "classification": {
                        "family": "Python",
                        "tags": [
                            "Action Parameter",
                            "Timer"
                        ]
                    },
                    "componentClass": "",
                    "description": "Test the interaction between python and the CamiTK application using a parameter and a timer. \nThis is a simple test where a counter is incremented in the tick() method called by a timer() that lives in Python.\n\nIt demonstrates how state can be preserved between two timer ticks calls using the action parameters. \n\nClick 'Start'/'Stop' to start/stop the timer. \n\nNote that the timer interval is slowed down/accelerated automatically within the tick() method.",
                    "gui": "Default Action GUI",
                    "name": "Test Parameter Interaction (Timer)",
                    "parameters": [
                        {
                            "defaultValue": 0,
                            "description": "This counter is retrieved, incremented and updated in a timer inside the python action.",
                            "group": "",
                            "maximum": 2147483647,
                            "minimum": 0,
                            "name": "Counter",
                            "readOnly": false,
                            "singleStep": 1,
                            "type": "int",
                            "unit": ""
                        }
                    ]
                },
                {
                    "classification": {
                        "family": "Python",
                        "tags": [
                            "Action __dict__",
                            "Self",
                            "Timer"
                        ]
                    },
                    "componentClass": "",
                    "description": "Test the interaction between python and the CamiTK application using 'self' and a timer. \nThis is a simple test where a counter is incremented in the tick() method called by a timer() that lives in Python. \n\nIt demonstrates how state can be preserved between two timer ticks calls using internal variables. \n\nClick 'Start'/'Stop' to start/stop the timer. Note that the timer interval is slowed down/accelerated automatically within the tick() method.\n\nNote also that the parameter is set to read only as a way to prove the internal self.counter increments properly.",
                    "gui": "Default Action GUI",
                    "name": "Test Self Interaction (Timer)",
                    "parameters": [
                        {
                            "defaultValue": 0,
                            "description": "This counter is updated using the action self.counter attribute, added and manipulated directly in python and incremented/updated in a timer inside the python action.",
                            "group": "",
                            "maximum": 2147483647,
                            "minimum": 0,
                            "name": "Counter",
                            "readOnly": true,
                            "singleStep": 1,
                            "type": "int",
                            "unit": ""
                        }
                    ]
                }
            ],
            "applications": [
            ],
            "components": [
            ],
            "contact": {
                "author": "CamiTK team",
                "email": "timc-camitk-contact@univ-grenoble-alpes.fr"
            },
            "description": "A python tutorial that demonstrates how to save/restore the action state from Python using either an action parameter or the \"self\" python dict.\n\nThe interaction with the CamiTK application is shown using the default action GUI.\n\nThis extension requires PySide2 to create a timer.",
            "language": "Python",
            "libraries": [
            ],
            "license": "LGPL-3 CamiTK",
            "name": "Python ActionState Test",
            "requirements": [
                "PySide2"
            ],
            "viewers": [
            ]
        },
        "timestamp": "2025-06-16T14:11:55",
        "version": "camitk-6.0"
    }
}
