You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

1

Tuesday, December 7th 2010, 1:34pm

thumbnails positioning

Hello,

I'm playing around with the demo version and I wonder what code that I have to change to see all thumbnails aligned (A) from the beginning and not 'all together' as they do automatically (B).

Cheers,
=servaas=

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

2

Tuesday, December 7th 2010, 2:06pm

OK !
I found it myself :-)

<action name="buildthumbs">
if(%1 != NEXT, set(i,0));
if(i LT scene.count,
copy(thumb, scene[get(i)].thumburl);
txtadd(thumbname,'thumb_',get(i));
addplugin(get(thumbname));
set(plugin[get(thumbname)].url, get(thumb));
set(plugin[get(thumbname)].keep, true);
set(plugin[get(thumbname)].align, leftbottom);
set(plugin[get(thumbname)].width, 40);
set(plugin[get(thumbname)].height, 40);
set(plugin[get(thumbname)].x, 10);
set(plugin[get(thumbname)].y, 10);
mul(plugin[get(thumbname)].x, i,50);
mul(plugin[get(thumbname)].y, i,0);

add(plugin[get(thumbname)].x, 5);
add(plugin[get(thumbname)].y, 5);
copy(plugin[get(thumbname)].xsmall, plugin[get(thumbname)].x);
copy(plugin[get(thumbname)].ysmall, plugin[get(thumbname)].y);
add(plugin[get(thumbname)].zorder, 100, i);
set(plugin[get(thumbname)].effect,glow(0xFFFFFF,1.0,2,10000));
set(plugin[get(thumbname)].jsborder,'1px solid #FFFFFF');
copy(plugin[get(thumbname)].thumbpos, i);
set(plugin[get(thumbname)].linkedscene, get(scene[get(i)].name) );
set(plugin[get(thumbname)].onclick, openthumbs() );
inc(i);
buildthumbs(NEXT);
);
</action>

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

3

Tuesday, December 7th 2010, 2:14pm

mmm... but not 100% as I wanted...

I just want them to appear and not to resize or anything. Just be clickable..

=servaas=

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

4

Tuesday, December 7th 2010, 3:08pm

Hi again,

I'm so far that thumbnails always stay in the same position.
You can have a look on this link; but only on iPhone/Pod/Pad

BUT I first have to click once on a thumbnails before they're active.
So how can I get rid of this first click ?

This is what's left of my code at this moment:

<action name="buildthumbs">
if(%1 != NEXT, set(i,0));
if(i LT scene.count,
copy(thumb, scene[get(i)].thumburl);
txtadd(thumbname,'thumb_',get(i));
addplugin(get(thumbname));
set(plugin[get(thumbname)].url, get(thumb));
set(plugin[get(thumbname)].keep, true);
set(plugin[get(thumbname)].align, leftbottom);
set(plugin[get(thumbname)].width, 80);
set(plugin[get(thumbname)].height, 80);
set(plugin[get(thumbname)].x, 40);
set(plugin[get(thumbname)].y, 40);
mul(plugin[get(thumbname)].x, i,0);
mul(plugin[get(thumbname)].y, i,100);
add(plugin[get(thumbname)].x, 5);
add(plugin[get(thumbname)].y, 5);
copy(plugin[get(thumbname)].xsmall, plugin[get(thumbname)].x);
copy(plugin[get(thumbname)].ysmall, plugin[get(thumbname)].y);
add(plugin[get(thumbname)].zorder, 100, i);
set(plugin[get(thumbname)].effect,glow(0xFFFFFF,1.0,2,10000));
set(plugin[get(thumbname)].jsborder,'1px solid #FFFFFF');
copy(plugin[get(thumbname)].thumbpos, i);
set(plugin[get(thumbname)].linkedscene, get(scene[get(i)].name) );
set(plugin[get(thumbname)].onclick, openthumbs() );
inc(i);
buildthumbs(NEXT);
);
</action>

<action name="openthumbs">
if(%1 != NEXT,
set(i,0);
set(events.onclick, set(events.onclick,null); delayedcall(0.1, closethumbs() ); );
);

if(i LT scene.count,
txtadd(thumbname,'thumb_',get(i));
openthumb(get(thumbname));
set(plugin[get(thumbname)].onclick, set(events.onclick,null); closethumbs(); loadscene(get(linkedscene),null,MERGE,BLEND(1)); );
inc(i);
openthumbs(NEXT);
);
</action>

VN2009

Professional

Posts: 1,334

Location: Duluth MN

  • Send private message

5

Tuesday, December 7th 2010, 3:19pm

put the open thumbs action here.

<action name="startup">
<!-- load the first scene -->
loadscene(get(scene[0].name), null, MERGE);

<!-- build the thumbnails (remove the next line to remove the thumbnails) -->
buildthumbs();
openthumbs(); </action>

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

6

Tuesday, December 7th 2010, 4:27pm

Hi,

thanks for your reaction.
I tried to add what you told me.. but now I got a XML parser error #2070

I attached the xml file.

Thanks,
=servaas=
servaas has attached the following file:
  • shore.xml (7.97 kB - 17 times downloaded - latest: Jan 16th 2012, 6:26pm)

servaas

Intermediate

  • "servaas" started this thread

Posts: 158

Location: Belgium

  • Send private message

7

Wednesday, December 8th 2010, 2:52pm

OK !
Looks like it does work !

Thanks a lot, VN2009.

=servaas=

manigordo

Trainee

Posts: 75

Location: Costa Rica

  • Send private message

8

Monday, October 17th 2011, 6:39pm

,thumbs

Hi

manigordo

Trainee

Posts: 75

Location: Costa Rica

  • Send private message

9

Monday, October 17th 2011, 6:41pm

thumbs

Hi,
Can I move thumnails to another position in the viewer? e.g. to other corner

10

Tuesday, October 18th 2011, 12:16pm

Hi,
Can I move thumnails to another position in the viewer? e.g. to other corner
change here the alignment:

Quoted

set(plugin[get(thumbname)].align, leftbottom);
see:
http://krpano.com/docu/xml/#plugin.align


best regards,
Klaus

manigordo

Trainee

Posts: 75

Location: Costa Rica

  • Send private message

11

Saturday, October 22nd 2011, 4:50am

Hi klaus thanx! *thumbsup*
How can I do for the thumnails to display a tip(description of the scene) when I pass the cursor over it?
for example like in the default buttons:
onhover="showtext(Abajo, buttonstyle);"
Regards

12

Thursday, October 27th 2011, 12:03pm

Hi,

look in the xml for the "buildthumbs" action and add there these red-marked lines:

Quoted

...
copy(plugin[get(thumbname)].ysmall, plugin[get(thumbname)].y);
add(plugin[get(thumbname)].zorder, 100, i);
set(plugin[get(thumbname)].effect, glow(0xFFFFFF,1.0,2,10000));
set(plugin[get(thumbname)].jsborder, '1px solid #FFFFFF');
copy(plugin[get(thumbname)].thumbpos, i);
set(plugin[get(thumbname)].linkedscene, get(scene[get(i)].name) );
set(plugin[get(thumbname)].onclick, openthumbs() );
set(plugin[get(thumbname)].scenetitle, get(scene[get(i)].title) );
set(plugin[get(thumbname)].onhover, showtext(get(
scenetitle),buttonstyle) );
inc(i);
buildthumbs(NEXT);
...
best regards,
Klaus