Sie sind nicht angemeldet.

Lieber Besucher, herzlich willkommen bei: krpano.com Forum. Falls dies Ihr erster Besuch auf dieser Seite ist, lesen Sie sich bitte die Hilfe durch. Dort wird Ihnen die Bedienung dieser Seite näher erläutert. Darüber hinaus sollten Sie sich registrieren, um alle Funktionen dieser Seite nutzen zu können. Benutzen Sie das Registrierungsformular, um sich zu registrieren oder informieren Sie sich ausführlich über den Registrierungsvorgang. Falls Sie sich bereits zu einem früheren Zeitpunkt registriert haben, können Sie sich hier anmelden.

Zephyr

Profi

  • »Zephyr« ist der Autor dieses Themas

Beiträge: 991

Wohnort: Netherlands

Beruf: Web developer

  • Nachricht senden

1

Montag, 31. Mai 2010, 11:42

change details on pan/tilt

Hi,

I want to change the details when the user is looking around. I know you can change the quality, but this isn't sufficient enough (especially with wmode transparent). How would I accomplish this:?
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).

2

Dienstag, 1. Juni 2010, 10:07

Hi,

sorry,but krpano is not designed for dynamic changes of the 'details' setting,
the internal 3D object was build once with the given quality, and every change needs a rebuild (by updateobject)

you could change it by:

Quellcode

1
2
set(display.details, ##);
updateobject();


but that's not sense full for continuous usage during viewing,

best regards,
Klaus

Zephyr

Profi

  • »Zephyr« ist der Autor dieses Themas

Beiträge: 991

Wohnort: Netherlands

Beruf: Web developer

  • Nachricht senden

3

Dienstag, 1. Juni 2010, 12:26

Ok,

I basicly now have this:

Quellcode

1
2
3
4
5
set(events.onidle, setDetails(32));
set(events.onmouseup, setDetails(32));
set(events.onmousedown, setDetails(8));
set(events.onkeydown, setDetails(8));
set(events.onkeyup, setDetails(8));

//(I only have arrowkeys enabled)

Quellcode

1
2
3
4
   <action name="setDetails">
		set(display.details, %1);
		updateobject();
   </action>


I alsoo call setDetails on every animation I do.

If I press tab, it works perfectly, untill you move to uncached area. Then I see some 32detailed tiles and movement becomes bit jaggy (this could alsoo be the result of the TAB view). It seems it updates the currentview to 8 details and not the whole Sphereobject.

Why is it not sensable to use updateobject alot? And what is alot? onviewchange would be alot, but would onmousedown/up raise some issues? Performance wise I see an improvement.

Btw doesn't the quality settings internally redraws the canvas? (same like the details settings)
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).

4

Dienstag, 1. Juni 2010, 14:41

Hi,
If I press tab, it works perfectly, untill you move to uncached area. Then I see some 32detailed tiles and movement becomes bit jaggy (this could alsoo be the result of the TAB view). It seems it updates the currentview to 8 details and not the whole Sphereobject.
when pressing tab - just lines around triangle will be down,

right, updateobject() updates only the details for the current level (note - you can set the details for each level in the xml),
updating all level is currently not possible,

Why is it not sensable to use updateobject alot? And what is alot? onviewchange would be alot, but would onmousedown/up raise some issues? Performance wise I see an improvement.
it depends also on the size of the pano, number of tiles, and the details setting itself, how long it will need to update the internal 3d object, changing the details on a >2 gigapixel pano would be slow, but on a 2-10 megapixel pano it would be fast in comparison, I can't give a recommendation here, maybe just try and see if it's okay in your case...


Btw doesn't the quality settings internally redraws the canvas? (same like the details settings)
how do you mean that?

best regards,
Klaus

Zephyr

Profi

  • »Zephyr« ist der Autor dieses Themas

Beiträge: 991

Wohnort: Netherlands

Beruf: Web developer

  • Nachricht senden

5

Mittwoch, 2. Juni 2010, 09:21

Zitat

Zitat

Btw doesn't the quality settings internally redraws the canvas? (same like the details settings)


how do you mean that?


Well If you use the HIGH Filter. Flash draws the bitmap (read panorama) anti-aliased using a 4 x 4 pixel grid and smoothed if the movie is static. If you put the quality to lets say LOW. Flash has to redraw the panorama to a non anti-alisased and non smooth one.

Isnt this basicly the same with details settings. Flash draws a 3d vector sphere/cube/cylinder, after changing the details, it has to redraw it.

The calculations made to redraw a 3d vector sphere would probally be faster then redrawing the whole stage or all the tiles to a other antialising setting.

Im just guessing stuff here :P

Zitat

right, updateobject() updates only the details for the current level (note - you can set the details for each level in the xml),
updating all level is currently not possible,


Settings details per level is something I like to avoid. I don't see the functionality of this. If details settings are to low or to high on the first level, how would the next step be different? I like to keep the details the same on all levels. This way I always have control over the perfomance in 1 xml file (I could make 1 plugin with details per leve <plugin name="leveldetails" level1="16" level2="32" keep="true"/>l and use get(plugin[leveldetails].level) per level step, but that overcomplicates things).

