I am following this tutorial: https://somethingaboutmaps.wordpress.com/blender-relief-tutorial-final-adjustments/
I am attempting to download DEM data which is supposed to come in the form of a TIFF.
Here it is: https://viewer.nationalmap.gov/basic/#productSearch
I can download such TIFF from the tutorial that the website recommends. However, when I download them they show up all white. They're just totally blank. I have tried on Mac and PC, as well as opening them in Photoshop.
I am trying to get these grayscale images like the thumbnails shown, but I can't! Another download option gives me a whole zip folder full of files. Can anybody help?
Here's what I did: install the open source program QGIS. Once installed, start a new project. Click the "data source manager" button and choose raster option. Navigate to your file and click "add" button. The image should appear in black and white.
Now right click on the layer name in the lower left box (should be USGSxxxx) and choose export. In this box change two things: change output mode from "raw data" to "rendered image" and specify a new file name. At bottom of box hit ok. You should now have a separate file with issue corrected.
TL;DR: it's a GIS quirk.
DEM data is could be floating point, you would need to change the render type to singleband pseudo color and use the color ramps to color the image based on the heights in the DEM
Related
So for example let's say I have a game running, I want to grab the image output of the game and display it onto another window I have, so I would have two identical looking windows, one with the game itself, and one with the output of it. I want this to be done with LUA.
You can try wxwidgets library (with wxlua wrapper), as it provides access to the screen device context to read its pixels. See for example this takeScreenshot function that saves a section of the display into a PNG file.
In a project we use GIMP to create banners (which are saved in the GIMP native format). All the work is done by humans. But it is often tedious work which consists of replacing one logo with an other logo with the same dimensions or one piece of text with an other piece of text. Sometimes many 100 times.
What is the best way to automatically replace an image (with the same dimensions) or a text in a GIMP file? Does it make more sense to script it within GIMP or is it better to do open heard surgery on the file itself without GIMP? Or is there a command line tool which I can use for this?
I am making the invoice part of an application, and at this moment I am done with the invoice generation (adding products and stuff).
The next step is to have a report displaying the invoice data, ready to print.
That works too. I used Fortes Reports because it is free, easy to work with, and has a free PDF export filter, and a Preview component, so it has everything I need.
Now, my problem is that I must allow my users to Annull an invoice. So when an invoice was emitted, if there was a problem with it, I cannot just delete it later, I must Annull it (I'm not sure that is how you call it - maybe make it void), but basically the invoice stays the same (in printed form) EXCEPT we must write/draw diagonally on top of the entire invoice one word: ANNULLED with RED color.
That means I will make a new report for this case (annulled invoices) and use this one whenever the user wants to print an annulled invoice
So now in Fortes Report there is an RLAngleLabel component that allows me (in theory) to do just that: draw/write the word ANNULLED on the report. But my problem is that I add the label just fine in the btDetail RLBand, only I just can't see it in Preview, and I have no idea what I am doing wrong. If it's not visible in designtime preview, I assume it wont be visible in runtime neither.
Should I place it in a specific way? Should I add it at runtime somehow? I cant seem to be able to access the report's Canvas so I could draw it in some event...
Does anyone have any experience with what I am describing?
In order to reproduce my problem, just add a RLReport control on your form, add bands to it (Titleband, ColumnHeaderBand, DetailBand), and on a detailBand (DetailGridBand)place an AngleLabel, then right click on the report and choose Preview...
If I place the AngleLabel on the TitleBand or on ColumnHeaderBand, then it shows in preview, except that I need to place this Angled label ON TOP of the contents of the invoice, not on the header info.
In the past I used a BMP image as big as the invoice (in order to have it transparent so I would see the contents beneath it), but that made my exported PDF report 5MB in size, and that is a little too much (PNG was not working correctly - I think it would not display it transparent or something like that, so I was stuck to using BMP).
Is there any way of achieving what I want (described above)?
For whoever encounters this dilema, I reached the conclusion that I should still go with displaying an image containing the desired text as background and setting the bands to Transparent.
The angleLabel approach seems to be unknown, so I dropped it.
I use this time a PNG file that is about 30-40 KB in size and that does not bother me to have it added to the size of the final PDF.
A lot better than the previous BMP image I used before (that increased the size of the PDF file with about 5 MB).
The neweest version of RLReports works with PNG images. That saved me
Also if you have any RLDraw objects on your report, you must set it's brush style to bsClear, so it would allow the background to be visible.
this question might be an "Open Question" and many of you might be eager to close it, but please don't. Let me explain.
As we all know, JPEG has two kinds of compression (at least in Photoshop save dialog)
optimized, where image was loaded kinda like line-by-line
progressive, where image was loaded first mosaic-like, the progressively better till the original resolution
I have read a lot of PNG/JPEG optimization articles before, but now I encountered this awesome third kind compression, from a wild random Google Image search. The JPEG in question is this
http://storage.googleapis.com/marc-pres/boston-event-1012/images/google-data-center.jpg
Try load the link in Chrome/Firefox (in IE/Safari only until the image was fully loaded then displayed)
you can observe:
image were loaded first in black & white
then looks like the Red channel loaded
next the Green channel loaded
last the Blue channel loaded
I tried loading it again with a emulated very slow connection, and observed that the JPEG is not only loads by channel order, but in progressive way as well. So first loaded image is blank-and-white mosaic then green-ish mosaic then gradually full color mosaic and finally full resolution and full color image.
This is amazing technology, suppose you are building an e-magazine, where each page has a lot of pictures, you want the user to fast flip browsing through pages, and this kind of image is exactly what works best. For fast preview, load blank-n-white thumbnail, if the user stays, fully load the original image.
So my question is: How could I generate such image using Python Pillow or ImageMagick, or any kind of open source software?
If you think this question is inappropriate please comment, don't just close it.
Update 1:
It turns out Google used this technology in all of its JPEG pictures 1, 2 e.g. this
Update 2: I found another clue
The image data in a JPEG file can be sliced up in many different ways, and the slices (or "scans" as they're usually called) can be stored in the file in many different orders.
In most JPEG files, the first scan in the file contains all of the image's color components, interleaved together if it is a color image. In a non-progressive JPEG, the file will contain just that one scan. In a progressive JPEG, other scans will follow, each of which may contain one component or multiple components.
But there's nothing that requires it to be done that way. If the first scan in the file does not contain all the color components, we might call such a file "non-interleaved".
Your examples files are non-interleaved, and they are also progressive. Progressive non-interleaved JPEGs seem to be more widely supported than non-progressive non-interleaved JPEGs.
The standard IJG libjpeg software is capable of creating non-interleaved files. Though it's not exactly easy, you can use its cjpeg utility, with the -scans option documented in the wizard.txt file.
I've been learning how to use Adobe Fireworks since I'd like to use some of the beneficial features such as better png compression compared with photoshop. In Photoshop on the layers palette it is straightforward to just turn off all the other layers in the open document by option clicking on the eye icon on the layer. However, this doesnt work in Fireworks. Is there a quick way of turning off all layers apart from the one the user is working on?
This isn't a great solution, but I can't seem to find any proper way to do this either, besides option clicking the eye and then clicking again to turn the chosen layer back on.
If you make a text file with this script and save it as "Hide Other Layers.jsf", you can drop it into your Fireworks Configuration / Commands folder. If it's in the right folder, it should show up in the Commands menu, and then you can add a keyboard shortcut to run it:
fw.getDocumentDOM().setLayerVisible(-1, -1, false, true);
fw.getDocumentDOM().setLayerVisible(-1, -1, true, false);
That will hide every layer, then reveal whichever layer you currently have selected.