• Which the release of FS2020 we see an explosition of activity on the forun and of course we are very happy to see this. But having all questions about FS2020 in one forum becomes a bit messy. So therefore we would like to ask you all to use the following guidelines when posting your questions:

    • Tag FS2020 specific questions with the MSFS2020 tag.
    • Questions about making 3D assets can be posted in the 3D asset design forum. Either post them in the subforum of the modelling tool you use or in the general forum if they are general.
    • Questions about aircraft design can be posted in the Aircraft design forum
    • Questions about airport design can be posted in the FS2020 airport design forum. Once airport development tools have been updated for FS2020 you can post tool speciifc questions in the subforums of those tools as well of course.
    • Questions about terrain design can be posted in the FS2020 terrain design forum.
    • Questions about SimConnect can be posted in the SimConnect forum.

    Any other question that is not specific to an aspect of development or tool can be posted in the General chat forum.

    By following these guidelines we make sure that the forums remain easy to read for everybody and also that the right people can find your post to answer it.

P3D v4 change the polygon elevation in the _CVX.bgl?

Messages
227
Country
maldives
Is it possible to change the polygon elevation in the CVX.bgl file(not having a project file .ad4)?
elev.jpg
 

Attachments

  • UGSB_ADEX_GVAF22_CVX.bgl
    1,003 bytes · Views: 185
Hello:

IIUC, this thread is on the same topic started with your prior thread here ? :scratchch



You can achieve your goal by using Patrick Germain's CvxExtractor to decompile a source CVX vector flatten BGL into ESRI *.SHP files. :idea:



You can import (Append) the ESRI *.SHP files into SBuilderX, edit assigned Altitudes of the vertex points, select all, and compile a new BGL.



GaryGB
 
Last edited:
IIUC, this thread is on the same topic started with your prior thread here ?
yes it is,at that time I did not know that the polygons and their characteristics were recorded in a file CVX.bgl, sorry...

You can achieve your goal by using Patrick Germain's CvxExtractor
I already tried to do this, but I can’t extract the vector data...
do you manage to do this with my file?
 
Did you run CvxExtractor with Windows Administrator permissions ? :scratchch


In CvxExtractor GUI
, configure:

Input BGL path \ file: UGSB_ADEX_GVAF22_CVX.bgl

Output folder path: (your choice of folder)

Output format: ESRI Shapes

[Extract] button


You should then output:

FLXUGSB_ADEX_GVAF22_CVX.shx
FLXUGSB_ADEX_GVAF22_CVX.shp (Flattens)
FLXUGSB_ADEX_GVAF22_CVX.dbf
FLXUGSB_ADEX_GVAF22_CVX.xm
EXXUGSB_ADEX_GVAF22_CVX.shx
EXXUGSB_ADEX_GVAF22_CVX.shp (Exclusion Polygons)
EXXUGSB_ADEX_GVAF22_CVX.dbf
EXXUGSB_ADEX_GVAF22_CVX.xml
RDXUGSB_ADEX_GVAF22_CVX.shx
RDXUGSB_ADEX_GVAF22_CVX.shp (Roads)
RDXUGSB_ADEX_GVAF22_CVX.dbf
RDXUGSB_ADEX_GVAF22_CVX.xml

https://www.prepar3d.com/SDKv4/sdk/world/terrain/terrain_overview.html#The Shp2Vec Tool

https://www.prepar3d.com/SDKv4/sdk/world/terrain/vector_shape_properties_guids.html



Append to SBuilderX: FLXUGSB_ADEX_GVAF22_CVX.shp:

SBuilderX Menu > File > Append > ESRI SHP ...


Configure "Appending Polygon Shape File":

Name or Label of Imported Polys > Get from this Field: GUID

GUID of Imported Polys > Get from this Field: GUID


Altitude and Color of Imported Polys:

Altitude (meters) > Get from these Fields > From Shape file

Color of Imported Polys > Color (click to change): Color on the left

Red: 255, Green: 255, Blue: 0 (Same Airport Boundary vector color as SDK TMFViewer and ADE)

Set Transparency: 64

[Continue] button


In SBuilderX work-space > Icon Toolbar > Pointer Mode

Select
: Each Poly vertices > Right-click > Properties > {General} Tab

Constant Altitude: (Meters value) > [Set] > [OK]

Select: Each Poly vertices > Right-click > Properties > {Vector polys} Tab > Type: 153 (AB_Flatten) > [OK]

Select: All Poly vertices > SBuilderX Menu > File > BGL Compile... > check: Terrain Vector > {Compile] button

Test new CVX vector BGL in FS.


Hope this helps a bit more. :)

