Author Topic: Modeled Thruster Updates  (Read 7098 times)

0 Members and 1 Guest are viewing this topic.

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Modeled Thruster Updates
Okay, since I managed to get modeled thrusters to render multiple animations instead of the species defined or $Thruster Normal Flame:  anim, I'm in need of some input from both modders and other coders on what would be the best method to make afterburner animations work when the "use thruster materials" ship flag(currently not merged into master) is present.

AdmiralRalwood (MageKing17) suggested a method that takes the base thruster anim name followed by the name of the anim to replace it with when afterburner is activated. This would naturally be a ships.tbl parameter.

If anyone else has any other suggestions, please feel free to put them forth.
« Last Edit: February 26, 2016, 01:27:02 pm by DahBlount »
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline Black Wolf

  • Twisted Infinities
  • 212
  • Hey! You! Get off-a my cloud!
    • Visit the TI homepage!
Re: Multi-Texture Modeled Thruster Discussion
Given that we already have textures that change colour in the engine, might it be possible to do something similar with afterburner textures, save some texture memory?
TWISTED INFINITIES · SECTORGAME· FRONTLINES
Rarely Updated P3D.
Burn the heretic who killed F2S! Burn him, burn him!!- GalEmp

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Re: Multi-Texture Modeled Thruster Discussion
I do not believe I know what you're talking about. Unless you're talking about -misc maps, but those don't really save texture memory afaik.
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline The E

  • He's Ebeneezer Goode
  • Moderator
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Re: Multi-Texture Modeled Thruster Discussion
Given that we already have textures that change colour in the engine, might it be possible to do something similar with afterburner textures, save some texture memory?

I think there is enough memory available that we do not have to worry about extra anis
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline Dragon

  • Citation needed
  • 212
  • The sky is the limit.
Re: Multi-Texture Modeled Thruster Discussion
Yeah, it's not KSP (in which memory is a primary concern due to lousy coding), we have memory to spare. :) It's not like those are big animations anyway. BMPMAN slots should not be a concern, either, as long as the anim isn't absurdly long.

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Re: Multi-Texture Modeled Thruster Discussion
I tested the replacement texture system and found that it doesn't work for afterburners. Did some checking around in the code and I have come to the conclusion that $Texture Replace: doesn't even work at all. The code for replacement textures works just fine with FRED, but they can't be set by tables apparently. I'll need to go fix that then test once more. Basically, the replacement textures never get used after being parsed into ship info.
« Last Edit: October 21, 2015, 04:02:21 pm by DahBlount »
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline mjn.mixael

  • Cutscene Master
  • 212
  • Chopped liver
    • Steam
    • Twitter
Re: Multi-Texture Modeled Thruster Discussion
If you fix Table Based Texture Replacement.. you will be a god amongst men. I have wanted that feature for years.
Cutscene Upgrade Project - Mainhall Remakes - Between the Ashes
Youtube Channel - P3D Model Box
Between the Ashes is looking for committed testers, PM me for details.
Freespace Upgrade Project See what's happening.

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Re: Multi-Texture Modeled Thruster Discussion
It was actually a moment of idiocy on my part, table based texture replacement does work, unless you're in the F3 Lab. That does raise the question of why it doesn't work in the lab, but it works just fine in missions.

With this though I can move ahead with the modeled thruster work.
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline AdmiralRalwood

  • 211
  • The Cthulhu programmer himself!
    • Skype
    • Steam
    • Twitter
Re: Multi-Texture Modeled Thruster Discussion
It doesn't work in F3 lab for the simple reason that there isn't a specific ship; we'd have to add another code path for loading the replacement textures into an array, and then set it in the render info. It could be done, but it wouldn't be a simple fix.
Ph'nglui mglw'nafh Codethulhu GitHub wgah'nagl fhtagn.

schrödinbug (noun) - a bug that manifests itself in running software after a programmer notices that the code should never have worked in the first place.

When you gaze long into BMPMAN, BMPMAN also gazes into you.

"I am one of the best FREDders on Earth" -General Battuta

<Aesaar> literary criticism is vladimir putin

<MageKing17> "There's probably a reason the code is the way it is" is a very dangerous line of thought. :P
<MageKing17> Because the "reason" often turns out to be "nobody noticed it was wrong".
(the very next day)
<MageKing17> this ****ing code did it to me again
<MageKing17> "That doesn't really make sense to me, but I'll assume it was being done for a reason."
<MageKing17> **** ME
<MageKing17> THE REASON IS PEOPLE ARE STUPID
<MageKing17> ESPECIALLY ME

<MageKing17> God damn, I do not understand how this is breaking.
<MageKing17> Everything points to "this should work fine", and yet it's clearly not working.
<MjnMixael> 2 hours later... "God damn, how did this ever work at all?!"
(...)
<MageKing17> so
<MageKing17> more than two hours
<MageKing17> but once again we have reached the inevitable conclusion
<MageKing17> How did this code ever work in the first place!?

<@The_E> Welcome to OpenGL, where standards compliance is optional, and error reporting inconsistent

<MageKing17> It was all working perfectly until I actually tried it on an actual mission.

<IronWorks> I am useful for FSO stuff again. This is a red-letter day!
* z64555 erases "Thursday" and rewrites it in red ink

<MageKing17> TIL the entire homing code is held up by shoestrings and duct tape, basically.

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
I recently discovered a method in UE4 with which we can soften the edges of modeled thrusters, essentially making them appear to be gaseous instead of solid.





All the functionality to achieve this already exists in FSO's shaders, it's just a matter of implementation. I'll be working on this over the next few days between school related assignments and projects.
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline The Dagger

  • 29
  • I like zod ships
