Commit Graph

28 Commits

Author SHA1 Message Date
Randy Heit 39bd295da8 - Fixed: The x64 Release build was configured to use the 32-bit GME, and
neither release nor debug builds built the library.


SVN r1966 (trunk)
2009-11-08 02:58:37 +00:00
Randy Heit a8de4fc2da - Fixed compilation of i_keyboard.cpp with MinGW, because w32api still doesn't have
everything that was new for XP.
- Swapped snes_spc out for the full Game Music Emu library.

SVN r1631 (trunk)
2009-06-03 03:05:02 +00:00
Christoph Oelckers bf4e17703d - Fixed: Dehacked string replacement did not check the clusters' finaleflats.
- Changed the definition of several typedef'd structs so that they are
  properly named.
- Limited DEHSUPP lump lookup to search zdoom.pk3 only. It will no longer
  be possible to load DEHSUPP lumps from user WADs.
- Brought back the text-based DEHSUPP parser and changed it to be able to 
  reference states by label. Also changed label names of 
  DoomUnusedStates and added proper labels to all states that were
  previously forced to be the first state of an actor so that the old
  (limited) method could access them. This was done to address the following
  bug:
- Fixed: The player's death states calling A_PlayerSkinCheck should not be
  part of the state set that is accessible by Dehacked. These will produce
  error messages when mapped to non-players.

SVN r1512 (trunk)
2009-03-28 11:49:44 +00:00
Randy Heit 75b7db858f - Added support for zip/pk3 files with LZMA and bzip2 compression to ZDoom.
- Added more output to zipdir and a -q option to turn it off.
- Added -u option to zipdir to only recompress those files in a zip that have
  changed. 
- Added -d and -f options to zipdir. -d forces deflate compression, and -f
  forces a write of the zip, even if it's newer than all the files it contains.
- Added support for bzip2 and LZMA compression to zipdir.


SVN r1468 (trunk)
2009-03-10 23:07:37 +00:00
Christoph Oelckers 3fe5db901c - fixed: x64 compile used debug updaterevision for release target.
SVN r1349 (trunk)
2009-01-03 21:43:08 +00:00
Randy Heit fb50df2c63 About a week's worth of changes here. As a heads-up, I wouldn't be
surprised if this doesn't build in Linux right now. The CMakeLists.txt
were checked with MinGW and NMake, but how they fair under Linux is an
unknown to me at this time.

- Converted most sprintf (and all wsprintf) calls to either mysnprintf or
  FStrings, depending on the situation.
- Changed the strings in the wbstartstruct to be FStrings.
- Changed myvsnprintf() to output nothing if count is greater than INT_MAX.
  This is so that I can use a series of mysnprintf() calls and advance the
  pointer for each one. Once the pointer goes beyond the end of the buffer,
  the count will go negative, but since it's an unsigned type it will be
  seen as excessively huge instead. This should not be a problem, as there's
  no reason for ZDoom to be using text buffers larger than 2 GB anywhere.
- Ripped out the disabled bit from FGameConfigFile::MigrateOldConfig().
- Changed CalcMapName() to return an FString instead of a pointer to a static
  buffer.
- Changed startmap in d_main.cpp into an FString.
- Changed CheckWarpTransMap() to take an FString& as the first argument.
- Changed d_mapname in g_level.cpp into an FString.
- Changed DoSubstitution() in ct_chat.cpp to place the substitutions in an
  FString.
- Fixed: The MAPINFO parser wrote into the string buffer to construct a map
  name when given a Hexen map number. This was fine with the old scanner
  code, but only a happy coincidence prevents it from crashing with the new
  code
- Added the 'B' conversion specifier to StringFormat::VWorker() for printing
  binary numbers.
- Added CMake support for building with MinGW, MSYS, and NMake. Linux support
  is probably broken until I get around to booting into Linux again. Niceties
  provided over the existing Makefiles they're replacing:
  * All command-line builds can use the same build system, rather than having
    a separate one for MinGW and another for Linux.
  * Microsoft's NMake tool is supported as a target.
  * Progress meters.
  * Parallel makes work from a fresh checkout without needing to be primed
    first with a single-threaded make.
  * Porting to other architectures should be simplified, whenever that day
    comes.
- Replaced the makewad tool with zipdir. This handles the dependency tracking
  itself instead of generating an external makefile to do it, since I couldn't
  figure out how to generate a makefile with an external tool and include it
  with a CMake-generated makefile. Where makewad used a master list of files
  to generate the package file, zipdir just zips the entire contents of one or
  more directories.
