////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Copyright (c) Qualcomm Technologies, Inc. and/or its subsidiaries.
// All Rights Reserved.
// Confidential and Proprietary - Qualcomm Technologies, Inc.
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// THIS IS AUTO-GENERATED CODE.  PLEASE DO NOT EDIT (File bug reports against tools).
///
/// Auto-generated by: Parameter Parser V5.5.1 (2411131018)
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// @file  afhafelements.cpp
/// @brief Auto-generated Chromatix parameter file
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

#include "afhafelements.h"
#include "parametersetmanager.h"

AFHAFELEMENTS_NAMESPACE_BEGIN

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// SetValue/GetValue Functions
/// Gets or sets the requested value
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFGyroSettingsType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enableGyroSamplingRateAdjustment") == 0)
    {
        ParameterUtils::DoubleToString((double)enableGyroSamplingRateAdjustment, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateMonitor") == 0)
    {
        ParameterUtils::DoubleToString((double)gyroSamplingRateMonitor, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearching") == 0)
    {
        ParameterUtils::DoubleToString((double)gyroSamplingRateSearching, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearchingHJ") == 0)
    {
        ParameterUtils::DoubleToString((double)gyroSamplingRateSearchingHJ, __value, __size);
        __result = true;
    }

    return __result;
}

bool chromatixHAFGyroSettingsType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enableGyroSamplingRateAdjustment") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableGyroSamplingRateAdjustment = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateMonitor") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gyroSamplingRateMonitor = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearching") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gyroSamplingRateSearching = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearchingHJ") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gyroSamplingRateSearchingHJ = (float)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFGyroSettingsType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enableGyroSamplingRateAdjustment
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableGyroSamplingRateAdjustment", ParameterParserDataType::Int32, (double)enableGyroSamplingRateAdjustment, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableGyroSamplingRateAdjustment") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableGyroSamplingRateAdjustment, 0));
    }

    // gyroSamplingRateMonitor
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gyroSamplingRateMonitor", ParameterParserDataType::Float, (double)gyroSamplingRateMonitor));
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateMonitor") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gyroSamplingRateMonitor));
    }

    // gyroSamplingRateSearching
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gyroSamplingRateSearching", ParameterParserDataType::Float, (double)gyroSamplingRateSearching));
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearching") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gyroSamplingRateSearching));
    }

    // gyroSamplingRateSearchingHJ
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gyroSamplingRateSearchingHJ", ParameterParserDataType::Float, (double)gyroSamplingRateSearchingHJ));
    }
    else if (PARAMETER_STRCMP(__name, "gyroSamplingRateSearchingHJ") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gyroSamplingRateSearchingHJ));
    }

    return __result;
}

bool chromatixAFFollowerStepType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        ParameterUtils::DoubleToString((double)stepSize, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        ParameterUtils::DoubleToString((double)numFarSteps, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        ParameterUtils::DoubleToString((double)numNearSteps, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixAFFollowerStepType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            stepSize = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            numFarSteps = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            numNearSteps = (INT32)dblValue; 
        }
    }

    return __result;
}

bool chromatixAFFollowerStepType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // stepSize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("stepSize", ParameterParserDataType::Int32, (double)stepSize, 0));
    }
    else if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)stepSize, 0));
    }

    // numFarSteps
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("numFarSteps", ParameterParserDataType::Int32, (double)numFarSteps, 0));
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)numFarSteps, 0));
    }

    // numNearSteps
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("numNearSteps", ParameterParserDataType::Int32, (double)numNearSteps, 0));
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)numNearSteps, 0));
    }

    return __result;
}

bool chromatixSearchInfoType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "AFFollowerMacroRange") == 0)
    {
        __result = AFFollowerMacroRange.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerMidRange") == 0)
    {
        __result = AFFollowerMidRange.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFarRange") == 0)
    {
        __result = AFFollowerFarRange.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool chromatixSearchInfoType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "AFFollowerMacroRange") == 0)
    {
        __result = AFFollowerMacroRange.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerMidRange") == 0)
    {
        __result = AFFollowerMidRange.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFarRange") == 0)
    {
        __result = AFFollowerFarRange.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool chromatixSearchInfoType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // AFFollowerMacroRange
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFFollowerMacroRange", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerMacroRange") == 0)
    {
        __result = AFFollowerMacroRange.GetInfo(&__path[__pos], __info);
    }

    // AFFollowerMidRange
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFFollowerMidRange", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerMidRange") == 0)
    {
        __result = AFFollowerMidRange.GetInfo(&__path[__pos], __info);
    }

    // AFFollowerFarRange
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFFollowerFarRange", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFarRange") == 0)
    {
        __result = AFFollowerFarRange.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool chromatixFollowerFineSearchInfoType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "normalLightFineSearchInfo") == 0)
    {
        __result = normalLightFineSearchInfo.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "lowLightFineSearchInfo") == 0)
    {
        __result = lowLightFineSearchInfo.GetValue(&__path[__pos], __value, __size);
    }

    return __result;
}

bool chromatixFollowerFineSearchInfoType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "normalLightFineSearchInfo") == 0)
    {
        __result = normalLightFineSearchInfo.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "lowLightFineSearchInfo") == 0)
    {
        __result = lowLightFineSearchInfo.SetValue(&__path[__pos], __value);
    }

    return __result;
}

bool chromatixFollowerFineSearchInfoType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // normalLightFineSearchInfo
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("normalLightFineSearchInfo", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "normalLightFineSearchInfo") == 0)
    {
        __result = normalLightFineSearchInfo.GetInfo(&__path[__pos], __info);
    }

    // lowLightFineSearchInfo
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lowLightFineSearchInfo", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "lowLightFineSearchInfo") == 0)
    {
        __result = lowLightFineSearchInfo.GetInfo(&__path[__pos], __info);
    }

    return __result;
}

bool chromatixHAFFollowerSettingsType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enableFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)enableFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFineSearchSettings") == 0)
    {
        __result = AFFollowerFineSearchSettings.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "enableGravityCompensationForFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)enableGravityCompensationForFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "jumpToStartLimitForFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)jumpToStartLimitForFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "lowLightThresholdForFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)lowLightThresholdForFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "useFineSearchExtensionForFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)useFineSearchExtensionForFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "activeConvergenceFollowForFollower") == 0)
    {
        ParameterUtils::DoubleToString((double)activeConvergenceFollowForFollower, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "lensPosThresholdForActiveConvergenceFollow") == 0)
    {
        ParameterUtils::DoubleToString((double)lensPosThresholdForActiveConvergenceFollow, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "searchStrategy") == 0)
    {
        ParameterUtils::DoubleToString((double)searchStrategy, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "lensMappingStrategy") == 0)
    {
        ParameterUtils::DoubleToString((double)lensMappingStrategy, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enablePdafSearchAssist") == 0)
    {
        ParameterUtils::DoubleToString((double)enablePdafSearchAssist, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixHAFFollowerSettingsType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enableFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableFollower = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFineSearchSettings") == 0)
    {
        __result = AFFollowerFineSearchSettings.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "enableGravityCompensationForFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableGravityCompensationForFollower = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "jumpToStartLimitForFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            jumpToStartLimitForFollower = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "lowLightThresholdForFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            lowLightThresholdForFollower = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "useFineSearchExtensionForFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            useFineSearchExtensionForFollower = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "activeConvergenceFollowForFollower") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            activeConvergenceFollowForFollower = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "lensPosThresholdForActiveConvergenceFollow") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            lensPosThresholdForActiveConvergenceFollow = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "searchStrategy") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            searchStrategy = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "lensMappingStrategy") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            lensMappingStrategy = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enablePdafSearchAssist") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enablePdafSearchAssist = (BOOL)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFFollowerSettingsType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enableFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableFollower", ParameterParserDataType::Int32, (double)enableFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableFollower, 0));
    }

    // AFFollowerFineSearchSettings
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFFollowerFineSearchSettings", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "AFFollowerFineSearchSettings") == 0)
    {
        __result = AFFollowerFineSearchSettings.GetInfo(&__path[__pos], __info);
    }

    // enableGravityCompensationForFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableGravityCompensationForFollower", ParameterParserDataType::Int32, (double)enableGravityCompensationForFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableGravityCompensationForFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableGravityCompensationForFollower, 0));
    }

    // jumpToStartLimitForFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("jumpToStartLimitForFollower", ParameterParserDataType::Int32, (double)jumpToStartLimitForFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "jumpToStartLimitForFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)jumpToStartLimitForFollower, 0));
    }

    // lowLightThresholdForFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lowLightThresholdForFollower", ParameterParserDataType::Int32, (double)lowLightThresholdForFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "lowLightThresholdForFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)lowLightThresholdForFollower, 0));
    }

    // useFineSearchExtensionForFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("useFineSearchExtensionForFollower", ParameterParserDataType::Int32, (double)useFineSearchExtensionForFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "useFineSearchExtensionForFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)useFineSearchExtensionForFollower, 0));
    }

    // activeConvergenceFollowForFollower
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("activeConvergenceFollowForFollower", ParameterParserDataType::Int32, (double)activeConvergenceFollowForFollower, 0));
    }
    else if (PARAMETER_STRCMP(__name, "activeConvergenceFollowForFollower") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)activeConvergenceFollowForFollower, 0));
    }

    // lensPosThresholdForActiveConvergenceFollow
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lensPosThresholdForActiveConvergenceFollow", ParameterParserDataType::Int32, (double)lensPosThresholdForActiveConvergenceFollow, 0));
    }
    else if (PARAMETER_STRCMP(__name, "lensPosThresholdForActiveConvergenceFollow") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)lensPosThresholdForActiveConvergenceFollow, 0));
    }

    // searchStrategy
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("searchStrategy", ParameterParserDataType::Int32, (double)searchStrategy, 0));
    }
    else if (PARAMETER_STRCMP(__name, "searchStrategy") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)searchStrategy, 0));
    }

    // lensMappingStrategy
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lensMappingStrategy", ParameterParserDataType::Int32, (double)lensMappingStrategy, 0));
    }
    else if (PARAMETER_STRCMP(__name, "lensMappingStrategy") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)lensMappingStrategy, 0));
    }

    // enablePdafSearchAssist
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enablePdafSearchAssist", ParameterParserDataType::Boolean, (double)enablePdafSearchAssist, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enablePdafSearchAssist") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Boolean, (double)enablePdafSearchAssist, 0));
    }

    return __result;
}

