Logarithmic Curve Generation Method, Device, and Storage Medium
AssigneeHonor Device Co., Ltd.
InventorsYan Mo, Hantao Cui
Life of this patent
Estimating the term…
Abstract
Embodiments of this application provide a logarithmic curve generation method, a device, and a storage medium. The method includes: determining a dynamic range of a photosensitive element of a mobile device and a coding depth of the mobile device; obtaining a plurality of numerical points within the dynamic range, where each numerical point includes a stop within the dynamic range and a corresponding code value; and performing curve fitting based on the plurality of numerical points to obtain a log curve, where when the mobile device shoots in a log mode, the log curve is used to convert, into a code value, a raw signal that is output by the photosensitive element and that indicates brightness.
Claims20
A logarithmic curve generation method, comprising:
- determining a dynamic range of a photosensitive element of a mobile device and a coding depth of the mobile device;
- obtaining a plurality of numerical points within the dynamic range, wherein each numerical point comprises a stop within the dynamic range and a corresponding code value;
- and
- performing curve fitting based on the plurality of numerical points to obtain a log curve, wherein when the mobile device shoots in a log mode, the log curve is used to convert, into a code value, a raw signal that is output by the photosensitive element and that indicates brightness;
- when a horizontal axis is scene reflectance and a vertical axis is normalized code value, a formula of the log curve is as follows:
- when Tscenereflection is greater than 0.0028,
- Y
- cv
- =
- 0
- .
- 3
-
- 1
-
- 4
-
- 5
- ×
- log
- 1
-
- 0
- (
- 5
- .
- 5
-
- 5
-
- 5
-
- 5
-
- 5
-
- 6
- ×
- T
- scene
- reflection
- +
- 0
- .
- 0
-
- 7
-
- 9
-
- 0
-
- 7
- )
- +
- 0
- .
- 4
-
- 471
- ;
- or
- when Tscenereflection is not greater than 0.0028,
- Y
- cv
- =
- 1
-
- 1
- .
- 4
-
- 6
-
- 9
-
- 5
- ×
- T
- scene
- reflection
- +
- 0
- .
- 0
-
- 9
-
- 2
-
- 8
-
- 641
- ;
- and
- wherein Tscenereflection is the scene reflectance, and Ycv is the normalized code value.
An electronic device, comprising a memory and one or more processors, wherein
- the memory is configured to store a computer program;
- and
- the one or more processors are configured to execute the computer program, and executing the computer program causes the electronic device to:
- determine a dynamic range of a photosensitive element of a mobile device and a coding depth of the mobile device;
- obtain a plurality of numerical points within the dynamic range, wherein each numerical point comprises a stop within the dynamic range and a corresponding code value;
- and
- perform curve fitting based on the plurality of numerical points to obtain a log curve, wherein when the mobile device shoots in a log mode, the log curve is used to convert, into a code value, a raw signal that is output by the photosensitive element and that indicates brightness;
- wherein when a horizontal axis is scene reflectance and a vertical axis is normalized code value, a formula of the log curve is as follows:
- when Tscenereflection is greater than 0.0028,
- Y
- cv
- =
- 0.3145
- ×
- log
- 10
- (
- 5.555556
- ×
- T
- scene
- reflection
- +
- 0.07907
- )
- +
- 0.4471
- ;
- or
- when Tscenereflection is not greater than 0.0028,
- Y
- cv
- =
- 11.
- 4
-
- 6
-
- 95
- ×
- T
- scene
- reflection
- +
- 0.0928641
- ;
- and
- wherein Tscenereflection is the scene reflectance, and Ycv is the normalized code value.
(canceled)
A non-transitory computer storage medium, configured to store a computer program, and when the computer program is executed, an electronic device is caused to:
- determine a dynamic range of a photosensitive element of a mobile device and a coding depth of the mobile device;
- obtain a plurality of numerical points within the dynamic range, wherein each numerical point comprises a stop within the dynamic range and a corresponding code value;
- and
- perform curve fitting based on the plurality of numerical points to obtain a log curve, wherein when the mobile device shoots in a log mode, the log curve is used to convert, into a code value, a raw signal that is output by the photosensitive element and that indicates brightness;
- wherein when a horizontal axis is scene reflectance and a vertical axis is normalized code value, a formula of the log curve is as follows:
- when Tscenereflection is greater than 0.0028,
- Y
- cv
- =
- 0
- .
- 3
-
- 1
-
- 4
-
- 5
- ×
- log
- 1
-
- 0
- (
- 5
- .
- 5
-
- 5
-
- 5
-
- 5
-
- 56
- ×
- T
- scene
- reflection
- +
- 0.07907
- )
- +
- 0
- .
- 4
-
- 471
- ;
- or
- when Tscenereflection is not greater than 0.0028,
- Y
- cv
- =
- 1
-
- 1
- .
- 4
-
- 6
-
- 95
- ×
- T
- scene
- reflection
- +
- 0.0928641
- ;
- wherein Tscenereflection is the scene reflectance, and Ycv is the normalized code value.
Dependencies are inferred from the claim text.