- Added the gdtoa package from netlib's fp library so that ZDoom's printf-style
  formatting can be entirely independant of the CRT.

SVN r1082 (trunk)
2008-07-23 04:57:26 +00:00
Randy Heit cdba77a406 - Undo inadvertent commit of bad zdoom.sln.
SVN r1064 (trunk)
2008-07-05 03:34:00 +00:00
Randy Heit 78890d57bc - Fixed: Screenwipes now pause sounds, since there can be sounds playing
during it.
- UI sounds are now omitted from savegames.
- Fixed: Menu sounds had been restricted to one at a time again.
- Moved the P_SerializeSounds() call to the end of G_SerializeLevel() so that
  it will occur after the players are loaded.
- Added fixes from FreeBSD for 0-length and very large string buffers
  passed to myvsnprintf.


SVN r1063 (trunk)
2008-07-05 03:32:44 +00:00
Randy Heit 01f59fa85f - Added an alternate module replay engine that uses foo_dumb's replayer, a
heavily customized version of DUMB (Dynamic Universal Music Bibliotheque).
  It has been slightly modified by me:
  * Added support for Ogg Vorbis-compressed samples in XM files ala FMOD.
  * Removed excessive mallocs from the replay core.
  * Rerolled the loops in resample.c. Unrolling them made the object file
    ~250k large while providing little benefit. Even at ~100k, I think it's
    still larger than it ought to be, but I'll live with it for now.
  Other than that, it's essentially the same thing you'd hear in foobar2000,
  minus some subsong detection features. Release builds of the library look
  like they might even be slightly faster than FMOD, which is a plus.
- Fixed: Timidity::font_add() did not release the file reader it created.
- Fixed: The SF2 loader did not free the sample headers in its destructor.


SVN r995 (trunk)
2008-05-29 23:33:07 +00:00
Randy Heit 7160e09b04 - Fixed: When R_DrawTiltedPlane() calculates the p vector, it can overflow
if the view is near the bounds of the fixed point coordinate system. This
  happens because it rotates the view position around (0,0) according to
  the current viewangle, so the resultant coordinate may be outside the
  bounds of fixed point. All important math in this function is now done
  entirely in floating point.
- Fixed: Slopes didn't draw right on 64-bit platforms.


SVN r986 (trunk)
2008-05-22 05:17:21 +00:00
Randy Heit bc5f49dd49 - Various fixes for compiling working 64-bit binaries with Visual C++. The
number of changes was pleasantly small, and a cursory check seems to show
  everything working alright.


SVN r948 (trunk)
2008-04-29 02:43:42 +00:00
Randy Heit 3237c6b4e8 - Changed MIDI playback to not bother playing super short songs that don't
contain enough music to fill the initial output buffers.
- Removed the read barrier around ADehackedPickup::RealPickup. If the real
  pickup is picked up, it may very well destroy itself before the dehacked
  wrapper's stubs that use it are called.
- Reverted revision 840. For a file we don't want end users to be touching,
  making DEHSUPP plain text sends out mixed messages: "Don't mess with this.
  Oh, by the way, it's plain text now to make it easier for you to edit."
  Is there some reason other than a desire to do away with binary lumps to
  make the distributed lump text?
- Added a new speakermode for Stereo + HRTF: "Headphones". This is the only
  way to get the HRTF low pass filter effect now.
- Fixed: No more than one sector could make noise at once.
- Trying out sound without varying priorities again. 
- Fixed: Need to use setSpeakerMix to let 2D sounds (aka streamed music) use
  their full volume range.


SVN r842 (trunk)
2008-03-23 05:24:40 +00:00
Christoph Oelckers 9c1fa19dd2 - Changed DEHSUPP loader so that it reads the text file directly. As a result
the DEHSUPP compiler is gone now. Unlike XLATCC I'm using FScanner though.
  A fully featured parser seems like overkill for this simple text file.


SVN r840 (trunk)
2008-03-22 21:07:31 +00:00
Christoph Oelckers 8ea316e33b - Integrated xlatcc into ZDoom.exe so that the linedef translation files
don't need to be compiled and can be stored as text in zdoom.pk3.


SVN r815 (trunk)
2008-03-19 21:09:53 +00:00
Randy Heit 3bfcc5c09c - Removed lots of spc_* cvars that are no longer meaningful and changed
spc_amp from a x.4 fixed point number to a normal float.
- Switched SPC playback from the external SNESAPU.DLL to Blargg's LGPL
  snes_spc library. I've compiled it with the fast DSP rather than the
  highly accurate one, since I didn't notice a meaningful difference between
  the two in my limited testing. In short: SPC playback is now built in to
  ZDoom. You don't need to download anything extra to make it work, and it
  also works on Linux as well as Windows (though building with Linux is
  currently untested).