bool chromatixHAFROISettingsType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "HAFROIEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFROIEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIHNum") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFROIHNum, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIVNum") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFROIVNum, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFCenterROISize") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFCenterROISize, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFCornerROISize") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFCornerROISize, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIDelay") == 0)
    {
        ParameterUtils::DoubleToString((double)HAFROIDelay, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableROIShifting") == 0)
    {
        ParameterUtils::DoubleToString((double)enableROIShifting, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "ROIShiftType") == 0)
    {
        ParameterUtils::DoubleToString((double)ROIShiftType, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixHAFROISettingsType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "HAFROIEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFROIEnable = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIHNum") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFROIHNum = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIVNum") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFROIVNum = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFCenterROISize") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFCenterROISize = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFCornerROISize") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFCornerROISize = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIDelay") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HAFROIDelay = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableROIShifting") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableROIShifting = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "ROIShiftType") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            ROIShiftType = (INT32)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFROISettingsType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // HAFROIEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFROIEnable", ParameterParserDataType::Int32, (double)HAFROIEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HAFROIEnable, 0));
    }

    // HAFROIHNum
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFROIHNum", ParameterParserDataType::Int32, (double)HAFROIHNum, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIHNum") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HAFROIHNum, 0));
    }

    // HAFROIVNum
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFROIVNum", ParameterParserDataType::Int32, (double)HAFROIVNum, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIVNum") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HAFROIVNum, 0));
    }

    // HAFCenterROISize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFCenterROISize", ParameterParserDataType::Float, (double)HAFCenterROISize));
    }
    else if (PARAMETER_STRCMP(__name, "HAFCenterROISize") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)HAFCenterROISize));
    }

    // HAFCornerROISize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFCornerROISize", ParameterParserDataType::Float, (double)HAFCornerROISize));
    }
    else if (PARAMETER_STRCMP(__name, "HAFCornerROISize") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)HAFCornerROISize));
    }

    // HAFROIDelay
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFROIDelay", ParameterParserDataType::Int32, (double)HAFROIDelay, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HAFROIDelay") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HAFROIDelay, 0));
    }

    // enableROIShifting
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableROIShifting", ParameterParserDataType::Int32, (double)enableROIShifting, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableROIShifting") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableROIShifting, 0));
    }

    // ROIShiftType
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("ROIShiftType", ParameterParserDataType::Int32, (double)ROIShiftType, 0));
    }
    else if (PARAMETER_STRCMP(__name, "ROIShiftType") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)ROIShiftType, 0));
    }

    return __result;
}

bool chromatixAFFineSearchExtensionType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        ParameterUtils::DoubleToString((double)enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "maximumFineSearchExtensionCount") == 0)
    {
        ParameterUtils::DoubleToString((double)maximumFineSearchExtensionCount, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        ParameterUtils::DoubleToString((double)numNearSteps, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        ParameterUtils::DoubleToString((double)numFarSteps, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        ParameterUtils::DoubleToString((double)stepSize, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "decreaseDropRatio") == 0)
    {
        ParameterUtils::DoubleToString((double)decreaseDropRatio, __value, __size);
        __result = true;
    }

    return __result;
}

bool chromatixAFFineSearchExtensionType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enable = (UINT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "maximumFineSearchExtensionCount") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            maximumFineSearchExtensionCount = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            numNearSteps = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            numFarSteps = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            stepSize = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "decreaseDropRatio") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            decreaseDropRatio = (float)dblValue; 
        }
    }

    return __result;
}

bool chromatixAFFineSearchExtensionType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable", ParameterParserDataType::UInt32, (double)enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::UInt32, (double)enable, 0));
    }

    // maximumFineSearchExtensionCount
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("maximumFineSearchExtensionCount", ParameterParserDataType::Int32, (double)maximumFineSearchExtensionCount, 0));
    }
    else if (PARAMETER_STRCMP(__name, "maximumFineSearchExtensionCount") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)maximumFineSearchExtensionCount, 0));
    }

    // numNearSteps
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("numNearSteps", ParameterParserDataType::Int32, (double)numNearSteps, 0));
    }
    else if (PARAMETER_STRCMP(__name, "numNearSteps") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)numNearSteps, 0));
    }

    // numFarSteps
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("numFarSteps", ParameterParserDataType::Int32, (double)numFarSteps, 0));
    }
    else if (PARAMETER_STRCMP(__name, "numFarSteps") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)numFarSteps, 0));
    }

    // stepSize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("stepSize", ParameterParserDataType::Int32, (double)stepSize, 0));
    }
    else if (PARAMETER_STRCMP(__name, "stepSize") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)stepSize, 0));
    }

    // decreaseDropRatio
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("decreaseDropRatio", ParameterParserDataType::Float, (double)decreaseDropRatio));
    }
    else if (PARAMETER_STRCMP(__name, "decreaseDropRatio") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)decreaseDropRatio));
    }

    return __result;
}

