Problem Scenario description containing image

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".
Hi, with Orbiter 2016 came the ability to use HTML in the scenario description. I'm able to include an image by linking to a HTML file in the environment help flag (as used by several scenarios in the Scenarios\2016 Edition folder.
But this is then also inherited by any current-state or quicksave scenarios.

So I want to include an image within the BEGIN_HYPERDESC/END_HYPERDESC tags.

But I can't get the relative image path to be recognized (../photo.jpg), I only get the image to show using an absolute path (like C:/Users/asbjos/MyPersonalOrbiterInstallation/photo.jpg). I even tried to put the image in the same folder as the scenario file, but no luck.

So what is the running folder of the launchpad html viewer, and how do I get the relative path to work?
 

GLS

Well-known member
Orbiter Contributor
Addon Developer
Joined
Mar 22, 2008
Messages
5,914
Reaction score
2,908
Points
188
Website
github.com
"Orbiter\Images"?
 

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".
"Orbiter\Images"?

No luck with that either. I've tried seven or eight multiples of "../", but no number of them work. Almost like it's either not in the orbiter folder at all, or that it is simply not supported. :idk:

---------- Post added at 22:44 ---------- Previous post was at 22:38 ----------

Here's my format, by the way:
Code:
BEGIN_HYPERDESC
<h1>Test</h1>
<p><img src="testImage.jpg" width="50%" alt="Photo: NASA (public domain)." /></p>
END_HYPERDESC

BEGIN_ENVIRONMENT
  System Sol
  Date MJD ...
  ...

So it works for an absolute path "C:/Orbiter2016/testImage.jpg", but not for any attempt at a relative path.
 

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
It all depends where your .html file is located. Relative paths are ...relative ;)
Without knowing the location of your .html file no one can give you a definite answer.

Example:
So if your .html file is located at C:\Orbiter\Html\Scenarios\Test.html
and your image is located at C:\Orbiter\Images\Test.jpg
your link should look like this
Code:
<img src="../../Images/Test.jpg" width="100%" />
For other locations (of either .html or image file) that path is different, of course.

Example2:
.html file at C:\Cool\Stuff\Orbiter\Html\Test.html
image file at C:\Cool\Stuff\Orbiter\Images\Test.jpg
your link should look like this
Code:
<img src="../Images/Test.jpg" width="100%" />
 
Last edited:

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".
Thank you, I guess I wasn't clear enough.

Orbiter can load an external html in the launchpad, by using the flag "Help myfolder\myfile" inside the BEGIN_ENVIRONMENT/END_ENVIRONMENT tags. It will then display the html file "ORBITER_ROOT\Html\Scenarios\myfolder\myfile.html", and include any images and relative paths defined in the file (relative to the defined html). Nice.

But there is also the option to include html code in the BEGIN_HYPERDESC/END_HYPERDESC, no html file required. Now if Orbiter then treats the scenario as a pseudo html file, or it loads the code into an other file, running from somewhere else, I don't know.
Anyway, CSS and other basic HTML commands work, but then it can't find any images. If the pseudo html file was inside the orbiter hierarchy, then it should detect an image in the orbiter root folder (ORBITER_ROOT\testImage.jpg) with the correct multiples of "../". So I tried up to eight times (including zero), but none worked. (i.e. "testImage.jpg", "..\testImage.jpg" ... "..\..\etc..\testImage.jpg")

And since JavaScript apparently is not supported, I can't get the running path from those functions.

The only successful attempts to include an image in HYPERDESC so far include an absolute path, and linking to an online image file. Of course, neither is optimal.
 
Last edited:

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
Ah, now I see!

The current working directory in that specific case seems to be odd...

With this scenario (part):
Code:
BEGIN_HYPERDESC
Test text with image <img src="./test.jpg" width="100%" />
END_HYPERDESC
I've tried to place an image in every directory of a drive, that only contains an orbiter installation...
X:\orbiter.exe
x:\Orbiter_ng.exe
x:\Html\
x:\Images\
x:\Scenarios\

...etc. pp.

and it didn't display any...:shrug:

So I'm guessing it's current working directory is something like C:\Windows\...?!?

Puzzling....
 

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".

I thought so too at first, but it doesn't work for inline graphics Orbiter.exe either. And even so, if it was running from ORBITER_ROOT\Modules\Server\, it should detect the image ORBITER_ROOT\testImage.jpg using "..\..\testImage.jpg".

It seems like an Orbiter bug/limitation, so I've reported it as an issue https://www.orbiter-forum.com/project.php?issueid=1460
Hopefully MartinS sees it and can fix or help shed some light on the situation. :hailprobe:
 

Marijn

Active member
Joined
Mar 5, 2008
Messages
755
Reaction score
166
Points
43
Location
Amsterdam
I remember running into this as well when trying to display vector images in the scenario description. There is a post where it was discussed. But I can't find it anymore.

