OpenStreetMap Forum

The Free Wiki World Map

You are not logged in.

#1 2017-12-18 21:28:41

n42k
Member
Registered: 2017-12-18
Posts: 11

3D Model Repository

I've created a 3D model repository for use with OSM as part of Google Summer of Code this year with my 2 mentors, and we're continuing to work on it, and eventually have it launch.

This repository basically allows linking features such as benches and monuments in OSM to 3D models, enabling a much improved 3D rendering of the world.

We're now looking for OSM 3D developers that wish to use our API, so that work on new features can begin earlier in your own projects, before the repository is launched. If you like the idea of adding more complex models to your 3D maps, I suggest reading how to get access to our test server here.

You can also check my older diary entries for more information about the project (in chronological order):
GSoC Diary: Start of Community Bonding
GSoC Diary: Web Design and REST API draft
GSoC Diary: Backend and the Live Preview
GSoC Diary: Conclusion

Offline

#2 2017-12-18 23:45:15

vvoovv
Moderator
Registered: 2008-03-04
Posts: 2,252

Re: 3D Model Repository

Which models are available in the 3D repository right now?

Offline

#3 2017-12-19 07:13:19

-karlos-
Member
Registered: 2016-05-29
Posts: 48

Re: 3D Model Repository

Its not about existing data/models, its about the service.
So there are not many models stored yet
but you may upload and set a tag in OSM to have them shown.

There are several proposels in the OSM wiki of coruse roll:
https://wiki.openstreetmap.org/wiki/Use … tory_links
https://wiki.openstreetmap.org/wiki/Relation_3D:Model


-karlos-

Offline

#4 2017-12-19 22:52:22

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

vvoovv wrote:

Which models are available in the 3D repository right now?

As -karlos- correctly said, the most important part is the service provided, there aren't currently many models, but they will come in time.

Offline

#5 2018-01-07 12:54:15

vvoovv
Moderator
Registered: 2008-03-04
Posts: 2,252

Re: 3D Model Repository

Let's consider a practical use case for the 3D model repository.

How to get all available models for Paris without duplications?

Offline

#6 2018-03-09 09:53:42

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

vvoovv wrote:

Let's consider a practical use case for the 3D model repository.

How to get all available models for Paris without duplications?

1. Get all 3dmr=* tags present in Paris.