bool chromatixHAFType::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "enable_section") == 0)
    {
        __result = enable_section.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "defaultROISize") == 0)
    {
        __result = defaultROISize.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "ROIGridSetting") == 0)
    {
        __result = ROIGridSetting.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "statsConsumeEnable") == 0)
    {
        if (__index < statsConsumeEnableCount)
        {
            ParameterUtils::DoubleToString((double)statsConsumeEnable[__index], __value, __size, 0);
            __result = true;
        }
        else
        {
            SIZE_T __valuePos = 0;
            for (UINT32 i = 0; i < statsConsumeEnableCount; i++)
            {
                if (i > 0)
                {
                    PARAMETER_STRCAT(__value, __size, ",");
                    __valuePos = PARAMETER_STRLEN(__value);
                }
                ParameterUtils::DoubleToString((double)statsConsumeEnable[i], &__value[__valuePos], (INT32)(__size - __valuePos), 0);
            }
            __result = true;
        }
    }
    else if (PARAMETER_STRCMP(__name, "statsSelect") == 0)
    {
        ParameterUtils::DoubleToString((double)(UINT32)statsSelect, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "fineSearchDropThreshold") == 0)
    {
        ParameterUtils::DoubleToString((double)fineSearchDropThreshold, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "fineStepSize") == 0)
    {
        ParameterUtils::DoubleToString((double)fineStepSize, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStep") == 0)
    {
        ParameterUtils::DoubleToString((double)maxMoveStep, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStepBuffer") == 0)
    {
        ParameterUtils::DoubleToString((double)maxMoveStepBuffer, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "baseFrameDelay") == 0)
    {
        ParameterUtils::DoubleToString((double)baseFrameDelay, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "AFFineSearchExtension") == 0)
    {
        __result = AFFineSearchExtension.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "sceneChangeDuringFS") == 0)
    {
        ParameterUtils::DoubleToString((double)sceneChangeDuringFS, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "faceCAFHighPriorityEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)faceCAFHighPriorityEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableInitialPosition") == 0)
    {
        ParameterUtils::DoubleToString((double)enableInitialPosition, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "initialLensIdx") == 0)
    {
        ParameterUtils::DoubleToString((double)initialLensIdx, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "depthConfidenceCountThreshold") == 0)
    {
        ParameterUtils::DoubleToString((double)depthConfidenceCountThreshold, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HAFROISettings") == 0)
    {
        __result = HAFROISettings.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "HAFFollowerSettings") == 0)
    {
        __result = HAFFollowerSettings.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "macroRegionThresholdInMM") == 0)
    {
        ParameterUtils::DoubleToString((double)macroRegionThresholdInMM, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "farRegionThresholdinMM") == 0)
    {
        ParameterUtils::DoubleToString((double)farRegionThresholdinMM, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "fineStartMoveBuffer") == 0)
    {
        ParameterUtils::DoubleToString((double)fineStartMoveBuffer, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "DOFMultiplier") == 0)
    {
        ParameterUtils::DoubleToString((double)DOFMultiplier, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableForceScanEnd") == 0)
    {
        ParameterUtils::DoubleToString((double)enableForceScanEnd, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enablePassiveScanTimeout") == 0)
    {
        ParameterUtils::DoubleToString((double)enablePassiveScanTimeout, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableZeroTouchLag") == 0)
    {
        ParameterUtils::DoubleToString((double)enableZeroTouchLag, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "maxScanCountThreshold") == 0)
    {
        ParameterUtils::DoubleToString((double)maxScanCountThreshold, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gyroSettings") == 0)
    {
        __result = gyroSettings.GetValue(&__path[__pos], __value, __size);
    }
    else if (PARAMETER_STRCMP(__name, "enableDynamicAnchorPoints") == 0)
    {
        ParameterUtils::DoubleToString((double)enableDynamicAnchorPoints, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition1") == 0)
    {
        ParameterUtils::DoubleToString((double)anchorPosition1, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition2") == 0)
    {
        ParameterUtils::DoubleToString((double)anchorPosition2, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "minimumFocusIndex") == 0)
    {
        ParameterUtils::DoubleToString((double)minimumFocusIndex, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "HJNormalizedWeightType") == 0)
    {
        ParameterUtils::DoubleToString((double)HJNormalizedWeightType, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "CAFHJNormalizedWeightType") == 0)
    {
        ParameterUtils::DoubleToString((double)CAFHJNormalizedWeightType, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)AFControlAECInfoEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoFPS") == 0)
    {
        ParameterUtils::DoubleToString((double)AFControlAECInfoFPS, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "spd_stats_type") == 0)
    {
        ParameterUtils::DoubleToString((double)spd_stats_type, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "spd_bg_stats_thresh_auto_convert_enable") == 0)
    {
        ParameterUtils::DoubleToString((double)spd_bg_stats_thresh_auto_convert_enable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "enableParallelSearch") == 0)
    {
        ParameterUtils::DoubleToString((double)enableParallelSearch, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "enable_section") == 0)
    {
        __result = enable_section.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "defaultROISize") == 0)
    {
        __result = defaultROISize.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "ROIGridSetting") == 0)
    {
        __result = ROIGridSetting.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "statsConsumeEnable") == 0)
    {
        if (__index < statsConsumeEnableCount)
        {
            const double dblValue = ParameterUtils::StringToDouble(__value, __result);
            if (__result)
            {
                statsConsumeEnable[__index] = (UINT32)dblValue; 
            }
        }
        else
        {
            SIZE_T __valueLen = PARAMETER_STRLEN(__value);
            UINT32 __pos = 0;

            __index = 0;
            while (__pos < __valueLen && __index < statsConsumeEnableCount)
            {
                CHAR __valueStr[MAX_SIZE];

                __pos += ParameterUtils::GetSubString(&__value[__pos], ',', __valueStr, MAX_SIZE);
                __pos++;

                const double dblValue = ParameterUtils::StringToDouble(__valueStr, __result);
                if (__result)
                {
                    statsConsumeEnable[__index] = (UINT32)dblValue; 
                }
                __index++;
            }
            __result = true;
        }
    }
    else if (PARAMETER_STRCMP(__name, "statsSelect") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            statsSelect = (chromatixAFFocusValueStatsType)(UINT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "fineSearchDropThreshold") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            fineSearchDropThreshold = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "fineStepSize") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            fineStepSize = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStep") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            maxMoveStep = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStepBuffer") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            maxMoveStepBuffer = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "baseFrameDelay") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            baseFrameDelay = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "AFFineSearchExtension") == 0)
    {
        __result = AFFineSearchExtension.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "sceneChangeDuringFS") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            sceneChangeDuringFS = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "faceCAFHighPriorityEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            faceCAFHighPriorityEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableInitialPosition") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableInitialPosition = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "initialLensIdx") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            initialLensIdx = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "depthConfidenceCountThreshold") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            depthConfidenceCountThreshold = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HAFROISettings") == 0)
    {
        __result = HAFROISettings.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "HAFFollowerSettings") == 0)
    {
        __result = HAFFollowerSettings.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "macroRegionThresholdInMM") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            macroRegionThresholdInMM = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "farRegionThresholdinMM") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            farRegionThresholdinMM = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "fineStartMoveBuffer") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            fineStartMoveBuffer = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "DOFMultiplier") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            DOFMultiplier = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableForceScanEnd") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableForceScanEnd = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enablePassiveScanTimeout") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enablePassiveScanTimeout = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableZeroTouchLag") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableZeroTouchLag = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "maxScanCountThreshold") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            maxScanCountThreshold = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gyroSettings") == 0)
    {
        __result = gyroSettings.SetValue(&__path[__pos], __value);
    }
    else if (PARAMETER_STRCMP(__name, "enableDynamicAnchorPoints") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableDynamicAnchorPoints = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition1") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            anchorPosition1 = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition2") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            anchorPosition2 = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "minimumFocusIndex") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            minimumFocusIndex = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "HJNormalizedWeightType") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            HJNormalizedWeightType = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "CAFHJNormalizedWeightType") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            CAFHJNormalizedWeightType = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            AFControlAECInfoEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoFPS") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            AFControlAECInfoFPS = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "spd_stats_type") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            spd_stats_type = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "spd_bg_stats_thresh_auto_convert_enable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            spd_bg_stats_thresh_auto_convert_enable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "enableParallelSearch") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            enableParallelSearch = (globalelements::enable_flag_type)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFType::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    const UINT32 __pos = ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // module_version
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("module_version", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "module_version") == 0)
    {
        __result = module_version.GetInfo(&__path[__pos], __info);
    }

    // parameter_version
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("parameter_version", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "parameter_version") == 0)
    {
        __result = parameter_version.GetInfo(&__path[__pos], __info);
    }

    // enable_section
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enable_section", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "enable_section") == 0)
    {
        __result = enable_section.GetInfo(&__path[__pos], __info);
    }

    // defaultROISize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("defaultROISize", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "defaultROISize") == 0)
    {
        __result = defaultROISize.GetInfo(&__path[__pos], __info);
    }

    // ROIGridSetting
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("ROIGridSetting", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "ROIGridSetting") == 0)
    {
        __result = ROIGridSetting.GetInfo(&__path[__pos], __info);
    }

    // statsConsumeEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("statsConsumeEnable", ParameterParserDataType::UInt32, true, false, statsConsumeEnableCount));
    }

    // statsSelect
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("statsSelect", ParameterParserDataType::Enum, (double)(UINT32)statsSelect, 0));
    }
    else if (PARAMETER_STRCMP(__name, "statsSelect") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Enum, (double)(UINT32)statsSelect, 0));
    }

    // fineSearchDropThreshold
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("fineSearchDropThreshold", ParameterParserDataType::Float, (double)fineSearchDropThreshold));
    }
    else if (PARAMETER_STRCMP(__name, "fineSearchDropThreshold") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)fineSearchDropThreshold));
    }

    // fineStepSize
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("fineStepSize", ParameterParserDataType::Int32, (double)fineStepSize, 0));
    }
    else if (PARAMETER_STRCMP(__name, "fineStepSize") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)fineStepSize, 0));
    }

    // maxMoveStep
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("maxMoveStep", ParameterParserDataType::Int32, (double)maxMoveStep, 0));
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStep") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)maxMoveStep, 0));
    }

    // maxMoveStepBuffer
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("maxMoveStepBuffer", ParameterParserDataType::Int32, (double)maxMoveStepBuffer, 0));
    }
    else if (PARAMETER_STRCMP(__name, "maxMoveStepBuffer") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)maxMoveStepBuffer, 0));
    }

    // baseFrameDelay
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("baseFrameDelay", ParameterParserDataType::Int32, (double)baseFrameDelay, 0));
    }
    else if (PARAMETER_STRCMP(__name, "baseFrameDelay") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)baseFrameDelay, 0));
    }

    // AFFineSearchExtension
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFFineSearchExtension", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "AFFineSearchExtension") == 0)
    {
        __result = AFFineSearchExtension.GetInfo(&__path[__pos], __info);
    }

    // sceneChangeDuringFS
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("sceneChangeDuringFS", ParameterParserDataType::Int32, (double)sceneChangeDuringFS, 0));
    }
    else if (PARAMETER_STRCMP(__name, "sceneChangeDuringFS") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)sceneChangeDuringFS, 0));
    }

    // faceCAFHighPriorityEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("faceCAFHighPriorityEnable", ParameterParserDataType::Int32, (double)faceCAFHighPriorityEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "faceCAFHighPriorityEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)faceCAFHighPriorityEnable, 0));
    }

    // enableInitialPosition
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableInitialPosition", ParameterParserDataType::Int32, (double)enableInitialPosition, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableInitialPosition") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableInitialPosition, 0));
    }

    // initialLensIdx
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("initialLensIdx", ParameterParserDataType::Int32, (double)initialLensIdx, 0));
    }
    else if (PARAMETER_STRCMP(__name, "initialLensIdx") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)initialLensIdx, 0));
    }

    // depthConfidenceCountThreshold
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("depthConfidenceCountThreshold", ParameterParserDataType::Int32, (double)depthConfidenceCountThreshold, 0));
    }
    else if (PARAMETER_STRCMP(__name, "depthConfidenceCountThreshold") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)depthConfidenceCountThreshold, 0));
    }

    // HAFROISettings
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFROISettings", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "HAFROISettings") == 0)
    {
        __result = HAFROISettings.GetInfo(&__path[__pos], __info);
    }

    // HAFFollowerSettings
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HAFFollowerSettings", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "HAFFollowerSettings") == 0)
    {
        __result = HAFFollowerSettings.GetInfo(&__path[__pos], __info);
    }

    // macroRegionThresholdInMM
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("macroRegionThresholdInMM", ParameterParserDataType::Float, (double)macroRegionThresholdInMM));
    }
    else if (PARAMETER_STRCMP(__name, "macroRegionThresholdInMM") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)macroRegionThresholdInMM));
    }

    // farRegionThresholdinMM
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("farRegionThresholdinMM", ParameterParserDataType::Float, (double)farRegionThresholdinMM));
    }
    else if (PARAMETER_STRCMP(__name, "farRegionThresholdinMM") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)farRegionThresholdinMM));
    }

    // fineStartMoveBuffer
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("fineStartMoveBuffer", ParameterParserDataType::Int32, (double)fineStartMoveBuffer, 0));
    }
    else if (PARAMETER_STRCMP(__name, "fineStartMoveBuffer") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)fineStartMoveBuffer, 0));
    }

    // DOFMultiplier
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("DOFMultiplier", ParameterParserDataType::Float, (double)DOFMultiplier));
    }
    else if (PARAMETER_STRCMP(__name, "DOFMultiplier") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)DOFMultiplier));
    }

    // enableForceScanEnd
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableForceScanEnd", ParameterParserDataType::Int32, (double)enableForceScanEnd, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableForceScanEnd") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableForceScanEnd, 0));
    }

    // enablePassiveScanTimeout
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enablePassiveScanTimeout", ParameterParserDataType::Int32, (double)enablePassiveScanTimeout, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enablePassiveScanTimeout") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enablePassiveScanTimeout, 0));
    }

    // enableZeroTouchLag
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableZeroTouchLag", ParameterParserDataType::Int32, (double)enableZeroTouchLag, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableZeroTouchLag") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableZeroTouchLag, 0));
    }

    // maxScanCountThreshold
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("maxScanCountThreshold", ParameterParserDataType::Int32, (double)maxScanCountThreshold, 0));
    }
    else if (PARAMETER_STRCMP(__name, "maxScanCountThreshold") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)maxScanCountThreshold, 0));
    }

    // gyroSettings
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gyroSettings", ParameterParserDataType::Structure));
    }
    else if (PARAMETER_STRCMP(__name, "gyroSettings") == 0)
    {
        __result = gyroSettings.GetInfo(&__path[__pos], __info);
    }

    // enableDynamicAnchorPoints
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableDynamicAnchorPoints", ParameterParserDataType::Int32, (double)enableDynamicAnchorPoints, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableDynamicAnchorPoints") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableDynamicAnchorPoints, 0));
    }

    // anchorPosition1
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("anchorPosition1", ParameterParserDataType::Int32, (double)anchorPosition1, 0));
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition1") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)anchorPosition1, 0));
    }

    // anchorPosition2
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("anchorPosition2", ParameterParserDataType::Int32, (double)anchorPosition2, 0));
    }
    else if (PARAMETER_STRCMP(__name, "anchorPosition2") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)anchorPosition2, 0));
    }

    // minimumFocusIndex
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("minimumFocusIndex", ParameterParserDataType::Int32, (double)minimumFocusIndex, 0));
    }
    else if (PARAMETER_STRCMP(__name, "minimumFocusIndex") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)minimumFocusIndex, 0));
    }

    // HJNormalizedWeightType
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("HJNormalizedWeightType", ParameterParserDataType::Int32, (double)HJNormalizedWeightType, 0));
    }
    else if (PARAMETER_STRCMP(__name, "HJNormalizedWeightType") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)HJNormalizedWeightType, 0));
    }

    // CAFHJNormalizedWeightType
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("CAFHJNormalizedWeightType", ParameterParserDataType::Int32, (double)CAFHJNormalizedWeightType, 0));
    }
    else if (PARAMETER_STRCMP(__name, "CAFHJNormalizedWeightType") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)CAFHJNormalizedWeightType, 0));
    }

    // AFControlAECInfoEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFControlAECInfoEnable", ParameterParserDataType::Int32, (double)AFControlAECInfoEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)AFControlAECInfoEnable, 0));
    }

    // AFControlAECInfoFPS
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("AFControlAECInfoFPS", ParameterParserDataType::Int32, (double)AFControlAECInfoFPS, 0));
    }
    else if (PARAMETER_STRCMP(__name, "AFControlAECInfoFPS") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)AFControlAECInfoFPS, 0));
    }

    // spd_stats_type
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("spd_stats_type", ParameterParserDataType::Int32, (double)spd_stats_type, 0));
    }
    else if (PARAMETER_STRCMP(__name, "spd_stats_type") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)spd_stats_type, 0));
    }

    // spd_bg_stats_thresh_auto_convert_enable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("spd_bg_stats_thresh_auto_convert_enable", ParameterParserDataType::Int32, (double)spd_bg_stats_thresh_auto_convert_enable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "spd_bg_stats_thresh_auto_convert_enable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)spd_bg_stats_thresh_auto_convert_enable, 0));
    }

    // enableParallelSearch
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("enableParallelSearch", ParameterParserDataType::Int32, (double)enableParallelSearch, 0));
    }
    else if (PARAMETER_STRCMP(__name, "enableParallelSearch") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)enableParallelSearch, 0));
    }

    return __result;
}