GaryGB
 
Last edited:
Did you run CvxExtractor with Windows Administrator permissions ? :scratchch
Yes, thanks for such a detailed instruction, but I have a problem at the very beginning: coordinate values In CvxExtractor are highlighted in red...
What coordinate values, should be specified if the default values are not suitable?
exctr.jpg
 
You do not need to use that CvxExtractor feature to create a sub-set of the total data in UGSB_ADEX_GVAF22_CVX.BGL.

You can regard the parameter values shown above as already 'suitable', and ignore that feature for this task at this airport.

Leave all those parameter values unchanged and intact ...as shown in your screenshot above.


You will then be able to extract the total data set for the UGSB_ADEX_GVAF22_CVX.bgl.

FYI: Data sets extracted from FS CVX vector BGLs are rarely very large, and can be edited after Appended to SBuilderX.


SBuilderX 'Append' of FLXUGSB_ADEX_GVAF22_CVX.shp is shown below:

sbuilderx_flxugsb_adex_gvaf22_cvx_shp-jpg.54132


GaryGB
 

Attachments

  • SBuilderX_FLXUGSB_ADEX_GVAF22_CVX_shp.jpg
    SBuilderX_FLXUGSB_ADEX_GVAF22_CVX_shp.jpg
    65 KB · Views: 824
Last edited:
Yes, thanks for such a detailed instruction, but I have a problem at the very beginning: coordinate values In CvxExtractor are highlighted in red...
What coordinate values, should be specified if the default values are not suitable?
View attachment 54130
This problem of the values highlighted in red ... I think it's a bug ... replace the decimal point with a comma and then it works. Obviously the program reads the decimal separator settings and behaves accordingly.
Giovanni
 
https://www.fsdeveloper.com/forum/t...-elevation-in-the-_cvx-bgl.446626/post-835220

This problem of the values highlighted in red ... I think it's a bug ... replace the decimal point with a comma and then it works. Obviously the program reads the decimal separator settings and behaves accordingly.
Giovanni


Hello:

While I appreciate the good intentions of that suggestion, I must respectfully offer this clarification to the contrary. ;)


It is imperative when working with FS / P3D, FS SDK and/or any 3rd party utilities, as well as nearly all software developed / used in North America, to set Windows Decimal Separator character to a period ...NOT a comma. :pushpin:


FYI: Most Windows software uses North American English code sets and key scan values, so you must change your Windows Decimal Separator character from a comma to a period (aka "dot").

1.) In Windows Control Panel, click Region and Language applet (Region and Language dialog box opens)


2.) In the Region and Language dialog box, click {Formats} tab


3.) On {Formats} tab > click [Additional Settings] button (Customize Formats dialog box opens)


4.) In Customize Formats dialog box > {Numbers} tab > Decimal Symbol:

a.) Set the Decimal symbol to a period (.) instead of another character such as a comma (,)

b.) Click [OK] button

c.) Back on the Region and Language dialog box {Formats} tab, click [OK] button

d.) Exit Control Panel


5.) Restart Windows


Some links for self-study and self help:

https://www.google.com/search?q=sit...+Period&ie=UTF-8&oe=UTF-8&hl=en&client=safari


Hope this helps. :)

GaryGB
 
Last edited:
Did you run SBuilderX with Windows Administrator permissions ? :scratchch

This is required so you can write the intermediate FLX_PROJECT.SHP file used by SDK SHP2VEC to compile the CVX vector BGL file.


Is a FLX_PROJECT.SHP file already inside SBuilderX "\Shapes" sub-folder ?

[SBuilderX315 install path]\Tools\Shapes\FLX_PROJECT.SHP


If you do not run SBuilderX with Windows Administrator permission. that sub-folder may be 'locked' by Windows during BGL compilation. :pushpin:


GaryGB
 
Your FLX.SBP project shows only the larger Polygon is selected; attempting to compile this to BGL fails as cited above.


If you select all Polygons, SBuilderX compiles

Otherwise, if you delete the (2) smaller polygons, then select the large Polygon, SBuilderX compiles.

After "Appending' FLXUGSB_ADEX_GVAF22_CVX.shp, keep and use only Polygons you require (delete others).


GaryGB
 
If you select all Polygons, SBuilderX compiles
you're right, I had to hold down the alt key and select all the polygons ...

but nonetheless, something is wrong,I can not view the ready compilation file (cvx_PROJECT.BGL) in tmfviewer.exe...
tmf.jpg

Obviously, this file is too small size compared to FLX_PROJECT.shp 1kb vis 4kb?

I attached compilation files to study:
 

