File: HelloWorld.rst

package info (click to toggle)
openexr 3.1.13-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 37,616 kB
  • sloc: cpp: 186,653; ansic: 24,266; sh: 173; python: 68; makefile: 23
file content (43 lines) | stat: -rw-r--r-- 801 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
..
  SPDX-License-Identifier: BSD-3-Clause
  Copyright Contributors to the OpenEXR Project.

.. _Hello:

Hello, World
############

.. toctree::
   :caption: Hello, World
   :maxdepth: 1

A simple program to write a simple ``.exr`` file of an image of 10x10
pixels with values that are a ramp in green and blue:

.. literalinclude:: src/writer/writer.cpp

And the ``CMakeLists.txt`` file to build:
   
.. literalinclude:: src/writer/CMakeLists.txt

To build:

.. literalinclude:: src/writer/build.sh

For more details, see :ref:`The OpenEXR API`.

And a simple program to read an ``.exr`` file:

.. literalinclude:: src/reader/reader.cpp


And the ``CMakeLists.txt`` file to build:
   
.. literalinclude:: src/reader/CMakeLists.txt

To build:

.. literalinclude:: src/reader/build.sh