- Fixed: Stereo separation was calculated very wrongly when in 2D sound mode.


SVN r794 (trunk)
2008-03-11 22:17:57 +00:00
Randy Heit 2b721975dd VERY IMPORTANT NOTE FOR ANYBODY BUILDING FROM THE TRUNK: This commit adds support
for FMOD Ex while at the same time removing support for FMOD 3. Be sure to update
your SDKs. GCC users, be sure to do a "make cleandep && make clean" before
building, or you will likely get inexplicable errors.

- Fixed: If you wanted to make cleandep with MinGW, you had to specifically
  specify Makefile.mingw as the makefile to use.
- Added a normalizer to the OPL synth. It helped bring up the volume a little,
  but not nearly as much as I would have liked.
- Removed MIDI Mapper references. It doesn't work with the stream API, and
  it doesn't really exist on NT kernels, either.
- Reworked music volume: Except for MIDI, all music volume is controlled
  through GSnd and not at the individual song level.
- Removed the mididevice global variable.
- Removed snd_midivolume. Now that all music uses a linear volume scale,
  there's no need for two separate music volume controls.
- Increased snd_samplerate default up to 48000.
- Added snd_format, defaulting to "PCM-16".
- Added snd_speakermode, defaulting to "Auto".
- Replaced snd_fpu with snd_resampler, defaulting to "Linear".
- Bumped the snd_channels default up from a pitiful 12 to 32.
- Changed snd_3d default to true. The new cvar snd_hw3d determines if
  hardware 3D support is used and default to false.
- Removed the libFLAC source, since FMOD Ex has native FLAC support.
- Removed the altsound code, since it was terribly gimped in comparison to
  the FMOD code. It's original purpose was to have been as a springboard for
  writing a non-FMOD sound system for Unix-y systems, but that never
  happened.
- Finished preliminary FMOD Ex support.


SVN r789 (trunk)
2008-03-09 03:13:49 +00:00
Randy Heit e5572a1c4e - Updated lempar.c to v1.31.
- Added .txt files to the list of types (wad, zip, and pk3) that can be
  loaded without listing them after -file.
- Fonts that are created by the ACS setfont command to wrap a texture now
  support animated textures.
- FON2 fonts can now use their full palette for CR_UNTRANSLATED when drawn
  with the hardware 2D path instead of being restricted to the game palette.
- Fixed: Toggling vid_vsync would reset the displayed fullscreen gamma to 1
  on a Radeon 9000.
