Hi eXpl0it3r, Laurent and FRex,
>>> You call setPosition after creating the window, right? <<<
Noob mistake
Forgot that RenderWindow does not "create" the window. Moved setPosition where it should be and it works now.
>>> Why don't you just use fullscreen mode, since you want to cover the whole screen? <<<
>>> This. Also these values for resolution are quite big imo, that'd not fit into my screen, if someone launches your game with smaller desktop resolution it'll not appear or display any error ordo anything at all. Just get one of valid video modes and run in fullscreen. <<<
I created the crap table as 1680 x 1050 since when resizing down, there's no loss of apparent resolution, but resizing say a 640x480 screen larger would have to invent pixels so not look as good. (I think anyway.)
I also thought that using fullscreen mode would distort the image if the aspect ratio of the screen was not the same as the aspect ratio of the image. IOW, I thought it would stretch the image to fill the entire screen even if the aspect ratios didn't match. I just tried a 4:3 aspect image as full screen on my 16:10 monitor and now see that's not the case. SFML displays the 4:3 aspect image with a black bar on the right side so it retains the image's aspect ratio as it should.
QUESTIONS:
1. Can I continue to load my 1680x1050 image but use fullscreen mode to accomodate lower res monitors? Or do I need to load a 640x480 image and have fullscreen mode resize it larger to the user's screen resolution?
2. Is there an example of actual code to convert coordinates when fullscreen mode is used? (Or could some kind soul write an example here?) I had a hard time coming up with the actual code when I looked at the SFML 2.0 documentation on that before. --- My needs are simple. I just need to click on different parts of the crap table to choose chip values, make bets on the desired items like passline, field, any craps, etc. where the chip(s) appear where I click, etc. IOW, no sprite movements or shooting or stuff like that.
Thanks,
Raptor