The $bool parameter is false by default. If you leave it false, the slider will still be output as a slider. But if it returns anything other than false (such as a string of HTML), it will return that instead. So just build your gallery HTML into the $gallery variable (or use output buffering if you like that way).