You are not logged in.

a.pu

Trainee

  • "a.pu" started this thread

Posts: 80

Location: Default city, Russia

Occupation: Vtour dev, design, UX and photography

  • Send private message

1

Saturday, May 13th 2017, 12:07pm

Textfield rendering functionality extension.

Well...

There is a way to bypass some limitations in html+css rendering.

I used this thing to make hotspots for VR look the same as in common mode:
https://github.com/pbakaus/domvas

It renders styled html code into canvas and lets save it as an image. WIth it's own limitations, yet, I was unable to render pictures into canvas.
A little layouts with some custom positioned blocks and custom icon fonts worked OK, and text features support is full.

Posts: 1,081

Location: Russia, Kaliningrad

  • Send private message

2

Sunday, May 14th 2017, 10:00pm

Well, i think html2canvas is better option, isn't it?
VRAP - desktop VR content player based on krpano.
Common tasks in one place in one click! Discussion thread
DOWNLOAD for MAC
DOWNLOAD for WIN

a.pu

Trainee

  • "a.pu" started this thread

Posts: 80

Location: Default city, Russia

Occupation: Vtour dev, design, UX and photography

  • Send private message

3

Sunday, May 14th 2017, 10:45pm

html2canvas


Does it support transparency?

4

Monday, May 15th 2017, 9:41am

Hi,
There is a way to bypass some limitations in html+css rendering.

I used this thing to make hotspots for VR look the same as in common mode:
https://github.com/pbakaus/domvas
That script uses the 'drawing a svg with a foreignObject with embedded html code to canvas' method. I'm aware about this possibility of course and tried it already some years ago, but there is a big problem with that - it doesn't work an iOS (due iOS bugs) and so far I remember there were also problems with other browsers - and by this it's unfortunately already dropped out. And hopping for bugfixes in newer iOS releases is illusory ;-).

Quoted

Well, i think html2canvas is better option, isn't it?
This one uses a similar approach as krpano by parsing the DOM and rendering everything manually.


I will not include any of them into krpano, but I will think about extending the current plugin API to allowing using a custom canvas element that could be directly used for the hotspot rendering. Then such scripts could be used in user plugins.

Best regards,
Klaus

a.pu

Trainee

  • "a.pu" started this thread

Posts: 80

Location: Default city, Russia

Occupation: Vtour dev, design, UX and photography

  • Send private message

5

Monday, May 15th 2017, 10:02am

Understood, thanks for the reply! *thumbup*

Similar threads