Sie sind nicht angemeldet.

1

Freitag, 14. September 2012, 02:41

changing paths in the template

I have a large number of panos I want to put up on my site so I thought it was a good time to dig into the templates. Mostly it seams pretty sensible.

One problem I am having is when I change the destination path of the XML it does not update the path to the tiles. If I change the orginal path in multires.config (krpanotools 1.0.8.15) from

Zitat

xmlpath=%INPUTPATH%/%BASENAME%.xml
to

Zitat

xmlpath=
%BASENAME%/krpano/xml/%BASENAME%.xml

it does as expected and creates the directories and puts the xml in the directory but the xml is still pointing at the tiles as if they were in a local subdirectory not where I defined they should be in multires.config.
ie the xml is looking for the files in

Zitat

<cube url="foo.tiles/mres_%s/l3/%v/l3_%s_%v_%h.jpg" />
rather than

Zitat

<cube url="../../foo.tiles/mres_%s/l3/%v/l3_%s_%v_%h.jpg" />
Is there another place where I can define the path to the tiles for the generated xml?

Another unexpected behavior I noticed is that when I changed the path to the xml the path to the generated HTML changed as well even though I did not change it in multires.config . The HTML seamed to follow the XML even though that was not the path set in the multires.config.

The reason I am organizing it this way is for quick modification later. I wanted to have a directory of just my xmls so I could use a batch editor on it if needed rather than digging through directories finding them, modifying them and then putting them back in the correct subdirectory. I also want all the files looking at the same interface graphics and krpano.swf so I can replace one file and have all of my panos on the site take advantage of the latest version.

Tuur

Erleuchteter

Beiträge: 2 899

Wohnort: Netherlands

Beruf: Krpano custom coding / Virtual Tours / Photography / Musician / Recording engineer

  • Nachricht senden

2

Freitag, 14. September 2012, 13:30

Hi Greg,

i think you should also edit the xml template that is read by the droplet config.
You can do that also with the html file that is taken by the droplet.

For global interface things i have a global skin map and i made the xml template (that is used by the droplet) point to that folder for code (skin.xml) and graphics.

so then you just put a pano on the droplet and take the tiles map to transfere/upload.
When not in standardisation of tile size you probably also have to get xml for just that info.. like tile size etc..

Hope it helps.

Tuur *thumbsup*
http://www.virtualtuur.com
Skype:studiotuur

3

Freitag, 14. September 2012, 18:55

Thanks for your response Tuur.

The problem in changing the path is that I can not see how you change the path to the tiles in any of the sources xml. There is very little data in the templates/xml/default.xml file

Quellcode

1
2
3
4
<krpano version="1.0.8.15"[PARTIALPANO]>		<include url="skin/defaultskin.xml" />		<view hlookat="0" vlookat="0" maxpixelzoom="1.0" [VIEWLIMITS]/>
	[PREVIEW]
	[IMAGE]
</krpano>



You are right, I can point all image xml to a global xml to make changes to everything (I am already doing that) but if it is possible my preference would be to also have the ability to make batch changes, ie if I only wanted to change half the images at a later date or something like that that.

4

Samstag, 15. September 2012, 09:07

Hi,

hmm... normally this should work...
the tile-paths (set by the 'tilepath' setting) should be made automatically relative to the xml-path ('xmlpath' setting)...

can you please show me your .config file?

best regards,
Klaus

5

Samstag, 15. September 2012, 20:47

Sure, Thanks for taking a look Klaus,

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# Multi-Resolution Panos
# Skin with Default Buttons
# Documentation: http://krpano.com/tools/kmakemultires/config?version=10815
# krpano tools 1.0.8.15

# basic settings
include basicsettings.config
panotype=autodetect
hfov=360
html5=auto

# convert spherical/cylindrical to cubical
converttocube=true
converttocubelimit=360x45

# multiresolution settings
multires=true
tilesize=512
levels=auto
levelstep=2
maxsize=auto
maxcubesize=auto
leveldownload=auto

