ofDocsexamples inputoutput dirListExample

dirListExample

dirListExample

Screenshot of dirListExample

Learning Objectives

This example demonstrates how to list all files in a directory and how how to access them.

In the code, pay attention to:

  • filtering the files by enabling certain file extensions
  • storing images to a vector from an ofDirectory object

Expected Behavior

When launching this app, you should see a screen with a list of images on the left side and a preview with usage instructions next to it.

Instructions for use:

  • Press any key to show the next image in the list

Other classes used in this file

  • http://openframeworks.cc/documentation/utils/ofDirectory/
  • http://openframeworks.cc/documentation/graphics/ofImage/