2. For each tag, get the model id (it's simply the value of the tag)

3. To actually get the corresponding models, either download the nightly, which will have the latest revision of all the models in the repository, and then the models are available as <id>.zip files, or use the repository's API, making an HTTP request for each model id, to /api/model/<id>, which will return a single .zip file.

Offline

#7 2018-03-21 22:37:58

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

It is with great pleasure that I announce the launch of the 3D Model Repository, which is now available at https://3dmr.eu!

Starting off from my Google Summer of Code project, over the past few months, along with my mentors, Jan and Tobias, I have been working hard on setting up the infrastructure required for the launch, namely a web server and the domain, which have been warmly provided by FOSSGIS. Along with this, some new features and bugfixes were added to the repository, including a PR by dkiselev. Finally, the last few miscellaneous issues before the launch have been resolved, and a few sample models were added to the repository.

On the renderer side, -karlos- has been making great progress with OSM go, having provided us with an easy way to show off the features of the repository. An example rendering can be seen here or in the picture below.

aF5fxFI.png

Contributing

Contributions are always welcome, in any form! There's several ways to contribute to the repository, such as modelling or developing. If you know how to use Blender or SketchUp, you can get started right away modelling features of your town, consult the wiki for more information. Otherwise, if you'd rather develop, you can implement the repository in a 3D renderer (more information available on the wiki and the API documentation), or add new features to the repository itself (a Gitlab repository is available). Other than that, if you have any other idea, make sure to get in contact.

Hope to see your additions!

Last edited by n42k (2018-03-22 13:53:08)

Offline

#8 2018-03-22 05:59:16

vvoovv
Moderator
Registered: 2008-03-04
Posts: 2,252

Re: 3D Model Repository

A note.

Sketchup isn't Google Sketchup for quite long time already.

Offline

#9 2018-03-22 13:56:36

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

vvoovv wrote:

A note.

Sketchup isn't Google Sketchup for quite long time already.

Thank you for that. I've fixed it where possible.

Offline

#10 2018-03-23 11:33:35

Harry Wood
Member
From: London UK
Registered: 2007-05-29
Posts: 146
Website

Re: 3D Model Repository

sddefault.jpg

I made a video of a little ride around the Eiffel Tower

What fun! That's starting from this location in osmgo.org: http://osmgo.org/go.html?lat=48.86091&l … name=beton

Offline

#11 2018-03-23 12:21:31

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

Harry Wood wrote:

Unfortunately that model wasn't from the 3D Model Repository, it was a fixed model that is always rendered there. Me and -karlos- are working on getting the Eiffel Tower in the repository (https://3dmr.eu/model/4/2) rendering correctly in OSM go. Perhaps you could do another video then?

Still shows how interesting OSM can be with 3d models!

Offline

#12 2018-03-23 15:44:27

Harry Wood
Member
From: London UK
Registered: 2007-05-29
Posts: 146
Website

Re: 3D Model Repository

Oh ok. I saw Eiffel tower was one of four models in there: https://3dmr.eu  ...but that's a different Eiffel tower hey?
Also I was wondering why there's an OSM logo in the middle of the view

Offline

#13 2018-03-23 17:12:22

pezza10
Member
Registered: 2016-12-28
Posts: 35

Re: 3D Model Repository

Congratulations! this is great!  But i still don't quite understand how to upload a model.I follow the instructions from the wiki page.
I have an obj. file with mtl. and textures in one .zip file.On tags field i put building=yes.

How do we link the model to OSM feature? is there any field where we have to put the 3dmr tag?

After i edit metadata nothing appears,just that blue background.Do we have to wait more time before we can see the 3d model?

Offline

#14 2018-03-23 19:44:10

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

Harry Wood wrote:

Also I was wondering why there's an OSM logo in the middle of the view

You should contact -karlos- about it, he made OSM go.

pezza10 wrote:

Congratulations! this is great!  But i still don't quite understand how to upload a model.I follow the instructions from the wiki page.
I have an obj. file with mtl. and textures in one .zip file.On tags field i put building=yes.

Your first attempt had a folder in the root of the zip file, but all files should be in the root of the zip, I'll be making the documentation clearer on that. It seems that your second attempt, at https://3dmr.eu/model/7/1, has a model which 3DMR is successfully loading. From looking at it in Blender, try placing the bottom of the building touching the origin (at 0,0,0) and experiment with scaling? Note that you can revise previous models to fix them, instead of uploading new ones.

pezza10 wrote:

How do we link the model to OSM feature? is there any field where we have to put the 3dmr tag?

Simply place a 3dmr=ID tag on the node/way you wish your model to appear on, with ID being your model's ID, which you can see on the URL of your model, https://3dmr.eu/model/7/1 (in this case it would be 3dmr=7).

pezza10 wrote:

After i edit metadata nothing appears,just that blue background.Do we have to wait more time before we can see the 3d model?

No, model viewing should be instant if your model was understood by 3DMR.

Offline

#15 2018-03-23 21:34:42

pezza10
Member
Registered: 2016-12-28
Posts: 35

Re: 3D Model Repository

It still shows nothing here https://3dmr.eu/model/7/1

Simply place a 3dmr=ID tag on the node/way you wish your model to appear on

Where can I do that? On openstreetmap.org? because my model doesn't appear there

Also if i go to the server page  https://3dmr.eu/ i can see only eifel tower,petronas towers and police box but the other 3, 2 of mine which the first one(with the folder inside the zip folder) i know it's not good,but neither of this 3 models i can't see them,just blue color - this happens in latest Google Chrome 64 bits
In latest Internet explorer i don't see neither of all six models on https://3dmr.eu/ page

By the way can you delete a model after you uploaded it and how?

Offline

#16 2018-03-23 22:50:29

pezza10
Member
Registered: 2016-12-28
Posts: 35

Re: 3D Model Repository

Ok now i see my model on the repository page,i had to zoom with mouse wheel to see it.
Some of the textures are not in the right place.
I modeled this in C4d and then export it as .obj format and when i open it back in C4d it's ok - the textures are where it should be

Now,what renders support these 3d models? osmgo.org? because i still can't see  my model there.

f4map-does it render the models?

Last edited by pezza10 (2018-03-23 22:56:01)

Offline

#17 2018-03-24 16:39:03

pezza10
Member
Registered: 2016-12-28
Posts: 35

Re: 3D Model Repository

Now i can see my model on OSMgo24 but it's rotated 90 dgr on z or x axis i think.
In the repository i see that you can rotate the model on vertical axis - which one of them is that x,y or z?i think it's y.Because i try to rotate the model but i can't get it right - my model needs to be rotated on another axis.
I rotate the model and even try to switch axis between them in C4d and i exported the model after that but after i upload it,on OSMgo24 it still doesn't have the right rotation.

and tell me about F4map,does it support these 3d models?

Last edited by pezza10 (2018-03-24 16:51:15)

Offline

#18 2018-03-25 20:06:21

n42k
Member
Registered: 2017-12-18
Posts: 11

Re: 3D Model Repository

pezza10 wrote:

i know it's not good,but neither of this 3 models i can't see them,just blue color - this happens in latest Google Chrome 64 bits
In latest Internet explorer i don't see neither of all six models on https://3dmr.eu/ page

Thanks for these reports. I'll see what I can do about them.

pezza10 wrote:

By the way can you delete a model after you uploaded it and how?

No. Admins can hide them, however. Perhaps we could extend that feature to also allow hiding if you own the model file.

pezza10 wrote:

Now i can see my model on OSMgo24 but it's rotated 90 dgr on z or x axis i think.
In the repository i see that you can rotate the model on vertical axis - which one of them is that x,y or z?i think it's y.Because i try to rotate the model but i can't get it right - my model needs to be rotated on another axis.
I rotate the model and even try to switch axis between them in C4d and i exported the model after that but after i upload it,on OSMgo24 it still doesn't have the right rotation.

Place the model normally in C4d, as you exported it the first time. Then, when exporting as OBJ, there might be an option to export it with Z as the up axis. There's this option in Blender, maybe C4d has it too (I've never used C4d).


