Search Unity

fullscreen?

Discussion in 'Flash' started by pretender, Apr 1, 2012.

  1. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    is full screen wokring for you in flash? it does not for me
     
  2. Wolfos

    Wolfos

    Joined:
    Mar 17, 2011
    Posts:
    951
    You mean the new fullscreen? The Youtube/HTML5/Chrome/OS-X combination uses OS-X Lion built-in fullscreen. This is not possible in Flash (yet).

    @pretender:
    Did you call fullscreen in Unity or in ActionScript? I also think (not sure) that Flash still can't use the keyboard in fullscreen applications, so it might be a bit useless anyway.
     
  3. CharlieSkinner

    CharlieSkinner

    Joined:
    Jan 25, 2011
    Posts:
    39
    I believe full screen keyboard control is available as part of Flash Player 11.3. Currently in beta, more details here:
     
  4. tripknotix

    tripknotix

    Joined:
    Apr 21, 2011
    Posts:
    744
    it seems calling full screen in unity does not infact call full screen in flash
     
  5. DDowell

    DDowell

    Joined:
    Feb 8, 2012
    Posts:
    52
    Fullscreen can only be toggled through the user interacting with the player. Since all input in Unity is handled on OnGUI which is frame based you cannot toggle fullscreen from there. What you need is to create a flash display object and have that listen for mouse clicks etc and then toggle fullscreen from that event handler.

    In a step-by-step fashion:
    1. Load unity through a Flash preloader SWF.
    2. Have unity trigger the display of a Sprite on screen (preferably where your button is in screen space).
    3. Setup a listener to said Sprite.
    4. React to mouse clicks directly on the sprite (circumventing Unity's Input handling). Toggle fullscreen by setting the Stage.displayState-property.
     
  6. pretender

    pretender

    Joined:
    Mar 6, 2010
    Posts:
    865
    so it is possible to trigger fullscreen? i am new to flash is there any actual example of how to do this properly?

    thanks!
     
  7. DDowell

    DDowell

    Joined:
    Feb 8, 2012
    Posts:
    52
    You still need help with this? If so, I can post an example project for you.
     
  8. DDowell

    DDowell

    Joined:
    Feb 8, 2012
    Posts:
    52
  9. RalphH

    RalphH

    Administrator

    Joined:
    Dec 22, 2011
    Posts:
    592
    manually setting the rect for rendering is fixed; scaling should be fine too. Furthermore, fullscreen with interactive also works ( all in 4.0 of course).
     
  10. ice99

    ice99

    Joined:
    Feb 8, 2013
    Posts:
    9
    Can anybody supply small working example or a part of a code for "Fullscreen" button?
     
  11. RalphH

    RalphH

    Administrator

    Joined:
    Dec 22, 2011
    Posts:
    592
    The scaling is fixed in Unity 4.0.
     
  12. ice99

    ice99

    Joined:
    Feb 8, 2013
    Posts:
    9
    Sample of Fullscreen trigger pleeeease.
     
  13. Onixcc

    Onixcc

    Joined:
    Jan 14, 2013
    Posts:
    1
    Project in the link seems to have some issues. Does anyone have an updated version that works? When i update the project all the scripts/materials/animations on the cube show as "missing"