Attachments

  • Shapes.rar
    1.5 KB · Views: 170
https://www.fsdeveloper.com/forum/t...-elevation-in-the-_cvx-bgl.446626/post-835281

you're right, I had to hold down the alt key and select all the polygons ...

but nonetheless, something is wrong,I can not view the ready compilation file (cvx_PROJECT.BGL) in tmfviewer.exe...
View attachment 54163
Obviously, this file is too small size compared to FLX_PROJECT.shp 1kb vis 4kb?

I attached compilation files to study:


Did you run SBuilderX with Windows Administrator permissions ? :scratchch

This is required so you can write the intermediate FLX_PROJECT.SHP file used by SDK SHP2VEC to compile the CVX vector BGL file.


Is a FLX_PROJECT.SHP file already inside SBuilderX "\Shapes" sub-folder ?

[SBuilderX315 install path]\Tools\Shapes\FLX_PROJECT.SHP


If you do not run SBuilderX with Windows Administrator permission. that sub-folder may be 'locked' by Windows during BGL compilation. :pushpin:


GaryGB


If you ran SBuilderX with Windows Administrator permissions, when you compile a CVX, it should first delete files in:

[SBuilderX315 install path]\Tools\Shapes\

...so that it can then write a new set of source files into the now empty folder to be compiled to BGL via SDK SHP2VEC


Manually delete all files in:

[SBuilderX315 install path]\Tools\Shapes\

...then after editing Altitude attributes for the selected Polygons that were 'Appended', re-compile; that should work.


You may wish to turn off Windows User Access Control (aka "UAC") in Windows Control Panel.


Better yet, create a Windows Shortcut file for SBuilderX.exe and set Compatibility attributes to Run As Administrator.

GaryGB
 
Manually delete all files in:

[SBuilderX315 install path]\Tools\Shapes\
Yes, that's exactly what I did, files are overwritten with a new date but the size remains the same...

Better yet, create a Windows Shortcut file for SBuilderX.exe and set Compatibility attributes to Run As Administrator.
Yes, that’s exactly what I did at the very beginning.

By you, at compilation, what file cvx_PROJECT.BGL size from the folder [SBuilderX315 install path]\Tools\Shapes\ ?
 
Last edited:
Attached please find the files output by SBuilderX version 3.15 (64-Bit) when I 'Appended':

FLXUGSB_ADEX_GVAF22_CVX.shp


...then selected and compiled all source data within the SBuilderX work-space into:


[SBuilderX315 install path]\Tools\Shapes\ ...sub-folder


GaryGB
 

Attachments

  • niksan_Shapes_GaryGB_SBuilderX_Output.rar
    1.9 KB · Views: 159
Last edited:
https://www.fsdeveloper.com/forum/t...-elevation-in-the-_cvx-bgl.446626/post-835396

Your file cvx_PROJECT.BGL also does not open for viewing in tmfviewer.exe...
Your files are the same as the ones I get when compiling.

Yes it does; here is the proof:

[SBuilderX315 install path]\Tools\Shapes\cvx_PROJECT.BGL ...Displayed in SDK TMFViewer

niksan_sbuilderx_output_cvx_project-bgl_tmfviewer-jpg.54223



[SBuilderX315 install path]\Tools\Shapes\FLX_PROJECT.shp ...Appended to SBuilderX

niksan_sbuilderx_output_cvx_project-bgl_sbuilderx_append_shp-jpg.54224



While you may be able to resolve some of the file / folder access and functionality issues via "Run As Administrator",
it appears you may have other pervasive Windows file / folder 'Permissions' issues which need to be fixed.


I recommend you research this more extensively and resolve that ...before proceeding further with FS development. :pushpin:


GaryGB
 

Attachments

  • niksan_SBuilderX_Output_cvx_PROJECT.BGL_TMFViewer.jpg
    niksan_SBuilderX_Output_cvx_PROJECT.BGL_TMFViewer.jpg
    61.9 KB · Views: 780
  • niksan_SBuilderX_Output_cvx_PROJECT.BGL_SBuilderX_Append_SHP.jpg
    niksan_SBuilderX_Output_cvx_PROJECT.BGL_SBuilderX_Append_SHP.jpg
    65.3 KB · Views: 744
Last edited:
Yes it does; here is the proof:
Thanks! i fixed it!
Now I have a new question, is it possible to do flattening in 3D(for another project)?
Really very difficult to use a flattening polygon(adjust altitude according to mesh), because we don’t see real-time altitude changes; (
 
I recommend that you open a separate new thread on that topic in ex: SBuilderX forum, and attach descriptive screenshots as needed. ;)

GaryGB
 
Back
Top