bool chromatixHAFType::module_versionStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)major_revision, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)minor_revision, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        ParameterUtils::DoubleToString((double)incr_revision, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::module_versionStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            major_revision = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            minor_revision = (INT32)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            incr_revision = (INT32)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFType::module_versionStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // major_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("major_revision", ParameterParserDataType::Int32, (double)major_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "major_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)major_revision, 0));
    }

    // minor_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("minor_revision", ParameterParserDataType::Int32, (double)minor_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "minor_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)minor_revision, 0));
    }

    // incr_revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("incr_revision", ParameterParserDataType::Int32, (double)incr_revision, 0));
    }
    else if (PARAMETER_STRCMP(__name, "incr_revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)incr_revision, 0));
    }

    return __result;
}

bool chromatixHAFType::parameter_versionStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        PARAMETER_STRCPY(__value, __size, revision);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::parameter_versionStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const /*__value*/)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        // Cannot modify strings, risk of memory leaks or corruption
    }

    return __result;
}

bool chromatixHAFType::parameter_versionStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // revision
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("revision", ParameterParserDataType::String, revision));
    }
    else if (PARAMETER_STRCMP(__name, "revision") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::String, revision));
    }

    return __result;
}

bool chromatixHAFType::enable_sectionStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "CAFEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)CAFEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "PDAFEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)PDAFEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "TOFEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)TOFEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "DCIAFEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)DCIAFEnable, __value, __size, 0);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "DepthAFEnable") == 0)
    {
        ParameterUtils::DoubleToString((double)DepthAFEnable, __value, __size, 0);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::enable_sectionStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "CAFEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            CAFEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "PDAFEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            PDAFEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "TOFEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            TOFEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "DCIAFEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            DCIAFEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "DepthAFEnable") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            DepthAFEnable = (globalelements::enable_flag_type)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFType::enable_sectionStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // CAFEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("CAFEnable", ParameterParserDataType::Int32, (double)CAFEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "CAFEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)CAFEnable, 0));
    }

    // PDAFEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("PDAFEnable", ParameterParserDataType::Int32, (double)PDAFEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "PDAFEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)PDAFEnable, 0));
    }

    // TOFEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("TOFEnable", ParameterParserDataType::Int32, (double)TOFEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "TOFEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)TOFEnable, 0));
    }

    // DCIAFEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("DCIAFEnable", ParameterParserDataType::Int32, (double)DCIAFEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "DCIAFEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)DCIAFEnable, 0));
    }

    // DepthAFEnable
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("DepthAFEnable", ParameterParserDataType::Int32, (double)DepthAFEnable, 0));
    }
    else if (PARAMETER_STRCMP(__name, "DepthAFEnable") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Int32, (double)DepthAFEnable, 0));
    }

    return __result;
}

