anyone have some ideas on this...

Get help using Construct 2

Post » Wed Jan 21, 2015 11:49 pm

in regards to identifying how much of the OBJECT was captured in the view_port Magistross would using anything like the overlapping at offset work in anyway... say at the time of snapping the screenshot the view_port is overlapping the OBJECT 25% would that be a recordable figure???
Need Sprites For Your Next Project?
100% Vector Animated Sprites
Posts: 170
Reputation: 1,086

Post » Thu Jan 22, 2015 12:44 pm

desjardins2014: Please do not use the report option for "feature suggestions", that's not the purpose of the feature.
Moreover, instead of posting multiple posts in a row, use the "Edit" feature in the top right corner of your posts. It limits the noise you make in the forums as well as the number of posts you produce in an hour and make them more "useful".

Last and only warning.
This is a forum, not a chat. Be more considerate when posting.
New to Construct ? Where to start

Image Image

Image Image

Please attach a capx to any help request or bug report !
Posts: 7,413
Reputation: 75,222

Post » Tue Jan 27, 2015 8:56 am

desjardins2014 wrote:I just wanting to take a canvas shot of a certain area only - NOT the whole screen and then save that image to later use

Can't open your file, it's saved as version 195 am on a lower version... but here's how i did it for my game:

Say the area you want to clip is placed under object (for example a 9patch with a thin frame) called "Viewfinder".

Create two global variables, OriginalCanvasW and OrginalCanvasH.

System>On start of layout:
set OriginalCanvasW = OriginalWindowWidth
set OriginalCanvasH = OriginalWindowHeight

Create two functions "ClipSave", called when you click your save button, and "ClipReset", called when "System>On Canvas Snapshot" is fired.

System>Set Canvas Size to Viewfinder.Width x Viewfinder.Height
System>Take Snapshot of Canvas

Do what you need to do with the snapshot (for example Browser>Invoke download of CanvasSnapshot with filename "mysnapshot")
System>Set Canvas Size to OriginalCanvasW x OriginalCanvasH

Hope this helps ;)
Posts: 16
Reputation: 282

Post » Tue Jan 27, 2015 10:37 am

There ya go, enjoy :)

Snapshot selected area / Clipped Snapshot:

Demo (click to save snapshot) will be linked here once i have enough rep points :)

Clipped Snapshot.capx
You do not have the required permissions to view the files attached to this post.
Posts: 16
Reputation: 282


Return to How do I....?

Who is online

Users browsing this forum: blackhornet and 1 guest