Skip to content

Instantly share code, notes, and snippets.

@wboykinm
Last active December 11, 2015 17:58
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wboykinm/4638533 to your computer and use it in GitHub Desktop.
Save wboykinm/4638533 to your computer and use it in GitHub Desktop.
Country-specific masking in CartoCSS
Map {
/*background-color: #b8dee6;*/
}
#countries[ADMIN='Nicaragua'] {
polygon-fill:#abd69b;
line-color:#754098;
polygon-opacity:0;
line-width:6;
line-opacity:0.8;
line-comp-op:hard-light;
line-join:round;
}
#mask {
::mask {
polygon-fill:#d7cebf;
comp-op:dst-out;
image-filters:agg-stack-blur(100,100);
}
::shape {
line-color:#754098;
line-width:3;
line-offset:3;
line-join:round;
line-opacity:0.7;
line-comp-op:hard-light;
image-filters: agg-stack-blur(1,1);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment