You are not logged in.

Zephyr

Professional

  • "Zephyr" started this thread

Posts: 994

Location: Netherlands

Occupation: Web developer

  • Send private message

1

Friday, August 14th 2015, 10:34pm

Flash support

Hi All,

As you all know krpano has support for alot of browsers and devices. Going from webgl, to css3d to flash.

The html5 tours have support for javascript plugins and through xml code (actions, events, and tons more). Flash tours only support flash plugins and xml code.

I've been creating interfaces mainly in xml code for several years, because whatever browser you run, if you support krpano, you will support the xml code. Creating a plugin for a ui element, for instance a menubar, means you have to create this in Javascript and in Flash. Unless you do it in krpano xml, then you're almost sure of it's workings in every browser.

I've been wondering, is it time to drop Flash support, and create javascript-only plugins. Krpano's xml language is great, dont get me wrong, but sometimes a miss a bit of power, dry code, and oop as a developer. Does anybody feel te same? Have you traveled this route, are there downsides?

What's the marketshare of flash, in the panorama industry? If I'm not mistaken, krpano uses flash for tours on Internet explorer 8 and lower, and Pre 4.0 android devices?
3d childrens game using krpano Game
Minify your xml with my krpano XML Compressor
Krpano XML Parsing Error Checklist
Available for hire (krpano xml, javascript, actionscript, flash, php and ipad plugins).

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

2

Friday, August 14th 2015, 11:16pm

I've had to dabble in flash and js plugins..
There's really really isn't a whole lot of difference between actionscript and javascript.
Converting between the two isn't that big of a deal.

Anything flash only is certainly over. And it seems there's also a lot of obsolete stuff in the plugins page.

The current marketplace for flash is 0% as virtual tours are pretty much the last source of new content and firefox displays a big ugly warning now.

Content that's replaceable now in html5. However, there's not really a good reason to not keep flash as the fallback.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

Zephyr

Professional

  • "Zephyr" started this thread

Posts: 994

Location: Netherlands

Occupation: Web developer

  • Send private message

3

Saturday, August 15th 2015, 12:02am

It's not hard to convert, true. Still it's 2 code bases you have to maintain, fix bugs, add features, update graphics.

And how about 'external' javascript tours? I've seen websites, that create an 'abstraction' layer on top of krpano. For instance, an oldie, https://github.com/Ciul/MooKrpano

In javascript you'd say new Hotspot({ath: 10 + window.offset, atv: 0}) or something like that. Then add some event listeners on those objects to handle the click events. You get the benefit of OOP and dry. But the downside, you'd still have to do alot in xml.

Another solution:
instead of creating a menu 'inside' krpano. Just add a div on top of it, that talks to krpano with krpano.call through the js interface. Downside of that one is, you cant go fullscreen and keep the interface. But the plus side is, you have all the power of html, css, and javascript, for instance responsive views, or use existing jquery libraries to create a 10 level deep menu structure. Same goes for popups and other 'layers'. I would recommend it for hotspots, since they need to follow the panorama.
3d childrens game using krpano Game
Minify your xml with my krpano XML Compressor
Krpano XML Parsing Error Checklist
Available for hire (krpano xml, javascript, actionscript, flash, php and ipad plugins).

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

4

Saturday, August 15th 2015, 2:26am

I don't like html over krpano for various reasons. Effects, tweens, images, are better done in krpano.. and that's also two code bases.
The fullscreen issue is a solved one for html though. Forms.. suck in krpano though. It needs to work properly with focus/tabindex etc. Unless it's forms I do it in krpano. Responsive views and multiple device support is better in krpano too.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

Zephyr

Professional

  • "Zephyr" started this thread

Posts: 994

Location: Netherlands

Occupation: Web developer

  • Send private message

5

Saturday, August 15th 2015, 10:23am

How did you solve the fullscreen issue with html elemnts overlaying? Just call the fullscreen API on the outlaying div instead of the pano div?

There are some stuff that a nicer in krpano, but some stuff, just to name a few:
- Show a youtube/vimeo video
- Sliders, (atm Im having an issue with an infinite looping slider which are dime a dozen in javascript but hard to figure out in krpano)
- Access to all css. instead of the limited flash subset
- Webfonts. Atm I make every text an image, to have full control of the styling. I've had tons of issues in textfields. Putting arial as a header, and tahoma as body text, suddenly the whoe text had Arial Mostly flash issues. But you know how certain brands are. They need that specific font.
- You can use SVG files. Vectorized logos that look crisp en sharp on all devices.
- Forms

