New Release D3D9Client Development

kuddel

Donator
Donator
Joined
Apr 1, 2008
Messages
2,064
Reaction score
507
Points
113
Are a feature branches supposed to hang-around forever in the branches or are they supposed to be deleted after merging ? or after becoming obsolete ?
Is this question for me? I'll take it anyway ;)
Usually a feature-branch will stay there forever.
You *can* remove them, but they are still in the repository (before the revision where it was removed). That's what revision control is made for anyway.
So in case you have a feature-branch named "new feature" (which is not a good name by the way) some time ago and that has been merged back to trunk some time ago,
you could re-use it for your "next" new feature by first updating it to represent the trunk, then -after developing is done- merge that branch back (again) to the trunk.
The graph would look something like this in that case:

Code:
   trunk: o---o---o---o---o---o---o---o---o--o--o---o---o
              \          ^            \         ^
               \        /              \       /
f-branch:       o-o-o--o  -  -  -  -  - o-o-o-o
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
Thanks the clarifying that. I have created a new branch called "Experiments" and I try to re-use the branch in the future.

The code in the "Experiments" can be in a state that it won't compile and some features may be off-line or not working.

Current Plan:

1. Implementation of Image Processing Interface (IPI)
2. Exporting the IPI for a community use
3. Using the IPI to pre-compute some scattering tables for atmospheric experiments.
4. Running some tests to study a use of Deferred rendering architecture with the Orbiter that will also take extensive use of IPI
5. If all goes well then implementing a deferred version of the client.
 

Marg

Active member
Joined
Mar 20, 2008
Messages
482
Reaction score
66
Points
28
Never paid attention to word "deferred" before...
But my only dream is here - vessel-vessel\self-shadows... other than that I am very satisfied with this d3d9.
 

SolarLiner

It's necessary, TARS.
Addon Developer
Joined
Jun 14, 2010
Messages
1,847
Reaction score
2
Points
0
Location
404 ROAD NOT FOUND
IIRC there are two ways of rendering things in realtime:
Forward rendering (current rendering method used by D3D9):
Every object is pushed individually to the scene after lights have been set up. Pixel and Vertex Shaders do the job of coloring and lighting each mesh separately.
Then, the image is composited and shown on screen.

Deffered rendering:
This way, all meshes are dumped into one 'supermesh' that will be processed at once by the shaders. This way, all the meshes are processed like in forward rendering but by only one Pixel and Vertex Shader for the whole scene.
This allows for massive optimizations of the graphics engine, and much more complex computation on the lighting side of things (self shadowing, ambient occlusion, global illumination, etc.).

