Jump to content
Sign in to follow this  
ShezA

Question...no.2

Recommended Posts

Guest JR Morgan

Hi Shez..Hey man, you're livin' right. It just dawned on me that I had one of your PR bitmaps (dca8a.bmp) in my download tank from placing one of your DCA jetway objects in SGX.The picture below shows that PR texture bmp on an airport area with all the autogen living happily on the ground polygon textured with your dca8a.bmp (A DXT3 bmp).Obviously, my test is merely a conglomerate of your total bmp --- but it works great making the polygon using AFW/188. I set the LayerCall in AFW at layer 8.So forget about what I said about emailing me any files -- since I already had one of your PR textures to work with I could go ahead and do it.J.Rhttp://forums.avsim.net/user_files/78847.jpg

Share this post


Link to post
Share on other sites

Thanks JR. This is very promising!Let me try this technique.CheersShez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites

Hi J.R,Actually my coding is done within the SCA file because of an anomaly in AFW polygon generator which does not display the bitmap properly on the polygon. If you notice your pic the PR bitmap is "jumbled up" i.e. the bitmap has been cut into four pieces and juggled like a maze. That is why my code is different. When I place your lines in my code the bitmap disappears. I think I am placing the code incorrectly.Here is a code of a ground polygon made in AFW166. It is different from my usual method but it is easier to work with.; polygon 1Area( b 33:40.83131 -117:51.71231 30 ) LayerCall( :Taglayer 8 ) Jump( : ):Taglayer RefPoint( 7 :TagPoly 5 33:40.83131 -117:51.71231 V1= 40000 V2= 1416 ) Bitmap( Image1.bmp 0 0 0 0 ) Smoothing( 1 ) Points( 1 -00100 0 00100 ; 001 00100 0 00100 ; 002 00100 0 -00100 ; 003 -00100 0 -00100 ; 004 ) StartSurface MoveToPt( 1 ) DrawToPt( 2 3 4 ) EndSurface Smoothing( 0 ):TagPoly ReturnEndAWhere would your code go in this?Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest JR Morgan

Hi Shez..Re: >"Actually my coding is done within the SCA file because of ananomaly in AFW polygon generator which does not display thebitmap properly on the polygon."<*I guess I don't understand the anamoly you mention. The portion of a bitmapdisplayed on a ground polygon in SCASM (AFW) is STRICTLY controlled by the "Points"definitions and the relative size (or resolution in AFW's polygon creator routine)of the polygon in the code. are you seeing the bitmaps being flipped vertically byAFW? If so, you could vertically flip the bitmap and re-save it for testing?*Re: >"If you notice your pic the PR bitmap is "jumbled up" i.e. the bitmap has beencut into four pieces and juggled like a maze. That is why my code is different. WhenI place your lines in my code the bitmap disappears. I think I am placing the codeincorrectly."<*Yes, I mentioned that the example I made was a "conglomerate" of your bitmap. I think thereason for that is that the polygon's resolution was set to 1 instead of 5 as in your macro below. I didn't know what your "Points Definitions" and the "relataivesize" of your polygon is. That exercise was merely to test whether or not autogen could be retained using a PR textured bitmap -- and obviously, it can.*Re: >"Here is a code of a ground polygon made in AFW166. It is different from my usualmethod but it is easier to work with."<* As regards placement of 'autogen friendly' ground polygons, I'm not sure whether or not'AFW166' does all the things regarding this that the latest (AFW 3.0/build 188) does. Iused the latest build in this test. Regardless of that, it's the coding that controlswhat's happening, whether compiled manually or within a GUI like AFW..As requested, I've inserted the code in your macro, as shown below and also, below that,the macro made by AFW/188 used for testing and as resulted in the previous picture showingall the autogen present. Notice that the only real difference is the "Scale or Resolution"setting in the RefPoint line of code. Yours is "5" and the test poly was "1", meaningthat in bitmap resolution, all distances (points-wise) would be in meters: ; polygon 1Area( b 33:40.83131 -117:51.71231 30 ) LayerCall( :Taglayer 8 ) Jump( : ):Taglayer RefPoint( 7 :TagPoly 5 33:40.83131 -117:51.71231 V1=40000 V2= 1416 ) Bitmap( Image1.bmp 0 0 0 0 ) Smoothing( 1 ) Points( 1 -00100 0 00100 ; 001 00100 0 00100 ; 002 00100 0 -00100 ; 003 -00100 0 -00100 ; 004 ) StartSurface MoveToPt( 1 ) DrawToPt( 2 3 4 ) EndSurface Smoothing( 0 ):TagPoly;===========================; Inserted Dummy Call and Surface Type Here RotatedCall( :B2 0 0 0 ) Return:B2 SurfaceType( 1 41 41 0 ); (For dirt or grass) ReturnEndA;============================;======== The AFW/188 tested macro =============================================Area( b 38:59.56291 -089:9.9118 30 ) LayerCall( :Taglayer 8 ) Jump( : ):Taglayer RefPoint( 7 :TagPoly 1 38:59.56291 -089:9.9118 V1= 40000 V2= 463 ) Bitmap( dca8a.bmp 0 0 0 0 ) Smoothing( 1 ) Points( 1 -00089 0 00213 ; 001 00084 0 00213 ; 002 00089 0 -00214 ; 003 -00083 0 -00213 ; 004 ) StartSurface MoveToPt( 1 ) DrawToPt( 2 3 4 ) EndSurface Smoothing( 0 ):TagPoly RotatedCall( :B2 0 0 0 ) Return:B2 SurfaceType( 1 41 41 0 ) ReturnEndAAgain, I don't know why your bitmap would not display because it works normally when tested here using your dca8a.bmp. Is the "Image1.bmp" used in your example an equivalent to dca8a.bmp PR bitmap? I think you're close to getting what you want here and I also think AFW could be used to easily place and scale those ground polys while retaining all the autogen. Also, I think you can use floating point values in scaling them.J.R.

