Sign in to follow this  
Guest cwright

AutoAsm and Coastline Import?

Recommended Posts

Hello,I thought I'd have a go at using AutoAsm to import coastline information from http://www.ngdc.noaa.gov/mgg/shorelines/shorelines.htmlI downloaded the dat file and copied it to the AutoAsm main directory. I then wen to the Editor panel and loaded it up there. However, the screen main screen doesn't show anything. I guess I must either be doing something wrong or I need to do more steps. I'm not sure which though.

Share this post


Link to post
Share on other sites
Help AVSIM continue to serve you!
Please donate today!

Thanks Horst.I'm ok up until step "e". Should I be seeing my coastline in the main screen when I get to this point? All I see is a blank square. The dat file loads ok in the earlier version of AutoAsm but that one doesn't give you a bitmap.I just tried again and it worked.

Share this post


Link to post
Share on other sites

Hello Victor,No, on Step e) you will not see the data.Set Bounds is only used, to get the information from the data you use, to get the correct settings (Centre Position, Size Degrees) for the main panel.You will not struggle to get the correct settings out of N,S,E,W (the bounds for your dataset).AutoAsm should give you the correct position for your bitmap from the imported data, when you use Read Data.Horst

Share this post


Link to post
Share on other sites

Hello Horst. I get a run time error when trying to save the bitmap in the editor panel.

Share this post


Link to post
Share on other sites

Hello Victor,after step i) or l)? (memory setting?)and which runtime error?Maybe you can give us a screenshot?Horst

Share this post


Link to post
Share on other sites

>Hello Victor,>after step i) or l)? (memory setting?)>and which runtime error?>Maybe you can give us a screenshot?>Horst>When I try step i). I think it was a "subscript out of range" error. I'll try again and check. I'll also try to get a screenshot.

Share this post


Link to post
Share on other sites

Well strangley I can't load in the coastline image until I have a blank project name box. It then loads in one of my other bitmaps.I can then load in my coastline file!!When I attempt to load in the dat file from a completely clean (ie no other projects or bitmaps included) it errors "File not found"

Share this post


Link to post
Share on other sites

Thanks Horst.Afraid I'm still a bit confused! When I try to get past step g) When I click LOAD, I get a message saying "Loading Data" for about 3 seconds and then I get blank main screen. I've looked at the dat file using WordPad and it does contain data.I'm using a completely clear AutoAsm file with no other projects or bitmaps loaded. I presume my previous attempt loaded via another project and that was maybe why I got an error??

Share this post


Link to post
Share on other sites

Hallo Victor,Sorry for confusing!When Chris will see the thread, I am sure, he will give you a better English explanation, and maybe correct my steps.Maybe Set Bounds is not working yet for these kind of data?Do you have the bounds for the data?Then leave out step e) and f) and try to set you up Centre Position and Size(Degrees) yourself instead.The zoom tool is also a little bit tricky :)HorstPS: Maybe read step :( again.

Share this post


Link to post
Share on other sites

Hi Horst.No you aren't confusing me. I'm probably confusing myself!:D Perhaps I should try another sort of data file to see if that works.Using Set Bounds does work and I see the coordinates in the right boxes.Should I be inputting anything to the Main screen? Project Name or Output File?

Share this post


Link to post
Share on other sites

Very important:The name of the bitmap you make, is the name of your project !!(Otherwise AutAsm will not find the right bitmap)Horst

Share this post


Link to post
Share on other sites

Hi Victor, first, thanks to Horst - his info and suggestions are excellent! It appears that the import process works correctly and you can see the bitmap display in the editor window (as in your screenshot). But you get the run-time error when you click SAVE to save the bitmap. It's certainly worth trying some different and smaller bitmap sizes. Also check that you have the file blank.bmp in the bitmaps sub-directory. This is essential for the import process. I've looked at the code and I can't see how this could happen. The error is almost certainly caused by an incorrectly dimensioned array. Two arrays are involved in the SAVE process and they should both be correctly dimensioned - I assume you attempt to save the bitmap immediately after doing the import. As Horst says, there could be a problem if you choose a very large bitmap size and you run out of memory. I've tested it at 10,000*10,000 (512 Mb memory). At this point in the process other settings on the Main panel probably don't matter apart from WORKING DIRECTORY. When you click on SAVE it will simply save the bitmap into the bitmaps sub-directory, so it doesn't need any other project settings. But even if you still can't save the bitmap it would be a good idea to create the project: just enter the bitmap name you're trying to save into PROJECT NAME (but without the .bmp extension) and click on SETTINGS/SAVE. Having a specific project means you will always have the same settings unless you explicitly change them. If you could email the files to me I'd be happy to take a look. I would need three files: the original import .dat file, plus the project .ini and .dat files (in the settings sub-directory). Best regards, Chris

Share this post


Link to post
Share on other sites

Hi Victor, thanks for sending the files - it makes trouble-shooting so much easier! There was only one obvious problem - the bitmap size was set to 3202*3214. The size needs to be multiples of 4, so I changed the size to 3204*3216. This would not stop you from saving the bitmap, but you would get an error message when you came to load it in again. Apart from that it worked fine. I was able to create the scenery without any problems (I did note that there was no name for SAVE in the editor - I assume you did enter a name when trying to save the bitmap).The polygons were not defined as water polygons. They were default roads. Note that if no polygons are defined as water then the SEARCH function will not find any errors - it's only interested in water polygons! When you come to read in the bitmap to make scenery, be sure that ISLANDS, AUTO FILL and AUTO CULL are enabled (I'm thinking of removing these options as really they should always be enabled). After importing, you'll need to do the BITMAP EDGES function (set PIXEL 0,0 to water). That's because all the polygons are islands. The function will add an outer water polygon. If you don't do this AutoAsm will decide that all the polygons are lakes! Then do REPAIR BITMAP and finally SEARCH to remove any residual errors. The milestone here is to get the green banner. Then save the bitmap and you're ready to make the scenery. Well, not quite! When you read in the bitmap to make scenery you'll note that all the polygons are red. That's because they're islands. Click on an island and then apply appropriate settings in the LINE TYPES panel. A tip: when creating a new project, it's useful to load in an existing project which you can then use as a template. Change any settings specific to the new project (particularly the project name!) and save. It'll then automatically have suitable settings for islands etc You'll get much better results if you apply a bit of smoothing and random to the line setting e.g. smooth = 2 and random = 30. This is particularly important here as the input data is relatively low resolution (compared, say, to USGS) though it's still much higher resolution than the default. I'll email back the dat and ini files with my changes. If there's still a problem, let me know. Try to be as specific as you can e.g. which button did you click etc? When you make the scenery, first check it's okay in LWMViewer - this is useful, as it does not depend on any default scenery. When you load it into FS you'll see you need some additional landclass to fill in the gaps. Good luck.... Best regards, Chris