Re: Modeled Thruster Updates
Wow! All of my yes!  :nod:
I guess it could be usefull for weapons fire too.

 

Offline Mongoose

  • Rikki-Tikki-Tavi
  • Global Moderator
  • 212
  • This brain for rent.
    • Minecraft
    • Steam
    • Something
Re: Modeled Thruster Updates
duuuuuuuuuude

 

Offline Kobrar44

  • On Suspended Sentence
  • 29
  • Let me tilerape it for you!
    • Steam
Re: Modeled Thruster Updates
How would non convex, like H-shaped thruster cone work? I believe I've seen those somewhere in use.
Oh guys, use that [ url ][ img ][ /img ][ /url ] :/

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Re: Modeled Thruster Updates
How would non convex, like H-shaped thruster cone work? I believe I've seen those somewhere in use.

That is a good question. Let me get back to you on that.

Update: It doesn't seem to do poorly. Although it does still have hard edges at certain view angles. I can probably remedy that, I'll just need some time.

« Last Edit: February 27, 2016, 02:05:50 pm by DahBlount »
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 

Offline Talon 1024

  • 29
  • How do you turn this on?
    • Mods, Games, and Stuff
Re: Modeled Thruster Updates
Wow! All of my yes!  :nod:
I guess it could be usefull for weapons fire too.

And shield hits, too!
To understand religion, you need to understand morality first. | WCSaga website | WCSaga Forum | 158th website | 158th forum | Project Leader: WC: Hostile Frontier | WCHF Thread at CIC | Wing Blender | Twist of Fate | Multipart turrets on angled surfaces, tutorial included. | My Google Drive stuff | To convert speeds from WC to WCS, multiply both the cruise speed and the Afterburner speed by 0.15625 (5/32)

FS2 Mods I'm waiting on: Inferno 10th Anniversary
Current Project: Contestant Android app, Learn4Life iOS app, Blender Commander (importer).
The FreeSpace Font Foundry is back in action!

 

Offline Bryan See

  • Has anyone really been far as decided to use even go want to do look more like?
  • 210
  • Trying to redeem, but under Tiger Parents
    • Skype
    • Steam
    • Twitter
Re: Modeled Thruster Updates
Cool. I'd love to see it implemented in the near future :D

Would it however be better to implement deferred, dynamic area lighting over the engine thruster/glows in realtime, without having to create glowpoints at engines and rendered them via glowpoint overrides?
Bryan See - My FreeSpace Wiki User Page (Talk, Contributions)

Full Projects:
Shattered Stars

Campaigns:
Lost in the Mist - Cyrene vs. Psamtik
FreeSpace: Reunited

Ships:
GTS Hygeia, GTT Argo, SC Raguel

Tools:
FSO TC/Game template

I've been under attack by Tiger Parents like Jennifer Pan...

 

Offline The E

  • He's Ebeneezer Goode
  • Moderator
  • 213
  • Nothing personal, just tech support.
    • Steam
    • Twitter
Re: Modeled Thruster Updates
Would it however be better to implement deferred, dynamic area lighting over the engine thruster/glows in realtime, without having to create glowpoints at engines and rendered them via glowpoint overrides?

This is a pretty unrelated problem. We currently do not have area lights in the engine.
If I'm just aching this can't go on
I came from chasing dreams to feel alone
There must be changes, miss to feel strong
I really need lifе to touch me
--Evergrey, Where August Mourns

 

Offline Bryan See

  • Has anyone really been far as decided to use even go want to do look more like?
  • 210
  • Trying to redeem, but under Tiger Parents
    • Skype
    • Steam
    • Twitter
Re: Modeled Thruster Updates
I hope this will be resolved by Swifty, who may have plans to add area lights to the FS2_Open engine at some point in the future.

Anyway, does these require shaders, with refractive, glowing, and lens flare ones?
Bryan See - My FreeSpace Wiki User Page (Talk, Contributions)

Full Projects:
Shattered Stars

Campaigns:
Lost in the Mist - Cyrene vs. Psamtik
FreeSpace: Reunited

Ships:
GTS Hygeia, GTT Argo, SC Raguel

Tools:
FSO TC/Game template

I've been under attack by Tiger Parents like Jennifer Pan...

 

Offline DahBlount

  • Moderator
  • 29
  • Alpine ☆ Cancer Tribulation
    • Minecraft
    • Skype
    • Steam
Re: Modeled Thruster Updates
I hope this will be resolved by Swifty, who may have plans to add area lights to the FS2_Open engine at some point in the future.

Anyway, does these require shaders, with refractive, glowing, and lens flare ones?

First off, lack of area lights is not an issue with the engine. You can get a similar effect anyways by using the glowpoint override system.

As for what is required for the thruster updates to work, they will only be able to added to the engine once the PBR branch gets merged in because they require the Fresnel function (Fresnel and use cases explained here) to work correctly and Swifty hasn't had the time to get back to me on certain conventions relating to that. We don't currently have Lens Flares and both glow maps and refraction/distortion are done in the fragment shaders via different functions.
<Axem> yet still more insightful than #hard-light

<Axem> jad2.23 will just be cat videos

<DahBlount> So
<DahBlount> JAD2.2 is like that
<Axem> maybe
<Axem> it can be whatever you like!
<DahBlount> A Chocolate Sundae?
<Axem> sure

My models: GTF Gilgamesh - GTD Nuadha [Redesigning] - Ningirama [WIP] - GTG Zephyrus

 
Re: Modeled Thruster Updates
What's wrong with lens flares used for stars? If I remember correctly old BP also used them for bomb explosions.
[19:31] <MatthTheGeek> you all high up on your mointain looking down at everyone who doesn't beam everything on insane blindfolded