Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions image_view/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# image_view

`image_view` provides simple tools to look at image topics and to save them to files.

```console
ros2 run image_view image_view --ros-args -r image:=/camera/image_raw
```

| Executable | What it does |
| --- | --- |
| `image_view` | Shows an image topic in a window. Right-click to save the image. |
| `stereo_view` | Shows the left and right images of a stereo camera and their disparity image. |
| `disparity_view` | Shows a `stereo_msgs/msg/DisparityImage`, color-mapped. |
| `image_saver` | Saves images to files: all of them, or on request with the `save` service. |
| `video_recorder` | Records an image topic to a video file. |
| `extract_images`, `extract_images_sync` | Save images to files (currently broken, see the documentation). |

Each tool is also available as a component, for example `image_view::ImageViewNode`.

## Documentation

The full documentation, including all the parameters, tutorials and known issues, is in the [doc](https://github.com/ros-perception/image_pipeline/blob/rolling/image_view/doc/index.rst) directory and it is published at [docs.ros.org](https://docs.ros.org/en/rolling/p/image_view/).

To build it locally, [install rosdoc2](https://github.com/ros-infrastructure/rosdoc2#installation) and run:

```console
rosdoc2 build --package-path .
```

The result is written to `docs_output/image_view/index.html`.
237 changes: 127 additions & 110 deletions image_view/doc/components.rst

Large diffs are not rendered by default.

177 changes: 17 additions & 160 deletions image_view/doc/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,182 +12,39 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# -*- coding: utf-8 -*-

# Sphinx configuration for the image_view package documentation.
#
# Configuration file for the Sphinx documentation builder.
# This file is not used directly: rosdoc2 exec()s it from a generated conf.py
# and then adds (or overrides) settings such as the project name, the version
# (both taken from package.xml), the theme and the breathe/exhale configuration
# used for the C++ API. Build the documentation with:
#
# This file does only contain a selection of the most common options. For a
# full list see the documentation:
# http://www.sphinx-doc.org/en/master/config

# -- Path setup --------------------------------------------------------------

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
import os
import sys
sys.path.insert(0, os.path.abspath('.'))


# -- Project information -----------------------------------------------------

project = 'image_view'
copyright = '2008-2024, Open Source Robotics Foundation, Inc.' # noqa
author = 'Open Source Robotics Foundation, Inc.'

# The short X.Y version
version = ''
# The full version, including alpha/beta/rc tags
release = '3.2.1'

# rosdoc2 build --package-path <path-to-this-package>

# -- General configuration ---------------------------------------------------

# If your documentation needs a minimal Sphinx version, state it here.
#
# needs_sphinx = '1.0'

# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'sphinx.ext.autodoc',
'sphinx.ext.autosummary',
'sphinx.ext.doctest',
'sphinx.ext.coverage',
'sphinx_rtd_theme',
]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']

# The suffix(es) of source filenames.
# You can specify multiple suffix as a list of string:
#
# source_suffix = ['.rst', '.md']
source_suffix = '.rst'

# The master toctree document.
master_doc = 'index'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = []
# rosdoc2 copies this directory a second time under 'user_docs/' and generates
# 'user_docs.rst' / '__readme_include.rst' wrappers for packages that do not
# ship their own index. This one does, and index.rst already links the
# tutorials and the API reference, so exclude the duplicate tree.
exclude_patterns = ['user_docs', 'user_docs.rst', 'user_docs_tutorials.rst',
'__readme_include.rst']

# The name of the Pygments (syntax highlighting) style to use.
pygments_style = None
project = 'image_view'
copyright = '2008-2024, Open Source Robotics Foundation, Inc.' # noqa: A001
author = 'Open Source Robotics Foundation, Inc.'

pygments_style = 'sphinx'

# -- Options for HTML output -------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'sphinx_rtd_theme'

# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#
# html_theme_options = {}

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = []

# Custom sidebar templates, must be a dictionary that maps document names
# to template names.
#
# The default sidebars (for documents that don't match any pattern) are
# defined by theme itself. Builtin themes are using these templates by
# default: ``['localtoc.html', 'relations.html', 'sourcelink.html',
# 'searchbox.html']``.
#
# html_sidebars = {}


# -- Options for HTMLHelp output ---------------------------------------------

# Output file base name for HTML help builder.
htmlhelp_basename = 'image_view_doc'


# -- Options for LaTeX output ------------------------------------------------

latex_elements = {
# The paper size ('letterpaper' or 'a4paper').
#
# 'papersize': 'letterpaper',

# The font size ('10pt', '11pt' or '12pt').
#
# 'pointsize': '10pt',

# Additional stuff for the LaTeX preamble.
#
# 'preamble': '',

# Latex figure (float) alignment
#
# 'figure_align': 'htbp',
}


# -- Options for manual page output ------------------------------------------

# One entry per manual page. List of tuples
# (source start file, name, description, authors, manual section).
man_pages = [
(master_doc, 'image_view', 'image_view Documentation',
[author], 1)
]


# -- Options for Texinfo output ----------------------------------------------

# Grouping the document tree into Texinfo files. List of tuples
# (source start file, target name, title, author,
# dir menu entry, description, category)
texinfo_documents = [
(master_doc, 'image_view', 'image_view Documentation',
author, 'image_view', 'ROS 2 components for visualising images.',
'Miscellaneous'),
]


# -- Options for Epub output -------------------------------------------------

# Bibliographic Dublin Core info.
epub_title = project

# The unique identifier of the text. This can be a ISBN number
# or the project homepage.
#
# epub_identifier = ''

# A unique identification for the text.
#
# epub_uid = ''

# A list of files that should not be packed into the epub file.
epub_exclude_files = ['search.html']


# -- Extension configuration -------------------------------------------------

autoclass_content = 'both'

autodoc_default_options = {
'members': True, # document members
'undoc-members': True, # also document members without documentation
}
4 changes: 4 additions & 0 deletions image_view/doc/docutils.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[restructuredtext parser]
# rosdoc2/exhale emits the generated class hierarchy as a single very long line,
# which can exceed docutils' 10000-character default.
line_length_limit: 200000
Binary file added image_view/doc/images/image_view.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Loading