Viewer embedding: what is better, embedpano() or createPanoViewer()/embed()?

  • Hello all,

    I've wondered if maybe I'm doing something wrong re: the embedding, since the fullscreen display of the site I'm working on seems to be broken on iOS (or at least, on some devices?) it doesn't zoom to fullscreen but instead seems stuck with full width but only about 1/3 of the vertical height. I'm iPhone deficient so I needed to rely on the screenshot that a co-worker sent to me and I'm kind of "deductive debugging" here *wink* ...

    The version I'm using is 1.18.2.
    My "flow" so far has been this:

    1. generate the viewer files, named krpano.js and krpano.swf
    2. include krpano.js in the html <head> section
    3. Javascript: var viewer = createPanoViewer();
    4. some viewer.addVariable and .addParam calls to set things up
    5. read/process the output of viewer.isHTML5possible() and viewer.isFlashpossible()
    6. then do some javascript logic to decide if it's even worth calling viewer.embed() (or fall back to QTVR or display a "sorry" message).
    7. call viewer.embed();

    I really like to be able to call .isHTML5possible() etc., so I'm hesitating to just call embedpano() the way it's suggested in the documentation, or is this absolutely required to get things to work as device compatible as possible?

    Basically, I guess what I'm asking is, is there a functional difference between calling embedpano( { parameters ... } ) and using var viewer = createPanoViewer(); viewer.embed(); ...?

    -Markus

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!