Then I learned that the scenario description can't be openend in-game so I never bothered about it anymore.
 

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
If you are really desperate you could do something like this:
HTML:
BEGIN_HYPERDESC
Test text with image <img src="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAGQAAABkCAYAAABw4pVUAAAABGdBTUEAALGPC/xhBQAAAAFzUkdCAK7OHOkAAAAgY0hSTQAAeiYAAICEAAD6AAAAgOgAAHUwAADqYAAAOpgAABdwnLpRPAAAAAlwSFlzAAAASAAAAEgARslrPgAAAAZiS0dEAP8A/wD/oL2nkwAAHe5JREFUeNrtnXmcHGWd/9/PU0efc5+ZI3PkJjck3AnIIXcEBVYRXFYFFfHgByorHrguniueIC91fz9kPVbxQEQMgooxBEgIQkggmWRmMlfm7szRd3fVs39UdU/PZHKwv8kkhPkmz1T1VFdN9/dT3/v7PAUzNEMzNEMzNEMzNEMzNEMzNEMzNEMzNEMzNENvDBJvgM8XAILu0IEIMAqEgfQMINNDPuAU4HxgFTAPyAckEAU6gJeBp4BNwCCgZgCZejKBM4GbgLcCJYf5jGHgH8DPgGGgHMhzpcnIeV/MPT7ggtkO9AMjgDUDyORUBnwceB9QAeA1NUoLPZQWeAj4DIQQJJI2Q+EkvaEY4WgKWymApCsh5mG+U8oFZxRoBTYDTwPPuWCpGUAcWgB8CVgH6H6vztyaPBbMzqe00IfH1NE1iRAShSBtKUajaZo7h9nRMsjQaBwpBJomkVKgaxJNOl9NoUinbSxbkbbs7P4EKXsF+AXwMLDvzQ7IEuA+YK0QUFse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jcmVhdGUAMjAxNC0wMS0yOVQyMDoxMDoxNSswMDowMEYP5toAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMTQtMDEtMjlUMjA6MTA6MTUrMDA6MDA3Ul5mAAAAR3RFWHRzb2Z0d2FyZQBJbWFnZU1hZ2ljayA2LjcuNy0xMCAyMDEzLTA5LTAxIFExNiBodHRwOi8vd3d3LmltYWdlbWFnaWNrLm9yZ09axc8AAAAYdEVYdFRodW1iOjpEb2N1bWVudDo6UGFnZXMAMaf/uy8AAAAYdEVYdFRodW1iOjpJbWFnZTo6aGVpZ2h0ADIwMDKKFrkAAAAXdEVYdFRodW1iOjpJbWFnZTo6V2lkdGgAMjAw7iZFNAAAABl0RVh0VGh1bWI6Ok1pbWV0eXBlAGltYWdlL3BuZz+yVk4AAAAXdEVYdFRodW1iOjpNVGltZQAxMzkxMDI2MjE1xP43rwAAABN0RVh0VGh1bWI6OlNpemUAMTQuM0tCQhtJJ0EAAAAgdEVYdFRodW1iOjpVUkkAZmlsZTovLy90bXAvcGhwYlFhbDRpNx4B2gAAAABJRU5ErkJggg==" width="33%" />
END_HYPERDESC
:)
 

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".
If you are really desperate you could do something like this:
HTML:
BEGIN_HYPERDESC
Test text with image <img src="data:image/png;base64,longCode" width="33%" />
END_HYPERDESC
:)

That's ... actually a really good idea! I love it! Thanks a bunch! :bighug:
 

tjc172

New member
Joined
Nov 8, 2020
Messages
1
Reaction score
1
Points
3
Location
Washington
I was looking for a solution when I ran across this... Didn't see a follow up so here is the solution I figured out.

You cannot have the Help command in your scenario. Delete the "Help CurrentState_img" line as it will overwrite your HYPERDESC image call. This Help command references a file in the "\html\scenarios\" folder which is not what you want.

Use the absolute path in your HYPERDESC like so
<p><img src="D:/Orbiter/Orbiter 2016/Images/quickcall.jpg" width="100%" alt="Quick Call Scenario" /></p>

With the Help command no longer in the file, this should work as you expect.

Alternatively, you can make a copy of the CurrentState_img.html file located in the \html\scenarios\ folder mentioned above, update the code, and save as a new file. Then use that name in place of the Help value to match the file name. But this approach overwrites everything in your Desc tags so do one or the other.
 

asbjos

tuanibrO
Addon Developer
Joined
Jun 22, 2011
Messages
696
Reaction score
259
Points
78
Location
This place called "home".
I was looking for a solution when I ran across this... Didn't see a follow up so here is the solution I figured out.

You cannot have the Help command in your scenario. Delete the "Help CurrentState_img" line as it will overwrite your HYPERDESC image call. This Help command references a file in the "\html\scenarios\" folder which is not what you want.

Use the absolute path in your HYPERDESC like so
<p><img src="D:/Orbiter/Orbiter 2016/Images/quickcall.jpg" width="100%" alt="Quick Call Scenario" /></p>

With the Help command no longer in the file, this should work as you expect.

Alternatively, you can make a copy of the CurrentState_img.html file located in the \html\scenarios\ folder mentioned above, update the code, and save as a new file. Then use that name in place of the Help value to match the file name. But this approach overwrites everything in your Desc tags so do one or the other.
For my specific problem, I didn't want to use the absolute path, as it was for an addon. One cannot assume that everyone has Orbiter installed in the same folder (I for one have it in C:/Orbiter2016/). So kuddel's solution was the best for me, which I used for the scenarios in my Project Mercury addon.

But thank you for your reply! I'm sure it will come to use for other people stumbling into this thread in the future!
 
Top