Share this post


Link to post
Share on other sites

J.R.Success! It works if I just leave the PR tiles in. Now the question is why when I place the scenery in does it not work. I remember there was a discussion post on how ground polygons made by AFW and especially roads tended to wipe out agen in a wide area. Maybe this is the issue?Anyway this is certainly a big help!ThanksShez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest JR Morgan

Shez..Re: >"Success! It works if I just leave the PR tiles in. Now the question is why when I place the scenery in does it not work.<"Oops, now I'm really confused -- when you say "it works" I'm 'guessing' you mean that after pasting-in the dummy RotatedCall and SurfaceType code into your macro, and compiling the macro, that then, the autogen appears on your PR textured 'tiles' (actually ground polygons)? Then you're saying that when you place the 'scenery in' it does not work? What method did you use to "place the scenery in"? -- Or, how did you determine that 'it works' if you had not yet placed the scenery into an active FS9 scenery folder and viewed it in the sim? If you could give more of a step by step description of the methods you used, then we could probably easily get things working the way you want.Re: >"I remember there was a discussion post on how ground polygons made by AFW and especially roads tended to wipe out agen in a wide area. Maybe this is the issue?"<Unless you're using and older version of AFW, this is not the issue. Recent versions of AFW allows the user to choose whether or not he wishes to implement the dummy calls into Polygons by providing an "Autogen Code" checkbox in it's 'Create Polygon' routine.For AFW roads, the user would need to manually edit the code for roads, applying the dummy call to the road system, else: yes, the AFW roads would be an autogen killer.J.R

Share this post


Link to post
Share on other sites