- Added back the off-by-one palette handling, but in a much more limited
  scope than before. The skipped entry is assumed to always be at 248, and
  it is assumed that all Shader Model 1.4 cards suffer from this. That's
  because all SM1.4 cards are based on variants of the ATI R200 core, and the
  RV250 in a Radeon 9000 craps up like this. I see no reason to assume that
  other flavors of the R200 are any different. (Interesting note: With the
  Radeon 9000, D3DTADDRESS_CLAMP is an invalid address mode when using the
  debug Direct3D 9 runtime, but it works perfectly fine with the retail
  Direct3D 9 runtime.) (Insight: The R200 probably uses bytes for all its
  math inside pixel shaders. That would explain perfectly why I can't use
  constants greater than 1 with PS1.4 and why it can't do an exact mapping to
  every entry in the color palette.
- Fixed: The software shaded drawer did not work for 2D, because its selected
  "color"map was replaced with the identitymap before being used.
- Fixed: I cannot use Printf to output messages before the framebuffer was
  completely setup, meaning that Shader Model 1.4 cards could not change
  resolution.
- I have decided to let remap palettes specify variable alpha values for
  their colors. D3DFB no longer forces them to 255.
- Updated re2c to version 0.12.3.
- Fixed: A_Wander used threshold as a timer, when it should have used
  reactiontime.
- Fixed: A_CustomRailgun would not fire at all for actors without a target
  when the aim parameter was disabled.
- Made the warp command work in multiplayer, again courtesy of Karate Chris.
- Fixed: Trying to spawn a bot while not in a game made for a crashing time.
  (Patch courtesy of Karate Chris.)
- Removed some floating point math from hu_scores.cpp that somebody's GCC
  gave warnings for (not mine, though).
- Fixed: The SBarInfo drawbar command crashed if the sprite image was
  unavailable.
- Fixed: FString::operator=(const char *) did not release its old buffer when
  being assigned to the null string.
- The scanner no longer has an upper limit on the length of strings it
  accepts, though short strings will be faster than long ones.
- Moved all the text scanning functions into a class. Mainly, this means that
  multiple script scanner states can be stored without being forced to do so
  recursively. I think I might be taking advantage of that in the near
  future. Possibly. Maybe.
- Removed some potential buffer overflows from the decal parser.
- Applied Blzut3's SBARINFO update #9:
  * Fixed: When using even length values in drawnumber it would cap to a 98
    value instead of a 99 as intended.
  * The SBarInfo parser can now accept negatives for coordinates. This
    doesn't allow much right now, but later I plan to add better fullscreen
    hud support in which the negatives will be more useful. This also cleans
    up the source a bit since all calls for (x, y) coordinates are with the
    function getCoordinates().
- Added support for stencilling actors.
- Added support for non-black colors specified with DTA_ColorOverlay to the
  software renderer.
- Fixed: The inverse, gold, red, and green fixed colormaps each allocated
  space for 32 different colormaps, even though each only used the first one.
- Added two new blending flags to make reverse subtract blending more useful:
  STYLEF_InvertSource and STYLEF_InvertOverlay. These invert the color that
  gets blended with the background, since that seems like a good idea for
  reverse subtraction. They also work with the other two blending operations.
- Added subtract and reverse subtract blending operations to the renderer.
  Since the ERenderStyle enumeration was getting rather unwieldy, I converted
  it into a new FRenderStyle structure that lets each parameter of the
  blending equation be set separately. This simplified the set up for the
  blend quite a bit, and it means a number of new combinations are available
  by setting the parameters properly.


SVN r710 (trunk)
2008-01-25 23:57:44 +00:00
Randy Heit 6040bc1f84 - Oops, you don't want the zdoom.sln from the previous revision.
SVN r488 (trunk)
2007-02-19 23:58:16 +00:00
Randy Heit 99df21c901 - Fixed: Playing a demo in windowed mode no longer grabs the mouse.
SVN r487 (trunk)
2007-02-19 23:48:52 +00:00
Randy Heit ea0c7395de - Added a new fixrtext tool that sets the IMAGE_SCN_MEM_WRITE flag for
.rtext files in the assembly object files. Now I can avoid doing this at
  runtime, which means that ZDoom is now UPX-compatible if anyone wants to
  pack it.
  
  You will need to do a rebuild or manually delete the old assembly .obj files
  for the first build from this revision to succeed, since there are no
  changes to the assembly files themselves, and the build process will not be
  able to automatically detect that they need to be rebuilt.


SVN r473 (trunk)
2007-02-03 02:51:13 +00:00
Randy Heit c412b42703 - Fixed: cycle_t was still a DWORD and not a QWORD under GCC.
- The stat meters now return an FString instead of sprintfing into a fixed
  output buffer.
- NOASM is now automatically defined when compiling for a non-x86 target.
- Some changes have been made to the integral types in doomtype.h:
  - For consistancy with the other integral types, byte is no longer a
    synonym for BYTE.
  - Most uses of BOOL have been change to the standard C++ bool type. Those
    that weren't were changed to INTBOOL to indicate they may contain values
    other than 0 or 1 but are still used as a boolean.
  - Compiler-provided types with explicit bit sizes are now used. In
    particular, DWORD is no longer a long so it will work with both 64-bit
    Windows and Linux.
  - Since some files need to include Windows headers, uint32 is a synonym
    for the non-Windows version of DWORD.
- Removed d_textur.h. The pic_t struct it defined was used nowhere, and that
  was all it contained.


SVN r326 (trunk)
2006-09-14 00:02:31 +00:00
Randy Heit ed12bdc0f4 - Switched to IJG code for reading JPEG images. I have included a stripped-
down version of the library with the ZDoom source. (It actually uses less
  space than zlib now.) Unix users probably ought to use the system-supplied
  libjpeg instead. I modified Makefile.linux to hopefully do that. I'm sure
  Jim or someone will correct me if it doesn't actually work.


SVN r293 (trunk)
2006-08-16 18:08:39 +00:00
Randy Heit c54f2f66fc - Unlimited the monster pain sounds in Hexen after playing as the Cleric a
while and killing centaurs with the flechette.
- Fixed: Moving to an old level in a hub caused the old player's inventory to
  spawn owned by the current player (but still hanging off the old player), so
  the game would hang when trying to delete it.
- Modified re2c so that it doesn't add a date to the file it generates. Thus,
  if it regenerates a file during a full rebuild, SVN won't see it as a change.
  Also updated it to 0.10.5.
- Fixed: SC_GetString() did not properly terminate sc_String when the last
  token in the file had no white space after it. Since I could not actually
  find the problem (it works fine in debug mode and I saw no logic errors),
  I decided to take this opportunity to reimplement it using an re2c-generated
  scanner. Now it's 1.6x faster than before and correctness is easier to
  verify.
- Fixed: FMODSoundRenderer::Shutdown() also needs to reset NumChannels.
- Added back the Manifest to zdoom.rc for non-VC8 Windows compilers.
- Fixed MinGW compilation again. Now it uses the same method as Makefile.linux
  to find all the source files so that it doesn't need to be manually updated
  each time source files are added or removed.
- Added the SVN revision number to the version string. A new tool is used to
  obtain this information from the svnversion command and write it into a
  header file. If you don't have the svn command line tools installed or didn't
  check it out from the repository, you can still build. I added some rules for
  this to Makefile.linux, and I assume they work because they do for
  Makefile.mingw.
- Fixed: MIDISong2 did not delete MusHeader in its destructor.


SVN r200 (trunk)
2006-06-20 20:30:39 +00:00
Randy Heit f50b284fda SVN r142 (trunk) 2006-05-24 15:31:21 +00:00
Randy Heit cb18719d05 - Fixed: The new sound pausing on menu open interrupted Strife conversations.
- Did some very preliminary support for x64 compiling.
- Now I see why makewad is using the __fastcall calling convention by default:
  Because the release zlib is built with it as well.
- Fixed: Conversion from 'const char *' to 'char *' in DEM_SAVEGAME case in
  Net_DoCommand().
- Updated the project files for Visual C++ 2005.


SVN r138 (trunk)
2006-05-23 04:25:49 +00:00
Randy Heit 7e7ab6b4ec - Fixed compilation with mingw again.
- Added multiple-choice sound sequences. These overcome one of the major
  deficiences of the Hexen-inherited SNDSEQ system while still being Hexen
  compatible: Custom door sounds can now use different opening and closing
  sequences, for both normal and blazing speeds.
- Added a serializer for TArray.
- Added a countof macro to doomtype.h. See the1's blog to find out why
  it's implemented the way it is.
    <http://blogs.msdn.com/the1/articles/210011.aspx>
- Added a new method to FRandom for getting random numbers larger than 255,
  which lets me:
- Fixed: SNDSEQ delayrand commands could delay for no more than 255 tics.
- Fixed: If you're going to have sector_t.SoundTarget, then they need to
  be included in the pointer cleanup scans.
- Ported back newer name code from 2.1.
- Fixed: Using -warp with only one parameter in Doom and Heretic to
  select a map on episode 1 no longer worked.
- New: Loading a multiplayer save now restores the players based on
  their names rather than on their connection order. Using connection
  order was sensible when -net was the only way to start a network game,
  but with -host/-join, it's not so nice. Also, if there aren't enough
  players in the save, then the extra players will be spawned normally,
  so you can continue a saved game with more players than you started it
  with.
- Added some new SNDSEQ commands to make it possible to define Heretic's
  ambient sounds in SNDSEQ: volumerel, volumerand, slot, randomsequence,
  delayonce, and restart. With these, it is basically possible to obsolete
  all of the $ambient SNDINFO commands.
- Fixed: Sound sequences would only execute one command each time they were
  ticked.
- Fixed: No bounds checking was done on the volume sound sequences played at.
- Fixed: The tic parameter to playloop was useless and caused it to
  act like a redundant playrepeat. I have removed all the logic that
  caused playloop to play repeating sounds, and now it acts like an
  infinite sequence of play/delay commands until the sequence is
  stopped.
- Fixed: Sound sequences were ticked every frame, not every tic, so all
  the delay commands were timed incorrectly and varied depending on your
  framerate. Since this is useful for restarting looping sounds that got
  cut off, I have not changed this. Instead, the delay commands now
  record the tic when execution should resume, not the number of tics
  left to delay.


SVN r57 (trunk)
2006-04-21 01:22:55 +00:00
Christoph Oelckers 8a7ba616f4 SVN r46 (trunk) 2006-04-15 15:00:29 +00:00
Randy Heit cf11cbdb30 Directory restructuring to make it easier to version projects that don't build zdoom.exe.
SVN r4 (trunk)
2006-02-24 04:48:15 +00:00