|
84 | 84 | \pnum |
85 | 85 | The data of \tcode{f} is processed into uncompressed raster graphics data as specified by the value of \tcode{i}. |
86 | 86 |
|
| 87 | +\pnum |
| 88 | +If \tcode{i} is \tcode{image_file_format::unknown}, it is \impldefplain{image_surface!constructor} whether the surface is created in the image file format, if any, that the implementation associates with \tcode{p.extension()} provided that \tcode{p.has_extension() == true}. If \tcode{p.has_extension() == false}, the implementation does not associate an image file format with \tcode{p.extension()}, or the implementation does not support reading in graphics data in that image file format, the error specified below occurs. |
| 89 | + |
87 | 90 | \pnum |
88 | 91 | The resulting uncompressed raster graphics data is then transformed into the data format specified by \tcode{fmt}. If the format specified by \tcode{fmt} only contains an alpha channel, the values of the color channels, if any, of the \underlyingimagesurface are \unspecnorm. If the format specified by \tcode{fmt} only contains color channels and the resulting uncompressed raster graphics data is in a premultiplied format, then the value of each color channel for each pixel shall be divided by the value of the alpha channel for that pixel. The visual data shall then be set as the visual data of the \underlyingimagesurface. |
89 | 92 |
|
90 | 93 | \pnum |
91 | 94 | \throws |
92 | | -As specified in Error reporting [\iotwod.fs.err.report] in \cppseventeen. |
| 95 | +As specified in Error reporting [\iotwod.err.report]. |
93 | 96 |
|
94 | 97 | \pnum |
95 | 98 | \errors |
96 | 99 | Any error that could result from trying to access \tcode{f}, open \tcode{f} for reading, or reading data from \tcode{f}. |
97 | 100 |
|
| 101 | +\pnum |
| 102 | +\tcode{errc::not_supported} if \tcode{image_file_format::unknown} is passed as an argument and the implementation is unable to determine the file format or does not support saving in the image file format it determined. |
| 103 | + |
98 | 104 | \pnum |
99 | 105 | Other errors, if any, produced by this function are \impldefplain{image_surface!data}. |
100 | 106 | \end{itemdescr} |
|
115 | 121 |
|
116 | 122 | \pnum |
117 | 123 | \effects |
118 | | -Any pending rendering and composing operations (\ref{\iotwod.surface.rendering}) shall be performed. |
| 124 | +Any pending rendering and composing operations (\ref{\iotwod.surface.rendering}) are performed. |
119 | 125 |
|
120 | 126 | \pnum |
121 | 127 | The visual data of the \underlyingimagesurface is written to \tcode{p} in the data format specified by \tcode{i}. |
122 | 128 |
|
| 129 | +\pnum |
| 130 | +If \tcode{i} is \tcode{image_file_format::unknown}, it is \impldefplain{image_surface!save} whether the surface is saved in the image file format, if any, that the implementation associates with \tcode{p.extension()} provided that \tcode{p.has_extension() == true}. If \tcode{p.has_extension() == false}, the implementation does not associate an image file format with \tcode{p.extension()}, or the implementation does not support saving in that image file format, the error specified below occurs. |
| 131 | + |
123 | 132 | \pnum |
124 | 133 | \throws |
125 | | -As specified in Error reporting [\iotwod.fs.err.report] in \cppseventeen. |
| 134 | +As specified in Error reporting [\iotwod.err.report]. |
126 | 135 |
|
127 | 136 | \pnum |
128 | 137 | \errors |
129 | 138 | Any error that could result from trying to create \tcode{f}, access \tcode{f}, or write data to \tcode{f}. |
130 | 139 |
|
| 140 | +\pnum |
| 141 | +\tcode{errc::not_supported} if \tcode{image_file_format::unknown} is passed as an argument and the implementation is unable to determine the file format or does not support saving in the image file format it determined. |
| 142 | + |
131 | 143 | \pnum |
132 | 144 | Other errors, if any, produced by this function are \impldefplain{image_surface!data}. |
133 | 145 | \end{itemdescr} |
|
0 commit comments