Special Aircraft Service

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: My crack at 3D tracer smoke  (Read 579 times)

0 Members and 1 Guest are viewing this topic.

WxTech

  • Modder
  • member
  • Offline Offline
  • Posts: 6066
My crack at 3D tracer smoke
« on: December 26, 2023, 07:08:08 PM »

My latest experiment with the '3D' tracer smokes. After much fiddling I have obtained a balance between appearance and resource impact I'm reasonably happy with.

I have Gun.class configured to allow the player to select, via a conf.ini control, whether or not to use '3D' tracer smokes. These apply for the player ONLY; all AI guns will always create the resource-friendlier 2D trails. The reason being that such particle-based '3D' tracer smokes only look decent from end-on or nearly so, which is the POV of the player firing his own guns. Other tracer smoke trails will be seen from all possible aspect angles (highlighting the unavoidable 'beads-on-a-string' appearance if of this '3D' construction), and even if seen along the line of sight are rarely positioned or glimpsed well enough to make obvious their 'flat ribbon' quality.

[click for larger]
Logged
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)

WxTech

  • Modder
  • member
  • Offline Offline
  • Posts: 6066
Re: My crack at 3D tracer smoke
« Reply #1 on: December 26, 2023, 07:21:23 PM »

Two different gun calibres, with different smokes, firing simultaneously from my Zero. The yellow tracers are the 7.7mm peashooters (with thinner, less opaque smoke), and the orange tracers are the 20mm cannon (with fatter, more opaque smoke). The views, like that in the first post, are pretty strongly zoomed in. Here we see the tracers from the outgoing and incoming perspective.

I forgot to mention in the first post that part of my scheme is to add a random transverse velocity component to the particles, so as to move some a little out of a straight-line path. This adds a more organic irregularity. This is coupled with the texture having an asymmetry, which, combined with an imparted rotation, further introduces an out-of-line staggering. It's not necessary to exaggerate this, as subtlety goes a long way. Dead straight trails of such particles look much to 'perfect' and artificial.

[click for larger]
Logged
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)

shardana

  • member
  • Offline Offline
  • Posts: 865
Re: My crack at 3D tracer smoke
« Reply #2 on: December 27, 2023, 12:12:17 AM »

Beautiful!
Logged

Whiskey_Sierra_972

  • Modder
  • member
  • Offline Offline
  • Posts: 6654
  • In memory of my beloved hero: Saburo SAKAI!
Re: My crack at 3D tracer smoke
« Reply #3 on: December 27, 2023, 04:58:24 AM »

Wonderful!
Logged

baggo

  • member
  • Offline Offline
  • Posts: 237
Re: My crack at 3D tracer smoke
« Reply #4 on: December 27, 2023, 10:07:56 AM »

superb Glen, just like vintage gun camera footage, kev.
Logged

WxTech

  • Modder
  • member
  • Offline Offline
  • Posts: 6066
Re: My crack at 3D tracer smoke
« Reply #5 on: December 27, 2023, 02:05:38 PM »

Logged
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)

WxTech

  • Modder
  • member
  • Offline Offline
  • Posts: 6066
Re: My crack at 3D tracer smoke
« Reply #6 on: December 31, 2023, 02:24:06 PM »

I've continued to make refinements. Here are three:

1) Using a texture which has an alpha channel. This delivers a more balanced appearance when the particles are seen against backgrounds having a large range in brightness. When seen against a bright sky, for instance, the particles will have a darker silhouette. Without the alpha channel the particles tend to blend into near invisibility. Not perfect, because of the limitations of the graphics engine, but better.

2) Making a fairly significant change to GasResist. I had the value fairly large so that the particles would very quickly slow down. The disadvantage is that they also quickly become widely separated. By using a smaller GasResist, the particles decelerate more slowly and thereby start out with a closer spacing, giving a bit better impression of a contiguous smoke trail.

3) Swapped the values for LiveTime and FinishTime, meaning FinishTime is reduced and LiveTime is increased. This retains the same total particle count. Its real purpose here is to stop the creation of the trail sooner, meaning the trail remains in the vicinity of the player's plane for longer. It doesn't look quite right to have a tracer make a smoke into the farther distance when the near end of the trail is also receding into the distance. Following the distant, thin smoke is kind of pointless when we're forced to keep the trail length on the short side. In such case, better to sacrifice the drawing of particles far away so as to keep the nearer ones visible longer.

The overall improvement is fairly significant, I think. When I'm satisfied I'll release an update.

In this screenie all 6 of the Hawk 75's .303s are barking, and every tracer has a smoke trail assigned (as I've done in all or nearly all gun classes). This effect, for the smaller calibre ammo, has a thinner trail than the smoke for larger calibres.




Here all 4 of the Zero's guns are speaking. The different particle size between the 7mm and 20mm ammo smokes is apparent. I'll probably do a bit more refining of the textures...

Logged
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)

Mick

  • Modder
  • member
  • Offline Offline
  • Posts: 5498
Re: My crack at 3D tracer smoke
« Reply #7 on: December 31, 2023, 02:40:14 PM »

... I love your refinements projects ... !  8)
Logged

WxTech

  • Modder
  • member
  • Offline Offline
  • Posts: 6066
Re: My crack at 3D tracer smoke
« Reply #8 on: December 31, 2023, 09:31:54 PM »

To show how the addition of an alpha channel aids in visibility against a bright background. Without it the smoke would be almost invisible against this sky.

Logged
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)
Pages: [1]   Go Up
 

Page created in 0.037 seconds with 26 queries.