# Not sure how to code this Random/shuffling image effect

**URL:** <https://discourse.processing.org/t/not-sure-how-to-code-this-random-shuffling-image-effect/5073>\
**Category:** Coding Questions\
**Created:** [October 31, 2018, 10:26pm UTC](https://discourse.processing.org/t/not-sure-how-to-code-this-random-shuffling-image-effect/5073 "2018-10-31T22:26:11Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![GoToLoop](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/gotoloop/32/86_2.png) [@GoToLoop](https://discourse.processing.org/u/GoToLoop)\
**Post date:** [November 1, 2018, 7:39pm UTC](https://discourse.processing.org/t/not-sure-how-to-code-this-random-shuffling-image-effect/5073/5 "2018-11-01T19:39:21Z")

</div>

> [@How to check if a file is exist in data folder by code?](https://discourse.processing.org/t/how-to-check-if-a-file-is-exist-in-data-folder-by-code/589/7):
>
> Yes! Just pass an empty string "" to dataPath(): dataFolderPath = this.dataPath('') + '/' print dataFolderPath … or to dataFile(): dir = this.dataFile('') dataFolderPath = dir.path + '/' print dataFolderPath However, if you need all files within the sketch’s “data/” folder, like all images for example, you can use listPaths(), passing the “data/” folder path + a string w/ all desired “extensions=,”: sunglasses PICS\_EXTS = 'extensions=,png,jpg,jpeg,gif,tif,tiff,tga,bmp,wbmp' dir = this.…

---

_[View the full topic](https://discourse.processing.org/t/not-sure-how-to-code-this-random-shuffling-image-effect/5073)._
