Commit graph

490 commits

Author SHA1 Message Date
marauder2k7
ad64b4f2df IES Loader
Updated IES loader to use torque math functions and calls in the problem areas for mac and linux.

New F32_MIN_EX which is lower than F32_MIN (required for ies profiles)
2024-02-21 09:36:37 +00:00
marauder2k7
a12d915180 Loads an IES Photometric profile.
ADDED: Ability to add IES profile as the cookie texture slot in both point lights and spot lights

TODO:
Have the IES Profile also drive the settings for the lights.
Make it work with Cookie textures. IES profiles are to be another slot in the advanced light section.
2024-02-21 06:22:37 +00:00
marauder2k7
d87199f5da Final Cleanup
-Removed LPNG
-Removed LJPEG
-Re-Added DefferredPNGWriter from rextimmy stb work

Commented out lines about file saving and reading in gfont, these are good for debugging font saves.
2024-01-23 08:47:26 +00:00
marauder2k7
8632468a9c Set format in read stream
Forgot to pass the decided format in read from stream
2024-01-21 20:10:29 +00:00
marauder2k7
43c2c918c7 Expanded Features
Added ability to set format dynamically on read from stream.
Added other formats to write to a stream.
2024-01-20 22:47:58 +00:00
marauder2k7
106346630d STB Memory functions for fonts
Add the ability to read and write to a stream.
2024-01-20 22:15:17 +00:00
marauder2k7
7216ba8530 Revert "revert #1148 as prematurely incorporated"
This reverts commit f946088214.
2024-01-20 18:01:57 +00:00
AzaezelX
f946088214 revert #1148 as prematurely incorporated
it's getting there, but there have been a few spots noted where it eroneously corrupts text, so we'll have to pull this back out for a bit barring a proper resolution
2024-01-11 13:33:03 -06:00
Brian Roberts
51426a3575
Merge pull request #1148 from marauder2k9-torque/STBImageLoading-PR
Stb image loading
2024-01-01 08:48:46 -06:00
AzaezelX
1f837304ea theoratexture can't downsample
so don't.
this stops $pref::Video::textureReductionLevel from crashing the applicaton in that scenario
2023-12-19 13:15:12 -06:00
marauder2k7
89a8a4d190 Merge remote-tracking branch 'upstream/development' into STBImageLoading-PR 2023-12-08 04:29:41 +00:00
AzaezelX
8c38448428 probe capture fixes
review of per and post bake protocols showed that the CAPTURING shader macro was not being properly recompiled in. as opengl was not playing nice with a simple batch shader recompilation for all effected shaders, a full lightmanager restart is at time of writing required. once we have a proper globally cached scene structure stored off GPU side, we'll want to change  GFXShader::addGlobalMacro("CAPTURING", String("1")); on over to dirtying that value in the cached buffer via setting a shader global uniform
review of prefilter examples shows a fixed sample count of 1024 across multiple implementations, so we'll use the standard barring further research into where that number is comming from for a scalar approach
review of gl shaders shows a doubleup in compiled state testing, so slimmed that down and added additional debugging reports
2023-12-05 13:32:03 -06:00
marauder2k7
5f8c59a8df MacOSX fixes 2023-12-04 00:16:07 +00:00
marauder2k7
a91b19d4dc Added hdr and bypass 16bit when png.
Added support for .hdr format, atm just being converted to ldr after the exposure is applied.

cleanup dds file

PNG skips 16bit altogether at the moment for textureArray issues.
2023-12-01 14:50:59 +00:00
marauder2k7
c18c14b415 Update gBitmap.h
typo
2023-11-30 15:58:41 +00:00
marauder2k7
6ed0374768 Added documentation
CompressionLevel argument now used to set jpeg quality as well. Values need to be 0-100 range for jpeg and 0-10 for png.
2023-11-30 15:57:59 +00:00
marauder2k7
870fae3e47 Update screenshot.cpp
Screenshot now works with stb: gBitmap outbuffer holds the whole image anyway so just use writeBitmap when its done.
2023-11-30 14:02:06 +00:00
marauder2k7
63682c43ec Bug fixes:
Generating image previews of image assets was failing

DDS remove redundant check for stream status.

STB requires the file to be free before being written to, move check to make sure we can open the path into gBitmap and remove FileStream checks from everywhere else.
2023-11-30 10:46:51 +00:00
marauder2k7
108ba34c08 STBImage
STB used for loading and writing images.
2023-11-30 09:09:13 +00:00
Lukas Aldershaab
89b0c7f73b Console Refactor 2023-09-13 10:33:20 +02:00
JeffR
0bdacb8795 Testing just disabling gfx device enumeration in test mode 2023-07-23 14:42:13 -05:00
Areloch
368b687043 This implements a fix to an issue with the CICD that causes a segfault.
The fix adds a sanity check to the D3D and GL device enumeration function that exits early if there's no registered display from the OS(implying it's running in commandline).
With newer versions of SDL, attempting to enumerate the GL device causes a segfault because the OS will return back a valid context, but the context isn't actually valid. So when tested against, it crashes. Avoiding enumerating the device when you're not in a position to render works around the issue.

