I'm looking to display a train track that extends horizonally out of the window. I would like to display the track as wrapping, and thus be able to scroll up and down to view the full length of the track - instead of including logic that would break the track up as it is rendered.
I would think that I could define a second view which contained the track outside the window, and then set a viewport stacked under the default view:
View view1 = getDefaultView(); //contains first portion of track
View view2(offscreen track x, offscreen track y); //contains second portion of track
view2.setViewport( 0 , offset from view1.y); //display second portion of track underneath first portion
//scroll down to view this portion
I've consulted:
https://en.sfml-dev.org/forums/index.php?topic=11526.msg80208#msg80208https://en.sfml-dev.org/forums/index.php?topic=23574.0and a few other threads to no avail.
Thanks for any input!