pezza10 wrote:

and tell me about F4map,does it support these 3d models?

I've never heard about F4map supporting 3DMR.

Offline

#19 2018-03-28 16:59:28

Tordanik
Moderator
From: Germany
Registered: 2008-06-17
Posts: 2,303
Website

Re: 3D Model Repository

n42k wrote:

I've never heard about F4map supporting 3DMR.

F4Map use their own, non-free 3d models. So far, they haven't expressed an interest in supporting 3DMR, but they'd be welcome of course. smile

Offline

#20 2018-03-28 22:10:40

SupapleX
Member
Registered: 2016-09-12
Posts: 21

Re: 3D Model Repository

Wow, thats an amazing project. I dreamed about an OSM related 3D-modell database since a while (having 3D buildings, connect them with an OSM way/node, replace them in 3D renderings) and you exactly realized it. Just saw the FOSSGIS-Talk (german language) - unfortunately my Blender skills aren't the best but maybee it's enough to try a simple modell.
Much thanks for your work, I hope this projekt grows and becomes better known in the community!

Offline

#21 2018-03-31 19:25:40

Tordanik
Moderator
From: Germany
Registered: 2008-06-17
Posts: 2,303
Website

Re: 3D Model Repository

SupapleX wrote:

Much thanks for your work, I hope this projekt grows and becomes better known in the community!

Thank you for the kind words, and I hope you enjoyed the FOSSGIS talk! Looking forward to your contributions if you manage to tame Blender! smile

Offline

#22 2018-03-31 22:03:13

-karlos-
Member
Registered: 2016-05-29
Posts: 48

Re: 3D Model Repository

pezza10 wrote:

Now i can see my model on OSMgo24 ...

Yes, I added the tag in OSM. Just to a Node, about at the right place. There is no Building in OSM to correctly add the 3dmr-tag, could you add it? And you should edit the size value of you model in 3DMR or in C4D. In OSM, 1 unit is 1 Meter. Then you will see this:

Building normal orientated

We need to add more documentation to 3DMR, may be even a tutorial - as video.

pezza10 wrote:

... but it's rotated 90 dgr on z or x axis i think.
In the repository i see that you can rotate the model on vertical axis - which one of them is that x,y or z?i think it's y.Because i try to rotate the model but i can't get it right - my model needs to be rotated on another axis.
I rotate the model and even try to switch axis between them in C4d and i exported the model after that but after i upload it,on OSMgo24 it still doesn't have the right rotation.

The orientation value in the 3DMR is meant to rotate the model to the real compas direction of the building. Values for switching axises could be added to 3DMR but I hope, you will be able to correct it in C4D. If you still have trouble, tell me, we will solve it, together.


-karlos-

Offline

#23 2018-03-31 22:17:59

-karlos-
Member
Registered: 2016-05-29
Posts: 48

Re: 3D Model Repository

* The start page of 3DMR shows the 6 last imported models. It takes quite a while until the models get visible. roll May be there sould only be pitures (screenshots of the rendereing). The rendering, rotating and scaling may be in the single model view only.

* Quite a view models don't render well. An info/error-message would be helpfull. I know, its on GitLab. I realy sould start to help there. cool


-karlos-

Offline

#24 2018-04-02 10:17:55

pezza10
Member
Registered: 2016-12-28
Posts: 35

Re: 3D Model Repository

Ok now the orientation/rotation and scaling of my 3d model it's pretty ok.I don't know exactly what i did in C4d - i flipped the Z Axis,swaped Y/Z axis,swapped faces in the obj. exporter options but in the end it turned ok.

Another aspect to consider it's clearing the browser cache after you revised your 3d model,because in the first time i didn't clear it all the time,and thus i couldn't see all the "transformations" on the Osmgo page.

I should correct the position of the model,i mean move it in the horizontal axis,but this i think it should be fixed with making the area of the building in Openstreetmap editor and then assign the right 3dmr tag to it,isnt'it?

Last edited by pezza10 (2018-04-02 10:58:11)

Offline

#25 2018-04-05 21:00:09

-karlos-
Member
Registered: 2016-05-29
Posts: 48

Re: 3D Model Repository

In OSMgo, the values of the parameter "origin" of 3dmr.eu are used now, to shift the zero/rotation point of the model. Meaning: [right,near,elevate]. smile  Mind: If you edit them, they toggle the sign! I think, it's a error hmm

To test the values of "origin", 3D models now can be moved (shift & arrow keys), elevated and rotated (no shift) if selected. cool Just click on it (only in control mode "View", key X to select it).

It's not final. We have to define a lot of things - later.

Moved flying 3D model Tardis


-karlos-

Offline

Board footer

Powered by FluxBB