HDR video reconstruction by converted tone mapping
Through the inverse tone mapping system, the upgrade function is derived from the LDR image to generate a pseudo-HDR image, and combined with the splitting and stretching operation of the brightness mapping function, the problem of HDR image reconstruction in the video communication system is solved, and efficient image decoding and vision are achieved Improved effect.
Patent Information
- Application Number
- CN202380039643.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2022-05-12
- Filing Date
- 2023-05-02
- Publication Date
- 2024-12-20
AI Technical Summary
Prior art In video communication systems, it is difficult to effectively reconstruct high dynamic range (HDR) images, especially when transmitting low dynamic range (LDR) images, resulting in problems of inaccurate decoding artifacts and brightness mapping, affecting the perceptibility of the image. Appearance and visual effects.
Through the inverse tone mapping (ITM) system, the upgrade function is derived from the input LDR image, a pseudo-HDR image is generated, and it is transmitted as a proxy image. The receiving side uses the inverse brightness mapping function to reconstruct the HDR image, combined with the disassembly of the brightness mapping function The segmentation and stretching operation ensures accurate decoding and reversibility of the image at the receiving end.
It realizes effective reconstruction of high dynamic range images in low dynamic range image transmission, reduces decoding artifacts, improves the accuracy of the visual effect and brightness mapping of the image, and is suitable for the dynamic range of different target displays.
Smart Images

