.. index:: 
  !PortraitProcessor.sharpnessThreshold Property

.. _id3_face_portrait_processor_sharpness_threshold_class_member:

===============================================================================
PortraitProcessor.sharpnessThreshold Property
===============================================================================

Module: :ref:`PortraitProcessor<id3_face_portrait_processor_class>`

Type: int

Definition
----------

Sharpness threshold. 

If the sharpness score is above this value, the image sharpness is sufficient.

.. hint:: Default value is 50.


.. tab-set::

  .. tab-item:: Python
    :sync: Python

    .. code:: Python

      sharpness_threshold: int


    **Exceptions**

      .. line-block::

        :ref:`FaceException<id3_face_face_exception>`
        An error has occurred during Face Library execution.

  .. tab-item:: Dart
    :sync: Dart

    .. code:: Dart

      int get sharpnessThreshold => getSharpnessThreshold();
      set sharpnessThreshold(int value) => setSharpnessThreshold(value);


    **Exceptions**

      .. line-block::

        :ref:`FaceException<id3_face_face_exception>`
        An error has occurred during Face Library execution.

  .. tab-item:: C#
    :sync: C#

    .. code:: C#

      public int sharpnessThreshold
      {
          get => GetsharpnessThreshold();
          set => SetsharpnessThreshold(ref value);
      }


    **Exceptions**

      .. line-block::

        :ref:`FaceException<id3_face_face_exception>`
        An error has occurred during Face Library execution.

  .. tab-item:: Java
    :sync: Java

    .. code:: Java

      public int getSharpnessThreshold() throws FaceException
      public void setSharpnessThreshold(int sharpnessThreshold) throws FaceException


    **Exceptions**

      .. line-block::

        :ref:`FaceException<id3_face_face_exception>`
        An error has occurred during Face Library execution.

  .. tab-item:: Swift
    :sync: Swift

    .. code:: Swift

      public var sharpnessThreshold: Int
          get {
              return Int(try! getSharpnessThreshold())
          }
      }


    **Exceptions**

      .. line-block::

        :ref:`FaceException<id3_face_face_exception>`
        An error has occurred during Face Library execution.

  .. tab-item:: C
    :sync: C

    .. code:: C

      int id3FacePortraitProcessor_GetSharpnessThreshold (ID3_FACE_PORTRAIT_PROCESSOR hPortraitProcessor, int * sharpnessThreshold)
      int id3FacePortraitProcessor_SetSharpnessThreshold (ID3_FACE_PORTRAIT_PROCESSOR hPortraitProcessor, int sharpnessThreshold)

    **Returns**
   
      .. line-block::

        ``int``
        An error code.
        See :ref:`id3FaceError<id3_face_face_error_enum>` file for the list of possible error codes.

