Yeah it can be a visual device to convey and express things to the audience.
For comics, that could be a visual comedy.
For movies, that could be to avoid to explicitly relay emotions with explicit thoughts that would sound unconvincing.
For books, it'd be a show, don't tell thing, and to...