Figure CN119174185A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method and an apparatus for reconstructing a high dynamic range (HDR) image from a received low dynamic range (LDR) image, and a corresponding encoding method, the LDR image together with a tone mapping function comprising the information required to decode at the receiving side of a video communication system a close reconstruction of a master HDR image created and encoded at the sending side. Background Art
[0002] Until the first studies around 2010 (and before the first purchasable HDR decoding TVs were deployed in 2015), at least for video, all video was produced according to a universal low dynamic range (LDR), also known as standard dynamic range (SDR) encoding framework. This had a number of properties. First, only one video was produced that was good for all displays. The system was relative, where white was the maximum (100%) signal, encoded with the maximum brightness code (255 in 8-bit YCbCr encoding), corresponding to the maximum non-linear RGB value: R'=G'=B'=255. Nothing was brighter than white, but all were typical reflection colors (e.g., a piece of paper will also maximally reflect all incident light, or absorb some red wavelengths and leave blue and green to reflect back to the eye, resulting in a cyan local color, which is, by definition, slightly darker than paper white). Each display displays this whitest white (as a "drive request") as the brightest color it is technically configured to render, e.g. 80 nits (the more easily written name for the SI quantity Cd / m^2) on a computer monitor and 200 nits on an LCD display with a TL backlight. The viewer's eyes quickly compensate for differences in brightness, so when not side by side in a store, then at home, all viewers see roughly the same image (despite the different displays).
[0003] People want to improve the perceived appearance of images, not just to make colors that can be printed or drawn on paper, but to make true emissive pixels that are much brighter than "paper white" (also called "diffuse white").
[0004] Some systems (such as the BBC's HLG) do this by defining values above white (given a reference level of white as "1" or 100%) in the encoded image, for example, up to 10 times whiter, which can define pixels that emit 10 times brighter.
[0005] Most systems so far have also moved to a paradigm where a video creator can define an absolute nit value for his image on a chosen target display dynamic range capability (i.e. not 2x or 10x compared to an undefined white level that translates to a variable actual nit output on each endpoint display). The target display is a virtual (intended) display on the video creation side, e.g. a 4000 nit (ML_C) target display for defining a 4000 nit specific video, and any actual consumer endpoint display may have a lower display maximum luminance (ML_D), e.g. 750 nits. In this case, the final display still needs to contain luminance remapping hardware or software, which is usually implemented as a luminance map that somehow makes the luminances of pixels in the HDR input image that have too high luminance dynamic range (particularly their maximum luminance) to be faithfully displayed consistent with values on the final display dynamic range. The simplest mapping simply clips all luminance above 750 nits to 750 nits, but this is the worst way to handle dynamic range mapping, because then in a 4000 nit sunset image, the beautiful structure of the sunlit clouds in the range of 1000-2000 nits is clipped and appears as a white uniform 750 patch. A better luminance mapping moves the 1000-2000 nit sub-range in the HDR input image to, for example, 650-740 of the terminal display dynamic range by a suitably determined function (which can be determined autonomously inside the receiving device (e.g. TV, STB, etc.); or determined by the video creator as the most suitable for his art film or program, and transmitted together with the video signal). Luma refers to any encoding of luminance, for example in 10 bits, using a function that assigns 0-1023 luminance codes to video luminances of, for example, 0.001-4000 nits by a so-called electro-optical transfer function (EOTF).
[0006] The simplest system simply sends (with a suitably defined EOTF) the HDR, for example, 4000 nit maximum brightness image itself. This is what the HDR10 standard does. More advanced systems (such as HDR10+) can also transmit a function for mapping the 4000 nit image down to a lower dynamic range (e.g., 750 nits). They make this easy by defining a mapping function between two different maximum brightness versions of the same scene image, and then using an algorithm to calculate a distorted version of the function to calculate other versions of the function to calculate other endpoint functions for the maximum brightness of the display. For example, if one agrees to define an SDR image so that a maximum pixel brightness of 100 nits is always achieved when the new interpretation is not a relative image, but an absolute nit image, the video creator can define and jointly transmit a function that specifies how to map 0.001 (or 0)-4000 nit brightness (as a first reference image grading) to the corresponding desired SDR 0-100 nit brightness (as a second reference grading), which is called display tuning or adaptation. If a function is defined in a graph of a 4000 nit ML_C input image (horizontal axis) and a 100 nit ML_C secondary graded / reference image normalized to 1.0 that boosts the darkest 20% of colors, say by a factor of 3, i.e. when going from 4000 nits all the way down to 100 nits, if in some specific end-user TV one needs to go down to 750 nits, the required boost might for example be only 2x (depending on the EOFT definition used for luminance, since as mentioned above luminance mapping is often actually implemented in the color processing IC / pipeline as a brightness mapping, e.g. using a psychovisually homogenized EOTF, since this allows defining brightness variations along that range to be more visually uniform, i.e. more relevant and more visually impactful to humans).
[0007] A third, more advanced class of HDR encoders takes these two reference graded images to the next level by re-imaging them the other way around. If one restricts oneself to using largely reversible functions, then one can actually send an LDR image, which can be calculated on the send side by down-mapping the luminance or brightness of, say, a 4000 nit HDR image to an SDR image, as a proxy for the actual master HDR image created by the video creator (e.g. a Hollywood studio for BD or OTT supply, or a broadcaster for sports programming, etc.). The receiving-side device can then apply the inverse function to reconstruct a close reconstruction of the master HDR image. We will refer to systems that transmit the HDR image itself (as created) as "HDR mode", and systems that transmit the LDR image as "LDR mode encoders".
[0008] exist Figure 1A typical example is shown in (eg, summarizing the principles previously patented by the applicant in, for example, WO 2015 / 180854), including the decoding function itself and the display adaptation as a subsequent box, the two technologies should not be confused.
[0009] Figure 1 The video decoding and communication and processing (display) systems are schematically shown. On the creation side, we show a typical encoder (100) embodiment. Those skilled in the art will appreciate that we first show a per-pixel processing pipeline for brightness processing (i.e., all pixels of the input HDR image Im_HDR (typically one of several master HDR images of a video created by a video creator, such as camera capture and coloring or offline color grading creation details are omitted because they are understandable to those skilled in the art and do not improve the exposition of the invention) are processed sequentially), followed by the video processing circuits operating on the entire image. For example, DCT compression of MPEG or a similar compressor like AV1 will work on blocks of pixels. Without wishing to limit the teaching, we will assume that the input image is a master HDR grading created by some human color grader. After selecting the maximum brightness of the master graded video, he will decide where to position (by average brightness) the various video objects on the available range so that the image has the best impact on the consumer. For example, classic averagely lit objects can have brightness comparable to what they would get in LDR grading, while various HDR effect objects (bright sunlit clouds, exploding fireballs, lampshades, objects lit by flash or sunlight, etc.) can get various brightnesses in the higher sub-range of the available brightness range (e.g. above a certain local scene white level). Some of these brightness levels can be changed dynamically in various images, e.g. if a dark corridor is made increasingly brighter by turning on consecutive rows of TL lights on the ceiling.
[0010] In Figure 10, we show two different scene images from a movie (dragon and open-air market (suk), see Fig. 10A), which the creator chooses to be best defined within the 1500 nits Primary HDR Maximum Luminance (ML_C_MH) luminance range (i.e. the primary image is the best representation of the video, which the creator believes is the best because, for example, it provides a good HDR effect for a dragon's fiery breath etc., although a secondary, less ideal but still as similar as possible (re)grading is necessary). One can imagine this as choosing a first canvas shape for painting, and then starting to paint the optimal composition. So, for the primary HDR video (PRIM_GRAD), a human grader (or an automaton) will choose various average luminances around which the pixel luminances of different image objects are distributed. For example, diffuse objects may be permanently lit, e.g. below a selected level LowH, e.g. 220 nits (or a corresponding secondary (re)grading (SEC_GRAD) ending at a secondary grading maximum brightness ML_C_secG, the corresponding secondary limit level (lowS) for permanently lit objects may be taken to be e.g. 120 nits (roughly, this level may correspond to most pixel colors that will be present in an SDR image when reinterpreted over this corresponding brightness range). The dragon may be black, e.g. with an average brightness of 10 nits, while the trees may be around 50 nits. For maximum impact despite the large area, the grader may have the flames spread out around 800 nits. Specular reflections on metal vases in sunlight in an image of a souk may reach pixel brightnesses of up to e.g. 1300 nits. Chandeliers should also be above average brightness, but moderate, e.g. 350 nits, as they will not draw attention (in contrast to the dragon's flames, which would be visible to the viewer if they were only 20 nits, but would then appear less realistic or impressive).
[0011] like Fig. 10B When regrading a secondary image, for example, over a smaller luminance dynamic range, the grader will have to find the corresponding luminance positions of all objects (of any image). For example, the flames are projected to a 400 nit level by the object projection Fo_regrad, because over this limited range one still wants fairly impressive flames, and they happen not to be too bright and significant in this movie. The trees can get an isoluminance projection, and the dragon can, for example, be slightly brightened to account for the expected smaller deep black capabilities of the secondary grade SEC_GRAD.
[0012] like Fig. 10C As can be seen, at least for practical purposes such as consumer video communications (i.e. broadcast, film, etc.) or video conferencing, this regrading can usually be summarized in a 2D plot (sometimes shown normalized to 1.0) by the shape of some luminance mapping function FL_regrad. Fig. 10BThe left side of the figure also shows that sometimes people don't start with a master HDR image that the video creator created as a starting image. Sometimes people can get a master HDR image by using some upscaling algorithm (i.e. Fig. 10B We start with an SDR image, which can be called the SDR master image (MST_SDR), using the PRIM_GRAD in the RGB image. For example, a strong enhancement function (MeffBoo) can be used for the brightest object in the SDR image of the dragon. Note that in principle, when distributing brightness over the main HDR brightness range, the SDR image has no maximum brightness, but it can be assumed that the SDR image continues until, for example, 100 nits.
[0013] Back to Figure 1 , we assume that we start with HDR pixel brightness L_HDR (note that some systems may already work from brightness), which is sent through the selected HDR inverse EOTF in the brightness conversion circuit 101 to obtain the corresponding HDR brightness Y_HDR. Note that the EOTF is usually a fixed function that is used to obtain the brightness from the brightness code that decodes these brightness, not to be confused with the re-grading function, which usually has different optimal shapes for various scene images. For example, a perceptual quantizer EOTF can be used. The input HDR brightness is brightness mapped by the brightness mapper 102 to obtain the corresponding SDR brightness Y_SDR. In this unit, the knowledge of colorimetry is applied. That is, there will be an input connection UI, which is used to appropriately determine the shape of the brightness mapping function (LMF). Broadly speaking, there can be two classes. The offline system can use a human color grader to determine the best LMF according to his artistic preferences through the color grading software. Without limitation, we assume that the LMF is defined as a LUT, which is defined by the coordinates of several nodes (for example, the coordinates of the first node are (x1, y1)). The human grader may set the slope of the first line segment, i.e. the position of the first node, because there is e.g. dark content in the image and he wants to keep it sufficiently visible when displayed on a lower dynamic range display, e.g. specifically a 100 nit ML_C image on a 100 nit ML_D LDR display.
[0014] The second category uses automata, which is an important embodiment for which the prior art described below is important. These automata analyze the image (which brightnesses are present, where they are present, and how many are present, etc.) and propose the best LMF function shape. A particularly interesting automaton, the so-called ITM ("Inverse Tone Mapping"), does not analyze the main HDR image, but rather analyzes the input LDR image on the creation side and makes a pseudo HDR image for that LDR image. The term pseudo here is not intended to mean that our HDR image is of lower quality, but rather that it is calculated from the beginning as an LDR image (possibly a high-quality LDR image, without too much clipping, usually digitized above 8 bits, such as 10 or 12 bits of brightness, without too much DCT or other compression artifacts, etc.), rather than being generated directly as the original main HDR, such as by grading the original decoding of the digital film original camera capture by a human color grader, interspersed with computer graphics objects, etc. This is very useful because most video has historically been displayed as LDR, but may even be created as SDR today or in the near future (at least some of the cameras in a multi-camera production may output SDR, e.g. a drone capturing a side shot of a sports game, and that side shot may need to be converted to the HDR format of the main program). When the capabilities of the LDR mode encoding system are appropriately coupled with the ITM system, the inventors and their technical partners have been able to define a system that can be doubly inverted. That is, the upscaling function for the pseudo HDR image generated by analyzing the original LDR input is essentially the inverse of the LMF used when decoding the LDR communication agent, which is usually an SDR image to be broadcast or unicast to receivers, and when a luminance mapping function commonly transmitted in the metadata is applied, some of those receivers can re-grade that SDR image to an approximation of the main HDR grading. In this way, one can make a system that can not only transmit the original (master) LDR image, but also the information used to make a good HDR image for it (if the content creation consumer wants it to be transmitted automatically, or in other versions also require human input, such as adjusting automatic settings). So, in effect, one is transmitting an HDR master image of the video to the receiver (albeit via a transmission proxy SDR video image).
[0015] The automaton will use various rules, such as determining where there is a light source in the image, but the exact details are irrelevant to the discussion of the present invention, except that it can generate some kind of function LUP (the inverse of the LMF). The functionality of the automaton can similarly be input via the connection UI to be applied to the brightness mapper 102. Note that in our simplest embodiment description, there is only one (degraded) brightness mapper 102. This is not necessarily a limitation: since both the EOTF and the brightness map typically map the normalized input domain [0,1] to the normalized output domain [0,1], there may be one or more intermediate normalized maps that (basically) map 0 input to 0 output and 1 input to 1 output. In this case, the previous intermediate brightness map is then used as a base map, and the (second row) brightness mapper 102 is then used as a correction map based on the first map.
[0016] The encoder now has a set of LDR image brightnesses Y_SDR that correspond to HDR image brightnesses Y_HDR. For example, the darkest pixel in the scene can be defined to be displayed as essentially the same brightness on HDR and SDR displays, but the brighter HDR brightness can be compressed to the upper range of the SDR image, as shown by the convex shape of the LMF function shown inside the brightness mapper 102, whose slope decreases (or reconverges toward the diagonal of the normalized axis system). Note that normalization is easily understood by those skilled in the art: simply divide the brightness code by a power (2; number_of_bits). If desired, the normalized brightness can also be defined by dividing any pixel brightness by the maximum value ML_C of its associated target display (e.g., 4000 nits).
[0017] So one can think of the example of an indoor-outdoor scene in one's mind. Since in the real world outdoor luminance is typically 100x brighter than indoor pixels, a traditional LDR image will show indoor objects as nice and colorful, but everything outside the window will be hard-clipped to a uniform white (i.e., invisible). Now, when transmitting HDR video using reversible proxy images, we will ensure that the bright outside areas seen through the windows are brightened (and possibly even desaturated), but in a controlled manner so that there is still enough information available to reconstruct back into HDR. This is good for both outputs, as any system that just wants to use the LDR image as-is will still see a good rendering of the outdoor scene within the limited LDR dynamic range.
[0018] Thus, the set of Y_SDR pixel luminances (together with their chrominances, the details of which are not necessary for this description) will form a "classic LDR image", in the sense that later circuits do not need to care whether this LDR image is generated intelligently or directly from the camera as in a conventional LDR system. Therefore, the video compressor 103 applies an algorithm such as MPEGHEVC or VVC compression. This is a set of data reduction techniques that, in particular, use discrete cosine transforms to transform blocks of, for example, 8x8 pixels into a finite set of spatial frequencies, which requires less information to represent them. The amount of information required can be adjusted by determining a quantization factor that determines how many DCT frequencies are retained and how accurately they are represented. The disadvantage is that the compressed LDR image (Im_C) is not as accurate as the input SDR image (Im_SDR), and in particular there will be blocking artifacts. Depending on the broadcaster's choice, it may, for example, be so severe that some blocks in the sky are represented only by their average luminance, so they may appear as uniform squares. This is not usually a problem, since the compressor will determine all of its settings (including the quantization factor) in such a way that quantization errors are largely invisible, or at least unobjectionable, to the human system.
[0019] A formatter 104 performs any signal formatting required for the communication channel (e.g. communication via a storage medium on a Blu-ray disc may be different from, for example, a DVB-T broadcast). In general, all variants will have the property that the compressed video image Im_C is bundled in the output image signal S_Im with a luminance mapping function LMF, which may vary (or not) from image to image.
[0020] A deformatter 151 performs the reverse operation of formatting so that the compressed LDR image and the function LMF for reconstructing an HDR image or performing other useful dynamic range mapping processing can be completed in a later circuit. A decompressor 152 undoes, for example, VVC or VP9 compression to obtain an approximate LDR luminance Ya_SDR sequence to be sent to the inverse HDR image reconstruction pipeline. In addition, an upgraded luminance mapper 153 transforms the SDR luminance into a reconstructed HDR luminance YR_HDR (it uses an inverse luminance mapping function ILMF, which is (essentially) the inverse of LMF). We show two possible receiver (150) devices in an illustrative diagram, which can exist as dual functions in one physical device (with the end user choosing which parallel processing to apply), or some devices may have only one parallel processing (for example, some set-top boxes may only reconstruct the main HDR image to store it in a memory 155 (e.g., a hard disk)).
[0021] If we have a display panel connected to a receiver embodiment, for example, a 750 nit ML_D end-user display 190, the receiver can have a display adaptation circuit 180 to calculate an output image of 750 nits instead of a reconstructed image of, for example, 4000 nits (we show this with a dotted line to show that it is an optional component and is not relevant to the teachings of the present invention, although it will typically be used in combination). Without going into detail about the many variations in which display adaptation can be implemented, there is typically a function determination circuit 157 that will come up with an adaptive brightness mapping function F_ADAP based on the shape of the inverse of the LMF (which will typically be closer to the diagonal). This function will be loaded into the display adaptive brightness mapper 156 to calculate a less intense HDR brightness L_MDR within a typically smaller dynamic range, ending up at ML_D=750 nits instead of ML_C=4000 nits.
[0022] Problems arise if the ITM automaton determines that the LMF function has soft clipping, or worse, hard clipping for the brightest luminances. Soft or hard clipping means that the slope of the highest line segment (or tangent to the curve) is small, especially when measured relative to the typical settings of the compressor. For example, if the compressor generates blocks in the sky, which may be the brightest object in the LDR image, the decoder's inverse LMF function will have a large slope for its highest segment or part of the curve. This will increase the visibility of artifacts that should not be visible according to normal compression principles, resulting in undesirable artifacts. One could force a human grader or automaton to only use functions that have a large enough slope for the brightest part of the curve, but this may be undesirable from an artistic point of view for some images and may not be easy for the automaton to program in its rule set.
[0023] Therefore, a general solution to the problem is needed, as the inventors have considered. This would also have the advantage that existing algorithms for determining the best desired Luminance Mapping Function (LMF) shape for any HDR scene image, and the luminance characteristics of its constituent objects and their composition, for example using artificial intelligence (especially when from ITM), do not have to be changed.
[0024] EP3621307 defines a system by which one can decode a higher quality master HDR image by calculating a proxy HDR image with a lower maximum decoded brightness (e.g. the proxy videos sent to the receiver reach or can reach a pixel maximum brightness value of 800 nits, but they should represent the original co-located pixel brightness of up to 2000 nits). In addition, some scaling value-based deformation of the brightness mapping function that determines how to degrade the lower dynamic range, i.e. the maximum brightness image, from the received 800 nit proxy image is stretched in the upward direction to also define a re-grading relationship between the two HDR images (i.e. the creator's master HDR image and the corresponding proxy image at the time of presentation). This deformation moves the curve (preserving its shape) closer to the diagonal of the brightness diagram, i.e., so as to make it straighter, or closer to the identity curve, and generally over the entire input and output range (i.e., independent of the clipping behavior; also note that whether a certain receiving display shows a certain clipping behavior is independent of the clipping behavior on the creation or encoding side).
[0025] WO2014 / 128586 describes one possible approach to HDR video encoding, which is to make a technical SDR proxy that is not visually perfect and add functionality in the commonly communicated metadata to convert it into a secondary, better looking SDR video. Summary of the invention
[0026] cleverly avoiding decoding artifacts when encoding an input high dynamic range image (Im_HDR_PSEU) into coded data (S_Im) using an encoder (100), the coded data comprising firstly a pixel color matrix (Y_SDR, Cb_SDR, Cr_SDR) of an image of a lower dynamic range (Im_SDR) compared to the high dynamic range image, and secondly metadata (SEI) of the image, the metadata comprising a brightness mapping function for calculating high dynamic range pixel brightness (Y_HDR) of the high dynamic range image by applying the function to the pixel brightness of the image of the lower dynamic range;
[0027] wherein the encoder comprises an input (997) for receiving a luminance mapping function (LMF) from a connectable or included inverse tone mapping system (200), the inverse tone mapping system being arranged to derive an upscaling function (LUP) based on the analyzed properties of a master low dynamic range image (Im_LDR_mastr) for calculating the high dynamic range image (Im_HDR_PSEU) from the master low dynamic range image (Im_LDR_mastr) by applying the upscaling function to the luminance of the master low dynamic range image (Im_LDR_mastr), and the inverse tone mapping system being arranged to invert the upscaling function (LUP) to obtain the luminance mapping function;
[0028] Characterized in that the encoder comprises a mapping splitting unit (901), which is arranged to compose the brightness mapping function (LMF) into two data items, wherein the first data item is a stretched brightness mapping function (LMF_HS), and the stretched brightness mapping function is defined in the following way: mapping a clipping point (PtCli) to an endpoint (Ptmax), at which the brightness mapping function (LMF) first reaches (near or usually exactly) a maximum output value (Vomax), and the endpoint (Ptmax) has a maximum value of an input value and a maximum value of an output value as coordinates, and the maximum value of the input value corresponds to a horizontal scaling factor; and mapping all points of the brightness mapping function having input coordinates lower than the input coordinates of the clipping point to stretched input coordinates, while maintaining the output coordinates of the corresponding curve points, and the stretched input coordinates are equal to the corresponding input coordinates multiplied by the horizontal scaling factor;
[0029] wherein the second data item is a scaling factor preferably equal to the inverse of the horizontal scaling factor; the encoder having a formatter (104) arranged to output the stretched luminance mapping function (LMF_HS) and the scaling value (SCAL) as metadata for the image of the lower dynamic range (Im_SDR) which is also output, and a corresponding decoder using the inverse operation of the first luminance mapping and then scaling using the received parameters defining these operations.
[0030] When the operation deals with brightness, the present solution can work both in relative HDR systems, i.e., systems that encode a certain amount of overbrightness as a multiple of the diffuse (LDR) white level through a maximum brightness code, as on an absolute display-defined HDR decoding system, which decodes the exact pixel brightness (through the corresponding brightness code) as the maximum decoded brightness ML_C, as they are intended to be displayed on a certain target display (e.g., ML_C=5000 nits or 1000 nits). The proxy SDR image has the property that all HDR colors can be calculated with sufficient accuracy by using a brightness mapping function. Of course there may be slight rounding errors, but the system has been proven to work well, except for the problems that are handled by the present improved technology when using, for example, 3x10 bits for Y, Cb and Cr pixel color images. Instead of SEI messages, which are standard MPEG mechanisms for transmitting any specific metadata as needed, other communication standards or channels (e.g., HDMI) have their own placeholders for conveying metadata. The encoder can reside in a professional system (e.g., a TV production studio) or in a consumer appliance, for example, uploading a video captured on a mobile phone for a social networking site. An Inverse Tone Mapping (ITM) system is any system that performs the "inverse" (not strictly mathematically, but as a functionality) of classical tone mapping, which is defined as squeezing a higher dynamic range image with a large range of luminances into a standard or low dynamic range of luminances. Thus, an ITM system makes some corresponding HDR image (also a pseudo HDR image, since it was not originally made as an HDR image) from an input LDR image, which is referred to in this text as a master LDR image (using a nomenclature similar to that of a master HDR image). Thus, any system that, for example, maintains the luminance (or its decoded luminance) of reflective objects, but boosts the luminance of emissive objects such as the sun, or increases the luminance of outdoor object pixels compared to indoor pixels, for example, using any technique, whether a program of heuristic rules or other techniques such as machine learning techniques, may be called an ITM. For the purposes of the present invention, ITM will be limited to variants that define upscaling of HDR images by using a luminance mapping function, and generally only by using a luminance mapping function. A stretch function is one that retains its shape (ie, it is offset upwards or downwards compared to, for example, a diagonal line) at least up to some selected end point (losing the clipped portion) but is stretched in size in some dimension. For example, it may be elongated in the horizontal direction.
[0031] Advantageously, an encoder for encoding a high dynamic range image may comprise a clipping detection circuit (904) arranged to detect whether (Im_HDR_PSEU) has a portion of its input range clipped to a maximum output. Following the core principle, the original LMF function is split into two luminance processing operations, namely, one luminance processing operation uses a regular function that maps to an output maximum only when the input maximum is reached and, as a secondary property, is advantageously located closer to the diagonal, which improves decoding and reversibility, and one luminance processing operation can build variants that process on several bad LMF curves by checking if there is some kind of clipping, or do some processing on all curves without checking, but when encountering a function that, for example, already maps 1.0 on 1.0, it keeps the mapping.
[0032] Advantageously, an encoder for encoding a high dynamic range image operates on images defined over an absolute nits dynamic range ending at maximum brightness.
[0033] Advantageously, the encoder for encoding high dynamic range images operates in a decoding system wherein images of lower dynamic range (Im_SDR) are predefined as low dynamic range images having a maximum brightness equal to 100 nits.
[0034] Advantageously, an encoder for encoding a high dynamic range image has its mapping splitting unit (901) determine a stretched luminance mapping function (LMF_HS) by performing a horizontal stretching comprising a linear scaling such that the input coordinate (XC) where limiting first occurs is mapped onto the maximum normalized input coordinate.
[0035] Useful new technical principles may also be embodied in a method of encoding a high dynamic range image (Im_HDR_PSEU), the high dynamic range image being firstly represented by a matrix of pixel colors (Y_SDR, Cb_SDR, Cr_SDR) of a lower dynamic range image (Im_SDR) compared to the high dynamic range image, the lower dynamic range image being compressed for transmission as a compressed lower dynamic range image (Im_C), and the high dynamic range image being secondly represented by metadata (SEI) of the image, the metadata comprising a brightness mapping function for calculating high dynamic range pixel brightness (Y_HDR) of the high dynamic range image by applying the function to pixel brightness of the lower dynamic range image,
[0036] wherein the luminance mapping function (LMF) is received from an inverse tone mapping system (200), the inverse tone mapping system being arranged to derive the luminance mapping function based on analyzed properties of a master low dynamic range image (Im_LDR_mastr) used to construct a corresponding high dynamic range image (Im_HDR_PSEU), wherein the method comprises: splitting the luminance mapping function into two consecutive operations, the second of the two consecutive operations comprising transforming the luminance mapping function into a stretched luminance mapping function (LMF_HS) having a shape that maps a maximum normalized input to a maximum normalized output, and the first operation comprising linear scaling with a scaling value (SCAL), the method being arranged to output the stretched luminance mapping function (LMF_HS) and the scaling value (SCAL) as metadata of the lower dynamic range image (Im_SDR) also output.
[0037] The method may include detecting whether (Im_HDR_PSEU) has a portion of its input range clipped to a maximum output.
[0038] The method may work on images defined over an absolute nits dynamic range ending at maximum brightness, more specifically, a lower dynamic range image (Im_SDR) is a low dynamic range image with a maximum brightness equal to 100 nits (and an HDR image may have an ML_C equal to an ML_C appropriately selected by the video creator, e.g., a person tuning the settings of the ITM, e.g., to produce an HDR image of the quality / impression of ML_C=2000 nits, or 10000 nits, etc.). The method may determine a stretched luminance mapping function (LMF_HS) by performing a horizontal stretch including a linear scaling, such that the input coordinate (XC) where clipping first occurs is mapped onto the maximum normalized input coordinate.
[0039] In particular, those skilled in the art understand that these technical elements can be embodied in various processing elements (such as ASICs (application-specific integrated circuits, i.e., typically IC designers will manufacture ICs (or portions thereof) that perform the method), FPGAs, processors being programmed, etc.), and can reside in various consumer devices or non-consumer devices, whether including a display (e.g., a mobile phone that encodes consumer video) or a non-display device that can be externally connected to a display, and images and metadata can be transmitted via various image communication technologies (such as wireless broadcasting, cable-based communications), and these devices can be used in various image communication and / or usage ecosystems (such as, for example, television broadcasting, on-demand on the Internet, video surveillance systems, video-based communication systems, etc.). BRIEF DESCRIPTION OF THE DRAWINGS
[0040] These and other aspects of the method and apparatus of the present invention will be apparent from the implementations and embodiments described below, and these and other aspects of the method and apparatus of the present invention will be explained with reference to the implementations and embodiments described below and with reference to the accompanying drawings, which are used only as non-limiting specific illustrations to illustrate more general concepts, and in which dashed lines are used to indicate that components are optional, and non-dashed line components are not necessarily necessary. Dashed lines can also be used to indicate elements that are interpreted as necessary but hidden inside an object, or for intangible things, such as the selection of an object / region.
[0041] In the attached picture:
[0042] Figure 1 Schematically shown are two possible functionalities / embodiments of an HDR image (particularly video) decoding system which decodes HDR images by not transmitting those HDR images themselves but LDR images used as proxies, from which LDR images can be calculated by using a substantially reversible luminance mapping function and vice versa. LDR images typically have such a colorimetric quality that they can also be used directly on conventional LDR displays (without further colorimetric adjustments);
[0043] Figure 2 An improved encoder for such an HDR video communication system is shown, which is coupled to or may include an ITM circuit for generating a good looking pseudo HDR image based on an input master LDR image, and a corresponding brightness mapping curve for transforming the image into a corresponding other image;
[0044] Figure 3 Schematically showing what type of inconvenient function (in degraded HDR to LDR mapping variants) may often be determined by some ITM variants, which function has the inconvenient property that it starts clipping too early, leading to reversibility problems;
[0045] Figure 4 Schematically showing what the reversibility problem will be: no matter how normalized the decoding is attempted, there will always be a high slope for the brightest image luminances, which is particularly problematic when used with high levels of video compression, as it will show strong blocking artifacts, which normally should be imperceptible (e.g. in LDR images) and may be even less perceptible and less objectionable when using a better encoding ( / decoding) system as taught in this patent application;
[0046] Figure 5 A first possibility to improve the brightness mapping curve from the ITM is shown, although it is not complete per se because it introduces another colorimetric artifact regarding the balance of image object brightness;
[0047] Figure 6A rotated and then diagonally stretched embodiment is shown, which is a suitable way to form a better reversible brightness mapping curve, which maps to the maximum output only when the maximum input is reached, and will be used together with the rescaling operation in the decoder to obtain essentially the same grading effect as when using the original brightness mapping function LMF;
[0048] Figure 7 The concept of stretching (scaling and different / stretched brightness mapping functions) at the encoder is shown;
[0049] Figure 8 shows what the decoder will do in order to reverse the encoder behavior: it first applies the new stretched luma mapping function taught by embodiments of the invention, and then applies a stretched correction scaling linked to the original luma mapping function (so that the shapes of the functions will overlap); d
[0050] Fig. 9 is a schematic depiction of units typically found in a novel encoder following the innovative principles of encoding by normalized luminance mapping of the present invention; and
[0051] FIG. 10 shows some examples of re-grading of the typical (eg, average) brightness of some image objects along various possible brightness ranges. DETAILED DESCRIPTION
[0052] exist Figure 2 In the figure, we show the encoding side (such as Figure 1Already explained), but now together with the ITM (Inverse Tone Mapping) system (200), as explained, instead of starting from a master HDR image (i.e., the image originally made as 4000 nit HDR), the ITM starts from a master LDR image (Im_LDR_mastr), from which the ITM can make a good looking HDR image (Im_HDR_PSEU). Note that its arrows are shown in dashed lines, because the core system does not actually need to calculate Im_HDR_PSEU, but only the calculated optimal upscaling function LUP, but some ITM variants may actually calculate the HDR output image to calculate some of its properties (e.g., regional histograms, relations between brightnesses of different regions, texture measures, lighting profiles, etc.). The input device that produces the master LDR image is also shown in dashed lines, because there may be several systems incorporated into the present invention. A typical application acquires real-time images from a camera (or formally from one or more cameras, whose images may, for example, be mixed in the mixed master LDR video), and their brightness properties (e.g., average brightness) may be roughly set by the shader 205. Another example is to retrieve an already completed LDR video (e.g., an old movie) from a memory. The brightness mapping function derivation unit 201 derives an optimal upscaling function (LUP) for the input LDR image. The function is inverted by an inverter 202, which produces the inverse of the upscaling function LUP as an output function LMF_out, which will be used as the brightness mapping function LMF of the encoder based on the LDR mode. However, please note (again represented by the dotted lines 101 and 102) that no actual HDR to LDR downgrade is required now, because the ITM system has already handled this: the main LDR image Im_LDR_mastr will be transmitted as a proxy image instead of the local HDR image, and the inverse function of the LUP function will be transmitted together as metadata (e.g., SEI message) so that the receiver reconstructs a close version of the (pseudo) HDR image Im_HDR_PSEU as an HDR image.
[0053] like Figure 3 As schematically shown in , the inventors have discovered that some ITM variants give hard-limited LMF curves on some input images. That is, a normalized input to the brightness mapper 102 that is equal to xc (e.g., xc=0.85, in approximately logarithmic perceptually uniform brightness) will be mapped to the maximum output of the LDR proxy image (i.e., normalized to 1.0, which corresponds to an 8-bit code value Y=R'=g'=B'=255). Using such a function, every input above, for example, 0.85 will also be written into the LDR image matrix at Y=255, and the transmitted function LMF will have a horizontal slope that exceeds XC, for example, 0.85. As Figure 4 As shown, a typical LDR mode decoder will have problems when reconstructing an HDR output image. In theory, there will be an infinite slope at LDR brightness Y=255 or normalized 1.0, which means that in principle the decoder cannot even work properly with such an ILMF input function received in the metadata of the image to be processed. In practice, there will be heuristic mitigation measures in the decoder. For example, the decoder can use a secondary curve ILMF2 derived from ILMF (or in fact, often derived from LMF, which may be the actual function transmitted in the metadata). Except for the highest value, this ILMF2 curve will generally have the same value (x, y) as ILMF for all its curve trajectory points. An embodiment is shown in which the highest sub-range of the curve is split into two parts, one with a small slope and one with a steep (but not infinite) slope. But this still leads to noticeable visual artifacts, especially if the quality of the MPEG compressor of the LDR proxy video is set low, that is, so that many compression artifacts (particularly at the brightest end of the brightness range) are significantly improved and become more visually annoying.
[0054] As about Figure 5 As explained, the inventors realize that they can rotate the LMF function toward the diagonal (exceeding the angle ROTH) so that the clipping point where the horizontal segment starts falls on the diagonal and has equal x and y coordinates (producing a rotated brightness mapping function LMF_R). This will have produced a substantially better reversible function because the curve is now closer to the identity transformation. However, the problem is that the output is not exactly as expected for this image or this particular HDR scene. For example, instead of the pseudo HDR brightness value XC becoming (usually displayed as) the whitest white on the LDR display, even higher values XE will only become as bright as YE (e.g., 240 in 8 bits). And only even brighter values, i.e. 1.0 (which may not even exist in the pseudo HDR image in some cases), obtain the whitest LDR color. Therefore the resulting image will be too dark. Since one of the benefits or even purposes of the LDR mode decoding / decoding system is that consumers who are still watching on traditional LDR displays will obtain very nice simulated LDR images corresponding to the HDR images that are finally transmitted, this purpose will now be hindered because they will watch too dark images. It can be seen that the clipping point (the first time the curve reaches 1.0, or a value very close to 1.0 if some leniency is allowed (for example, discarding a few of the brightest values, such as in a scene that would produce soft clipping) can be projected onto the diagonal by rotation (ROTH) to obtain the diagonal point PtDi, and finally the endpoint Ptmax (which is shown by the stretched arrow starting from this point, but this can be equivalently represented by an arrow starting from (0,0)).
[0055] Therefore, if Figure 6 As shown, they consider additional stretching (DSTR) along the diagonal, which makes the resulting output LDR image brighter again (so we are closer to the optimal LMF function originally determined, however, it has a clipping part at the high end). In fact, by further studying the system, they realized that since the rotation ROTH and the diagonal stretching DSTR basically form an equilateral triangle, the Y values of the nodes of the curve will be basically regained by the rotation and then stretching operation that produces the rotated and stretched brightness mapping function LMF_RS. Only the x points will be different positions, which is not perfect. Another property of the curve is that it still maintains its original shape (although stretched), except that the horizontal clipping part as explained is undesirable, at least for the good quality decoding of the HDR image from the transmitted LDR proxy image (which is the ultimate goal) is undesirable (not building a high-quality innovative HDR codec to be able to receive only good quality LDR images, but more importantly, the highest quality HDR display in the future will be able to watch near-perfect HDR images).
[0056] However, this substantial equality of the y values leads to the further insight that we can discard the second dimension and do everything in one dimension. That is, we can simply stretch the curve horizontally using HSTR.
[0057] This leads to the use of Figure 7 and Figure 8 The properties of the 1D mapping are shown, from which improved decoding (for corresponding mirror decoding) techniques can be further designed.
[0058] like Figure 7 , where the entire re-grading operation is shown on a diagram between the normalized input Norm_in (which will have HDR character, i.e. these luminances will encode a pseudo HDR image of e.g. 2000 nits, which can be obtained from the corresponding main LDR image by ITM) and the normalized output (which will be 8-bit or 10-bit LDR luminances also normalized).
[0059] If we want this LMF_HS mapping curve (which will correspond to LMF_RS in the rotated and stretched embodiment, but in our preferred embodiment produced simply by mapping the XC point of the LMF curve obtained from the ITM to a horizontal stretch of 1.0 on the horizontal axis of the input range) to have the property of mapping 1.0 to 1.0 rather than mapping XC=0.8 to 1.0, we should define the point 0.8 as the new "1.0".
[0060] This can be achieved by the previous scaling operator in the novel encoder, which satisfies these functions by correcting the inappropriate ITM LMF functions when needed (i.e., when there are hard-limited parts in the curve). We can use a linear scaling operation, which is defined as:
[0061] Norm_in_NEW = Norm_in*(1 / XC) [Equation 1]
[0062] If the decoder behaves accordingly (mirror symmetry), the linear scaling operation can be viewed as a brightness mapping of two units, as Figure 8 shown.
[0063] If the decoder knows the encoder's stretched scaling factor SCAL (or any value that enables the calculation of SCAL, e.g. the horizontal coordinate where the slicing starts for the LMF function XC), it can use the post-mapping block. Thus, the decoder first applies the inverse horizontal stretching luminance mapping function ILMF_HS, which maps 1.0 input to 1.0 output and has the shape of the inverse LMF_RS, and then a second block uses the metadata transmitted value SCAL (or any value for that matter, which enables the calculation of SCAL on the receiving side) for compression scaling, so that the value 1 is finally mapped to XC again. This XC value will be, for example, the HDR luminance defined on a perceptual quantizer EOTF (a perceptual quantizer EOTF is a visually homogenized luminance system, i.e. it is designed so that equidistant steps of luminance have essentially equal visual impact on humans across the entire luminance scale), which encodes an expected display luminance of, for example, 2500 nits. This will be the way HDR images are displayed, for example, if the user has a 4000 nit or 5000 nit display, they can usually display such an image by directly showing the pixel brightness intent in exact nits representation. For embodiments with display adaptation, the system will take this into account to calculate as good an approximation as possible of a 4000 nit image at the display dynamic range capability of, for example, 750 nits. In fact, it is not the very high HDR output required by the decoder output, but rather Figure 4. Note that when intermediate luma mappings are present, this strategy may not give exactly the same results as the original clipping mapping function of the ITM (except for the correction for the infinite decoding slope behavior, of course), but it will produce a small difference. Studies in practice have shown that this is not a real concern. If further improvement is still considered necessary, an innovative encoder can calculate a slightly different SCAL value so that when the LMF_HS curve is used with the scaling process, it overlaps more closely with the original LMF curve even in the presence of the intermediate mappers. In fact, once the splitting concept is formulated, an encoder embodiment can even slightly adjust the shape of the LMF_HS function if necessary, since its full shape details are transmitted to the decoder as metadata anyway.
[0064] A preferred way to define the SCAL value is so that it can be used directly on the decoding side to downscale on some luminance definition (e.g. PQ luminance) (which would typically upscale the received SDR proxy image and then scale it to below the theoretical maximum luminance). So, for example, if a value of 0.89 maps to 1.0 on the encoder side, we can define the SCAL value to be the value to which 1.0 should be (re)mapped to on the decoding side, i.e. 0.89 (the x-coordinate of the first clipping point PtCli (typically the normalized input value, which is normalized so that its maximum value is 1.0). Note that the clipping detector can for example work on a function, by for example checking whether all higher input values will map to the maximum normalized output value or y-coordinate, whose value is 1.0. Note that there is no need to check anything on the pseudo HDR image that the ITM can generate, since the function and the input SDR images define pseudo HDR images, i.e. they are decoded for pseudo HDR images. Then, for each point where the output value (y coordinate) of the curve is fixed to a value Y between 0 and 1, stretching the HSTR will correspond to multiplying its input value coordinate by a multiplier value equal to 1 / SCAL. Thus, for example, the x-coordinate (i.e. input value) of the original LMF curve equal to 0.5 will be moved (by multiplication with the inverse (i.e. reciprocal) of the scaling factor 1 / SCAL) to the input value of the LMF_HS curve of 0.5*1.1236=0.56, and this point will have the same y-coordinate as the original point on the LMF curve.
[0065] Therefore, if the decoder will use these two consecutive brightness mapping levels, the new TM improved encoder can meet this situation, such as Fig. 9 shown.
[0066] Fig. 9 An embodiment of an improved encoder according to the insights of the present invention is shown. Most of the technical units are again substantially as described above.
[0067] The innovative mapping splitting unit 901 will now place in the metadata associated with the image (or for a collection of images to be similarly mapped) a Figure 3-8 The adjusted brightness mapping function of one of the explained embodiments, for example, a horizontally stretched brightness mapping function LMF_HS (or a rotated and stretched brightness mapping function resulting from this embodiment), instead of just a brightness mapping function. It will now also output the corresponding scaling factor SCAL in the metadata, so that the whole of these two operations essentially maps the result of the mapping only with the original LMF obtained from the ITM, but with improved behavior at the decoder. Therefore, it can include a function shaping circuit 902, which is arranged to determine a stretched version of the LMF so that the maximum normalized input (1.0) is mapped to the maximum normalized output. And it can include a scaling factor determination unit 903, which is arranged to determine and output the scaling factor SCAL. In a typical color encoding, Cb_SDR and Cr_SDR are the blue chrominance component and the red chrominance component of the pixel color of the LDR proxy image Im_SDR, respectively (those skilled in the art know how to re-express it into, for example, R'G'B' encoding using known colorimetry techniques). The image signal output S_im for communicating with the receiver includes a compressed LDR image Im_C and metadata (SEI), which includes LMF_HS and SCAL. In addition, the function shaping circuit 902 can generally be embodied to analyze whether the LMF function requires shaping, for example, it can include a limit detection circuit 904, which is arranged to detect whether the LMF function of the ITM is limited to a maximum value (that is, usually a strictly increasing function), and whether the input value below 1.0 has been mapped to the output 1.0. If the function does not require shaping, the function shaping unit can also be embodied to perform an identity transformation. Various units can be physically combined.
[0068] The scaling factor is related to the start of clipping to (maximum output value) and should not be confused with other scaling factors in HDR techniques (e.g. values that control how much the curve should be shifted towards or away from the diagonal line in the normalized luminance graph), which correspond to identity transformations (e.g. a 1000 nit maximum luminance image is optimal for a 1000 nit maximum capability display, therefore no mapping should be applied on these image luminances to obtain the driven image for the display).
[0069] The algorithm components disclosed in this document may be implemented (completely or partially) in practice as hardware (eg, part of a dedicated IC) or as software running on a dedicated digital signal processor or a general-purpose processor, etc.
[0070] A person skilled in the art will understand which components may be optional modifications and may be implemented in combination with other components, and how the (optional) steps of the method correspond to the corresponding device units, and vice versa. The word "device" in the present application is used in its broadest sense, i.e. a group of units that allow a specific purpose to be achieved, and may thus be, for example, (a small circuit part of) an IC, or a dedicated appliance (e.g. an appliance with a display), or part of a networked system, etc. "Arrangement" is also intended to be used in the broadest sense, so it may in particular include a single device, a part of a device, a collection of (parts of) cooperating devices, etc.
[0071] The computer program product representation is to be understood as encompassing any physical realization of a set of commands that, after a series of loading steps (which may include intermediate conversion steps, such as conversion to an intermediate language and a final processor language), enables a general or special processor to input commands into the processor and perform any characteristic functions of the present invention. In particular, a computer program product may be realized as data on a carrier (such as, for example, a disk or tape), data present in a memory, data propagated via a network connection (wired or wireless), or program code on paper. In addition to the program code, characteristic data required for the program may also be embodied as a computer program product.
[0072] Some steps required for the operation of the method may already exist in the functionality of the processor rather than being described in the computer program product, such as data input and output steps.
[0073] It should be noted that the above embodiments illustrate rather than limit the present invention. In the case where a person skilled in the art can easily realize the mapping of the presented examples to other parts of the claims, for the sake of brevity, we have not mentioned all these options in depth. In addition to the combination of elements of the present invention combined in the claims, other combinations of elements are also possible. Any combination of elements can be realized in a single dedicated element.
[0074] Any reference signs between brackets in a claim are not intended to limit the claim. The word "comprising" does not exclude the presence of elements or aspects not listed in a claim. The word "a" or "an" preceding an element does not exclude the presence of a plurality of such elements.
Claims
1. An encoder (100) for encoding an input high dynamic range image (Im_HDR_PSEU) into coded data (S_im), the coded data comprising firstly a pixel color matrix (Y_SDR, Cb_SDR, Cr_SDR) of an image of a lower dynamic range (Im_SDR) compared to the high dynamic range image, and secondly metadata (SEI) of the image, the metadata comprising a brightness mapping function for calculating high dynamic range pixel brightness (Y_HDR) of the high dynamic range image by applying the function to the pixel brightness of the lower dynamic range image; in, The encoder comprises an input (997) for receiving a luminance mapping function (LMF) from a connectable or included inverse tone mapping system (200), the inverse tone mapping system being arranged to derive an upscaling function (LUP) based on analyzed properties of a master low dynamic range image (Im_LDR_mastr) for calculating the high dynamic range image (Im_HDR_PSEU) from the master low dynamic range image (Im_LDR_mastr) by applying the upscaling function to the luminance of the master low dynamic range image (Im_LDR_mastr), and the inverse tone mapping system being arranged to invert the upscaling function (LUP) to obtain the luminance mapping function; Characterized in that the encoder comprises a mapping splitting unit (901), which is arranged to compose the brightness mapping function (LMF) into two data items, wherein the first data item is a stretched brightness mapping function (LMF_HS), and the stretched brightness mapping function (LMF_HS) is defined in the following manner: mapping a clipping point (PtCli) to an endpoint (Ptmax), at which the brightness mapping function (LMF) first reaches a maximum output value (Vomax), and the endpoint (Ptmax) has a maximum value of an input value and a maximum value of an output value as coordinates, and the maximum value of the input value corresponds to a horizontal scaling factor; and mapping all points of the brightness mapping function having input coordinates lower than the input coordinates of the clipping point to stretched input coordinates, while maintaining the output coordinates of the corresponding curve points, and the stretched input coordinates are equal to the corresponding input coordinates multiplied by the horizontal scaling factor; wherein the second data item is a scaling factor preferably equal to the inverse of the horizontal scaling factor; the encoder having a formatter (104) arranged to output the stretched luminance mapping function (LMF_HS) and the scaling value (SCAL) as metadata for the lower dynamic range image (Im_SDR) which is also output.
2. An encoder for encoding a high dynamic range image according to claim 1, the encoder comprising a clipping detection circuit (904), the clipping detection circuit (904) being arranged to detect whether the brightness mapping curve (LMF) provided by the inverse tone mapping system to the input terminal (997) has a part of its input range clipped to a maximum output.
3. An encoder for encoding a high dynamic range image according to any one of the preceding claims, wherein: The image is defined over an absolute nits dynamic range ending at maximum brightness.
4. The encoder for encoding a high dynamic range image according to claim 3, wherein: The lower dynamic range image (Im_SDR) is a low dynamic range image having a maximum brightness equal to 100 nits.
5. A method for encoding an input high dynamic range image (Im_HDR_PSEU) into coded data (S_im), said coded data comprising firstly a pixel color matrix (Y_SDR, Cb_SDR, Cr_SDR) of an image of a lower dynamic range (Im_SDR) compared to said high dynamic range image, and secondly metadata (SEI) of said image, said metadata comprising a brightness mapping function for calculating high dynamic range pixel brightness (Y_HDR) of said high dynamic range image by applying said function to pixel brightness of said lower dynamic range image; receiving a luminance mapping function (LMF) from a connectable or included inverse tone mapping system (200), the inverse tone mapping system being arranged to derive an upscaling function (LUP) based on the analyzed properties of a master low dynamic range image (Im_LDR_mastr) for calculating the high dynamic range image (Im_HDR_PSEU) from the master low dynamic range image (Im_LDR_mastr) by applying the upscaling function to the luminance of the master low dynamic range image (Im_LDR_mastr), and the inverse tone mapping system being arranged to invert the upscaling function (LUP) to obtain the luminance mapping function (LMF); It is characterized in that The method comprises the steps of splitting the brightness mapping function (LMF) into two data items, wherein the first data item is a stretched brightness mapping function (LMF_HS), the stretched brightness mapping function (LMF_HS) being defined by: mapping a clipping point (PtCli), at which the brightness mapping function (LMF) first reaches a maximum output value (Vomax) to an endpoint (Ptmax), the endpoint (Ptmax) having as coordinates a maximum value of input values and a maximum value of output values, the maximum value of input values corresponding to a horizontal scaling factor; and mapping all points of the brightness mapping function having input coordinates lower than the input coordinates of the clipping point to stretched input coordinates while maintaining the output coordinates of the corresponding curve points, the stretched input coordinates being equal to the corresponding input coordinates multiplied by the horizontal scaling factor; wherein the second data item is a scaling factor preferably equal to the inverse of the horizontal scaling factor; The stretched luminance mapping function (LMF_HS) and the scaling value (SCAL) are output as metadata for the lower dynamic range image (Im_SDR) which is also output.
6. The method according to claim 5, comprising: It is detected whether the brightness mapping function has a portion of its input range clipped to a maximum output.
7. A method according to any one of the above method claims, wherein: The image is defined over an absolute nits dynamic range ending at maximum brightness.
8. The method according to claim 7, wherein: The lower dynamic range image (Im_SDR) is a low dynamic range image having a maximum brightness equal to 100 nits.