bool chromatixHAFType::defaultROISizeStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "width") == 0)
    {
        ParameterUtils::DoubleToString((double)width, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "height") == 0)
    {
        ParameterUtils::DoubleToString((double)height, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "lowlightScalerRatio") == 0)
    {
        ParameterUtils::DoubleToString((double)lowlightScalerRatio, __value, __size);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::defaultROISizeStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "width") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            width = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "height") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            height = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "lowlightScalerRatio") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            lowlightScalerRatio = (float)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFType::defaultROISizeStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // width
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("width", ParameterParserDataType::Float, (double)width));
    }
    else if (PARAMETER_STRCMP(__name, "width") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)width));
    }

    // height
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("height", ParameterParserDataType::Float, (double)height));
    }
    else if (PARAMETER_STRCMP(__name, "height") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)height));
    }

    // lowlightScalerRatio
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("lowlightScalerRatio", ParameterParserDataType::Float, (double)lowlightScalerRatio));
    }
    else if (PARAMETER_STRCMP(__name, "lowlightScalerRatio") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)lowlightScalerRatio));
    }

    return __result;
}

bool chromatixHAFType::ROIGridSettingStruct::GetValue(
    const CHAR* const __path,
    CHAR* const       __value,
    UINT32 const      __size)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "gridRatioH") == 0)
    {
        ParameterUtils::DoubleToString((double)gridRatioH, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gridRatioV") == 0)
    {
        ParameterUtils::DoubleToString((double)gridRatioV, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioH") == 0)
    {
        ParameterUtils::DoubleToString((double)gridGapRatioH, __value, __size);
        __result = true;
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioV") == 0)
    {
        ParameterUtils::DoubleToString((double)gridGapRatioV, __value, __size);
        __result = true;
    }

    return __result;
}

bool chromatixHAFType::ROIGridSettingStruct::SetValue(
    const CHAR* const __path,
    const CHAR* const __value)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    if (PARAMETER_STRCMP(__name, "gridRatioH") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gridRatioH = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gridRatioV") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gridRatioV = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioH") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gridGapRatioH = (float)dblValue; 
        }
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioV") == 0)
    {
        const double dblValue = ParameterUtils::StringToDouble(__value, __result);
        if (__result)
        {
            gridGapRatioV = (float)dblValue; 
        }
    }

    return __result;
}

bool chromatixHAFType::ROIGridSettingStruct::GetInfo(
    const CHAR* const           __path,
    PList<ParameterParserInfo>& __info)
{
    constexpr SIZE_T MAX_SIZE = 129;
    CHAR   __name[MAX_SIZE] = "";
    UINT32 __index          = MAX_UINT;
    bool   __result         = false;

    ParameterUtils::GetVariable(__path, __name, __index, MAX_SIZE);

    // gridRatioH
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gridRatioH", ParameterParserDataType::Float, (double)gridRatioH));
    }
    else if (PARAMETER_STRCMP(__name, "gridRatioH") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gridRatioH));
    }

    // gridRatioV
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gridRatioV", ParameterParserDataType::Float, (double)gridRatioV));
    }
    else if (PARAMETER_STRCMP(__name, "gridRatioV") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gridRatioV));
    }

    // gridGapRatioH
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gridGapRatioH", ParameterParserDataType::Float, (double)gridGapRatioH));
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioH") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gridGapRatioH));
    }

    // gridGapRatioV
    if (__name[0] == '\0')
    {
        __result = true;
        __info.Add(ParameterParserInfo("gridGapRatioV", ParameterParserDataType::Float, (double)gridGapRatioV));
    }
    else if (PARAMETER_STRCMP(__name, "gridGapRatioV") == 0)
    {
        __result = true;
        __info.Add(ParameterParserInfo(nullptr, ParameterParserDataType::Float, (double)gridGapRatioV));
    }

    return __result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// @brief Read enum value
/// @param entry [in] Symbol table entry
/// @param enumValue [out] Enum value to read
/// @param alignment [in] Symbol table byte alignment
/// @return true if successful
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool ReadEnum_chromatixAFFocusValueStatsType(
    ParameterFileSymbolTableEntry* const entry,
    chromatixAFFocusValueStatsType& enumValue,
    BYTE const alignment)
{
    bool result {false};

    UINT32 uintValue {entry->ReadEnum(&result, alignment)};

    if (result)
    {
        switch (uintValue)
        {
        case static_cast<UINT32>(chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_HW_1):
            enumValue = chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_HW_1;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_HW_2):
            enumValue = chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_HW_2;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_SW):
            enumValue = chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_SW;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_MAX):
            enumValue = chromatixAFFocusValueStatsType::AF_FV_STATS_TYPE_MAX;
            result    = true;
            break;
        default:
            PARAMETER_LOG_ERROR(entry->SetManager, "Invalid value(% u) converting UINT32 to chromatixAFFocusValueStatsType", uintValue);
            break;
        }
    }
    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// @brief Read enum value