And other stuff are way better in krpano:
- simple animations (sequences however you'd better use sometihing like TweenTimeline from gs).
- Hotspots
- Audio (directional)
- Device detection and showing hiding elements based on that

It all depends on the job, but I've been making 'complex' interfaces with popups, youtube videos, sliders, multilevel floorplans, all that need to be exact like ta PSD thats delivered. Sometimes I look at my xml code, and think, how much simpeler this would be if I could skip Flash support, or even make this completely in html and js. For instance if there is a copy change, I need to open the PSD, adjust the text, export it, and maybe adjust the crop again. If text is longer, maybe I need to manually offset some elements to prevent overlapping. In html it would just be typing the text, and if text gets longer, it just flows, and other elements would flow beneath it. And agreed you would have 2 codebases to, but one codebase would be regular html/js something you could put a frontender on it, or ask on stackoverflow, or use an existing library to leverage the work.

Dont get me wrong, this is not a rant! I would hate if people think that. I'm just trying to find an optimum workflow and was wondering how much does Flash matter these days?
3d childrens game using krpano Game
Minify your xml with my krpano XML Compressor
Krpano XML Parsing Error Checklist
Available for hire (krpano xml, javascript, actionscript, flash, php and ipad plugins).

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

6

Saturday, August 15th 2015, 4:58pm

For html, you use the html5 version of fullscreen (found in the examples folders) and ensure the html is a child of krpano. All the kolor stuff has been doing it this way.

Sliders rock in krpano. You can use layertoscreen to make some awesome stuff for dragging and clicking.
webfonts+textfield are available in html5 krpano. Easy peasy. Flash sucks. As soon as I build a new screen capture plugin, I'm dropping flash completely. But the webgl canvas buffer can not be used. On my own cms, I dropped flash as a default. It's better now since I can tell instantly when I messed up the xml instead of flash just kinda still working with bad xml.

Youtube videos are pretty simple, but I think you can access most stuff just by using the krpano iframe/textfield combo..

Besides screen capture, flash doesn't need to be used at all for krpano.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

Zephyr

Professional

  • "Zephyr" started this thread

Posts: 994

Location: Netherlands

Occupation: Web developer

  • Send private message

7

Saturday, August 15th 2015, 6:57pm

Thank you for some insight Sachagriffin :)

I would love to see your CMS. I tried to write my own, but always get stuck at the part of 'how to upload images, and proccess them to create a tour'. I got it working at some point by assuming the uploaded picture is always a equarectagilar image, and run them through commandline toolbelt. But if people tart to upload 1GB files in partial panorama or something, it tends to eat up bandwidth and cpu/memory costs. Lately I've been exploring frameworks like Electron to create a desktop app and do all the file handling locally. But I have short attention span, and jump from personal project to another.

What do you mean with layertoscreen? I think we have a different idea of slides ;p I dont mean the distorted pictures, that flyout http://krpano.com/examples/118/examples/…e-hotspots.html

but rather http://kenwheeler.github.io/slick/
3d childrens game using krpano Game
Minify your xml with my krpano XML Compressor
Krpano XML Parsing Error Checklist
Available for hire (krpano xml, javascript, actionscript, flash, php and ipad plugins).

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

8

Saturday, August 15th 2015, 7:16pm

With layer to screen you can test for whether you are clicking to the left right, above or below a layer.
For your slide thing, I would create a sub layer system that sets the proper content dynamically as you drag it.

layers 1 2 3 4 5 6

[hidden layers] 6 5 --- visible [4 3] ---hidden 2 1

and as you drag it it dynamically, creates the edge layers. scrolling left...

deleted 6 [hidden layers]5 4 --- visible [3 2] ---hidden 1 created -- 6

something like that

my cms can tile normal images tiles from source images but I use imagemackick for resizing thumbnails and stuff.
I tried a gigapixels and those "convert"s blew the server up... I will need to revisit all that code. It's an old drupal 6 install that I'll replace with drupal 7 in a couple weeks I think.

For those gigapixels, I just uploaded small equi's and replaced the tiles. my scripts auto explore the tiles to figure out the proper tilesizes and levels for krpano.. so the swap worked perfect!
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

9

Saturday, August 15th 2015, 8:11pm

For your slide thing, I would create a sub layer system that sets the proper content dynamically as you drag it.


Or another method is to make triple layers and jump the scroll area back and forth on set points to provide the illusion it's wrapping around.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour