• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

screen_save just take some part. not full screen.

N

NoahGames

Guest
Hello,

help me.

I want to take screenshot.

And i use screen_save("screen.png") or bmp.

But it works like a foolish.

It cuts it self. I can take only some part of screen.

I did not use screen_save_part.



I think problem is my phone's resoulution is diffrent with my room size.

But i don't know solution.

i want to use screen_save. not surface.

plz help me plz
 

sercan

Member
Hello,

help me.

I want to take screenshot.

And i use screen_save("screen.png") or bmp.

But it works like a foolish.

It cuts it self. I can take only some part of screen.

I did not use screen_save_part.



I think problem is my phone's resoulution is diffrent with my room size.

But i don't know solution.

i want to use screen_save. not surface.

plz help me plz
Please let me know if you solved the issue. I have the same problem.
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
A LOT depends on when you call the function. My own experience is that it's best in the POST draw event, and I use it something like this:

Code:
// If Fullscreen:
screen_save_part(file, 0, 0, display_get_width(), display_get_height());
// If windowed
screen_save_part(file, 0, 0, window_get_width(), window_get_height());
 

sercan

Member
A LOT depends on when you call the function. My own experience is that it's best in the POST draw event, and I use it something like this:

Code:
// If Fullscreen:
screen_save_part(file, 0, 0, display_get_width(), display_get_height());
// If windowed
screen_save_part(file, 0, 0, window_get_width(), window_get_height());
didn't work on GMS2. looks like a bug or something.
 

Nocturne

Friendly Tyrant
Forum Staff
Admin
HOW didn't it work? Maybe some screenshots for reference? ANd when did you call the code? How is your game camera and viewport setup? You give zero information... so before declaring a bug, maybe show us what you are doing and what results it gives?
 

sercan

Member
HOW didn't it work? Maybe some screenshots for reference? ANd when did you call the code? How is your game camera and viewport setup? You give zero information... so before declaring a bug, maybe show us what you are doing and what results it gives?
I sad looks like. ok friend maybe ı am seen a bit agressive but im not. I will try today again something different if still same i will post the screenshots. on windows testing it is OK, but same code same project on android, it is not. all the codes shown below gives me same wrong result.

screen_save_part(file, 0, 0, display_get_width(), display_get_height()); windows ok, android a part of screen ( top left )
screen_save(file, 0, 0, display_get_width(), display_get_height()); windows ok, android part of screen ( top left )
screen_save_part(file, 0, 0,720,1280); windows ok, android a part of screen ( top left )
screen_save_part(file, 0, 0,480,800); windows ok, android a part of screen ( top left )
 
Top