# output images path
## greg mod ## added "tiles_%BASENAME%/" to create directory for root level
tilepath=%INPUTPATH%/tiles_%BASENAME%/%BASENAME%.tiles/[mres_c/]l%Al/%Av/l%Al[_c]_%Av_%Ah.jpg

# preview pano settings
preview=true
graypreview=false
previewsmooth=25
## greg mod ## added "tiles_%BASENAME%/" to create directory for root level, removed "%BASENAME%.tiles/"
previewpath=%INPUTPATH%/tiles_%BASENAME%/preview.jpg

# generate smaller mobile images
customimage[mobile].size=1024
## greg mod ## added "tiles_%BASENAME%/" to create directory for root level, replaced "%BASENAME%.tiles/" with "mobile/"
customimage[mobile].path=%INPUTPATH%/tiles_%BASENAME%/mobile/mobile_%s.jpg
customimage[mobile].imagesettings=jpegquality=85 jpegsubsamp=444 jpegoptimize=true
customimage[mobile].xml=<mobile>[NL][TAB]<cube url="[PATH]" />[NL]</mobile>

# xml output
xml=true
## greg mod ## added "%INPUTPATH%/krpano/xml/" to create directory for root level
xmlpath=%INPUTPATH%/krpano/xml/%BASENAME%.xml

# skin / xml template
include defaultbuttons.skin

# html output/template
html=true
## greg mod ## added "tiles_%BASENAME%/" to create directory for root level
htmlpath=%INPUTPATH%/tiles_%BASENAME%/%BASENAME%.html
htmltemplate=html/swfkrpano.html
htmltemplate_js=html/swfkrpano.js

# compression settings (no jpegoptimize for very big panos)
jpegquality=82
jpegsubsamp=422
jpegoptimize=false

Dieser Beitrag wurde bereits 1 mal editiert, zuletzt von »gregdowning« (15. September 2012, 20:58)


6

Dienstag, 25. September 2012, 14:41

Hi,

just a quick note - I have fixed that bug now - that means this will work with the next release.

Best regards,
Klaus

7

Dienstag, 25. September 2012, 19:05

Thanks Klaus! *smile*

jschrader

Fortgeschrittener

Beiträge: 236

Wohnort: Bavaria, Germany

Beruf: Photographer, Producer

  • Nachricht senden

8

Dienstag, 26. Februar 2013, 13:51

I have a similar problem and can't get my head around how to solve it.
I want the files to be created in the local path as common, but want a different path to be written into the XML.

The code I use here works perfect for the customimage-tiles

Quellcode

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# output images path
tilepath=%INPUTPATH%/%BASENAME%.tiles/pano[_c].jpg


# preview pano settings
preview=true
graypreview=false
previewsmooth=25
previewpath=%INPUTPATH%/%BASENAME%.tiles/preview.jpg

# generate smaller mobile images
customimage[mobile].size=1024
customimage[mobile].path=%INPUTPATH%/%BASENAME%.tiles/mobile_%s.jpg
customimage[mobile].imagesettings=jpegquality=80 jpegsubsamp=420 jpegoptimize=true
customimage[mobile].xml=<mobile>[NL][TAB]<cube url="http://my.individual.url.com/[PATH]" />[NL]</mobile>


But whenever I try to alter the tilepath, the batch processor tries to write the files to this path which of course won't work when the path is to an external server.

So to explain it again, what I want is to keep the tilepath for the creation of the tiles as given here, but the path written to the XML should be different.
How do i do this?

9

Donnerstag, 28. Februar 2013, 12:22

Hi,
So to explain it again, what I want is to keep the tilepath for the creation of the tiles as given here, but the path written to the XML should be different.
How do i do this?
That's currently not possible, but I will think about something to make that customizable too.

Best regards,
Klaus

jschrader

Fortgeschrittener

Beiträge: 236

Wohnort: Bavaria, Germany

Beruf: Photographer, Producer

  • Nachricht senden

10

Donnerstag, 28. Februar 2013, 12:32

Thank you Klaus, that would be very nice and is much appreciated.
And thank god that I didn't try longer to find a solution on my own, hahaha *thumbsup*

Ähnliche Themen