TODO: If the machine is running in terminal-only mode, and thus has no valid render context, but still has a monitor plugged into the machine, it can sidestep the sanity check and still result in a segfault. Need a more robust check for that circumstance in a future fix.
2023-07-23 01:04:29 -05:00
marauder2k7
e0119efbb5 move border to gfxglstateblock 2023-07-19 16:33:01 +01:00
marauder2k7
63b2aba467
Apply suggestions from code review 2023-07-19 15:41:24 +01:00
marauder2k7
e325902bac init commit 2023-07-19 13:36:14 +01:00
JeffR
38b81eb804 Adds a logical check for when we try and check for found adapters, so if we're defined to use a Null device, we can skip looking around 2023-07-17 21:12:46 -05:00
XXTH
a81c6ebd06 clean up 2023-05-12 11:42:06 +02:00
XXTH
e0ab3830af bsd ready 2023-05-10 14:58:47 +02:00
Brian Roberts
a6f03897ed
Merge pull request #1016 from Azaezel/alpha41/mangledMath
clean up math varsize complaints
2023-05-08 21:28:49 -05:00
AzaezelX
0d4221fa59 uninitialized and unused value cleanups
(cherry picked from commit 1f08602cf0ad84409cd8b3520510f9c6ce7d5f9c)
2023-05-01 10:40:02 -05:00
AzaezelX
0ce2da3a23 clean up math varsize complaints 2023-04-27 16:10:04 -05:00
AtomicWalrus
c64c2212ad Fix for MacOS OGL 4.1 support
Workaround: MacOS does not have access to glClipControl.

Because the lower range of the 32F buffer is not available using this workaround, the improvements to depth behavior from depth reversal will be limited on MacOS. Behavior is equivalent to reversed depth on a 24UINT buffer; Better than stock, but not dramatically.
2023-04-15 15:21:49 -06:00
AtomicWalrus
75625dc679 Reverse depth & 32F buffer format
-Adds reversed depth projection model, dramatically increasing depth buffer effective resolution.
-Adds 32F depth 8U stencil format GFXFormatD32FS8X24 (following DX naming conventions). Note this is a 64-bit format, and likely not suitable for mobile platforms. Revert to GFXFormatD24S8 in renderManager.tscript for mobile & "ancient" platforms.
-Corrects alignment of texture type details array.
2023-04-14 20:13:28 -06:00
AzaezelX
fd02044d20 cut control chars for font population
zip referenceablilty for font files
2023-03-17 23:02:27 -05:00
AzaezelX
7872f01689 since we do in fact allow arbitrary tack on variables to scriptobject derivatives, and thus tamls, reporting theres a non hardcoded variable entry is actively counterproductive to flexibility.
plus minor format fix
2023-03-07 16:10:46 -06:00
Johan Mattsson
70a464b3f4 Fix corruption of file encoding. 2023-03-05 11:56:47 +01:00
Johan Mattsson
77e808cc3a
Use correct calculation for dStrncat 2023-03-05 11:28:23 +01:00
Johan Mattsson
3c0a251f71
Release memory 2023-03-04 21:58:16 +01:00
Johan Mattsson
390be98140
Release memory 2023-03-04 21:55:39 +01:00
Johan Mattsson
fa5b377ec3
Fix argument to dStrncat 2023-03-04 21:47:04 +01:00
AzaezelX
1b33b01eb1 add "docsURL" filter to assignFieldsFrom to prevent it from triggering opening web pages when inheriting values 2023-01-28 16:12:05 -06:00
AzaezelX
f5a34308f9 add a docsURL; macro to link a given set of script config vars to git or similar storage urls via clicking on the inspector 2023-01-27 01:13:15 -06:00
AzaezelX
7284d44833 bump up max allowable texture dimensions 2023-01-10 17:44:17 -06:00
AzaezelX
d23ee397e6 adds wetness
cliffsnotes:
   $Core::WetnessTexture = "core/rendering/images/wetMap.png"; //for the influence degree map
probes/skylight have a new canDamp boolean, set to off for probes, on for skylight by default.
:levelinfo has a dampness multiplier (0-1)
kicked up numTextures from 8 to 16 for shaderdata and postfx since that hit the 8 texture-in prior limit, and we've already adopted apis that can handle the higher count
2022-11-21 21:12:23 -06:00
AzaezelX
cdf3b6cf79 kill console spam
no point in reporting mismatched texture formats the line right before we try and convert the things and report if we couldn't
*was mostly due to excessive reports for fully compatible rgb vs rgba mixes
2022-10-09 00:30:06 -05:00
AzaezelX
04f4a5fcf4 dedicated server nulltexturemanager work
also supress warning for imageassets not loading a texture in nulldevice, and early out of _determineFeatures shadergen methods under the same conditions
2022-10-01 12:44:45 -05:00
AzaezelX
aafbb7bfba add debug reportingfor cubemap arrays, and correct transcription flaw 2022-09-18 07:30:47 -05:00
AzaezelX
62a99adb74 aug GFXTextureArray::setTexture to report what texture sizes are mismatching 2022-09-18 05:36:11 -05:00
Brian Roberts
3a800e51cc
Merge pull request #891 from Azaezel/alpha401/CubeMapMangle
get probes displaying with low Texture quality
2022-09-15 18:01:24 -05:00
Jeff Hutchinson
2e006390f8 Add GFXFormatA8L8 for OpenGL 2022-09-15 17:59:00 -04:00