/// @param entry [in] Symbol table entry
/// @param enumValue [out] Enum value to read
/// @param alignment [in] Symbol table byte alignment
/// @return true if successful
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool ReadEnum_chromatixAFFollowerDistanceType(
    ParameterFileSymbolTableEntry* const entry,
    chromatixAFFollowerDistanceType& enumValue,
    BYTE const alignment)
{
    bool result {false};

    UINT32 uintValue {entry->ReadEnum(&result, alignment)};

    if (result)
    {
        switch (uintValue)
        {
        case static_cast<UINT32>(chromatixAFFollowerDistanceType::AF_FOLLOWER_MACRO_RANGE):
            enumValue = chromatixAFFollowerDistanceType::AF_FOLLOWER_MACRO_RANGE;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFollowerDistanceType::AF_FOLLOWER_MID_RANGE):
            enumValue = chromatixAFFollowerDistanceType::AF_FOLLOWER_MID_RANGE;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFollowerDistanceType::AF_FOLLOWER_FAR_RANGE):
            enumValue = chromatixAFFollowerDistanceType::AF_FOLLOWER_FAR_RANGE;
            result    = true;
            break;
        case static_cast<UINT32>(chromatixAFFollowerDistanceType::AF_FOLLOWER_MAX_RANGE):
            enumValue = chromatixAFFollowerDistanceType::AF_FOLLOWER_MAX_RANGE;
            result    = true;
            break;
        default:
            PARAMETER_LOG_ERROR(entry->SetManager, "Invalid value(% u) converting UINT32 to chromatixAFFollowerDistanceType", uintValue);
            break;
        }
    }
    return result;
}