(Simplified and out of my memory here, but I think it's about right)
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
I'll explain the detains about deferred when I got some positive test results supporting the idea of moving in deferred architecture. If the test results are negative then we don't move to it. Also, some pictures and diagrams would help to understand it.

So, what would it mean ?

Good things:
- SSAO (Screen Space Ambient Occlusion) would become available. That's practically the only way to provide AO for Orbiter. Google "Ambient Occlusion" for more information.

- Local lights would work in per pixel basis instead of per vertex basis. Normal map/light interaction would also work much better.

- A feel of a light could be improved via light post-processing with lower costs than in current architecture.

- Vertex processing is simple and faster and that could improve performance in high vertex count scenes.

Bad things:
- MSAA (Multi Sample Anti-alias) would no longer work. SSAA (Super Sample Anti-alias) could be used instead but the performance costs are higher.

- Transparencies are more problematic, likely post rendered to a scene, would not receive nor contribute to image processing effects.
 

Marg

Active member
Joined
Mar 20, 2008
Messages
482
Reaction score
66
Points
28
I am just thinking about the Moon in Orbiter Beta, how good it looks. The last thing remaining is to add surface microtexturing at small altitudes (<3 km). Is it d3d9 or Orbiter's realm?
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
I am just thinking about the Moon in Orbiter Beta, how good it looks. The last thing remaining is to add surface microtexturing at small altitudes (<3 km). Is it d3d9 or Orbiter's realm?

It should be pretty easy thing to do but we don't have micro textures. Otherwise, it would have been implemented years ago. I suppose I could throw my DSLR high in the air and hope to take a good shot but there aren't martian/luna like terrain anywhere nearby.
 

Post much?

New member
Joined
Sep 10, 2009
Messages
28
Reaction score
0
Points
0
I seem to still crash after ~10s in, using the D3D9 client.
Terrain settings are at maximum quality.
Using D3D9Client r47 w/ beta r47
Intel i5 w/ HD4600

Using the same settings with the inline client produces no crashes.

D3D9Client.cfg:

Code:
FrameRate = 200
EnableLimiter = 0
CustomCamMode = 0
PlanetPreloadMode = 1
PlanetTexLoadFreq = 500
Anisotrophy = 8
SceneAntialias = 0
SketchpadMode = 0
SketchpadFont = 3
PreLoadBaseVisuals = 0
EnableNormalMapping = 1
NearClipPlaneMode = 0
RwyLightAnimate = 1
RwyLightAngle = 120
RwyBrightness = 1.8
NightLightsAngle = 10
BumpMapAmplitude = 1
PlanetGlow = 0.7
EnvMapSize = 512
EnvMapMode = 0
EnvMapFaces = 1
ShadowMapMode = 1
ShadowMapSize = 1024
EnableGlass = 1
EnableMeshDbg = 1
TileMipmaps = 0
TextureMips = 1
TileDebug = 0
StereoSeparation = 65
StereoConvergence = 0.2
DebugLvl = 4
VCNearPlane = 0.1
LightSourcesInUse = 12
DisableDrvMgm = 0
NVPerfHUD = 0
DebugLineFontSize = 18
GDIRTSDebug = 0
ManagedTiles = 0
DisableVisualHelperReadout = 0
LODBias = 3
MeshRes = 2
SolCfg = Sol
DebugLineFont = Fixed

Orbiter_NG.cfg:

Code:
; === ORBITER Master Configuration File ===
EchoAllParams = FALSE
LPadRect = 353 325 895 887

; === Logical parameters ===
DamageModel = 1
MFDTransparent = TRUE

; === Debugging options ===
DisableFontSmoothing = FALSE
ForceReenableFontSmoothing = TRUE
VerboseLog = TRUE

; === Physics engine ===
DistributedVesselMass = TRUE
NonsphericalGravitySources = TRUE
RadiationPressure = TRUE
AtmosphericWind = TRUE

; === Planet rendering parameters ===
PlanetPatchGrid = 6
PlanetResolutionBias = 2

; === Device settings ===
DeviceIndex = 0
ModeIndex = 32
Fullscreen = TRUE
NoVSync = TRUE
StencilBuffer = TRUE
FullscreenPageflip = FALSE
WindowWidth = 400
WindowHeight = 300

; === Window positions ===
LpadScnListWidth = 139
LpadModListWidth = 213
LpadExtListWidth = 213

; === Active plugin list ===
ACTIVE_MODULES
  D3D9Client
END_MODULES

Orbiter.log:

Code:
**** Orbiter.log
000000.000: Build Jan 29 2016 [v.160129]
000000.000: Timer precision: 3.20734e-007 sec
000000.000: Found 0 joystick(s)
000000.000: Module AtlantisConfig.dll .... [Build 150906, API 150906]
000000.000: Module AtmConfig.dll ......... [Build 150906, API 150906]
000000.000: Module DGConfigurator.dll .... [Build 150906, API 150906]
000000.000: Module D3D9Client.dll ........ [Build 160129, API 160129]
000000.000: 
000000.000: **** Creating simulation session
000000.000: D3D9Client: [DirectX 9 Initialized]
000000.000: D3D9Client: Sytem has XNA math support
000000.000: D3D9Client: [3DDevice Initialized]
000000.000: D3D9Client: [Loading Stars]
000000.000: D3D9Client: [Loading Constellations]
000000.000: D3D9Client: [D3D9Client Initialized]
000000.000: Attempting to clear a texture 0x77DCCF0 color=0x0
000000.000: Module Sun.dll ............... [Build 150906, API 150906]
VSOP87(E) Sun: Precision 1e-006, Terms 554/6634
000000.000: Module Mercury.dll ........... [Build 150906, API 150906]
VSOP87(B) Mercury: Precision 1e-005, Terms 167/7123
000000.000: Module Venus.dll ............. [Build 150906, API 150906]
000000.000: Module VenusAtm2006.dll ...... [Build 150906, API 150906]
VSOP87(B) Venus: Precision 1e-005, Terms 79/1710
000000.000: Module Earth.dll ............. [Build 150906, API 150906]
000000.000: Module EarthAtm2006.dll ...... [Build 150906, API 150906]
VSOP87(B) Earth: Precision 1e-008, Terms 2564/2564
000000.000: Module Moon.dll .............. [Build 150906, API 150906]
ELP82: Precision 1e-005, Terms 116/829
000000.000: Module Mars.dll .............. [Build 150906, API 150906]
000000.000: Module MarsAtm2006.dll ....... [Build 150906, API 150906]
VSOP87(B) Mars: Precision 1e-005, Terms 405/6400
000000.000: Module Phobos.dll ............ [Build ******, API 060425]
000000.000: Module Deimos.dll ............ [Build ******, API 060425]
000000.000: Module Galsat.dll ............ [Build 150906, API 150906]
000000.000: Module Jupiter.dll ........... [Build 150906, API 150906]
VSOP87(B) Jupiter: Precision 1e-006, Terms 1624/3625
000000.000: Module Io.dll ................ [Build 150906, API 150906]
000000.000: Module Europa.dll ............ [Build 150906, API 150906]
000000.000: Module Ganymede.dll .......... [Build 150906, API 150906]
000000.000: Module Callisto.dll .......... [Build 150906, API 150906]
000000.000: Module Satsat.dll ............ [Build 150906, API 150906]
000000.000: Module Saturn.dll ............ [Build 150906, API 150906]
VSOP87(B) Saturn: Precision 1e-006, Terms 2904/6365
000000.000: Module Mimas.dll ............. [Build 150906, API 150906]
SATSAT Mimas: Terms 113
000000.000: Module Enceladus.dll ......... [Build 150906, API 150906]
SATSAT Enceladus: Terms 33
000000.000: Module Tethys.dll ............ [Build 150906, API 150906]
SATSAT Tethys: Terms 101
000000.000: Module Dione.dll ............. [Build 150906, API 150906]
SATSAT Dione: Terms 59
000000.000: Module Rhea.dll .............. [Build 150906, API 150906]
SATSAT Rhea: Terms 68
000000.000: Module Titan.dll ............. [Build 150906, API 150906]
SATSAT Titan: Terms 100
000000.000: Module Iapetus.dll ........... [Build 150906, API 150906]
SATSAT Iapetus: Terms 605
000000.000: Module Uranus.dll ............ [Build 150906, API 150906]
VSOP87(B) Uranus: Precision 1e-006, Terms 1827/5269
000000.000: Module Miranda.dll ........... [Build ******, API 060425]
000000.000: Module Ariel.dll ............. [Build ******, API 060425]
000000.000: Module Umbriel.dll ........... [Build ******, API 060425]
000000.000: Module Titania.dll ........... [Build ******, API 060425]
000000.000: Module Oberon.dll ............ [Build ******, API 060425]
000000.000: Module Neptune.dll ........... [Build 150906, API 150906]
VSOP87(B) Neptune: Precision 1e-006, Terms 391/2024
000000.000: Finished initialising world
000000.000: Module DeltaGlider.dll ....... [Build 160127, API 160127]
000000.000: Module LuaInline.dll ......... [Build 150906, API 150906]
000000.000: Module ShuttleA.dll .......... [Build 151205, API 151205]
000000.000: Finished initialising status
000000.000: Finished initialising camera
000000.000: Finished setting up render state
000000.000: D3D9Client: [Scene Initialized]
000000.000: ---------------------------------------------------------------
000000.000: >>> WARNING: Obsolete API function used: oapiTriggerRedrawArea
000000.000: Replaced by VESSEL::TriggerRedrawArea
000000.000: ---------------------------------------------------------------
000000.000: Attempting to fill a texture 0x7783368 color=0x0
000000.000: Attempting to fill a texture 0x7783368 color=0x0
000000.000: Finished initialising panels
[B]000012.991: .\Tilemgr2.cpp Line:959 Error:-2005532292 pDev->CreateVertexBuffer(nv*sizeof(VERTEX_2TEX), D3DUSAGE_DYNAMIC|D3DUSAGE_WRITEONLY, 0, D3DPOOL_DEFAULT, pVB, NULL)
000012.991: Failed to create vertex buffer
000013.002: .\Tilemgr2.cpp Line:959 Error:-2005532292 pDev->CreateVertexBuffer(nv*sizeof(VERTEX_2TEX), D3DUSAGE_DYNAMIC|D3DUSAGE_WRITEONLY, 0, D3DPOOL_DEFAULT, pVB, NULL)
000013.002: Failed to create vertex buffer[/B]
 

Marg

Active member
Joined
Mar 20, 2008
Messages
482
Reaction score
66
Points
28
It should be pretty easy thing to do but we don't have micro textures. Otherwise, it would have been implemented years ago. I suppose I could throw my DSLR high in the air and hope to take a good shot but there aren't martian/luna like terrain anywhere nearby.
I think remember AMSO landing sites contained something like this. At least if option could be in (turn- ON/OFF), textures could be made.
Actuallu I looked in my Moon high-RES folders and there are also some tiles, which could be used for this purpose -
Moon\Surf\11\000055\000081.dds, 000082.dds - they look pretty similar to Moons surface closeup ( I do not know technical requirements though).
P.S. I found a file Gdetail.dds in AMSO texture folder - it is texture used for surface closeups in bases, it has appropriate transparency...
 
Last edited:

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
000012.991: Failed to create vertex buffer
000013.002: .\Tilemgr2.cpp Line:959 Error:-2005532292 pDev->CreateVertexBuffer(nv*sizeof(VERTEX_2TEX), D3DUSAGE_DYNAMIC|D3DUSAGE_WRITEONLY, 0, D3DPOOL_DEFAULT, pVB, NULL)

Out Of Video Memory. It's recommended to turn of surface tile mipmaps. Doesn't save much but little better than nothing.
 

turtle91

Active member
Joined
Nov 1, 2010
Messages
319
Reaction score
7
Points
33
Do you mean system- or video-memory ?
I am asking, because I have had simmilar issues on my desktop-system, but no issues on my notebook, which has more system+video-ram.

sorry...forget my last post, I have just re-read your answer.:facepalm:
 
Last edited:

JMW

Aspiring Addon Developer
Joined
Aug 5, 2008
Messages
611
Reaction score
52
Points
43
Location
Happy Wherever
Can someone quickly explain why I can't see my base tiles in D3D9Client ?
And is there a fix ?
(Sorry if this is an age old question)
 
Last edited:

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
Can someone quickly explain why I can't see my base tiles in D3D9Client ?

They are disabled, I wasn't aware of they exists in Orbiter beta. Do they take surface elevation in account properly ?
 

JMW

Aspiring Addon Developer
Joined
Aug 5, 2008
Messages
611
Reaction score
52
Points
43
Location
Happy Wherever
I think so, and they add so much detail/immersion, IMO
Now we can manipulate elevation data in certain areas (a severe learning curve for me) it would be worth enabling them. Again, IMO
 
Last edited:

fort

Active member
Joined
Mar 19, 2008
Messages
1,017
Reaction score
20
Points
38
Do they take surface elevation in account properly ?

In their traditional configuration, no. But converted in the orbiter beta tile system/distribution, yes.

It lacks an instrument that could make this conversion easyly.

Matlab? I have not yet explored this possibility.
 

jarmonik

Well-known member
Orbiter Contributor
Addon Developer
Beta Tester
Joined
Mar 28, 2008
Messages
2,651
Reaction score
785
Points
128
Here is a new build for testing with Orbiter Beta rev.47

- Vertex data is now packed more tight. Memory and bandwidth has reduced from 48 bytes per vertex down to 24.

- Surface micro textures are now available for moon and mars. (included)
 

Attachments

  • D3D9ClientBeta17b-forRev47.zip
    1.4 MB · Views: 19

gosavich

New member
Joined
Apr 11, 2008
Messages
15
Reaction score
0
Points
0
Interesting problem with the latest build of the D3D9 Client. Orbiter_ng (v47) won't load successfully any longer. Who knew a GTX970 isn't compatible with D3D9? LOL

000000.000: **** Creating simulation session
000000.000: D3D9: [DirectX 9 Initialized]
000000.000: D3D9: 3D-Adapter = NVIDIA GeForce GTX 970
000000.000: D3D9: MaxTextureWidth........: 16384
000000.000: D3D9: MaxTextureHeight.......: 16384
000000.000: D3D9: NumSimultaneousRTs.....: 4
000000.000: D3D9: XNA Math Support.......: Yes
000000.000: D3D9: Vertex Texture.........: Yes
000000.000: D3D9: Shadow Mapping.........: Yes
000000.000: D3D9: D3DFMT_A16B16G16R16F...: Yes
000000.000: D3D9: D3DFMT_A32B32G32R32F...: Yes
000000.000: D3D9: D3DFMT_D32F_LOCKABLE...: Yes
000000.000: D3D9: D3DFMT_A2R10G10B10.....: Yes
000000.000: D3D9: D3DDTCAPS_DEC3N........: No (Critical)
000000.000: D3D9: FAIL: !! Graphics card doesn't meet the minimum requirements to run !!
000000.000: D3D9: ERROR: ERROR: Failed to initialize 3D Framework
000000.000: D3D9: ERROR: Invalid Window !! RenderWndProc() called after calling clbkDestroyRenderWindow() uMsg=0x49F3A0
000000.000: D3D9: ERROR: Invalid Window !! RenderWndProc() called after calling clbkDestroyRenderWindow() uMsg=0x49F3A0
 

DaveS

Addon Developer
Addon Developer
Donator
Beta Tester
Joined
Feb 4, 2008
Messages
9,429
Reaction score
680
Points
203
The GTX970 is completely compatible with D3D9Client. I use it and have never had any problems with it. It could be a driver issue on your end.
 
Top