when I export with the cocoon, I select the "Scale Letterbox" mode in the construct, and the cocoon (ludei) site, has three more choices: Scale to fill, Scale to fit, Strecht to fill, but I've tested all three and still keeps popping up what's underneath the layer, for example, my application is in 800x480 resolution. and the orientation is Landscape Left to choose.
Anyone know how to make the cocoon does not display those parts that are out of 800x480?
Scale letterbox will expose your 'outside layer elements' if the target device has a bigger/unfitting resolution then your project view resolution.
Scale inner scales to fit to the smallest side, meaning you could end up having a part of your layout outside the users target devices viewport.
Stretch to fill actually stretches your project view to adapt itself to fit in the target screen , taking on its ratio, often problematic for objects placed in a HUD.
I set construct generally scale outer, and have about 20% of extra background around my viewport to fill empty spaces from resolution/aspect ratio differences.
This way they will just see a bit of extra background and no black lines.
This means it will scale the size of your project view until its widest size matches the width of the target device.
This is as close to an easy solution I got for an approach of 1 fits all.
CocoonJS does not support Letterbox, so even if you select 'Scale Letterbox' in C2, then CocoonJS anyway uses "Scale Outer"
good solution is to make layout bigger than Window Size,
make background fitting those layout size
and then, on layout start, use ScrollTo in the center of layout,
so even if there will be another aspect ratio, or another resolution
(i.e. 800x480 vs. 853x480) your app will show nicely in the center
Develop games in your browser. Powerful, performant & highly capable.
Thanks for the instructions, was of good help.
Could you explain me how does pro layout stay downtown more clearly? And thanks for the help.