Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I have 3 layers of vectors (shapefiles) that I've loaded into Tilemill. However, nothing is visible in Tilemill. What am I doing wrong, and what should I do to get my map to show up?

This is part of a web app to show the shop floor of a factory. I've built 3 layers in Inkscape, and used QGIS to get it into the shapefile format. I initially had some errors getting Tilemill to load the files, but that now seems to be resolved.

You can see the problem here:

Tilemill with 2 layers loaded

I've looked at all zoom levels, and there's nothing there. When I view a layer's features, though, it seems that there's data:

Tilemill with layer's features menu visible

Thanks!

share|improve this question
add comment

2 Answers 2

up vote 5 down vote accepted

When you add a layer to a TileMill project, you need to also create a style definition for that layer. If there is no style definition, nothing will show up. When creating a new layer, you can click the 'Save & Style' button to have TileMill insert some default styling code for you.

Based on your first screenshot (in which I see two line shapefiles) you could add something like this to the code window to style those two layers:

#aisles {
  line-color: blue;
}

#extwalls {
  line-color: red;
}

Save that to your project and things should show up. (You can then click on one of the magnifying glass icons in the layers list to automatically zoom the map to the right spot for that layer.)

Have a look at this introduction to working with CartoCSS in TileMill, as well as the full CartoCSS reference.

share|improve this answer
    
Thanks! That did the trick. Thanks for the links, also. –  ahuth Oct 2 '12 at 20:09
add comment

Probably a coordinate system problem.
You have a few options but will require some GIS knowledge.
You need a software sytem that will alow you to assign/project/re-project the autocad data you are using.
That could be OSGEO4W, QGIS, GDAL/OGR, autocad map3d, arcmap, or many many other options (those are my most familiar resources).
You should decide on a local system for your coordinates (the smaller the area the better) and re-project (this means you need to know what system teh coordinates are in initially) or you may have to rubbersheet the data to a known coordinate system.
I hope some of the key words here help you find other solutions within this site or others. feel free to edit your question with more details.

share|improve this answer
    
Thanks for the response! I've accepted ajashton's answer below, because it solved the immediate problem of the layers not being visible. However, doing this revealed some other problems: my layers are only halfway on the map, and the proportions are distorted. I think that your answer will solve these new problems, so I'll definitely look into what you've said. Thanks for your help! –  ahuth Oct 2 '12 at 20:11
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.