Data processing method, device, apparatus and readable storage medium
By acquiring and updating the slope of the configuration control points, a globally monotonically increasing business curve is generated, which solves the problem of insufficient monotonicity of traditional Bézier curves in image mapping, and achieves consistency in cross-platform display and improved computational efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- TENCENT TECHNOLOGY (SHENZHEN) CO LTD
- Filing Date
- 2026-04-03
- Publication Date
- 2026-07-31
AI Technical Summary
Traditional Bézier curves cannot guarantee monotonically increasing in image mapping, leading to local inversions and inflection points, which affects the consistency of cross-platform display.
By acquiring the coordinate information of N configuration control points, candidate slopes are generated, and the candidate slopes are updated according to the monotonicity conditions of adjacent control points to generate calibration slopes, ensuring that the sub-curves are monotonically increasing and the generated business curves are globally monotonically increasing.
It achieves smooth incremental image mapping, reduces the difficulty and computational complexity of control point setting, improves computational efficiency, and ensures consistency of cross-platform display.
Smart Images

Figure CN122496720A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer technology, and in particular to a data processing method, apparatus, device, and readable storage medium. Background Technology
[0002] When there is a difference between the image standard of video data and the image standard supported by the display device, such as when HDR (High Dynamic Range) video data is converted to SDR (Standard Dynamic Range) display device, image mapping of the video data is required to ensure consistency of cross-device display.
[0003] Image mapping defines a mapping curve in the metadata of image data to achieve the mapping between input and output signals. The curve is typically set using a Bézier curve. Traditional Bézier curves rely on control points, which provide information about the curve's direction of curvature. The curve can gradually approach the control points through concave or convex points, but it doesn't actually pass through them. This makes setting control points unintuitive and difficult. Furthermore, image mapping needs to satisfy the requirement of gradual increase, but traditional Bézier curve generation methods cannot consider the constraint of monotonically increasing curves. This can easily lead to local inversions, inflection points, and other non-monotonic increases, resulting in a generated curve that fails to maintain consistency across different image mapping stages. Summary of the Invention
[0004] This application provides a data processing method, apparatus, device, and readable storage medium, which can reduce the cost of setting up control points and ensure the consistency of image mapping.
[0005] One embodiment of this application provides a data processing method, including: Obtain N configuration control points used to control signal changes in media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; Generate candidate slopes corresponding to N configuration control points. If it is determined from the two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset conditions for monotonicity, then update the candidate slopes corresponding to the target configuration control point to obtain the calibration slopes corresponding to the target configuration control point; otherwise, determine the candidate slopes corresponding to the target configuration control point as the calibration slopes; the N configuration control points include the target configuration control point. Based on the calibration slopes corresponding to the N configuration control points, a service curve consisting of N-1 sub-curves is generated. The N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing. Each sub-curve contains two adjacent configuration control points from the N configuration control points. The service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0006] One embodiment of this application provides a data processing apparatus, including: The acquisition module is used to acquire N configuration control points for controlling the signal changes of media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; The calibration module generates candidate slopes for N configuration control points. If, based on two adjacent configuration control points, it is determined that the target configuration control point does not meet the preset conditions for monotonicity, the candidate slopes corresponding to the target configuration control point are updated to obtain the calibration slopes corresponding to the target configuration control point. Otherwise, the candidate slopes corresponding to the target configuration control point are determined as the calibration slopes. The N configuration control points include the target configuration control point. The generation module is used to generate a service curve consisting of N-1 sub-curves based on the calibration slopes corresponding to N configuration control points. The N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, and each sub-curve contains two adjacent configuration control points from the N configuration control points. The service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0007] In one possible implementation, the N configuration control points are arranged in a strictly monotonically increasing order of their x-coordinates; when the calibration module generates candidate slopes corresponding to the N configuration control points, it specifically performs the following operations: A starting auxiliary point is generated based on the first z configuration control points out of N configuration control points; z is a positive integer greater than or equal to 2. Generate the last auxiliary point based on the last z configuration control points out of N configuration control points; The starting auxiliary point, N configuration control points, and the ending auxiliary point are determined as N+2 extended control points. Based on the N+2 extended control points, candidate slopes corresponding to the N configuration control points are generated.
[0008] In one possible implementation, the first z configuration control points include a first configuration control point and a second configuration control point. When the calibration module generates the starting auxiliary point based on the first z configuration control points out of N configuration control points, it specifically performs the following operations: Generate an initial auxiliary x-coordinate based on the x-coordinate of the first and second configured control points; Generate an initial auxiliary ordinate based on the ordinate of the first and second configured control points; Determine the starting auxiliary point in the coordinate system based on the starting auxiliary abscissa and the starting auxiliary ordinate; the first configuration control point is the midpoint of the line segment formed by the starting auxiliary point and the second configuration control point.
[0009] In one possible implementation, the N configuration control points include configuration control points. , where i is an integer greater than or equal to 0, and the control point is configured. For N+2 extended control points The calibration module is used to generate candidate slopes corresponding to N configuration control points based on N+2 extended control points. Specifically, it performs the following operations: Obtain the control points from the N+2 extended control points. Two adjacent extended control points; Based on and extended control points The coordinate information corresponding to two adjacent extended control points is used to generate configuration control points. The corresponding candidate slope.
[0010] In one possible implementation, the N configuration control points are arranged in a strictly monotonically increasing order of their abscissas. The two configuration control points adjacent to the target configuration control point include the left neighbor control point preceding the target configuration control point and the right neighbor control point following the target configuration control point. The calibration module is also used to perform the following operations: Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, a first verification value is generated to characterize the monotonicity of the left neighbor curve; the left neighbor curve is the curve determined by the target configuration control point and the left neighbor control point. Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the right neighbor control point, and the candidate slope corresponding to the right neighbor control point, a second verification value is generated to characterize the monotonicity of the right neighbor curve; the right neighbor curve is the curve determined by the target configuration control point and the right neighbor control point. If the first verification value indicates that the left neighbor curve is non-monotonic, and / or the second verification value indicates that the right neighbor curve is non-monotonic, then it is determined that the target configuration control point does not meet the preset conditions for monotonicity. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the target configuration control point is determined to meet the preset conditions for monotonicity.
[0011] In one possible implementation, when the calibration module generates a first verification value to characterize the monotonicity of the left neighbor curve based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, it specifically performs the following operations: Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, the first left neighbor ordinate estimate is generated for the left neighbor curve. Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the target configuration control point, a second left neighbor ordinate estimate is generated for the left neighbor curve. The first left neighbor ordinate difference between the ordinate of the generated left neighbor control point and the estimated ordinate of the first left neighbor, the second left neighbor ordinate difference between the estimated ordinate of the first left neighbor and the estimated ordinate of the second left neighbor, and the third left neighbor ordinate difference between the estimated ordinate of the second left neighbor and the ordinate of the target configuration control point are generated. Based on the first left neighbor ordinate difference, the second left neighbor ordinate difference, and the third left neighbor ordinate difference, a first verification value is generated to characterize the monotonicity of the left neighbor curve.
[0012] In one possible implementation, when the calibration module generates a first verification value to characterize the monotonicity of the left neighbor curve based on the first ordinate difference, the second ordinate difference, and the third ordinate difference, it specifically performs the following operations: Obtain the second-order difference results between the first, second, and third ordinate differences, as well as the geometric mean constraint results between the first, second, and third ordinate differences; Obtain the first comparison result between the second-order difference result and the difference threshold, and the second comparison result between the geometric mean constraint result and the monotonicity threshold; A first verification value is generated for the left neighbor curve based on the first comparison result and the second comparison result. If the first comparison result is a second-order difference result greater than the difference threshold, and the second comparison result is a geometric mean constraint result less than the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is non-monotonically increasing. If the first comparison result is a second-order difference result less than or equal to the difference threshold, and / or the second comparison result is a geometric mean constraint result greater than or equal to the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is monotonically increasing.
[0013] In one possible implementation, the calibration module is used to update the candidate slope corresponding to the target configuration control point to obtain the calibration slope corresponding to the target configuration control point if it is determined from two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset condition for monotonicity; otherwise, when the candidate slope corresponding to the target configuration control point is determined as the calibration slope, it is specifically used to perform the following operations: Based on the left neighbor control points and the target configuration control points, the left neighbor slope corresponding to the left neighbor curve is generated; based on the right neighbor control points and the target configuration control points, the right neighbor slope corresponding to the right neighbor curve is generated. If the first verification value indicates that the left neighbor curve is non-monotonic and the second verification value indicates that the right neighbor curve is non-monotonic, then the minimum value between the left neighbor slope and the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is non-monotonic and the second verification value indicates that the right neighbor curve is monotonically increasing, then the slope of the left neighbor is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, then the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the candidate slope corresponding to the target configuration control point is determined as the calibration slope.
[0014] In one possible implementation, the N configuration control points include adjacent first and second configuration control points; when the generation module generates a business curve consisting of N-1 sub-curves based on the calibration slopes corresponding to the N configuration control points, it specifically performs the following operations: Obtain the calibration slope corresponding to the first configuration control point and the calibration slope corresponding to the second configuration control point; Based on the difference in the horizontal coordinate between the first and second configuration control points, the calibration slope corresponding to the first configuration control point, and the vertical coordinate corresponding to the first configuration control point, the vertical coordinate of the left inner auxiliary control point is generated. Based on the difference in the horizontal coordinate between the first and second configuration control points, the calibration slope corresponding to the second configuration control point, and the vertical coordinate corresponding to the second configuration control point, the vertical coordinate of the right inner auxiliary control point is generated. Using the first configuration control point as the curve start point and the second configuration control point as the curve end point, a sub-curve containing the first configuration control point and the second configuration control point is generated by using the coordinate information corresponding to the curve start point, curve end point, first configuration control point and second configuration control point respectively, the ordinate of the left inner auxiliary control point and the ordinate of the right inner auxiliary control point. When the sub-curves corresponding to each pair of adjacent configuration control points among the N configuration control points are obtained, the N-1 sub-curves are combined to obtain the business curve.
[0015] In one possible implementation, the generation module is also used to perform the following operations: Obtain the input signal value of the j-th pixel in the media data. j is a positive integer; Obtain the input signal value from N configuration control points. Two adjacent configuration control points are associated as two candidate configuration control points; input signal values Located within the interval defined by the x-coordinates of two adjacent configuration control points; Based on input signal value And the x-coordinates of the two candidate configuration control points, to generate the input signal value The interpolation factor is used to generate the input signal value based on the interpolation factor and a sub-curve containing two candidate configuration control points. The corresponding curve mapping value; If the mapping relationship between input signal values and output signal values in the metadata of the media data is a direct mapping relationship, then the input signal values will be... The corresponding curve mapping value is determined as the input signal value. The corresponding output signal value; If the mapping relationship between the input signal value and the output signal value in the metadata is an indirect mapping relationship, then obtain the intermediate function for the input signal value and the output signal value, based on the input signal value. The corresponding curve mapping value and intermediate function are used to generate the input signal value. The corresponding output signal value.
[0016] In one possible implementation, the generation module is also used to perform the following operations: Obtain a list of preset input values for the business curve; the list of preset input values includes R discrete preset input values; R is a positive integer; Based on the business curve and R preset input values, output signal values corresponding to the R preset input values are generated respectively; Obtain the input signal value of the j-th pixel in the media data. Obtain the input signal value from R preset input values. Two adjacent preset input values, based on the input signal value The input signal value is obtained by interpolating the output signal values corresponding to the two preset input values to determine the degree of difference between them. The corresponding output signal value.
[0017] One embodiment of this application provides a computer device, including: a processor, a memory, and a network interface; The processor is connected to a memory and a network interface. The network interface is used to provide data communication functions, and the memory is used to store computer programs. When the computer program is executed by the processor, the computer device performs the method provided in the embodiments of this application.
[0018] One aspect of this application provides a computer-readable storage medium storing a computer program adapted to be loaded and executed by a processor, so that a computer device having the processor performs the method provided in this application.
[0019] One embodiment of this application provides a computer program product comprising a computer program stored in a computer-readable storage medium. A processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to perform the method provided in this application embodiment.
[0020] This application embodiment obtains N configuration control points for controlling signal changes in media data. The coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data. The horizontal coordinates of the N configuration control points are strictly monotonically increasing, and the vertical coordinates of the N configuration control points are monotonically increasing, ensuring that the input signal value and output signal value are arranged in an orderly manner from small to large, constraining the monotonicity of the information source from the source, and providing a monotonicity basis for subsequent slope adjustment. Candidate slopes representing the steepness of signal changes at each configuration control point are generated. Based on two configuration control points adjacent to the target configuration control point, it is determined whether the local curve segment corresponding to the target configuration control point meets the preset conditions for monotonicity. Local monotonicity is determined using these two adjacent configuration control points. Candidate slopes corresponding to target configuration control points that do not meet the preset conditions are updated to obtain the calibration slope corresponding to the target configuration control point. Candidate slopes corresponding to target configuration control points that meet the preset conditions are directly determined as calibration slopes. This corrects the monotonicity defects of candidate slopes, avoiding distortions such as dips and inflection points in local curve segments caused by directly using candidate slopes, and preventing non-monotonic increases such as local reversals. This ensures that local curve segments are monotonically increasing. Therefore, by generating candidate slopes and using preset conditions for monotonicity, candidate slopes that do not meet monotonicity can be updated and corrected, mitigating the risk of distortion in local curve segments. The calibration slope controls the direction of local curve segments (i.e., sub-curves), ensuring a smooth increase in local curve segments. Finally, N-1 sub-curves are generated using the calibration slopes corresponding to the N configuration control points. Each sub-curve contains two adjacent configuration control points from the N configuration control points. This effectively splits the multiple Bézier curves into cubic Bézier curves that always pass through the start and end points, ensuring that each generated sub-curve passes through two adjacent configuration control points. Since the generation of each sub-curve only needs to consider two adjacent configuration control points, high-order operations of multiple Bézier curves are avoided, reducing computational complexity and cost, and improving computational efficiency. The calibration slopes ensure that each sub-curve increases monotonically segment by segment, and the entire spliced service curve also exhibits a globally monotonically increasing trend. Through the service curve, the mapping between the input and output signal values of the media data can be achieved. In this embodiment, the generated service curve can be intuitively and quantitatively controlled through N configuration control points, improving the flexibility and controllability of the service curve. Because the service curve always passes through N configuration control points and exhibits a globally monotonically increasing trend, the difficulty of setting control points and the required computational cost are reduced, ensuring that the output signal value changes synchronously with the input signal value, achieving consistency in image mapping. Attached Figure Description
[0021] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0022] Figure 1 This is a schematic diagram of a network architecture provided in an embodiment of this application; Figure 2 This is a scenario illustration of a data processing method provided in an embodiment of this application. Figure 1 ; Figure 3 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 1 ; Figure 4 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 2 ; Figure 5 This is a scenario illustration of a data processing method provided in an embodiment of this application. Figure 2 ; Figure 6 This is a schematic diagram of the structure of a data processing device provided in an embodiment of this application; Figure 7 This is a schematic diagram of the structure of a computer device provided in an embodiment of this application. Detailed Implementation
[0023] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the scope of protection of this application.
[0024] It is understood that in the specific embodiments of this application, user (object or player) data is involved, such as media data and configuration control points that can be provided by the user. When the above and below embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant regions.
[0025] If this application requires the collection of object data (such as user data), a prompt interface or pop-up window will be displayed before and during the collection process. This prompt interface or pop-up window is used to inform the user that certain data is being collected. The data acquisition steps will only begin after the user confirms the prompt interface or pop-up window; otherwise, the process will end. Furthermore, the acquired user data will be used in reasonable and legal scenarios or for legitimate purposes. Optionally, in scenarios where user data needs to be used but user authorization has not been obtained, authorization can be requested from the user, and the user data can only be used after authorization is granted.
[0026] The key terms and their definitions used in this application are as follows: Signal value refers to a parameter in a specific dimension of an image standard, such as brightness, color depth, color space, and contrast. These image signals determine the range of brightness, color richness, and contrast that an image or video can display. Image standards include SDR and HDR. SDR is the traditional video standard, with strict upper limits on brightness, color, and contrast, and has been the mainstream standard for televisions, monitors, and DVDs (Digital Video Discs) / Blu-rays for the past few decades. HDR is a new generation video standard that significantly expands the brightness range, color space, and color depth, making the image closer to the real world as seen by the human eye. The image signals referred to in this application include, but are not limited to, the original linear domain image signals, image signals converted by the Opto-Electronic Transfer Function (OETF), or the Electro-Optical Transfer Function (EOTF), or the Opto-Optical Transfer Function (OOTF), and logarithmic domain image signals converted by logarithmic functions. The Opto-Electronic Transfer Functions include, but are not limited to, BT.709 (a high-definition television color standard), PQ (Perceptual Quantizer), HLG (Hybrid Log–Gamma), etc. The embodiments of this application are not limited herein.
[0027] A Bézier curve is a mathematical parametric curve that generates a smooth curve using control points; it is a smooth interpolation curve. In this application, Bézier curves are used to define the mapping relationship between input signal values and output signal values, such as the mapping relationship between image brightness under the HDR standard and image brightness under the SDR standard.
[0028] Configuration control points. Different from the control points of traditional Bezier curves that only provide mapping direction information, the configuration control points proposed in this application are the points that must be passed through when setting a Bezier curve. After ensuring that the configuration control points are necessarily passed through, the Bezier curve generated in this application can strictly ensure the mapping relationship determined by the horizontal and vertical coordinates of the control points, improving the mapping accuracy of the Bezier curve and reducing the difficulty of setting control points in the Bezier curve.
[0029] Monotonicity. Monotonicity is one of the basic properties of a function, referring to the increasing or decreasing trend presented by the function as the independent variable changes within its defined interval, also known as increasing and decreasing property. In the field of image mapping, when the input signal gradually increases, it is also required that the output signal increases synchronously. Therefore, the Bezier curve needs to be monotonically increasing to ensure the synchronization and consistency of cross-terminal display. If for any x1 < x2 within the defined interval of the function, f(x1) ≤ f(x2), then the function is said to be monotonically increasing (also known as non-decreasing). If for any x1 < x2 within the defined interval of the function, f(x1) ≥ f(x2), then the function is said to be monotonically decreasing. If there exists at least one pair of x1 < x2 within the defined interval of the function such that f(x1) > f(x2), then the function is said to be non-monotonically increasing. Monotonic increasing also includes a special case, strictly monotonic increasing, which means that for any x1 < x2, f(x1) < f(x2), then the function is said to be strictly monotonic increasing.
[0030] Please refer to Figure 1 , Figure 1 It is a schematic diagram of a network architecture provided by an embodiment of this application. As Figure 1 shown, the network architecture may include a business server 100 and a cluster of terminal devices. The cluster of terminal devices may include terminal devices 10a, terminal devices 10b,..., terminal devices 10n. Among them, any terminal device in the cluster of terminal devices may have a communication connection with the business server 100. For example, there is a communication connection between terminal device 10a and business server 100, and there is a communication connection between terminal device 10b and business serverEach terminal device in the terminal device cluster shown can be equipped with an application client that has data processing capabilities. When the application client runs on each terminal device, it can interact with the aforementioned... Figure 1 Data interaction is performed between the business servers 100 shown.
[0032] The application client can specifically include: in-vehicle client, smart home client, entertainment client (e.g., game client), multimedia client (e.g., video client), social client, and information client (e.g., news client), etc. In this embodiment, the application client can be integrated into a client (e.g., a social client) or it can be a standalone client (e.g., a news client). This embodiment does not limit the type of application client. The business server 100 can be the server corresponding to the application client. The business server 100 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers.
[0033] like Figure 1 As shown, for ease of understanding, let's take terminal device 10a in the terminal device cluster as an example. Terminal device 10a can send a video acquisition request for target video data to the service server 100. For example, if the display components (such as monitors or displays) of terminal device 10a only support the SDR screen standard and the service server 100 only stores the target video data of the HDR screen standard, the service server 100 can send the target video data of the HDR screen standard to terminal device 10a.
[0034] Image mapping methods can include real-time parsing (conversion during playback) and pre-conversion (conversion in advance). Taking real-time parsing as an example, when starting to play target video data, the terminal device 10a can use the service curve (i.e., Bézier curve) contained in the metadata of the target video data to calculate the output signal value corresponding to the input signal value of each pixel in real time, and complete the image mapping of the target video data to obtain each video frame that conforms to the SDR picture standard.
[0035] Taking pre-conversion as an example, terminal device 10a can perform image mapping on the target video data in advance through the service curve contained in the metadata of the target video data to obtain the target video data of the SDR screen standard. Terminal device 10a can then play the target video data of the SDR screen standard through the display component.
[0036] Optionally, image mapping can also be performed by the service server 100. That is, the service server 100 can convert the target video data of the HDR picture standard into the target video data of the SDR picture standard through image mapping, and distribute the target video data of the SDR picture standard to the terminal device 10a.
[0037] This application embodiment achieves dynamic conversion between SDR and HDR standards through image mapping, enabling cross-device compatibility. This allows display components that only support the SDR standard to recognize and play HDR standard video data. At the same time, the business server 100 only needs to store one set of HDR standard master files, which can reduce the distribution and storage costs of the business server 100.
[0038] Please see Figure 2 , Figure 2 This is a scenario illustration of a data processing method provided in an embodiment of this application. Figure 1 .like Figure 2 As shown, the computer device can acquire control point information, which may include the coordinate information (e.g., horizontal and vertical coordinates) corresponding to N configured control points. These N configured control points are used to control the signal changes of the media data. The computer device can be, for example, […]. Figure 1 The business server 100 shown can be any terminal device in the terminal device cluster, such as terminal device 10a. The horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are also monotonically increasing in the order of arrangement. The coordinate information corresponding to the N configuration control points is used to indicate the input signal value and output signal value of the media data.
[0039] A computer device can divide N configuration control points into N-1 configuration control point pairs, where each pair contains two adjacent configuration control points. The computer device can obtain the calibration slope corresponding to each configuration control point in the N-1 configuration control point pairs. The process of generating the calibration slope is described below. Figure 3 The specific descriptions of steps S102 and S103 in the corresponding embodiments are as follows: The computer device can generate N-1 sub-curves based on the calibration slope corresponding to each configuration control point in the N-1 configuration control point pairs, and combine the N-1 sub-curves into a service curve. Specifically, one configuration control point pair is used to generate one sub-curve, the N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, each sub-curve contains two adjacent configuration control points from the N configuration control points, and the service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0040] This application's embodiments can be applied to multiple fields that rely on Bézier curves, such as graphic design, animation production, image processing, and embodied intelligence. In graphic design, the pen tool in drawing software such as PS, AI, CAD, Figma, and Sketch uses Bézier curves to control the curvature when drawing logos, icons, and illustrations. The curve generation method proposed in this application allows for the creation of accurate curves based solely on manually determined point information, avoiding manual adjustments and reducing the cost of curve drawing. In animation production, the movement of characters and objects, particle and camera paths in film and television special effects, and curved surfaces in 3D modeling are all defined by Bézier curves. The curve generation method proposed in this application allows for the creation of accurate, flexible, and controllable Bézier curves by quantifying the coordinates of configuration control points. In image processing, such as HDR / SDR brightness mapping and tone mapping, this application's embodiments can directly obtain several configuration control points through information such as bitstream and sidedata (private auxiliary data), automatically generating Bézier curves for image mapping, achieving precise image mapping effects, and reducing the difficulty of setting Bézier curves. In the field of embodied intelligence, the motion trajectory of a robotic arm and the smooth movement for obstacle avoidance can both be generated using Bezier interpolation to produce motion curves with continuous acceleration and no abrupt changes, thus preventing vibration, impact, and mechanical wear. The curve generation method proposed in this application can reduce the difficulty of setting Bezier curves, ensure that the motion trajectory is free of abrupt changes, reduce the computational cost required for the aforementioned movements, and improve efficiency.
[0041] Please see Figure 3 , Figure 3 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 1 This data processing method can be executed by a computer device, which can be, for example, Figure 1 The business server 100 shown or any terminal device in the terminal device cluster, such as terminal device 10a, can be used. The following description will use the example of this data processing method being executed by a computer device. This data processing method will at least include the following steps S101-S104: Step S101: Obtain N configuration control points for controlling the signal changes of media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; Specifically, the computer device can acquire N configuration control points for controlling signal changes in media data. These N configuration control points can be obtained from image and video files, bitstreams, sidedata (private ancillary data), etc., or can be parameters set by the user; this embodiment does not impose such limitations. The horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of their arrangement, and the vertical coordinates are also monotonically increasing in the order of their arrangement. The coordinate information corresponding to each of the N configuration control points is used to indicate the input and output signal values of the media data. The media data can be image data, video data, etc. The signal channel composition of the signal values corresponding to the media data includes, but is not limited to, three-channel images (such as RGB images) and single-channel images (such as grayscale images).
[0042] Taking the acquisition of N configuration control points from the media data stream as an example, if the N configuration control points are used to complete the image mapping between the HDR image standard and the SDR image standard, the computer device can generate a proportional scaling factor based on the value range of the signal values under the HDR image standard and the value range of the signal values under the SDR image standard. Based on the proportional scaling factor, N configuration control points are sampled at equal intervals in the two value ranges, where N can generally be a positive integer greater than or equal to 2. The specific coordinates of the N configuration control points are not limited in this embodiment, nor are they limited to whether the N configuration control points include the origin or whether there is at least one point outside the first quadrant. Image mapping can refer to TM (Tone Mapping), iTM (Inverse Tone Mapping), etc., and is not limited in this embodiment.
[0043] For any one of the N configuration control points , It should include coordinate information: ,in, Indicates the configuration control point The horizontal axis is used to indicate the input signal value of the media data. Indicates the configuration control point The ordinate is used to indicate the output signal value of the media data. For all control points, the x-coordinate must be strictly monotonically increasing, and the ordinate must be monotonically increasing, i.e., for each control point... ,satisfy ,and .when When, it means that during image mapping, multiple consecutive input signal values are allowed to be mapped to the same output signal value.
[0044] Step S102: Generate candidate slopes corresponding to N configuration control points respectively; Specifically, the computer device can generate a list of control point x-coordinates and a list of control point y-coordinates corresponding to N configuration control points. The list of control point x-coordinates can be represented as... The list of control point ordinates can represent .
[0045] Computer equipment can generate starting auxiliary points based on the first z configuration control points out of N configuration control points. Based on the last z configuration control points out of N configuration control points, generate the last auxiliary point. Where z is a positive integer greater than or equal to 2, the starting auxiliary point is used for forward extension to help generate a sub-curve for the first z configuration control points, and the ending auxiliary point is used for backward extension to help generate a sub-curve for the last z configuration control points. The computer device can determine the starting auxiliary point, N configuration control points, and ending auxiliary point together as N+2 extended control points. For any one of the N+2 extended control points... , When i=0, When i = N+1, When i ≠ 0 or N+1, , .
[0046] The computer device can generate candidate slopes corresponding to N configuration control points based on N+2 extended control points. A candidate slope indicates the slope between adjacent extended control points and the corresponding configuration control point. For any one of the N configuration control points... This configuration control point This can also be called the target configuration control point. It can also correspond to the extension control points among N+2 extension control points. For example, configuring control points The corresponding candidate slope can refer to the extended control point. With extension control points The slope between them is... .in, Indicates the configuration control point The ordinate, Indicates the configuration control point The ordinate, Indicates the configuration control point x-coordinate Indicates the configuration control point The x-coordinate.
[0047] Step S103: If it is determined from the two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset conditions for monotonicity, then the candidate slope corresponding to the target configuration control point is updated to obtain the calibration slope corresponding to the target configuration control point; otherwise, the candidate slope corresponding to the target configuration control point is determined as the calibration slope; the N configuration control points include the target configuration control point. Specifically, computer equipment can configure control points according to the target. For two adjacent configuration control points, determine whether the target configuration control point meets the preset conditions for monotonicity. This includes the configuration control point preceding the target configuration control point (which can be called the left neighbor control point). ) and the next configuration control point after the target configuration control point (which can be called the right neighbor control point) For example, if we consider the left neighbor control point... and target configuration control points The curves formed by the left neighboring regions are non-monotonic and / or for the right neighboring control points. and target configuration control points If the right neighbor curves formed are non-monotonic and increasing, then the computer equipment can determine the target configuration control point. If the preset conditions for monotonicity are not met, and both the left and right neighboring curves are monotonically increasing, then the computer device can determine the target configuration control point. The preset conditions are met. Among them, the left neighbor curve refers to the curve defined by the left neighbor control point. A cubic Bézier curve is generated starting from the target control point and ending at the target configuration control point. The right neighbor curve refers to a curve generated starting from the target configuration control point and ending at its right neighbor control point. A cubic Bézier curve generated for the endpoint. The direction information used to generate the curve can be found below. Figure 4 The specific description of step S205 in the corresponding embodiment.
[0048] If the target configuration control point If the preset conditions for monotonicity are not met, the computer device can update the candidate slope corresponding to the target configuration control point based on the two configuration control points adjacent to the target configuration control point, thus obtaining the calibration slope corresponding to the target configuration control point; if the target configuration control point If the preset conditions for monotonicity are not met, the computer device can determine the candidate slope corresponding to the target configuration control point as the calibration slope.
[0049] In this embodiment, by judging the monotonicity of the left and right domain curves, the candidate slope can be updated to directionally repair local curve segments that do not meet the preset conditions for monotonicity, thereby obtaining a calibrated slope. The calibrated slope ensures that the local curve segments remain monotonically increasing, without inflection points or reversals, and maintain shape safety.
[0050] Step S104: Based on the calibration slopes corresponding to the N configuration control points, generate a service curve consisting of N-1 sub-curves; the N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, and each sub-curve contains two adjacent configuration control points among the N configuration control points; the service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0051] Specifically, the computer device can divide N configuration control points into N-1 configuration control point pairs, where each configuration control point pair includes two adjacent configuration control points. Based on the calibration slope and coordinate information corresponding to each configuration control point in the N-1 configuration control point pairs, the computer device can generate auxiliary control point pairs corresponding to each of the N-1 configuration control point pairs, with each configuration control point pair including the first configuration control point. Second configuration control point For example, a computer device can obtain the first configuration control point. The corresponding calibration slope and the second configuration control point The corresponding calibration slope is based on the first configuration control point. With the second configuration control point The difference in the horizontal coordinates between them, and the first configuration control point The corresponding calibration slope and the first configuration control point The corresponding ordinate is used to generate the ordinate of the left inner auxiliary control point. Based on the first configured control point. With the second configuration control point The difference in the horizontal coordinates between them, and the second configuration control point The corresponding calibration slope and the second configuration control point The corresponding ordinate is used to generate the ordinate of the right inner auxiliary control point.
[0052] Computer equipment can be the first configuration control point As the starting point of the curve and the second configuration control point As the endpoint of the curve, passing through the curve start point, curve endpoint, and first configuration control point. Second configuration control point The corresponding coordinate information, the ordinate of the left inner auxiliary control point, and the ordinate of the right inner auxiliary control point are used to generate a control point containing the first configuration point. Second configuration control point The sub-curves can be cubic Bézier curves. When the sub-curves corresponding to each pair of adjacent configuration control points among N configuration control points are obtained, the computer device can combine the N-1 sub-curves to obtain the business curve.
[0053] This application embodiment obtains N configuration control points for controlling signal changes in media data. The coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data. The horizontal coordinates of the N configuration control points are strictly monotonically increasing, and the vertical coordinates of the N configuration control points are monotonically increasing, ensuring that the input signal value and output signal value are arranged in an orderly manner from small to large, constraining the monotonicity of the information source from the source, and providing a monotonicity basis for subsequent slope adjustment. Candidate slopes representing the steepness of signal changes at each configuration control point are generated. Based on two configuration control points adjacent to the target configuration control point, it is determined whether the local curve segment corresponding to the target configuration control point meets the preset conditions for monotonicity. Local monotonicity is determined using these two adjacent configuration control points. Candidate slopes corresponding to target configuration control points that do not meet the preset conditions are updated to obtain the calibration slope corresponding to the target configuration control point. Candidate slopes corresponding to target configuration control points that meet the preset conditions are directly determined as calibration slopes. This corrects the monotonicity defects of candidate slopes, avoiding distortions such as dips and inflection points in local curve segments caused by directly using candidate slopes, and preventing non-monotonic increases such as local reversals. This ensures that local curve segments are monotonically increasing. Therefore, by generating candidate slopes and using preset conditions for monotonicity, candidate slopes that do not meet monotonicity can be updated and corrected, mitigating the risk of distortion in local curve segments. The calibration slope controls the direction of local curve segments (i.e., sub-curves), ensuring a smooth increase in local curve segments. Finally, N-1 sub-curves are generated using the calibration slopes corresponding to the N configuration control points. Each sub-curve contains two adjacent configuration control points from the N configuration control points. This effectively splits the multiple Bézier curves into cubic Bézier curves that always pass through the start and end points, ensuring that each generated sub-curve passes through two adjacent configuration control points. Since the generation of each sub-curve only needs to consider two adjacent configuration control points, high-order operations of multiple Bézier curves are avoided, reducing computational complexity and cost, and improving computational efficiency. The calibration slopes ensure that each sub-curve increases monotonically segment by segment, and the entire spliced service curve also exhibits a globally monotonically increasing trend. Through the service curve, the mapping between the input and output signal values of media data can be achieved. In this embodiment, the generated service curve can be intuitively and quantitatively controlled through N configuration control points, improving the flexibility and controllability of the service curve. Because the service curve always passes through N configuration control points and exhibits a globally monotonically increasing trend, the difficulty of setting control points and the required computational cost are reduced. This ensures that the output signal value changes synchronously with the input signal value, achieving consistency in image mapping and improving the efficiency of workflows that rely on service curves.
[0054] Please see Figure 4 , Figure 4 This is a flowchart illustrating a data processing method provided in an embodiment of this application. Figure 2 This data processing method can be executed by a computer device, which can be, for example, Figure 1 The business server 100 shown or any terminal device in the terminal device cluster, such as terminal device 10a, can be used. The following description will use the example of this data processing method being executed by a computer device. This data processing method will at least include the following steps S201-S210: Step S201: Generate a list of control point coordinates; Specifically, the computer device can acquire N configuration control points for controlling signal changes in media data. These N configuration control points can be obtained from image and video files, bitstreams, sidedata (private ancillary data), etc., or can be parameters set by the user; this embodiment does not impose any limitations. The horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of their arrangement, and the vertical coordinates are also monotonically increasing in the order of their arrangement. The coordinate information corresponding to each of the N configuration control points is used to indicate the input and output signal values of the media data.
[0055] Taking the acquisition of N configuration control points from the media data stream as an example, if the N configuration control points are used to complete the image mapping between the HDR image standard and the SDR image standard, the computer device can generate a proportional scaling factor based on the value range of the signal values under the HDR image standard and the value range of the signal values under the SDR image standard. Based on the proportional scaling factor, N configuration control points are sampled at equal intervals in the two value ranges, where N can generally be a positive integer greater than or equal to 2. The specific coordinates of the N configuration control points are not limited in this embodiment, nor are there any limitations on whether the N configuration control points include the origin or whether there is at least one point outside the first quadrant.
[0056] The computer device can generate a list of configuration control point coordinates based on the coordinate information corresponding to N configuration control points. This list can be represented as... For any configuration control point in the configuration control point coordinate list. , It should include coordinate information: The computer equipment can generate a list of control point x-coordinates and a list of control point y-coordinates corresponding to N configuration control points. The list of control point x-coordinates can be represented as... The list of control point ordinates can represent .
[0057] in, Indicates the configuration control point The horizontal axis is used to indicate the input signal value of the media data. Indicates the configuration control point The ordinate is used to indicate the output signal value of the media data. For all control points, the x-coordinate must be strictly monotonically increasing, and the ordinate must be monotonically increasing, i.e., for each control point... ,satisfy ,and .when When, it means that during image mapping, multiple consecutive input signal values are allowed to be mapped to the same output signal value.
[0058] For interval It should cover all possible numerical ranges of the output signal values that need to be image mapped in the media data, that is, the input signal value for any pixel (such as the j-th pixel) in the media data. , , The total number of pixels in the media data, all satisfying .
[0059] Step S202: Generate a list of auxiliary control point coordinates; Specifically, the computer device can generate a starting auxiliary point based on the first z configuration control points out of N configuration control points. Taking z = 2 as an example, the first z configuration control points can include the first configuration control point (also called the configuration control point). ) and the second configuration control point (also known as the configuration control point) ), starting auxiliary point The calculation method for the horizontal and vertical coordinates is shown in formula (1): Formula (1) in, Indicates the starting auxiliary point x-coordinate Indicates the starting auxiliary point The ordinate, Indicates the configuration control point x-coordinate Indicates the configuration control point x-coordinate Indicates the configuration control point The ordinate, Indicates the configuration control point The ordinate. It can be understood that control points are configured by extending forward. can be the starting auxiliary point With configuration control points The midpoint of the line segment formed.
[0060] Computer equipment can generate a final auxiliary point based on the last z configuration control points out of N configuration control points. Taking z = 2 as an example, the auxiliary point at the end... The calculation method for the horizontal and vertical coordinates is shown in formula (2): Formula (2) in, Indicates the starting auxiliary point x-coordinate Indicates the starting auxiliary point The ordinate, Indicates the configuration control point x-coordinate Indicates the configuration control point x-coordinate Indicates the configuration control point The ordinate, Indicates the configuration control point The ordinate. It can be understood that control points are configured by extending forward. can be the starting auxiliary point With configuration control points The midpoint of the line segment formed.
[0061] It is understandable that, since the endpoint tangents of the first and last configuration control points in the configuration control point coordinate list cannot be calculated using central difference, this embodiment of the application extends the starting auxiliary point corresponding to the first configuration control point and the ending auxiliary point corresponding to the last configuration control point through linear extrapolation. Using the starting and ending auxiliary points, the tangent directions of the curve's start and end points can be fixed, ensuring that the beginning and end segments do not produce sharp angles, achieving a smooth curve termination without abrupt jumps.
[0062] Computer equipment can be based on the starting auxiliary point and the last auxiliary point For each corresponding coordinate information, generate an auxiliary control point coordinate list. The auxiliary control point coordinate list can be represented as... Please see also... Figure 5 , Figure 5 This is a scenario illustration of a data processing method provided in an embodiment of this application. Figure 2 .like Figure 5 As shown, the list of control point coordinates includes... For example, among which, , , Computer devices can generate configuration control points. and configuration control points Corresponding starting auxiliary point Generate configuration control points and configuration control points Corresponding end auxiliary point ,in, , .
[0063] Step S203: Generate an extended control point list; Specifically, the computer equipment can determine the starting auxiliary point, N configuration control points, and the ending auxiliary point as N+2 extended control points. For any one of these N+2 extended control points... , When i=0, When i = N+1, When i ≠ 0 or N+1, , .
[0064] That is, for any one of the N+2 extended control points, the x-coordinate , When i=0, When i = N+1, When i ≠ 0 or N+1, , For any one of the N+2 extended control points, the ordinate... , When i=0, When i = N+1, When i ≠ 0 or N+1, , .
[0065] Step S204: Generate N candidate slopes; Specifically, the computer device can generate candidate slopes corresponding to N configuration control points based on N+2 extended control points. A candidate slope indicates the slope between adjacent extended control points. These N configuration control points... For example, this configuration control point This can also be called the target configuration control point. It can also correspond to the extended control points among N+2 extended control points. The configuration control point is defined as the two configuration control points adjacent to the target configuration control point, including the configuration control point preceding the target configuration control point (which can be called the left neighbor control point). ) and the next configuration control point after the target configuration control point (which can be called the right neighbor control point) For example, computer equipment can be based on the left neighbor control point. and right neighbor control points Generate configuration control points (i.e., extended control points) The candidate slope corresponding to ) is calculated as shown in formula (3): Formula (3) in, Indicates the configuration control point The corresponding candidate slope, Indicates the right neighbor control point The ordinate, Indicates the left neighbor control point The ordinate, Indicates the right neighbor control point x-coordinate Indicates the left neighbor control point The x-coordinate.
[0066] In this embodiment, the three-point center difference method is used, that is, at intervals of one point (i.e., the target configuration control point). Select the left neighbor control point. and right neighbor control points To fit the target configuration control points The slope of the tangent line of the curve is estimated by restoring the direction of the Bézier curve through the three-point central difference, and the initial tangent line (candidate slope) of each configuration control point that is native and fits the curve trend is obtained, which lays the foundation for the subsequent construction of a smooth calibration slope.
[0067] Step S205: Based on the two configuration control points adjacent to the target configuration control point, determine whether the target configuration control point meets the preset conditions for monotonicity; Specifically, the computer equipment can determine whether the target configuration control point meets the preset conditions for monotonicity based on two configuration control points adjacent to it. For ease of understanding, the target configuration control point will be referred to as the configuration control point. The two configuration control points adjacent to the target configuration control point include the left neighbor control point. and right neighbor control points For example, computer equipment can be configured with control points based on target settings (i.e., configuration control points). Left Neighbor Control Point (When i is greater than 1, it is a configuration control point) ) and left neighbor control points The corresponding candidate slope is used to generate the first left neighbor ordinate estimate for the left neighbor curve, and the calculation process is shown in formula (4): Formula (4) in, This represents the estimated ordinate value of the first left neighbor. Indicates the configuration control point The ordinate, The coefficient is a preset value, which can be 1 / 3, 1 / 6, etc., and this application embodiment does not limit it. To configure control points The corresponding candidate slope, Indicates the configuration control point The corresponding x-coordinate, Indicates the configuration control point The corresponding x-coordinate.
[0068] The computer device can generate a second left neighbor ordinate estimate for the left neighbor curve based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the target configuration control point. The calculation process is shown in formula (5): Formula (5) in, This represents the estimated ordinate value of the second left neighbor. Indicates the configuration control point The ordinate. To configure control points The corresponding candidate slope.
[0069] In this embodiment of the application, the left neighbor curve refers to the curve configured with control points. Configure control points as the starting point. For the last point, the estimated ordinate of the first left neighbor. Second left neighbor ordinate estimate A cubic Bézier curve generated as directional information.
[0070] Please see also Figure 5 ,like Figure 5 As shown, computer equipment can be configured with control points. and configuration control points Generate the estimated ordinate of the first left neighbor. Second left neighbor ordinate estimate The estimated value of the ordinate of the first left neighbor Second left neighbor ordinate estimate Used for configuring control points The corresponding left neighbor curve provides directional information.
[0071] Computer equipment can generate the ordinates of left neighbor control points. The estimated value of the ordinate of the first left neighbor The difference in the first left neighbor's ordinate The estimated value of the ordinate of the first left neighbor The estimated value of the ordinate of the second left neighbor The difference in the ordinates of the second left neighbor , and the second left neighborhood ordinate estimate value and the ordinate of the target configuration control point The third left neighborhood ordinate difference therebetween . For example, specifically, it may be , , .
[0072] The computer device may generate a first verification value for characterizing the monotonicity of the left neighborhood curve based on the first left neighborhood ordinate difference , the second left neighborhood ordinate difference , and the third left neighborhood ordinate difference . The specific process is as follows: The computer device may generate a second-order difference result between the first left neighborhood ordinate difference , the second left neighborhood ordinate difference , and the third left neighborhood ordinate difference . The second-order difference result may be expressed as . The computer device may generate a geometric mean constraint result between the first left neighborhood ordinate difference , the second left neighborhood ordinate difference , and the third left neighborhood ordinate difference . The geometric mean constraint result may be expressed as [[ID=4)),
[0073] The computer device may obtain a first comparison result between the second-order difference result between the first left neighborhood ordinate difference , the second left neighborhood ordinate difference , and the third left neighborhood ordinate difference and the difference threshold, and a second comparison result between the geometric mean constraint result between the first left neighborhood ordinate difference , the second left neighborhood ordinate difference , and the third left neighborhood ordinate difference and the monotonicity threshold, and generate a first verification value for the left neighborhood curve according to the first comparison result and the second comparison result. If the first comparison result is that the second-order difference result is greater than the difference threshold, and the second comparison result is that the geometric mean constraint result is less than the monotonicity threshold, the first verification value is used to indicate that the left neighborhood curve is non-monotonically increasing. That is, if (i.e., the difference threshold) holds and (i.e., the monotonicity threshold) holds, it means that there is at least one pair of x1 < x2 in the left neighborhood curve such that f(x1)>f(x2), that is, the left neighborhood curve is non-monotonically increasing, and the computer device may set the first verification value The first value can be 1, meaning it represents the non-monotonic increase of a local curve segment (such as the left neighbor curve). In other words, it is the first verification value with the first value. Used to indicate that the curve in the left neighborhood is not monotonically increasing.
[0074] If the first comparison result is a second-order difference result less than or equal to the difference threshold, and / or the second comparison result is a geometric mean constraint result greater than or equal to the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is monotonically increasing. That is, if Not valid, and / or If this is not true, the computer device can set the first verification value. The second value is a variable that can be 0. This second value is used to characterize a local curve segment (such as the left neighbor curve) as monotonically increasing; it represents the first verification value with the second value. Used to indicate that the curve in the left neighborhood is monotonically increasing.
[0075] Understandable. , and These represent the estimated values of the local estimated points (the estimated values of the ordinates of the first left neighboring region). Second left neighbor ordinate estimate The first difference of the curve represents the local rising rhythm of the curve, which is determined by the discriminant. and We select neighborhood curves that conform to monotonicity as the basis for updating candidate slopes, so that the updated calibrated slope can keep the local curve segments monotonically increasing, without inflection points or reversals, and with safe shape.
[0076] Similarly, computer equipment can be configured with control points based on target settings (i.e., configuration control points). ), right neighbor control point (i.e., configuring control points) ) and right neighbor control points The corresponding candidate slope is used to generate the first right neighbor ordinate estimate for the right neighbor curve, and the calculation process is shown in formula (6): Formula (6) in, This represents the estimated ordinate value of the first right neighbor. Indicates the configuration control point The ordinate, The coefficient is a preset value, which can be 1 / 3, 1 / 6, etc., and this application embodiment does not limit it. To configure control points The corresponding candidate slope, Indicates the configuration control point The corresponding x-coordinate, Indicates the configuration control point The corresponding x-coordinate.
[0077] The computer device can generate a second right neighbor ordinate estimate for the right neighbor curve based on the target configuration control point, the right neighbor control point, and the candidate slope corresponding to the target configuration control point. The calculation process is shown in formula (7): Formula (7) in, This represents the estimated ordinate value of the second right neighbor. Indicates the configuration control point The ordinate. To configure control points The corresponding candidate slope.
[0078] In this embodiment of the application, the right neighbor curve refers to the curve configured with control points. Configure control points as the starting point. For the last point, the estimated ordinate of the first right neighbor. Second right neighbor ordinate estimate A cubic Bézier curve generated as directional information.
[0079] Please see also Figure 5 ,like Figure 5 As shown, computer equipment can be configured with control points. and configuration control points Generate the estimated ordinate of the first right neighbor. Second right neighbor ordinate estimate The estimated value of the ordinate of the first right neighbor Second right neighbor ordinate estimate Used for configuring control points The corresponding right neighbor curve provides directional information.
[0080] Computer equipment can generate the ordinates of the target configuration control points. The estimated value of the ordinate of the first right neighbor The difference in the first right neighbor's ordinate The estimated value of the first right neighbor's ordinate The estimated value of the ordinate of the second right neighbor The difference in the ordinates of the second right neighbor and the estimated value of the ordinate of the second right neighbor. ordinate of the right neighbor control point The difference in the ordinates of the third right neighbor For example, it could specifically be... , , 。
[0081] The computer device can generate a second verification value for characterizing the monotonicity of the right neighborhood curve based on the first right neighborhood ordinate difference , the second right neighborhood ordinate difference and the third right neighborhood ordinate difference . The specific process is as follows: The computer device can generate the first right neighborhood ordinate difference . The computer device can generate the second-order difference result between the first right neighborhood ordinate difference , the second right neighborhood ordinate difference and the third right neighborhood ordinate difference . The second-order difference result can be expressed as . The computer device can generate the geometric mean constraint result between the first right neighborhood ordinate difference , the second right neighborhood ordinate difference and the third right neighborhood ordinate difference . The geometric mean constraint result can be expressed as [[ID=2二十七]].
[0082] The computer device can obtain the third comparison result between the second-order difference result between the first right neighborhood ordinate difference , the second right neighborhood ordinate difference and the third right neighborhood ordinate difference and the difference threshold, and the fourth comparison result between the geometric mean constraint result between the first right neighborhood ordinate difference , the second right neighborhood ordinate difference and the third right neighborhood ordinate difference and the monotonicity threshold, and generate a second verification value for the right neighborhood curve according to the third comparison result and the fourth comparison result. If the third comparison result is that the second-order difference result is greater than the difference threshold, and the fourth comparison result is that the geometric mean constraint result is less than the monotonicity threshold, the second verification value is used to indicate that the right neighborhood curve is non-monotonically increasing. That is, if (i.e., the difference threshold) holds and (i.e., the monotonicity threshold) holds, it means that there is at least one pair of x1 < x2 in the right neighborhood curve such that f(x1) > f(x2), that is, the right neighborhood curve is non-monotonically increasing. The computer device can make the second verification value be the first numerical value. The first numerical value can be 1, that is, the first numerical value is used to characterize that the local curve segment (such as the right neighborhood curve) is non-monotonically increasing. That is, at this time, the second verification value with the first numerical value is used to indicate that the right neighborhood curve is non-monotonically increasing.
[0083] If the third comparison result is a second-order difference result less than or equal to the difference threshold, and / or the fourth comparison result is a geometric mean constraint result greater than or equal to the monotonicity threshold, then the second verification value is used to indicate that the right neighbor curve is monotonically increasing, i.e., if Not valid, and / or If this is not true, the computer device can set the second verification value. The second value is a variable that can be 0. This second value is used to characterize a local curve segment (such as the right neighbor curve) as monotonically increasing; it represents the second verification value at this point. Used to indicate that the curve in the right neighboring region is monotonically increasing.
[0084] If the first verification value indicates that the left neighbor curve is non-monotonic, and / or the second verification value indicates that the right neighbor curve is non-monotonic, then the computer device can determine that the target configuration control point does not meet the preset condition for monotonicity, i.e., when the first verification value... Or the second verification value When any one of them equals 1, the computer device can determine that the target configuration control point does not meet the preset conditions for monotonicity.
[0085] If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the computer device can determine that the target configuration control point meets the preset condition, that is, when the first verification value... Second verification value When all values are equal to 0, the computer equipment can determine that the target configuration control point meets the preset conditions.
[0086] Step S206: If the target configuration control point does not meet the preset conditions for monotonicity, the candidate slope corresponding to the target configuration control point is updated to obtain the calibration slope corresponding to the target configuration control point. Specifically, if the target configuration control point does not meet the preset conditions for monotonicity, the computer device can configure the control point based on the left neighbor control point (i.e., the configuration control point). ) and target configuration control point (i.e., configuration control point) The coordinate information corresponding to each node is used to generate the slope of the left neighbor curve, and the right neighbor control points (i.e., the configuration control points) are used as the basis. The coordinate information corresponding to the target configuration control point and the right neighbor slope corresponding to the right neighbor curve is generated by using the coordinate information of the target configuration control point. The process is shown in formula (8): Formula (8) in, This represents the slope of the left neighbor curve. This represents the slope of the right neighbor curve.
[0087] Computer equipment can be based on the first verification value Second verification value The value of , the slope in the left neighborhood and right neighbor slope Select a slope and update the candidate slope corresponding to the target configuration control point, as follows: If the first verification value indicates that the left neighbor curve is non-monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, that is... =1, and If the slope is equal to 1, the computer device can determine the minimum value between the left and right neighbor slopes as the target configuration control point (i.e., the configuration control point). The corresponding calibration slope ,Right now It is understandable that when both the left and right neighbor curves conform to monotonicity, the computer device can choose a smoother (i.e., lower slope) curve as the basis for the candidate slope of the update, so that the update has a smoother calibration slope and the smallest increment, avoiding the curve from steeply increasing, overshooting, or bulging due to an excessively large slope.
[0088] If the first verification value indicates that the left neighbor curve is non-monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, that is... =1, and =0, then the computer device can determine the left neighbor slope as the calibration slope corresponding to the target configuration control point. ,Right now .
[0089] If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, that is... =0, and =1, then the computer device can determine the right neighbor slope as the calibration slope corresponding to the target configuration control point. ,Right now .
[0090] It's understandable, when =1, and When =0, the slope of the left neighbor curve corresponding to the left neighbor curve is forcibly reused as the calibration slope, which can directionally repair the slope of the other side curve (right neighbor curve). Similarly, when =1, and When =0, the slope of the right neighbor curve corresponding to the right neighbor curve is forcibly reused as the calibration slope to correct the slope of the right neighbor curve in a targeted manner, ensuring that the overall curve increases smoothly.
[0091] Step S207: If the target configuration control point meets the preset conditions for monotonicity, then the candidate slope corresponding to the target configuration control point is determined as the calibration slope. Specifically, when the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, that is... =0, and When the value is 0, the computer device can determine that the target configuration control point satisfies the preset conditions for monotonicity, and the computer device can determine the candidate slope corresponding to the target configuration control point as the calibration slope. ,Right now .
[0092] Step S208: Generate pairs of auxiliary control points corresponding to each of the N-1 sub-curves; Specifically, the computer device can divide N configuration control points into N-1 configuration control point pairs, where each configuration control point pair includes two adjacent configuration control points. Based on the calibration slope and coordinate information corresponding to each configuration control point in the N-1 configuration control point pairs, the computer device can generate auxiliary control point pairs corresponding to each of the N-1 configuration control point pairs, with each configuration control point pair including the first configuration control point. Second configuration control point For example, a computer device can obtain the first configuration control point. The corresponding calibration slope and the second configuration control point For the corresponding calibration slope, based on the first configuration control point With the second configuration control point The difference in the horizontal coordinates between them, and the first configuration control point The corresponding calibration slope and the first configuration control point The corresponding ordinate is used to generate the first configuration control point. The corresponding left inner auxiliary control point ordinate is shown in formula (9): Formula (9) in, As the first configuration control point The corresponding value represents the ordinate of the left inner auxiliary control point. The coefficient is a preset value, which can be 1 / 3, 1 / 6, etc., and this application embodiment does not limit it. To configure control points The corresponding calibration slope, Indicates the configuration control point The corresponding x-coordinate, Indicates the configuration control point The corresponding x-coordinate.
[0093] Computer equipment can be based on the first configuration control point With the second configuration control point The difference in the horizontal coordinates between them, and the second configuration control point The corresponding calibration slope and the second configuration control point The corresponding ordinate is used to generate the first configuration control point. The corresponding ordinate of the right inner auxiliary control point is shown in formula (10): Formula (10) in, As the first configuration control point The corresponding ordinate of the right inner auxiliary control point, To configure control points The corresponding calibration slope.
[0094] Step S209: Generate a business curve consisting of N-1 sub-curves; Specifically, a configuration control point includes a first configuration control point. Second configuration control point For example, a computer device can configure the first control point. As the starting point of the curve and the second configuration control point As the endpoint of the curve, passing through the curve start point, curve endpoint, and first configuration control point. Second configuration control point The corresponding coordinate information, the ordinate of the left inner auxiliary control point, and the ordinate of the right inner auxiliary control point are used to generate a control point containing the first configuration point. Second configuration control point The sub-curves can be cubic Bézier curves. When the sub-curves corresponding to each pair of adjacent configuration control points among N configuration control points are obtained, the computer device can combine the N-1 sub-curves to obtain the business curve.
[0095] Step S210: Perform image mapping on the media data.
[0096] Specifically, computer devices can acquire unit images from media data. If the media data is image data, then the unit image is the image data itself; if the media data is video data, then the unit image is a specific video frame. A unit image can include M pixels. Taking the j-th pixel in the unit image as an example... , This represents the total number of pixels in a unit image.
[0097] The computer device can acquire the input signal value of the j-th pixel. Input signal value This can refer to image parameters such as brightness, color depth, color space, and contrast, as well as combinations thereof. Computer equipment can acquire input signal values from N configured control points. Two adjacent configuration control points are considered as two candidate configuration control points. The input signal value... Located within the interval determined by the x-coordinates of two adjacent configuration control points, i.e., if The possible valid values of k are Then the computer device can configure the control point. and configuration control points Determined as input signal value The two corresponding candidate configuration control points.
[0098] Computer devices can be based on input signal values And the x-coordinates of the two candidate configuration control points, to generate the input signal value The interpolation factor is calculated as shown in formula (11): Formula (11) in, For the input signal value interpolation factor, To configure control points x-coordinate To configure control points The x-coordinate.
[0099] Computer equipment can generate input signal values based on interpolation factors and a subcurve containing two candidate configuration control points. The corresponding curve mapping value, with coef taking a value of 1 / 3, generates the input signal value. The process of mapping the corresponding curve values can be shown in formula (12): Formula (12) in, That is, the input signal value The corresponding curve mapping value, To configure control points x-coordinate To configure control points The ordinate. That is, configure control points The corresponding ordinate of the left inner auxiliary control point, That is, configure control points The corresponding ordinate of the right inner auxiliary control point.
[0100] It is understandable that the possible valid values of k are The computer equipment can traverse the valid values of k and generate N-1 sub-curves in succession through the above formula (12), and combine the N-1 sub-curves into a business curve.
[0101] If the mapping relationship between input signal values and output signal values in the metadata of media data is a direct mapping relationship, then the computer device can directly map the input signal values. The corresponding curve mapping value is determined as the input signal value. Corresponding output signal value ,Right now .
[0102] If the mapping relationship between input signal values and output signal values in the metadata is an indirect mapping relationship, then the computer device can obtain an intermediate function for the input signal values and output signal values, based on the input signal values. The corresponding curve mapping value and intermediate function are used to generate the input signal value. The corresponding output signal value.
[0103] Taking the calculation of the gain coefficient for media data using a business curve as an example, and then mapping it, this method is suitable when the control point information defines the gain coefficient corresponding to the image signal intensity (input signal value). The computer device can obtain the intermediate function corresponding to the gain coefficient, i.e. According to the input signal value The corresponding curve mapping value and intermediate function are used to generate the input signal value. Corresponding output signal value .in, This represents the gain coefficient.
[0104] Taking the calculation of logarithmic domain gain coefficients using business curves as an example, followed by mapping, this method is suitable when the control point information defines the logarithmic domain gain coefficients corresponding to the image signal intensity. The computer equipment can obtain the intermediate function corresponding to the gain coefficients, i.e. According to the input signal value The corresponding curve mapping value and intermediate function are used to generate the input signal value. Corresponding output signal value .in, Represents the logarithmic domain gain coefficient. The base is 2, and the parameter is a preset value, typically 2. It is understood that the intermediate function can also take other forms, and this embodiment does not impose any limitations on it.
[0105] Optionally, the above output signal value can also be calculated using LUT (Lookup Table) interpolation. That is, the computer device can obtain a list of preset input values for the business curve. The list of preset input values includes R discrete preset input values, such as R values that are equally sampled in the domain of the input signal value.
[0106] Computer equipment can generate output signal values corresponding to R preset input values based on a business curve and R preset input values. The method for generating output signal values based on preset input values is the same as the method for generating output signal values based on input signal values. That is, the output signal values corresponding to the R input signal values are pre-calculated, and the mapping relationship between the R preset input values and output signal values is formed into a LUT (Local Unified Test). In image mapping, taking the j-th pixel in media data as an example, the computer equipment can generate output signal values based on the input signal values... Obtain the input signal value in the LUT If two adjacent preset input values, The possible valid values of k are Then, with the input signal value Two adjacent preset input values can be and .
[0107] Computer equipment can be based on input signal values The input signal value is obtained by interpolating the output signal values corresponding to the two preset input values to determine the degree of difference between them. The corresponding output signal value. The interpolation method can include linear interpolation and bilinear interpolation, which are not limited to this embodiment. It is understood that this application supports both real-time curve calculation and pre-generated LUT lookup tables, improving versatility and compatibility.
[0108] This application embodiment obtains N configuration control points for controlling signal changes in media data. The coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data. The horizontal coordinates of the N configuration control points are strictly monotonically increasing, and the vertical coordinates of the N configuration control points are monotonically increasing, ensuring that the input signal value and output signal value are arranged in an orderly manner from small to large, constraining the monotonicity of the information source from the source, and providing a monotonicity basis for subsequent slope adjustment. Candidate slopes representing the steepness of signal changes at each configuration control point are generated. Based on two configuration control points adjacent to the target configuration control point, it is determined whether the local curve segment corresponding to the target configuration control point meets the preset conditions for monotonicity. Local monotonicity is determined using these two adjacent configuration control points. Candidate slopes corresponding to target configuration control points that do not meet the preset conditions are updated to obtain the calibration slope corresponding to the target configuration control point. Candidate slopes corresponding to target configuration control points that meet the preset conditions are directly determined as calibration slopes. This corrects the monotonicity defects of candidate slopes, avoiding distortions such as dips and inflection points in local curve segments caused by directly using candidate slopes, and preventing non-monotonic increases such as local reversals. This ensures that local curve segments are monotonically increasing. Therefore, by generating candidate slopes and using preset conditions for monotonicity, candidate slopes that do not meet monotonicity can be updated and corrected, mitigating the risk of distortion in local curve segments. The calibration slope controls the direction of local curve segments (i.e., sub-curves), ensuring a smooth increase in local curve segments. Finally, N-1 sub-curves are generated using the calibration slopes corresponding to the N configuration control points. Each sub-curve contains two adjacent configuration control points from the N configuration control points. This effectively splits the multiple Bézier curves into cubic Bézier curves that always pass through the start and end points, ensuring that each generated sub-curve passes through two adjacent configuration control points. Since the generation of each sub-curve only needs to consider two adjacent configuration control points, high-order operations of multiple Bézier curves are avoided, reducing computational complexity and cost, and improving computational efficiency. The calibration slopes ensure that each sub-curve increases monotonically segment by segment, and the entire spliced service curve also exhibits a globally monotonically increasing trend. Through the service curve, the mapping between the input and output signal values of media data can be achieved. In this embodiment, the generated service curve can be intuitively and quantitatively controlled through N configuration control points, improving the flexibility and controllability of the service curve. Because the service curve always passes through N configuration control points and exhibits a globally monotonically increasing trend, the difficulty of setting control points and the required computational cost are reduced. This ensures that the output signal value changes synchronously with the input signal value, achieving consistency in image mapping and improving the efficiency of workflows that rely on service curves.
[0109] On the other hand, based on the coordinate information of the pre-set configuration control points, precise image mapping can be achieved, thereby providing artists with the greatest ability to express their creative intentions. At the same time, it effectively avoids the problem of brightness reversal after image mapping, reduces the difficulty for artists or automated algorithms to set curve control points, and improves workflow efficiency. Finally, since the Bézier curves used are all cubic Bézier curves, they also have the advantage of low computational load.
[0110] Please see Figure 6 , Figure 6 This is a schematic diagram of the structure of a data processing device provided in an embodiment of this application. Figure 6 As shown, the data processing device 1 includes an acquisition module 610, a calibration module 620, and a generation module 630.
[0111] The acquisition module 610 is used to acquire N configuration control points for controlling the signal changes of media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; The calibration module 620 is used to generate candidate slopes corresponding to N configuration control points. If it is determined from the two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset conditions for monotonicity, the candidate slopes corresponding to the target configuration control point are updated to obtain the calibration slopes corresponding to the target configuration control point; otherwise, the candidate slopes corresponding to the target configuration control point are determined as the calibration slopes. The N configuration control points include the target configuration control point. The generation module 630 is used to generate a service curve consisting of N-1 sub-curves based on the calibration slopes corresponding to N configuration control points. The N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, and each sub-curve contains two adjacent configuration control points among the N configuration control points. The service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0112] In one possible implementation, the N configuration control points are arranged in a strictly monotonically increasing order of their abscissas; when generating the candidate slopes corresponding to the N configuration control points, the calibration module 620 specifically performs the following operations: A starting auxiliary point is generated based on the first z configuration control points out of N configuration control points; z is a positive integer greater than or equal to 2. Generate the last auxiliary point based on the last z configuration control points out of N configuration control points; The starting auxiliary point, N configuration control points, and the ending auxiliary point are determined as N+2 extended control points. Based on the N+2 extended control points, candidate slopes corresponding to the N configuration control points are generated.
[0113] In one possible implementation, the first z configuration control points include a first configuration control point and a second configuration control point. When the calibration module 620 generates the starting auxiliary point based on the first z configuration control points among the N configuration control points, it specifically performs the following operations: Generate an initial auxiliary x-coordinate based on the x-coordinate of the first and second configured control points; Generate an initial auxiliary ordinate based on the ordinate of the first and second configured control points; Determine the starting auxiliary point in the coordinate system based on the starting auxiliary abscissa and the starting auxiliary ordinate; the first configuration control point is the midpoint of the line segment formed by the starting auxiliary point and the second configuration control point.
[0114] In one possible implementation, the N configuration control points include configuration control points. , where i is an integer greater than or equal to 0, and the control point is configured. For N+2 extended control points The calibration module 620 is used to generate candidate slopes corresponding to N configuration control points based on N+2 extended control points. Specifically, it performs the following operations: Obtain the control points from the N+2 extended control points. Two adjacent extended control points; Based on and extended control points The coordinate information corresponding to two adjacent extended control points is used to generate configuration control points. The corresponding candidate slope.
[0115] In one possible implementation, the N configuration control points are arranged in a strictly monotonically increasing order of their horizontal coordinates. The two configuration control points adjacent to the target configuration control point include the left neighbor control point preceding the target configuration control point and the right neighbor control point following the target configuration control point. The calibration module 620 is also used to perform the following operations: Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, a first verification value is generated to characterize the monotonicity of the left neighbor curve; the left neighbor curve is the curve determined by the target configuration control point and the left neighbor control point. Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the right neighbor control point, and the candidate slope corresponding to the right neighbor control point, a second verification value is generated to characterize the monotonicity of the right neighbor curve; the right neighbor curve is the curve determined by the target configuration control point and the right neighbor control point. If the first verification value indicates that the left neighbor curve is non-monotonic, and / or the second verification value indicates that the right neighbor curve is non-monotonic, then it is determined that the target configuration control point does not meet the preset conditions for monotonicity. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the target configuration control point is determined to meet the preset conditions for monotonicity.
[0116] In one possible implementation, when the calibration module 620 generates a first verification value to characterize the monotonicity of the left neighbor curve based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, it specifically performs the following operations: Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, the first left neighbor ordinate estimate is generated for the left neighbor curve. Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the target configuration control point, a second left neighbor ordinate estimate is generated for the left neighbor curve. The first left neighbor ordinate difference between the ordinate of the generated left neighbor control point and the estimated ordinate of the first left neighbor, the second left neighbor ordinate difference between the estimated ordinate of the first left neighbor and the estimated ordinate of the second left neighbor, and the third left neighbor ordinate difference between the estimated ordinate of the second left neighbor and the ordinate of the target configuration control point are generated. Based on the first left neighbor ordinate difference, the second left neighbor ordinate difference, and the third left neighbor ordinate difference, a first verification value is generated to characterize the monotonicity of the left neighbor curve.
[0117] In one possible implementation, when the calibration module 620 generates a first verification value to characterize the monotonicity of the left neighbor curve based on the first ordinate difference, the second ordinate difference, and the third ordinate difference, it specifically performs the following operations: Obtain the second-order difference results between the first, second, and third ordinate differences, as well as the geometric mean constraint results between the first, second, and third ordinate differences; Obtain the first comparison result between the second-order difference result and the difference threshold, and the second comparison result between the geometric mean constraint result and the monotonicity threshold; A first verification value is generated for the left neighbor curve based on the first comparison result and the second comparison result. If the first comparison result is a second-order difference result greater than the difference threshold, and the second comparison result is a geometric mean constraint result less than the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is non-monotonically increasing. If the first comparison result is a second-order difference result less than or equal to the difference threshold, and / or the second comparison result is a geometric mean constraint result greater than or equal to the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is monotonically increasing.
[0118] In one possible implementation, the calibration module 620 is used to update the candidate slope corresponding to the target configuration control point to obtain the calibration slope corresponding to the target configuration control point if it is determined from two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset condition for monotonicity; otherwise, when the candidate slope corresponding to the target configuration control point is determined as the calibration slope, it is specifically used to perform the following operations: Based on the left neighbor control points and the target configuration control points, the left neighbor slope corresponding to the left neighbor curve is generated; based on the right neighbor control points and the target configuration control points, the right neighbor slope corresponding to the right neighbor curve is generated. If the first verification value indicates that the left neighbor curve is non-monotonic and the second verification value indicates that the right neighbor curve is non-monotonic, then the minimum value between the left neighbor slope and the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is non-monotonic and the second verification value indicates that the right neighbor curve is monotonically increasing, then the slope of the left neighbor is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, then the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the candidate slope corresponding to the target configuration control point is determined as the calibration slope.
[0119] In one possible implementation, the N configuration control points include adjacent first and second configuration control points; when the generation module 630 generates a business curve consisting of N-1 sub-curves based on the calibration slopes corresponding to the N configuration control points, it specifically performs the following operations: Obtain the calibration slope corresponding to the first configuration control point and the calibration slope corresponding to the second configuration control point; Based on the difference in the horizontal coordinate between the first and second configuration control points, the calibration slope corresponding to the first configuration control point, and the vertical coordinate corresponding to the first configuration control point, the vertical coordinate of the left inner auxiliary control point is generated. Based on the difference in the horizontal coordinate between the first and second configuration control points, the calibration slope corresponding to the second configuration control point, and the vertical coordinate corresponding to the second configuration control point, the vertical coordinate of the right inner auxiliary control point is generated. Using the first configuration control point as the curve start point and the second configuration control point as the curve end point, a sub-curve containing the first configuration control point and the second configuration control point is generated by using the coordinate information corresponding to the curve start point, curve end point, first configuration control point and second configuration control point respectively, the ordinate of the left inner auxiliary control point and the ordinate of the right inner auxiliary control point. When the sub-curves corresponding to each pair of adjacent configuration control points among the N configuration control points are obtained, the N-1 sub-curves are combined to obtain the business curve.
[0120] In one possible implementation, the generation module 630 is also used to perform the following operations: Obtain the input signal value of the j-th pixel in the media data. j is a positive integer; Obtain the input signal value from N configuration control points. Two adjacent configuration control points are associated as two candidate configuration control points; input signal values Located within the interval defined by the x-coordinates of two adjacent configuration control points; Based on input signal value And the x-coordinates of the two candidate configuration control points, to generate the input signal value The interpolation factor is used to generate the input signal value based on the interpolation factor and a sub-curve containing two candidate configuration control points. The corresponding curve mapping value; If the mapping relationship between input signal values and output signal values in the metadata of the media data is a direct mapping relationship, then the input signal values will be... The corresponding curve mapping value is determined as the input signal value. The corresponding output signal value; If the mapping relationship between the input signal value and the output signal value in the metadata is an indirect mapping relationship, then obtain the intermediate function for the input signal value and the output signal value, based on the input signal value. The corresponding curve mapping value and intermediate function are used to generate the input signal value. The corresponding output signal value.
[0121] In one possible implementation, the generation module 630 is also used to perform the following operations: Obtain a list of preset input values for the business curve; the list of preset input values includes R discrete preset input values; R is a positive integer; Based on the business curve and R preset input values, output signal values corresponding to the R preset input values are generated respectively; Obtain the input signal value of the j-th pixel in the media data. Obtain the input signal value from R preset input values. Two adjacent preset input values, based on the input signal value The input signal value is obtained by interpolating the output signal values corresponding to the two preset input values to determine the degree of difference between them. The corresponding output signal value.
[0122] This application embodiment obtains N configuration control points for controlling signal changes in media data. The coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data. The horizontal coordinates of the N configuration control points are strictly monotonically increasing, and the vertical coordinates of the N configuration control points are monotonically increasing, ensuring that the input signal value and output signal value are arranged in an orderly manner from small to large, constraining the monotonicity of the information source from the source, and providing a monotonicity basis for subsequent slope adjustment. Candidate slopes representing the steepness of signal changes at each configuration control point are generated. Based on two configuration control points adjacent to the target configuration control point, it is determined whether the local curve segment corresponding to the target configuration control point meets the preset conditions for monotonicity. Local monotonicity is determined using these two adjacent configuration control points. Candidate slopes corresponding to target configuration control points that do not meet the preset conditions are updated to obtain the calibration slope corresponding to the target configuration control point. Candidate slopes corresponding to target configuration control points that meet the preset conditions are directly determined as calibration slopes. This corrects the monotonicity defects of candidate slopes, avoiding distortions such as dips and inflection points in local curve segments caused by directly using candidate slopes, and preventing non-monotonic increases such as local reversals. This ensures that local curve segments are monotonically increasing. Therefore, by generating candidate slopes and using preset conditions for monotonicity, candidate slopes that do not meet monotonicity can be updated and corrected, mitigating the risk of distortion in local curve segments. The calibration slope controls the direction of local curve segments (i.e., sub-curves), ensuring a smooth increase in local curve segments. Finally, N-1 sub-curves are generated using the calibration slopes corresponding to the N configuration control points. Each sub-curve contains two adjacent configuration control points from the N configuration control points. This effectively splits the multiple Bézier curves into cubic Bézier curves that always pass through the start and end points, ensuring that each generated sub-curve passes through two adjacent configuration control points. Since the generation of each sub-curve only needs to consider two adjacent configuration control points, high-order operations of multiple Bézier curves are avoided, reducing computational complexity and cost, and improving computational efficiency. The calibration slopes ensure that each sub-curve increases monotonically segment by segment, and the entire spliced service curve also exhibits a globally monotonically increasing trend. Through the service curve, the mapping between the input and output signal values of media data can be achieved. In this embodiment, the generated service curve can be intuitively and quantitatively controlled through N configuration control points, improving the flexibility and controllability of the service curve. Because the service curve always passes through N configuration control points and exhibits a globally monotonically increasing trend, the difficulty of setting control points and the required computational cost are reduced. This ensures that the output signal value changes synchronously with the input signal value, achieving consistency in image mapping and improving the efficiency of workflows that rely on service curves.
[0123] On the other hand, based on the coordinate information of the pre-set configuration control points, precise image mapping can be achieved, thereby providing artists with the greatest ability to express their creative intentions. At the same time, it effectively avoids the problem of brightness reversal after image mapping, reduces the difficulty for artists or automated algorithms to set curve control points, and improves workflow efficiency. Finally, since the Bézier curves used are all cubic Bézier curves, they also have the advantage of low computational load.
[0124] In the embodiments of this application, the terms "module" or "unit" refer to a computer program or part of a computer program that has a predetermined function and works with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.
[0125] Please see Figure 7 , Figure 7 This is a schematic diagram of the structure of a computer device provided in an embodiment of this application. Figure 7 As shown, the computer device 1000 may include a processor 1001, a network interface 1004, and a memory 1005. Furthermore, the computer device 1000 may also include a user interface 1003 and at least one communication bus 1002. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display screen and a keyboard; optionally, the user interface 1003 may also include a standard wired interface or a wireless interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The memory 1005 may be high-speed RAM or non-volatile memory, such as at least one disk storage device. Optionally, the memory 1005 may also be at least one storage device located remotely from the processor 1001. Figure 7 As shown, the memory 1005, which is a computer-readable storage medium, may include an operating system, a network communication module, a user interface module, and a device control application.
[0126] In such Figure 7 In the computer device 1000 shown, the network interface 1004 provides network communication elements; the user interface 1003 is mainly used to provide an input interface for the user; and the processor 1001 can be used to call the device control application stored in the memory 1005 to achieve: Obtain N configuration control points used to control signal changes in media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; Generate candidate slopes for N configuration control points. If, based on the two configuration control points adjacent to the target configuration control point, it is determined that the target configuration control point does not meet the preset conditions for monotonicity, then update the candidate slopes corresponding to the target configuration control point to obtain the calibration slopes corresponding to the target configuration control point; otherwise, determine the candidate slopes corresponding to the target configuration control point as the calibration slopes. The N configuration control points include the target configuration control point. Based on the calibration slopes corresponding to the N configuration control points, a service curve consisting of N-1 sub-curves is generated. The N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing. Each sub-curve contains two adjacent configuration control points from the N configuration control points. The service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
[0127] It should be understood that the computer device 1000 described in the embodiments of this application can execute the foregoing text. Figure 3 and Figure 4 The description of the data processing method in any corresponding embodiment will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated.
[0128] Furthermore, it should be noted that this application embodiment also provides a computer-readable storage medium, which stores a computer program. When the processor executes the computer program, it can execute the aforementioned... Figure 3 and Figure 4 The description of the data processing method in any corresponding embodiment is already provided, and therefore will not be repeated here. Furthermore, the beneficial effects of using the same method will also not be repeated. For technical details not disclosed in the computer-readable storage medium embodiments related to this application, please refer to the description of the method embodiments of this application.
[0129] The aforementioned computer-readable storage medium can be an internal storage unit of the data processing apparatus or computer device provided in any of the foregoing embodiments, such as a hard disk or memory of the computer device. The computer-readable storage medium can also be an external storage device of the computer device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., provided on the computer device. Furthermore, the computer-readable storage medium can include both internal storage units and external storage devices of the computer device. The computer-readable storage medium is used to store the computer program and other programs and data required by the computer device. The computer-readable storage medium can also be used to temporarily store data that has been displayed or will be displayed.
[0130] Furthermore, it should be noted that this application also provides a computer program product, which includes a computer program stored in a computer-readable storage medium. The processor of a computer device reads the computer program from the computer-readable storage medium and executes the computer program, causing the computer device to perform the aforementioned... Figure 3 and Figure 4 The method provided in any of the corresponding embodiments.
[0131] The terms "first," "second," etc., in the specification, claims, and drawings of this application are used to distinguish different objects, not to describe a specific order. Furthermore, the term "comprising," and any variations thereof, are intended to cover non-exclusive inclusion. For example, a process, method, apparatus, product, or device that includes a series of steps or units is not limited to the listed steps or modules, but may optionally include steps or modules not listed, or may optionally include other step units inherent to these processes, methods, apparatuses, products, or devices.
[0132] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the composition and steps of each example have been generally described in the foregoing description as a network element. Whether these network elements are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can implement the described network elements using different methods for each specific application, but such implementation should not be considered beyond the scope of this application.
[0133] The methods and related apparatus provided in this application are described with reference to the method flowcharts and / or structural diagrams provided in this application. Specifically, each block of the method flowchart and / or structural diagram, as well as combinations of blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable device to create a machine, such that the instructions, which execute via the processor of the computer or other programmable device, generate instructions for implementing the process. Figure 1 A schematic diagram of one or more processes and / or structures. Figure 1 The computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 A schematic diagram of one or more processes and / or structures. Figure 1 The functions specified in one or more boxes. These computer program instructions may also be loaded onto a computer or other programmable device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable device for implementing the process. Figure 1 A process or multiple processes and / or structures illustrate the steps of the functions specified in one or more boxes.
[0134] The steps in the method of this application embodiment can be adjusted, combined, or deleted according to actual needs.
[0135] The modules in the device of this application embodiment can be merged, divided, and deleted according to actual needs.
[0136] The above-disclosed embodiments are merely preferred embodiments of this application and should not be construed as limiting the scope of this application. Therefore, any equivalent variations made in accordance with the claims of this application shall still fall within the scope of this application.
Claims
1. A data processing method, characterized in that, include: N configuration control points are obtained for controlling signal changes in media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; Candidate slopes are generated for each of the N configuration control points. If, based on two configuration control points adjacent to the target configuration control point, it is determined that the target configuration control point does not meet the preset condition for monotonicity, the candidate slopes corresponding to the target configuration control point are updated to obtain the calibration slopes corresponding to the target configuration control point; otherwise, the candidate slopes corresponding to the target configuration control point are determined as the calibration slopes. The N configuration control points include the target configuration control point. Based on the calibration slopes corresponding to the N configuration control points, a service curve consisting of N-1 sub-curves is generated; the N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, and each sub-curve contains two adjacent configuration control points among the N configuration control points; the service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
2. The method according to claim 1, characterized in that, The N configuration control points are arranged in a strictly monotonically increasing order of their horizontal coordinates; the generation of candidate slopes corresponding to the N configuration control points includes: Based on the first z configuration control points among the N configuration control points, a starting auxiliary point is generated; z is a positive integer greater than or equal to 2. Based on the last z configuration control points among the N configuration control points, generate the last auxiliary point; The starting auxiliary point, the N configuration control points, and the ending auxiliary point are determined as N+2 extended control points. Based on the N+2 extended control points, candidate slopes corresponding to the N configuration control points are generated respectively.
3. The method according to claim 2, characterized in that, The first z configuration control points include a first configuration control point and a second configuration control point. The step of generating a starting auxiliary point based on the first z configuration control points among the N configuration control points includes: Based on the x-coordinates of the first and second configured control points, generate an initial auxiliary x-coordinate. Based on the ordinate of the first configured control point and the ordinate of the second configured control point, generate the initial auxiliary ordinate. Based on the initial auxiliary abscissa and the initial auxiliary ordinate, the initial auxiliary point is determined in the coordinate system; the first configuration control point is the midpoint of the line segment formed by the initial auxiliary point and the second configuration control point.
4. The method according to claim 2, characterized in that, The N configuration control points include configuration control points , where i is an integer greater than or equal to 0, the configuration control point For the N+2 extension control points ; The step of generating candidate slopes corresponding to the N configuration control points based on the N+2 extended control points includes: Obtain the corresponding extension control point from the N+2 extension control points. Two adjacent extended control points; Based on the extension control point The coordinate information corresponding to two adjacent extended control points is used to generate the configuration control points. The corresponding candidate slope.
5. The method according to claim 1, characterized in that, The N configuration control points are arranged in a strictly monotonically increasing order of their horizontal coordinates. The two configuration control points adjacent to the target configuration control point include the left neighbor control point preceding the target configuration control point and the right neighbor control point following the target configuration control point. The method further includes: Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, a first verification value is generated to characterize the monotonicity of the left neighbor curve; the left neighbor curve is a curve determined by the target configuration control point and the left neighbor control point. Based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the right neighbor control point, and the candidate slope corresponding to the right neighbor control point, a second verification value is generated to characterize the monotonicity of the right neighbor curve; the right neighbor curve is a curve determined by the target configuration control point and the right neighbor control point. If the first verification value indicates that the left neighbor curve is non-monotonic, and / or the second verification value indicates that the right neighbor curve is non-monotonic, then it is determined that the target configuration control point does not meet the preset conditions for monotonicity. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the target configuration control point is determined to satisfy the preset condition for monotonicity.
6. The method according to claim 5, characterized in that, The step of generating a first verification value to characterize the monotonicity of the left neighbor curve based on the target configuration control point, the candidate slope corresponding to the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point includes: Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the left neighbor control point, a first left neighbor ordinate estimate is generated for the left neighbor curve. Based on the target configuration control point, the left neighbor control point, and the candidate slope corresponding to the target configuration control point, a second left neighbor ordinate estimate is generated for the left neighbor curve. Generate a first left neighbor ordinate difference between the ordinate of the left neighbor control point and the estimated ordinate of the first left neighbor, a second left neighbor ordinate difference between the estimated ordinate of the first left neighbor and the estimated ordinate of the second left neighbor, and a third left neighbor ordinate difference between the estimated ordinate of the second left neighbor and the ordinate of the target configuration control point; Based on the first left neighbor ordinate difference, the second left neighbor ordinate difference, and the third left neighbor ordinate difference, a first verification value is generated to characterize the monotonicity of the left neighbor curve.
7. The method according to claim 6, characterized in that, The step of generating a first verification value to characterize the monotonicity of the left neighbor curve based on the first ordinate difference, the second ordinate difference, and the third ordinate difference includes: Obtain the second-order difference result between the first ordinate difference, the second ordinate difference, and the third ordinate difference, as well as the geometric mean constraint result between the first ordinate difference, the second ordinate difference, and the third ordinate difference; Obtain a first comparison result between the second-order difference result and the difference threshold, and a second comparison result between the geometric mean constraint result and the monotonicity threshold; A first verification value is generated for the left neighbor curve based on the first comparison result and the second comparison result; if the first comparison result is that the second-order difference result is greater than the difference threshold, and the second comparison result is that the geometric mean constraint result is less than the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is non-monotonic; if the first comparison result is that the second-order difference result is less than or equal to the difference threshold, and / or the second comparison result is that the geometric mean constraint result is greater than or equal to the monotonicity threshold, then the first verification value is used to indicate that the left neighbor curve is monotonically increasing.
8. The method according to claim 5, characterized in that, If, based on two adjacent configuration control points, it is determined that the target configuration control point does not meet the preset condition for monotonicity, then the candidate slope corresponding to the target configuration control point is updated to obtain the calibration slope corresponding to the target configuration control point; otherwise, the candidate slope corresponding to the target configuration control point is determined as the calibration slope, including: Based on the left neighbor control point and the target configuration control point, the left neighbor slope corresponding to the left neighbor curve is generated; based on the right neighbor control point and the target configuration control point, the right neighbor slope corresponding to the right neighbor curve is generated. If the first verification value indicates that the left neighbor curve is non-monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, then the minimum value between the left neighbor slope and the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is non-monotonic, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the left neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is non-monotonically increasing, then the right neighbor slope is determined as the calibration slope corresponding to the target configuration control point. If the first verification value indicates that the left neighbor curve is monotonically increasing, and the second verification value indicates that the right neighbor curve is monotonically increasing, then the candidate slope corresponding to the target configuration control point is determined as the calibration slope.
9. The method according to claim 1, characterized in that, The N configuration control points include adjacent first configuration control points and second configuration control points; the step of generating a service curve composed of N-1 sub-curves based on the calibration slopes corresponding to the N configuration control points includes: Obtain the calibration slope corresponding to the first configuration control point and the calibration slope corresponding to the second configuration control point; Based on the difference in abscissa between the first configuration control point and the second configuration control point, the calibration slope corresponding to the first configuration control point, and the ordinate corresponding to the first configuration control point, the ordinate of the left inner auxiliary control point is generated. Based on the difference in the horizontal coordinate between the first and second configuration control points, the calibration slope corresponding to the second configuration control point, and the vertical coordinate corresponding to the second configuration control point, the vertical coordinate of the right inner auxiliary control point is generated. Using the first configured control point as the curve start point and the second configured control point as the curve end point, a sub-curve containing the first configured control point and the second configured control point is generated by using the curve start point, curve end point, coordinate information corresponding to the first and second configured control points respectively, the ordinate of the left inner auxiliary control point and the ordinate of the right inner auxiliary control point. When the sub-curves corresponding to each pair of adjacent configuration control points among the N configuration control points are obtained, the N-1 sub-curves are combined to obtain the service curve.
10. The method according to claim 1, characterized in that, Also includes: Obtain the input signal value of the j-th pixel in the media data. j is a positive integer; Obtain the input signal value from the N configuration control points. Two adjacent configuration control points are associated as two candidate configuration control points; the input signal value Located within the interval determined by the abscissas of the two adjacent configuration control points; Based on the input signal value The input signal value is generated by combining the x-coordinates of the two candidate configuration control points. The interpolation factor is used to generate the input signal value based on the interpolation factor and the sub-curve containing the two candidate configuration control points. The corresponding curve mapping value; If the mapping relationship between the input signal value and the output signal value in the metadata of the media data is a direct mapping relationship, then the input signal value... The corresponding curve mapping value is determined as the input signal value. The corresponding output signal value; If the mapping relationship between the input signal value and the output signal value in the metadata is an indirect mapping relationship, then an intermediate function for the input signal value and the output signal value is obtained, based on the input signal value. The corresponding curve mapping value and the intermediate function are used to generate the input signal value. The corresponding output signal value.
11. The method according to claim 1, characterized in that, Also includes: Obtain a list of preset input values for the business curve; the list of preset input values includes R discrete preset input values; R is a positive integer; Based on the business curve and the R preset input values, output signal values corresponding to the R preset input values are generated respectively; Obtain the input signal value of the j-th pixel in the media data. Obtain the input signal value from the R preset input values. Two adjacent preset input values, based on the input signal value The degree of difference between the two preset input values is used to interpolate the output signal values corresponding to the two preset input values to obtain the input signal value. The corresponding output signal value.
12. A data processing apparatus, characterized in that, include: The acquisition module is used to acquire N configuration control points for controlling signal changes in media data; the coordinate information of each configuration control point is used to indicate the input signal value and output signal value of the media data; the horizontal coordinates of the N configuration control points are strictly monotonically increasing in the order of arrangement, and the vertical coordinates of the N configuration control points are monotonically increasing in the order of arrangement, where N is a positive integer; The calibration module is used to generate candidate slopes corresponding to the N configuration control points. If it is determined from the two configuration control points adjacent to the target configuration control point that the target configuration control point does not meet the preset conditions for monotonicity, the candidate slopes corresponding to the target configuration control point are updated to obtain the calibration slopes corresponding to the target configuration control point; otherwise, the candidate slopes corresponding to the target configuration control point are determined as the calibration slopes. The N configuration control points include the target configuration control point. The generation module is used to generate a service curve composed of N-1 sub-curves based on the calibration slopes corresponding to the N configuration control points. The N calibration slopes are used to control the N-1 sub-curves to be monotonically increasing, and each sub-curve contains two adjacent configuration control points among the N configuration control points. The service curve is used to complete the mapping between the input signal value and the output signal value of the media data.
13. A computer device, characterized in that, include: Processor, memory, and network interface; The processor is connected to the memory and the network interface, wherein the network interface is used to provide data communication functions, the memory is used to store computer programs, and the processor is used to call the computer programs so that the computer device executes the method according to any one of claims 1-11.
14. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program adapted to be loaded and executed by a processor to cause a computer device having the processor to perform the method of any one of claims 1-11.
15. A computer program product, characterized in that, The computer program product includes a computer program stored in a computer-readable storage medium and adapted to be read and executed by a processor so that a computer device having the processor performs the method of any one of claims 1-11.