Dataset containing countries ISO codes and images of their borders - dataset

Looking for a dataset which would contain all countries with images of their borders without any text data on it.
This is closest to what I want https://www.geoboundaries.org/index.html#tabs1-css
Problem is that these images contain frame and text around country borders:
This could be cut if it always had same dimensions but unfortunately these images differ a lot. Where do I find this kind of dataset?

All credit goes to #Mike, who has commented my original question.
After little tweaks this gets the job done:
https://codesandbox.io/s/vector-layer-forked-bx2pi1?file=/main.js

Related

How can I display fewer labels on the X-axis when it is an instance of CategoryAxis? (JFreeChart library)

I have a CategoryAxis used with a BarChart where I have too many labels to be readable.
I would like to set a visible interval for the labels, so let's say each ten values the label is printed.
I read some posts where setTickUnit() method is recommended, but such method doesn't exist in CategoryAxis.
Here you can see a sample of what I am referring to, as you see I have tens of dates so you can't read them:
Any pointer or recommendation?
Thanks!
You can find a pretty good explanation of the problem (and some solutions) in the FAQ section of the JFreeChart homepage.
You might be better of with an XYPlot and an XYBarRenderer.

How to change Construct 2 coloring pictures

I have to change pictures in a Construct 2 coloring game and i don't know how get it.
There are a some .png file that contain the old pictures:
This pictures are loaded and generated i don't know how by the data.js file that cut and put in each hole
Anybody could help me ? I'm very lost with this.
There is a solution to this problem.
https://www.construct.net/en/forum/construct-2/how-do-i-18/create-coloring-game-134338
And if you're too lazy to look at it, here it is.
*One way would be to prepare all the colorizable elements of your illustration -- the regions within the black lines -- as separate white sprites (PNGs), with the ReplaceColor effect applied. Then when the user clicks in a "color palette" sprite, store the clicked color value as a global value, and assign this to the ReplaceColor effect of any clicked illustration sprite.
Depending on the complexity of your illustration, it could be a fair amount of work to position all the illustration sprites in the appropriate positions in the layout, but it should work.
There may be other options that treat the problem more like paint fills, but I'm not aware of how to do this.* -netdzynr

Initialize JFreeChart range axis values

I am trying to load dataset during initialization of the JFreeChart. But every time I tried to create a dataset with higher "number of item per series", the more data (all data) displayed visible in the chart (the bigger the dataset, the smaller the graph). But actually what I wanted is to have the fixed range of dataset values displayed on the chart while the rest is still hidden. Just the same way the data would normally be displayed in the actual trading platform, let's say Metatrader (MT4). First time when I open the chart I can see the screen filled with the only visible dataset of the chart and if I left-scroll the chart I will be able to see the old/history dataset as well. Does anyone have idea how to achieve this using JFreechart?
Really appreciate for any help or any thing/articles I can refer. Thanks so much!
You can use setRange() on either the domain or range axis, as shown in this fragment. If you've already tried this, it may help to edit your question to include an sscce and/or image that exhibits any problems you encountered.

Displaying a user-customized part on a web site

I'm building a web site (asp.net) for a company that manufactures small customizable anodized aluminum products. Products are a variety of shapes. but mostly flat, domed or ring-shaped. Products can be colored in one of about 15 colors.
The user can specify one or more lines of text and a font, a simple line drawing (e.g., a heart or four-leafed clover), or both. Text is limited to about 5-15 characters per line. The text or drawing is milled into the part and can be colored in a contrasting color.
What I want to do is display the customized product to the user, so that after selecting product, colors, text,, font and artwork the site will display an image of how the finished product will look. Ideally they would be able to rotate the image but that's not critical.
I have digital descriptions (CAD and CNC milling instructions) of all the parts, fonts, and artwork and can translate them into whatever format is needed.
Can this be done with Flash, SilverLight, or some similar technology? Ideas, references, suggestions, and tutorials welcome! Thanks
It can be done in Flash, but it requires a lot of work:
To get a realistic version of the product displayed, you have to produce pictures, videos and whatever other depictions of all possible shapes and colors of your product, then you simply have to switch between those depending on the user's choice.
Adding the writing is a bit trickier when the surface isn't flat, but you can model a dome or ring-shaped surface with 3D polygons and add the text as an image texture.
It is best to have a set of standard views, maybe 4 or 5 angles, so that you only have to figure each position out once for each similar shape, and afterwards you can just copy the positioning etc.

How can I implement a color search for an image gallery?

I'm working on a simple image gallery project and I'd like to implement the ability to search based on a color hex code. So if someone enters 'ff1212' into the search, it will display only those images that contain that particular shade of red. I've seen a website that has a search that works the way I want: http://cssline.com (the AJAX part is nice, but its the server-side stuff I'm after).
I can't figure out how to store the color data from each image. Should I get each unique hex code used in an image and store them as tags in a database? It seems like this would create a huge dataset which would slow down the search. What about storing the images themselves in the database and scanning their colors during the search? That also sounds like it would be slow. I know that once I figure out how to store the data for speedy searching I can figure out how to code the search itself.
Does anybody have any tips or advice that can help me?
First of all, bring the number of colors in the images down to an amount that is workable (max 16 or so).
Then, to be able to compare different images, i think it's a good idea to store only websafe values (the intervals #erelander was talking about) to normalize the results.
You may try storing color intervals of each image in a database rather than storing each unique color value. Of course, searching these intervals may require a different search algorithm.
I dont think that storing color values in database will make it slow. It will, although, make it insanely large! And given that you can index data on color values, the process will be fast.

Resources