On a completely other subject. Maybe I asked this before but, how does the (pre)loader work? Does it include plugin and xml files? Like if I have a 1mb plugin file, does he preload it together with the tiles? or is it just the tiles/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).

Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »Zephyr« (2. Juni 2010, 09:37)


6

Mittwoch, 2. Juni 2010, 15:08

Hi,
Isnt this basicly the same with details settings. Flash draws a 3d vector sphere/cube/cylinder, after changing the details, it has to redraw it.
no, Flash itselfs doesn't draw or calculate the sphere/cube/...
the data structures and generation of the final triangles is all done by krpano,
and after changing the details the whole data structure (which includes much more than just coordinates or so) behind the sphere/cube must be rebuild,


On a completely other subject. Maybe I asked this before but, how does the (pre)loader work? Does it include plugin and xml files? Like if I have a 1mb plugin file, does he preload it together with the tiles? or is it just the tiles/panorama?
which preloader?

krpano itselfs work in that way:
- first the xml files will be loaded and parsed
- then it starts loading the plugin/hotspots files and the preview image at the same time
- when the preview image was done, it start loading the tiles

best regards,
Klaus

Zephyr

Profi

  • »Zephyr« ist der Autor dieses Themas

Beiträge: 991

Wohnort: Netherlands

Beruf: Web developer

  • Nachricht senden

7

Mittwoch, 2. Juni 2010, 20:06

The Loader:

Quellcode

1
2
<progress showload="bar(center,33%,3%,0,15%,shaded,
                        0x000000,0x666666,0xAAAAAA)" />


Since it's in the xml, I reckon that it doesn't take the size of the xml in consideration. (So If you have 100kb xml file, it has to load 100kb, before it shows anything, you basicly stare to a blank screen).

Then it loads the preview image and the plugins. Is that added in the preloader bar?

If it's not, then it has to load loads of Kb before the user sees anything.

So:
Loads index.html/ javascripts/images in the html file/ krpano.swf
You'll see your htmlpage
Krpano stage is blank
Now it loads loads the xml, the first xml can be quite massive with includes, settings, view, contextmenu, keybuttons, events, actions, etc. Usually the 2nd, 3rd, 4th, 5th xml is smaller with just scene information)
You see nothing yet
Loads preivew image, is shows as soon as load is done
Loads plugins url from xmls
If plugin preload = true, wait till plugin is loaded, then:
You see preview image
Loads the tiles. THIS IS WHERE YOU SEE THE PRELOADER BAR LOAD. By now 1-2mb is already downloaded depending on how many plugins you have

It seems there is an awfull lot of loading before the user sees that its loading.

I know it's impossible to show a loader when loading the xml files when the loader information is in the xml file, but would it be possible (as a feature request) to include the bytes from the preview image and plugins in the preloader bar?

What I always do is make 1 global.xml In this global.xml I declare all general settings for the photo's. I load the flash interface, buttons, map, maphotspots, mousecursor, viewersettings, detailsettings. Well easily 10's of pages of xml and 100'kbs of swf's and images. Then this xml is included within every location. So my initial load is high, while during the tour, I only load tiles and scene xml. The downside now is, that the scene starts loading after the global.xml + plugins are done. This isn't a problem as long as people see that Im loading stuff and that it isn't broken. People lose their attention after 3 seconds.
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).

8

Mittwoch, 9. Juni 2010, 15:32

Hi,
Since it's in the xml, I reckon that it doesn't take the size of the xml in consideration. (So If you have 100kb xml file, it has to load 100kb, before it shows anything, you basicly stare to a blank screen).
right, that's true,
such large xml files were never part of the loading design...
but why is that xml so larger, there should be ways to make it smaller...


Then it loads the preview image and the plugins. Is that added in the preloader bar?

If it's not, then it has to load loads of Kb before the user sees anything.
no, this 'loading bar' shows only the progress of the pano tiles loading,


I know it's impossible to show a loader when loading the xml files when the loader information is in the xml file, but would it be possible (as a feature request) to include the bytes from the preview image and plugins in the preloader bar?
that's more difficult as you maybe think - the filesize of the plugins is not known before starting loading them, and the number of simultaneous loading files is limited by the browser, you see the problem also when using multi-resolution panos, calculating a sense-full progress bar there, is not an easy topic...

but you could do the following:
include a 'loading screen' per plugin and preload it (maybe it a separate small xml before the main one),
e.g.

startup.xml:

Quellcode

1
2
3
4
5
6
7
8
9
10
11
<krpano onstart="startup();"> 
	
	<plugin name="loadingscreen" url="image.jpg" align="center" keep="true" />
	
	<action name="startup">
		loadpano(main.xml, null, MERGE);
		wait(BLEND);
		tween(plugin[loadingscreen].alpha, 0.0, 0.5, default, removeplugin(loadingscreen) );
	</action>

</krpano>


best regards,
Klaus