Share this post


Link to post
Share on other sites

I still seem to be having problems so I'll go through my procedure to make sure I'm doing it right - or wrong as the case may be!!1. I copy the revised files to my AutoAsm Settings folder2, I open up AutoAsm and click the TOOLs box3. I then enter 3204 and 3216 into the O/P Bitmap X and Y Boxes4. I then select my dat file by clicking the selection box in the next to FILE NAME5. I then click LOAD ALL and SET BOUNDS. After the bounds are set I click SET MAIN.6. After that I click LOAD. "Loading Data" appears in the major screen. After that has finished (a few seconds) I see a blank major screen apart from a large greenish square. A message appears "Data Loaded"7. I create a blank bitmap size 3204 X 3216 256 colours and save this to the Bitmap folder.8. I then follow the above procedure and when I get to step 6 I then go the Main Panel and click READ DATA. "Reading Bitmap Lines 500,1000 etc" appears followed by the message "No Polygons Found"9. I then go back to the Tools Panel and click LOAD again. The islands now appear on the screen. 10. I adjust the line properties as required using the Line Types panel.11. In order to obtain a bitmap prior to editing I go to the Editor panel and enter my bitmap name "jersey" in the OUTPUT box. 12. I click SAVE. After a few seconds the error message "Run Time Error (9). Subscript Out of Range" AppearsI hope I'm not going to end up looking too stupid!!

Share this post


Link to post
Share on other sites

Hi Victor, I think I have the answer! I mentioned the file blank.bmp earlier - I'm fairly confident you don't have it installed. You'll find it in one of the update zips. blank.bmp should be placed in the bitmaps directory. AutoAsm uses it as a template and in particular it uses the palette from that file. Earlier, I didn't think that was the problem because the program gives a clear error message if blank.bmp is not found. However - I just realised that I added that check later, and so it probably isn't in the version you have. This explains rather neatly why steps 7 etc seemed to fix it. That's because loading another bitmap would generate the necessary palette data. If this theory is correct ( and I'm confident!) then, when you imported the file, the lines were in fact present - but the palette for that colour was zero, so the lines didn't show. Also, during read-in to create scenery, any lines with grey or black colours (R,G and B components all equal) are ignored. As I said, you should find blank.bmp in one of the update zips - I'm assuming you downloaded all three zips. Just in case, I'll email you blank.bmp plus the latest program version that has the blank.bmp check. Just pop blank.bmp into the bitmaps directory and hopefully you'll find it all works! Best regards, Chris

Share this post


Link to post
Share on other sites

Aahaa!!!That's it. I did have a blank.bmp in my bitmaps folder but it wwas 0kb. The new one you sent was 11kb. Many thanks for all the help you've given me.

Share this post


Link to post
Share on other sites

Hi Victor, glad to hear it! Any more questions, don't hesitate to ask.... Best regards, Chris

Share this post


Link to post
Share on other sites

Hello Victor,First:I am glad and happy, that you can import the data.It is very important to understand the import process!You have now a lot of possibilities, to use data wit AutoAsm.(my post here: http://forums.avsim.net/dcboard.php?az=sho...2109&mode=full)Try always to find some data out in the NET and translators for the data to come to the formats AutoAsm can read (bln and mp) (You will never find the ultimate link for world data - scientist will be happy

Share this post


Link to post
Share on other sites

Horst, how can you say the detail looks the same?! The 250,000 is more detailed than the default. Ok it may not be as fine a detail as may be available for free for the US coasts but still, it is more detailed than the default.Here are three more shots from the same area. The default coastline is the yellow line. http://forums.avsim.net/user_files/89672.jpghttp://forums.avsim.net/user_files/89673.jpghttp://forums.avsim.net/user_files/89674.jpg

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this