As Dave points out, the while loop you describe would work if it weren't for ls issues. Here's what doesn't work:

items=()
produce_items | while read item; items+=( "$item" ); done
do_stuff_with "${items[@]}"

Oh, how many times I have made this mistake.

"items" gets updated just fine, in a subshell, and then after the pipe has finished executing, execution continues in the parent shell where the array is still empty.

Null-terminating and giving "read" the appropriate parameters is an HPR episode of its own, no doubt already made by Dave, or in his pipeline. ;-)