////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Default Constructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
chromatixHAFTypeClass::chromatixHAFTypeClass(
    const CHAR* const name)
    : ParameterModule(name, MAJOR, MINOR, PATCH, nullptr)
{
    PARAMETER_INITIALIZE(SymbolTableID);
    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(enable_section);
    PARAMETER_INITIALIZE(defaultROISize);
    PARAMETER_INITIALIZE(ROIGridSetting);
    PARAMETER_INITIALIZE(statsConsumeEnableCount);
    PARAMETER_INITIALIZE(statsConsumeEnable);
    PARAMETER_INITIALIZE(statsSelect);
    PARAMETER_INITIALIZE(fineSearchDropThreshold);
    PARAMETER_INITIALIZE(fineStepSize);
    PARAMETER_INITIALIZE(maxMoveStep);
    PARAMETER_INITIALIZE(maxMoveStepBuffer);
    PARAMETER_INITIALIZE(baseFrameDelay);
    PARAMETER_INITIALIZE(AFFineSearchExtension);
    PARAMETER_INITIALIZE(sceneChangeDuringFS);
    PARAMETER_INITIALIZE(faceCAFHighPriorityEnable);
    PARAMETER_INITIALIZE(enableInitialPosition);
    PARAMETER_INITIALIZE(initialLensIdx);
    PARAMETER_INITIALIZE(depthConfidenceCountThreshold);
    PARAMETER_INITIALIZE(HAFROISettings);
    PARAMETER_INITIALIZE(HAFFollowerSettings);
    PARAMETER_INITIALIZE(macroRegionThresholdInMM);
    PARAMETER_INITIALIZE(farRegionThresholdinMM);
    PARAMETER_INITIALIZE(fineStartMoveBuffer);
    PARAMETER_INITIALIZE(DOFMultiplier);
    PARAMETER_INITIALIZE(enableForceScanEnd);
    PARAMETER_INITIALIZE(enablePassiveScanTimeout);
    PARAMETER_INITIALIZE(enableZeroTouchLag);
    PARAMETER_INITIALIZE(maxScanCountThreshold);
    PARAMETER_INITIALIZE(gyroSettings);
    PARAMETER_INITIALIZE(enableDynamicAnchorPoints);
    PARAMETER_INITIALIZE(anchorPosition1);
    PARAMETER_INITIALIZE(anchorPosition2);
    PARAMETER_INITIALIZE(minimumFocusIndex);
    PARAMETER_INITIALIZE(HJNormalizedWeightType);
    PARAMETER_INITIALIZE(CAFHJNormalizedWeightType);
    PARAMETER_INITIALIZE(AFControlAECInfoEnable);
    PARAMETER_INITIALIZE(AFControlAECInfoFPS);
    PARAMETER_INITIALIZE(spd_stats_type);
    PARAMETER_INITIALIZE(spd_bg_stats_thresh_auto_convert_enable);
    PARAMETER_INITIALIZE(enableParallelSearch);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Constructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
chromatixHAFTypeClass::chromatixHAFTypeClass(
    const CHAR* const name,
    ModuleData* const moduleData)
    : ParameterModule(name, MAJOR, MINOR, PATCH, moduleData)
{
    PARAMETER_INITIALIZE(SymbolTableID);
    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(enable_section);
    PARAMETER_INITIALIZE(defaultROISize);
    PARAMETER_INITIALIZE(ROIGridSetting);
    PARAMETER_INITIALIZE(statsConsumeEnable);
    PARAMETER_INITIALIZE(statsSelect);
    PARAMETER_INITIALIZE(fineSearchDropThreshold);
    PARAMETER_INITIALIZE(fineStepSize);
    PARAMETER_INITIALIZE(maxMoveStep);
    PARAMETER_INITIALIZE(maxMoveStepBuffer);
    PARAMETER_INITIALIZE(baseFrameDelay);
    PARAMETER_INITIALIZE(AFFineSearchExtension);
    PARAMETER_INITIALIZE(sceneChangeDuringFS);
    PARAMETER_INITIALIZE(faceCAFHighPriorityEnable);
    PARAMETER_INITIALIZE(enableInitialPosition);
    PARAMETER_INITIALIZE(initialLensIdx);
    PARAMETER_INITIALIZE(depthConfidenceCountThreshold);
    PARAMETER_INITIALIZE(HAFROISettings);
    PARAMETER_INITIALIZE(HAFFollowerSettings);
    PARAMETER_INITIALIZE(macroRegionThresholdInMM);
    PARAMETER_INITIALIZE(farRegionThresholdinMM);
    PARAMETER_INITIALIZE(fineStartMoveBuffer);
    PARAMETER_INITIALIZE(DOFMultiplier);
    PARAMETER_INITIALIZE(enableForceScanEnd);
    PARAMETER_INITIALIZE(enablePassiveScanTimeout);
    PARAMETER_INITIALIZE(enableZeroTouchLag);
    PARAMETER_INITIALIZE(maxScanCountThreshold);
    PARAMETER_INITIALIZE(gyroSettings);
    PARAMETER_INITIALIZE(enableDynamicAnchorPoints);
    PARAMETER_INITIALIZE(anchorPosition1);
    PARAMETER_INITIALIZE(anchorPosition2);
    PARAMETER_INITIALIZE(minimumFocusIndex);
    PARAMETER_INITIALIZE(HJNormalizedWeightType);
    PARAMETER_INITIALIZE(CAFHJNormalizedWeightType);
    PARAMETER_INITIALIZE(AFControlAECInfoEnable);
    PARAMETER_INITIALIZE(AFControlAECInfoFPS);
    PARAMETER_INITIALIZE(spd_stats_type);
    PARAMETER_INITIALIZE(spd_bg_stats_thresh_auto_convert_enable);
    PARAMETER_INITIALIZE(enableParallelSearch);
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Destructor
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
chromatixHAFTypeClass::~chromatixHAFTypeClass()
{
    if (Loaded)
    {
        UnloadModule();
    }
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// GetName
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
const CHAR* chromatixHAFTypeClass::GetName(
    const CHAR* const type)
{
    const CHAR* name = type;
    CHAR temp[ParameterFileSymbolTableEntry::TYPE_LEN + 1];
    if (PARAMETER_STRCMP(type, ModuleData::GetType(temp, "chromatixHAF")) == 0)
    {
        name = "chromatixHAF";
    }
    return name;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixHAFGyroSettingsType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFGyroSettingsType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enableGyroSamplingRateAdjustment);
    PARAMETER_INITIALIZE(gyroSamplingRateMonitor);
    PARAMETER_INITIALIZE(gyroSamplingRateSearching);
    PARAMETER_INITIALIZE(gyroSamplingRateSearchingHJ);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enableGyroSamplingRateAdjustment, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gyroSamplingRateMonitor, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gyroSamplingRateSearching, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gyroSamplingRateSearchingHJ, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixAFFollowerStepType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixAFFollowerStepType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(stepSize);
    PARAMETER_INITIALIZE(numFarSteps);
    PARAMETER_INITIALIZE(numNearSteps);

    SYMBOL_TABLE_ENTRY_READ(entry, result, stepSize, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, numFarSteps, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, numNearSteps, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixSearchInfoType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixSearchInfoType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(AFFollowerMacroRange);
    PARAMETER_INITIALIZE(AFFollowerMidRange);
    PARAMETER_INITIALIZE(AFFollowerFarRange);

    result = AFFollowerMacroRange.Load(entry, alignment);
    if (result)
    {
        result = AFFollowerMidRange.Load(entry, alignment);
    }
    if (result)
    {
        result = AFFollowerFarRange.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixFollowerFineSearchInfoType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixFollowerFineSearchInfoType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(normalLightFineSearchInfo);
    PARAMETER_INITIALIZE(lowLightFineSearchInfo);

    result = normalLightFineSearchInfo.Load(entry, alignment);
    if (result)
    {
        result = lowLightFineSearchInfo.Load(entry, alignment);
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixHAFFollowerSettingsType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFFollowerSettingsType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enableFollower);
    PARAMETER_INITIALIZE(AFFollowerFineSearchSettings);
    PARAMETER_INITIALIZE(enableGravityCompensationForFollower);
    PARAMETER_INITIALIZE(jumpToStartLimitForFollower);
    PARAMETER_INITIALIZE(lowLightThresholdForFollower);
    PARAMETER_INITIALIZE(useFineSearchExtensionForFollower);
    PARAMETER_INITIALIZE(activeConvergenceFollowForFollower);
    PARAMETER_INITIALIZE(lensPosThresholdForActiveConvergenceFollow);
    PARAMETER_INITIALIZE(searchStrategy);
    PARAMETER_INITIALIZE(lensMappingStrategy);
    PARAMETER_INITIALIZE(enablePdafSearchAssist);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enableFollower, alignment)
    if (result)
    {
        result = AFFollowerFineSearchSettings.Load(entry, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableGravityCompensationForFollower, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, jumpToStartLimitForFollower, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, lowLightThresholdForFollower, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, useFineSearchExtensionForFollower, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, activeConvergenceFollowForFollower, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, lensPosThresholdForActiveConvergenceFollow, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, searchStrategy, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, lensMappingStrategy, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enablePdafSearchAssist, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixHAFROISettingsType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFROISettingsType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(HAFROIEnable);
    PARAMETER_INITIALIZE(HAFROIHNum);
    PARAMETER_INITIALIZE(HAFROIVNum);
    PARAMETER_INITIALIZE(HAFCenterROISize);
    PARAMETER_INITIALIZE(HAFCornerROISize);
    PARAMETER_INITIALIZE(HAFROIDelay);
    PARAMETER_INITIALIZE(enableROIShifting);
    PARAMETER_INITIALIZE(ROIShiftType);

    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFROIEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFROIHNum, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFROIVNum, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFCenterROISize, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFCornerROISize, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HAFROIDelay, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableROIShifting, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, ROIShiftType, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixAFFineSearchExtensionType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixAFFineSearchExtensionType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(enable);
    PARAMETER_INITIALIZE(maximumFineSearchExtensionCount);
    PARAMETER_INITIALIZE(numNearSteps);
    PARAMETER_INITIALIZE(numFarSteps);
    PARAMETER_INITIALIZE(stepSize);
    PARAMETER_INITIALIZE(decreaseDropRatio);

    SYMBOL_TABLE_ENTRY_READ(entry, result, enable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, maximumFineSearchExtensionCount, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, numNearSteps, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, numFarSteps, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, stepSize, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, decreaseDropRatio, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load chromatixHAFType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(module_version);
    PARAMETER_INITIALIZE(parameter_version);
    PARAMETER_INITIALIZE(enable_section);
    PARAMETER_INITIALIZE(defaultROISize);
    PARAMETER_INITIALIZE(ROIGridSetting);
    PARAMETER_INITIALIZE(statsConsumeEnable);
    PARAMETER_INITIALIZE(statsSelect);
    PARAMETER_INITIALIZE(fineSearchDropThreshold);
    PARAMETER_INITIALIZE(fineStepSize);
    PARAMETER_INITIALIZE(maxMoveStep);
    PARAMETER_INITIALIZE(maxMoveStepBuffer);
    PARAMETER_INITIALIZE(baseFrameDelay);
    PARAMETER_INITIALIZE(AFFineSearchExtension);
    PARAMETER_INITIALIZE(sceneChangeDuringFS);
    PARAMETER_INITIALIZE(faceCAFHighPriorityEnable);
    PARAMETER_INITIALIZE(enableInitialPosition);
    PARAMETER_INITIALIZE(initialLensIdx);
    PARAMETER_INITIALIZE(depthConfidenceCountThreshold);
    PARAMETER_INITIALIZE(HAFROISettings);
    PARAMETER_INITIALIZE(HAFFollowerSettings);
    PARAMETER_INITIALIZE(macroRegionThresholdInMM);
    PARAMETER_INITIALIZE(farRegionThresholdinMM);
    PARAMETER_INITIALIZE(fineStartMoveBuffer);
    PARAMETER_INITIALIZE(DOFMultiplier);
    PARAMETER_INITIALIZE(enableForceScanEnd);
    PARAMETER_INITIALIZE(enablePassiveScanTimeout);
    PARAMETER_INITIALIZE(enableZeroTouchLag);
    PARAMETER_INITIALIZE(maxScanCountThreshold);
    PARAMETER_INITIALIZE(gyroSettings);
    PARAMETER_INITIALIZE(enableDynamicAnchorPoints);
    PARAMETER_INITIALIZE(anchorPosition1);
    PARAMETER_INITIALIZE(anchorPosition2);
    PARAMETER_INITIALIZE(minimumFocusIndex);
    PARAMETER_INITIALIZE(HJNormalizedWeightType);
    PARAMETER_INITIALIZE(CAFHJNormalizedWeightType);
    PARAMETER_INITIALIZE(AFControlAECInfoEnable);
    PARAMETER_INITIALIZE(AFControlAECInfoFPS);
    PARAMETER_INITIALIZE(spd_stats_type);
    PARAMETER_INITIALIZE(spd_bg_stats_thresh_auto_convert_enable);
    PARAMETER_INITIALIZE(enableParallelSearch);

    result = module_version.Load(entry, alignment);
    if (result)
    {
        result = parameter_version.Load(entry, alignment);
    }
    if (result)
    {
        result = enable_section.Load(entry, alignment);
    }
    if (result)
    {
        result = defaultROISize.Load(entry, alignment);
    }
    if (result)
    {
        result = ROIGridSetting.Load(entry, alignment);
    }

    // Reading Array statsConsumeEnable from symbol table
    // Do not check result value here because the count value needs to be initialized in this block
    {
        statsConsumeEnableCount = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, statsConsumeEnableCount, alignment)
        constexpr const CHAR* const file {__FILE__};
        constexpr INT32 line {LINE_CONST};
        ParameterFileSymbolTableEntry  pointerEntryCls;
        ParameterFileSymbolTableEntry* const pointerEntry = &pointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(pointerEntryCls, entry, alignment);
        }

        if (result)
        {
            statsConsumeEnableID = pointerEntry->ID;
            DupObjInfo* statsConsumeEnableDupInfo = pointerEntry->GetDupObject(statsConsumeEnableCount, file, line);
            if (statsConsumeEnableDupInfo != nullptr && statsConsumeEnableDupInfo->Object != nullptr)
            {
                statsConsumeEnable = (UINT32*)statsConsumeEnableDupInfo->Object;
                if (statsConsumeEnable == nullptr)
                {
                    if (statsConsumeEnableDupInfo->File != nullptr)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "statsConsumeEnable duplicate found but object is nullptr: %s:%d, RefCount: %d\n",
                            statsConsumeEnableDupInfo->File, statsConsumeEnableDupInfo->Line, statsConsumeEnableDupInfo->RefCount);
                    }
                    else
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "statsConsumeEnable duplicate found but Object is nullptr: <nullptr file ptr>:%d, RefCount: %d\n",
                            statsConsumeEnableDupInfo->Line, statsConsumeEnableDupInfo->RefCount);
                    }
                }
            }

            if (statsConsumeEnable == nullptr)
            {
                if (result && statsConsumeEnableCount > 0)
                {
                    statsConsumeEnable = pointerEntry->ReadArray<UINT32>(statsConsumeEnableCount, alignment);
                    result = statsConsumeEnable != nullptr;
                }
                if (!result || statsConsumeEnable == nullptr)
                {
                    if (statsConsumeEnableCount > 0)
                    {
                        PARAMETER_LOG_ERROR(entry->SetManager, "Failed to allocate statsConsumeEnable\n");
                    }
                    statsConsumeEnableCount = 0;
                }
            }
        }
        if (statsConsumeEnable == nullptr)
        {
            statsConsumeEnableCount = 0;
        }
    }
    if (result)
    {
        result = afhafelements::ReadEnum_chromatixAFFocusValueStatsType(entry, statsSelect, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, fineSearchDropThreshold, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, fineStepSize, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, maxMoveStep, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, maxMoveStepBuffer, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, baseFrameDelay, alignment)
    if (result)
    {
        result = AFFineSearchExtension.Load(entry, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, sceneChangeDuringFS, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, faceCAFHighPriorityEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableInitialPosition, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, initialLensIdx, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, depthConfidenceCountThreshold, alignment)
    if (result)
    {
        result = HAFROISettings.Load(entry, alignment);
    }
    if (result)
    {
        result = HAFFollowerSettings.Load(entry, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, macroRegionThresholdInMM, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, farRegionThresholdinMM, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, fineStartMoveBuffer, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, DOFMultiplier, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableForceScanEnd, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enablePassiveScanTimeout, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableZeroTouchLag, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, maxScanCountThreshold, alignment)
    if (result)
    {
        result = gyroSettings.Load(entry, alignment);
    }
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableDynamicAnchorPoints, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, anchorPosition1, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, anchorPosition2, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, minimumFocusIndex, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, HJNormalizedWeightType, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, CAFHJNormalizedWeightType, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, AFControlAECInfoEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, AFControlAECInfoFPS, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, spd_stats_type, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, spd_bg_stats_thresh_auto_convert_enable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, enableParallelSearch, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load module_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::module_versionStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(major_revision);
    PARAMETER_INITIALIZE(minor_revision);
    PARAMETER_INITIALIZE(incr_revision);

    SYMBOL_TABLE_ENTRY_READ(entry, result, major_revision, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, minor_revision, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, incr_revision, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load parameter_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::parameter_versionStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(revision);


    // Reading String revision from symbol table
    {
        UINT32 count = 0;
        SYMBOL_TABLE_ENTRY_READ(entry, result, count, alignment)
        ParameterFileSymbolTableEntry stringPointerEntryCls;
        ParameterFileSymbolTableEntry* const stringPointerEntry = &stringPointerEntryCls;
        if (result)
        {
            result = entry->Table->ReadPointerEntry(stringPointerEntryCls, entry, alignment);
        }
        SYMBOL_TABLE_ENTRY_READ_STRING(stringPointerEntry, result, revision, count, alignment)
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load enable_sectionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::enable_sectionStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(CAFEnable);
    PARAMETER_INITIALIZE(PDAFEnable);
    PARAMETER_INITIALIZE(TOFEnable);
    PARAMETER_INITIALIZE(DCIAFEnable);
    PARAMETER_INITIALIZE(DepthAFEnable);

    SYMBOL_TABLE_ENTRY_READ(entry, result, CAFEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, PDAFEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, TOFEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, DCIAFEnable, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, DepthAFEnable, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load defaultROISizeStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::defaultROISizeStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(width);
    PARAMETER_INITIALIZE(height);
    PARAMETER_INITIALIZE(lowlightScalerRatio);

    SYMBOL_TABLE_ENTRY_READ(entry, result, width, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, height, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, lowlightScalerRatio, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load ROIGridSettingStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFType::ROIGridSettingStruct::Load(
    ParameterFileSymbolTableEntry* const entry,
    BYTE const alignment)
{
    bool result = true;

    PARAMETER_INITIALIZE(gridRatioH);
    PARAMETER_INITIALIZE(gridRatioV);
    PARAMETER_INITIALIZE(gridGapRatioH);
    PARAMETER_INITIALIZE(gridGapRatioV);

    SYMBOL_TABLE_ENTRY_READ(entry, result, gridRatioH, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gridRatioV, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gridGapRatioH, alignment)
    SYMBOL_TABLE_ENTRY_READ(entry, result, gridGapRatioV, alignment)

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload chromatixHAFType
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void chromatixHAFType::Unload(ParameterFileSymbolTable* const __table)
{
    parameter_version.Unload(__table);
    if (__table != nullptr && __table->ReleaseDupObject(statsConsumeEnable))
    {
        PARAMETER_DELETE[] statsConsumeEnable;
    }
    statsConsumeEnable = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload parameter_versionStruct
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void chromatixHAFType::parameter_versionStruct::Unload(ParameterFileSymbolTable* const __table)
{
    if (__table != nullptr && __table->ReleaseDupObject(revision))
    {
        PARAMETER_DELETE[] revision;
    }
    revision = nullptr;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Release the ParameterModule object
/// Requires that this object was created via a ParameterSetManager::GetModule call
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void chromatixHAFType::Release()
{
    ((chromatixHAFTypeClass*)this)->Release();
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Returns the ParameterModule::Modified value
/// The Modified value is incremented when the module's data or pointer values change
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
UINT32 chromatixHAFType::GetModified()
{
    return ((chromatixHAFTypeClass*)this)->Modified;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Create module, and return a new object
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
ParameterModule* chromatixHAFTypeClass::Create(
    ModuleData*    moduleData,
    DefaultModule* const defModule) const
{
    chromatixHAFTypeClass* cls = nullptr;

    if (PARAMETER_STRCMP(Type, moduleData->Type) == 0 && Version.Value == moduleData->Version.Value)
    {
        const UINT32 id = moduleData->DuplicateID > 0 ? moduleData->DuplicateID : moduleData->ID;

        ParameterModule* const module = defModule->Find(id);
        if (module != nullptr)
        {
            cls = (chromatixHAFTypeClass*)module;
        }
        else
        {
            cls = PARAMETER_NEW chromatixHAFTypeClass(GetName(moduleData->Type), moduleData);
            cls->SymbolTableID = id;
            defModule->AddModule((ParameterModule*)cls);
        }
    }
    else if (Version.Value != moduleData->Version.Value)
    {
        PARAMETER_LOG_ERROR(moduleData->SetManager, "Unable to create chromatixHAFTypeClass, binary version (%lld) does not match source version (%lld)\n",
            moduleData->Version.Value, Version.Value);
    }
    else
    {
        PARAMETER_LOG_ERROR(moduleData->SetManager, "Unable to create chromatixHAFTypeClass, binary name (%s) does not match source name (%s)\n",
            moduleData->Type, Type);
    }

    return (ParameterModule*)cls;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Load module data, return true is successful
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
bool chromatixHAFTypeClass::LoadModule(
    ParameterFileSymbolTable* const table)
{
    bool result = true;

    if (!Loaded)
    {
        BYTE const alignment = table->Alignment;
        chromatixHAFTypeClass* const cls = this;

        ParameterFileSymbolTableEntry  entryObj;
        ParameterFileSymbolTableEntry* const entry = &entryObj;
        // With EzTune enabled, the unused upper byte of SymbolTableID value can change, so clear it
        result = table->Find(entryObj, SymbolTableID & 0x00ffffff);

        if (!result)
        {
            PARAMETER_LOG_ERROR(entry->SetManager, "chromatixHAFTypeClass::LoadModule Failed to find module ID (%d) in Symbol Table\n", SymbolTableID);
        }

        if (result)
        {
            result = cls->Load(entry, alignment);
        }
        Modified++;
        Loaded = true;
    }

    if (!result)
    {
        /// Module failed to fully load, unload it
        UnloadModule();
    }

    return result;
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// Unload module data
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void chromatixHAFTypeClass::UnloadModule()
{
    if (Loaded)
    {
        if (Data != nullptr && Data->SymbolTable != nullptr)
        {
            Unload(Data->SymbolTable);
        }
        else
        {
            PARAMETER_LOG_ERROR(Data != nullptr ? Data->SetManager : nullptr, "UnloadModule %s called with nullptr "
                "Data->SymbolTable object\n", Name);
            Unload(nullptr);
        }
        Loaded = false;
    }
}

////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/// /// Release the ParameterModule object
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void chromatixHAFTypeClass::Release()
{
    ParameterModule::Release();
}

AFHAFELEMENTS_NAMESPACE_END