>Shez..>>Re: >"Success! It works if I just leave the PR tiles in.>Now the question is why when I place the scenery in does it>not work.<">>Oops, now I'm really confused -- when you say "it works" I'm>'guessing' you mean that after pasting-in the dummy>RotatedCall and SurfaceType code into your macro, and>compiling the macro, that then, the autogen appears on>your PR textured 'tiles' (actually ground polygons)? Then>you're saying that when you place the 'scenery in' it does not>work? What method did you use to "place the scenery in"? -->Or, how did you determine that 'it works' if you had not yet>placed the scenery into an active FS9 scenery folder and>viewed it in the sim? If you could give more of a step by>step description of the methods you used, then we could>probably easily get things working the way you want.My ground tiles are in a separate bgl.>Re: >"I remember there was a discussion post on how ground>polygons made by AFW and especially roads tended to wipe out>agen in a wide area. Maybe this is the issue?"<>>Unless you're using and older version of AFW, this is not the>issue. Recent versions of AFW allows the user to choose>whether or not he wishes to implement the dummy calls into>Polygons by providing an "Autogen Code" checkbox in it's>'Create Polygon' routine.>I am using 166 but can try out 188. Let me check this.>For AFW roads, the user would need to manually edit the code>for roads, applying the dummy call to the road system, else:>yes, the AFW roads would be an autogen killer.Roger on this. I guess I have not been following AFW development closely and missed this checkbox.>J.RShez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest JR Morgan

Shez..Re: >"My ground tiles are in a separate bgl."<I think that should not be a problem as long as you have and can edit the SCASM source code that made the seperate bgl for your PR polygons, because that's the code that needs editing to apply the dummy call and SurfaceType. If you should do it that way, then you probably would not want to use the AFW created polygons although I think they could be made to work for you.With both bgls in the active scenery folder there may be a layering problem because AFW hard codes ground polygons at layer 8 and the 'seperate bgl' (without the added Dummy Call) may be set to a layer call that overrides layer 8.J.R

Share this post


Link to post
Share on other sites

Actually the success was for the PR tiles bgl so no worries there. I need to work out the polygons placed in my main scenery bgl which brings in AFW generated ramp polygons on top of the PR tiles. These will need the checkbox treatment from AFW188.;-) Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

Share this post


Link to post
Share on other sites
Guest JR Morgan

Hi Shez..Hey, that's good news. Now I understand the situation. I'm glad you can now retain all the default agn objects on your PR textured ground polys; and could add other bldgs of your choice by TransformCalling them.I think you'd do well in upgrading AFW to the latest build and using the ltest SCASM release. 'Lots of new capabilities in it, some of which are:- Opening multiple projects at the same time for the purpose of copying/pasting objects between projects.- Improved background map usage (now handled same as any other object and able to quickly toggle it on or off with 1 click).- Buffered for FP calculations. And of course, the "Autogen Checkbox" (presently limited to polygons only) which inserts the dummy calls into your code, if checked.J.R

Share this post


Link to post
Share on other sites

Thanks J.R. and success again with AFW188! Thanks for all the assistance. Unfortunately I don't get the time to do much tinkering around these days but with the wife and kids away on holidays to the in-laws I have some time to catch up with stuff.I did use AFW188 previously but went back to 166 when I found that working with a background map was causing a proble. Specifically, if I wanted to zoom in to amend polygon points etc. the map used to default back to point 0,0 on the grid. Not sure if anyone has found this problem but it was a pain.BTW having looked at AFW188 should we not all marvel at its sheer breadth of capability and proficiency in doing scenery design!FANTASTIC JOB! to Tim and his team! a great example of freeware design development over many years! :-beerchug Shez


Shez Ansari

Windows 11; CPU: Intel Core i7-8700K; GPU: EVGA GEFORCE GTX 1080Ti 11GB; MB: Gigabyte Z370 AORUS Gaming 5; RAM: 16GB; HD: Samsung 960 Pro 512GB SSD, Samsung 850 Pro 256GB SSD; Display: ASUS 4K 28", Asus UHD 26"

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  

  • Tom Allensworth,
    Founder of AVSIM Online


  • Flight Simulation's Premier Resource!

    AVSIM is a free service to the flight simulation community. AVSIM is staffed completely by volunteers and all funds donated to AVSIM go directly back to supporting the community. Your donation here helps to pay our bandwidth costs, emergency funding, and other general costs that crop up from time to time. Thank you for your support!

    Click here for more information and to see all donations year to date.
×
×
  • Create New...