How do I do a screen capture?

Get help using Construct 2

Post » Sat Dec 27, 2014 6:37 pm

hello i would liek to add a function in my app to make a screenshot & save the png how i can make this?
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sat Dec 27, 2014 6:58 pm

Snapshot canvas
Take a screenshot of the current display. This triggers On canvas snapshot when the snapshot is ready, and the resulting image can be accessed with the CanvasSnapshot system expression. This can then be loaded in to a sprite or tiled background, sent to a server, or opened with the Browser object in a new tab.

https://www.scirra.com/manual/125/system-actions
ImageImageImage
B
71
S
22
G
257
Posts: 3,788
Reputation: 142,692

Post » Sat Dec 27, 2014 7:40 pm

i used this method, somehting has to be wrong :s
http://postimg.org/image/fz511cdn1/

i also tested this method:
http://postimg.org/image/3ysogk62x/
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sat Dec 27, 2014 8:30 pm

You have to wait for the trigger: On canvas snapshot
ImageImageImage
B
71
S
22
G
257
Posts: 3,788
Reputation: 142,692

Post » Sat Dec 27, 2014 9:09 pm

i made this now, but no result
http://postimg.org/image/ka32tarbt/
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sat Dec 27, 2014 9:21 pm

Using AJAX in file system is that you are doing it wrong.


Use node-webkit plugin to write a file or use Browser plugin to download a file
B
99
S
35
G
29
Posts: 3,139
Reputation: 28,421

Post » Sat Dec 27, 2014 9:27 pm

ok if i do write a file, then the options are just for adding text to a file???
how to save my snapshot to the c:\users\capture.png
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sat Dec 27, 2014 10:00 pm

k, teh system take a snapshot when i do a left click, after i added system on canvas snapshot sprite set animation to canvassnapshot and node webkit write file canvasnapshot to c:\users\capture.png but nothign happens
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sat Dec 27, 2014 11:06 pm

can someone help to achieve this?
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Post » Sun Dec 28, 2014 8:57 pm

Im still with my problem :s of capturing the snapshot :s
i added this but its not working
http://postimg.org/image/65txmqegp/
B
40
S
16
G
7
Posts: 1,747
Reputation: 9,932

Next

Return to How do I....?

Who is online

Users browsing this forum: R0J0hound and 10 guests