Permalink
Switch branches/tags
Nothing to show
Commits on Aug 2, 2018
  1. Calculate bounds for unanimated IQM models

    zturtleman committed Aug 2, 2018
    Bounds are optional for animated IQM models but are not possible to
    include with unanimated models (seems intended for use with separate
    model containing animations and bounds). Calculating bounds for
    unanimated IQM models fixes culling and head model on HUD which
    calculates position from model bounds.
Commits on Jul 31, 2018
  1. Fix axis returned by IQM's LerpTag

    zturtleman committed Jul 31, 2018
    The axis returned for IQM tag was the animation's joint rotation without
    the base frame joint rotation. It only worked correct for models that
    did not rotate the base frame joints.
Commits on Jul 27, 2018
  1. OpenGL2: Add GPU vertex skinning for IQM models

    zturtleman committed Jul 27, 2018
    Using GPU vertex skinning is significantly faster than CPU vertex
    skinning. Especially since OpenGL2 has to run R_VaoPackNormal() and
    R_VaoPackTangent() each vertex each frame which causes CPU vertex
    skinning to be significantly slower than OpenGL1 renderer.
  2. Improve IQM CPU vertex skinning performance

    zturtleman committed Jul 27, 2018
    Only calculate vertex blend matrix for each unique bone indexes/weights
    combination once per-surface instead of recalculating for each vertex.
    For best performance the model surfaces needs to use few vertex bone
    indexes and weights combinations.
    
    Unroll loops so GCC better optimizes them.
    
    In my tests drawing animated IQM may take 50% as long in opengl1 and
    70% as long in opengl2. It will vary by model though and might not
    help much at all.
    
    Made unanimated IQM models skip matrix math altogether.
  3. Improve IQM loading

    zturtleman committed Jul 27, 2018
    - Only allocate memory for vertex arrays that are present in the IQM
    file and are actually used (may not have colors or blend index/weights,
    don't load tangents in opengl1). (Colors is fixed to next commit.)
    - Explicitly handle loading IQM files without meshes (bones only).
    - Better IQM validation. Header data offset 0 mean data is not present
    in file. Check if required vertex arrays are present.
    
    This involved a lot of white space changes and moving code around.
  4. Fix IQM root joint backlerp when joint number is more than 0

    zturtleman committed Jul 27, 2018
    Backlerp for root joint (joint with no parent) was always applied to
    joint 0. This is an issue when a model has multiple root joints.
Commits on Jul 21, 2018
  1. OpenGL2: Misc fixes and cleanup

    zturtleman committed Jul 21, 2018
    Fix two constants in GLSL shaders. Remove f suffix from float and fix
    int to float assignment. They were causing shader compile errors in
    OpenGL ES 2 context.
    
    Remove disabling clip plane. Clip plane is unused and never enabled in
    the opengl2 renderer. Remove disabling it to avoid causing a GL error
    when using OpenGL 3.2 core profile or OpenGL ES.
    
    Make VAO cache vertex stride be size of srfVert_t since that is what
    is uploaded to the GPU. No behavior change. There is a disabled debug
    id in srfVert_t though which if enabled changes srfVert_t size.
  2. OpenGL2: Fix world VAO cache drawing when glIndex_t is unsigned short

    zturtleman committed Jul 21, 2018
    OpenGL ES is only required to support unsigned short for element buffer
    values.
    
    R_DrawElements() firstIndex argument was glIndex_t which caused element
    indexes to wrap around to 0 when glIndex_t is an unsigned short.
    (glIndex_t is an index into the vertexes buffer, not element buffer.)
    Change it to 'int' like tess.firstIndex which is passed to
    R_DrawElements().
    
    World VAO cache buffer size allowed storing more vertexes than unsigned
    short glIndex_t could reference. This resulted in the vertex indexes in
    the element buffer wrapping around to 0.
  3. Don't check fixed function GL extensions when using shader pipeline

    zturtleman committed Jul 21, 2018
    GL_TEXTURE_UNITS_ARB is not part of OpenGL ES 2 API and sets GL error.
    It's not part of OpenGL 3.2 core profile either.
  4. Load OpenGL ES 2.0 function procs

    zturtleman committed Jul 21, 2018
    Load functions procs supported by OpenGL ES 2.0, though there is not a
    compatible renderer yet. Change argument for GLimp_Init from coreContext
    to fixedFunction.
  5. Don't load non-core GL functions for OpenGL 3.2 core context

    zturtleman committed Jul 21, 2018
    Also declare the GL functions in tr_local.h so there is compile error
    for non-core GL functions instead of SEGFAULT from dereferencing a NULL
    pointer.
    
    Disable the non-functional stencil shadow code that hasn't been updated
    to use OpenGL 3.2 core compatible drawing.
  6. OpenGL1: Use RE_UploadCinematic() instead of duplicate code

    zturtleman committed Jul 21, 2018
    Already done in opengl2 renderer.
  7. Don't upload 8 bit grayscale images as 16 bit luminance

    zturtleman committed Jul 21, 2018
    Using more color bits than the source image provides shouldn't improve
    the quality.
  8. Fix renderer not clearing some GL extension variables at vid_restart

    zturtleman committed Jul 21, 2018
    If renderer is compiled into client (USE_RENDERER_DLOPEN=0) and after
    start up set r_allowExtension to 0 and run vid_restart, some extension
    were still used.
Commits on Jun 25, 2018
Commits on Jun 12, 2018
  1. Allow pkg-config binary to be overridden with PKG_CONFIG

    smcv authored and timangus committed Jun 12, 2018
    This is one of the de facto standard interfaces used in Linux
    distributions for cross-compilation (alongside overriding CC and
    similar variables), and in particular is used in Debian and its
    derivatives.
    
    Signed-off-by: Simon McVittie <smcv@debian.org>
Commits on Jun 10, 2018
  1. Fix in_restart causing fatal error while video is shutdown

    zturtleman committed Jun 10, 2018
    Connecting to a server running a different fs_game and using a
    autoexec.cfg containing in_restart would hit a fatal error in IN_Init().
    
        IN_Init called before SDL_Init( SDL_INIT_VIDEO )
    
    Reported by smokey2k on the ioquake3 forum.
Commits on Jun 3, 2018
  1. Fix Linux uninstaller redirecting stderr to stdout in preuninstall.sh

    zturtleman committed Jun 3, 2018
    Last commit accidently made stderr redirect to stdout tty instead of
    /dev/null.
    
    Reported by @illwieckz.
  2. Fix Linux uninstaller requiring Bash

    zturtleman committed Jun 3, 2018
    Linux loki-setup uninstaller is failing on distros that have /bin/sh
    linked to Dash instead of Bash. Use standard shell method for
    redirecting stdout and stderr instead of a Bash specific method.
Commits on May 28, 2018
Commits on May 22, 2018
  1. Fix client kicked as unpure when missing the latest cgame/ui pk3s

    zturtleman committed May 22, 2018
    In 2013 ioquake3 stopped referencing the pk3 file that qagame.qvm was
    loaded from. This had the unintended side affect of causing
    non-dedicated pure servers to no longer reference a pk3 that only
    contains the three QVM files.
    
    Non-dedicated pure servers did not reference the pk3 containing the
    latest cgame.qvm so if client did not have the pk3 file they were kicked
    as unpure instead of the client trying to download the pk3 file.
    
    Also make server touch ui.qvm since it's required to pass pure check and
    may be separate from cgame.qvm.
Commits on May 15, 2018
Commits on May 14, 2018
  1. Fix console offset while Team Arena voiceMenu is open

    zturtleman committed May 14, 2018
    Fix console text being on top of the Tema Arena voice chat head in
    screen resolutions higher than 640x480.
Commits on May 12, 2018
  1. Use SDL 2.0.1 headers for macOS ppc64

    zturtleman committed May 12, 2018
    The libSDL2-2.0.0.dylib in repo doesn't support ppc64 though.
    
    Based on patch by MAN-AT-ARMS.
  2. Isolate the Altivec code so non-Altivec PPC targets can use the same …

    smcv authored and rcgordon committed May 12, 2018
    …binary.
    
    Moved all the code using Altivec intrinsics to separate files. This 
    means we can optionally use GCC's -maltivec on just these files, which
    are chosen at runtime if the CPU supports Altivec, and compile the rest
    without it, making a single binary that has Altivec optimizations but
    can still work on G3.
    
    Unlike SSE and similar extensions on x86, there does not seem to be
    a way to enable conditional, targeted use of Altivec based on runtime
    detection (which is what ioquake3 wants to do) without also giving the
    compiler permission to use Altivec in code generation; so to not crash
    on CPUs that do not implement Altivec, we'll have to turn it off
    altogether, except in translation units that are only entered when
    runtime Altivec detection is successful.
    
    This has been tested on Linux PPC (on an Altivec-enabled CPU),
    but we may need further work after testing trickles out to other
    PowerPC devices and ancient Mac OS X builds.
    
    I did a little work on this patch, but the majority of the effort belongs 
    to Simon McVittie (thanks!).
  3. Don't allow SDL audio capture using pulseaudio

    zturtleman committed May 12, 2018
    When you start recording using SDL pulseaudio driver the client sends
    all audio captured while not recording. 240 milliseconds of audio is
    sent each frame until the capture buffer is empty. This is a problem for
    privacy and causes confusing to debug VoIP playback issues on other
    clients connected to server and when playing back demos.
  4. OpenGL2: Fix parsing specularScale in shaders

    zturtleman committed May 12, 2018
    Fix specularScale <metallic> <smoothness> with r_pbr 1 which has been
    broken since r_pbr was implemented in 2016.
    
    Fix specularScale <r> <g> <b> <gloss> setting b to gloss and leaving
    gloss as 0 since it was implemented in 2014.
Commits on May 6, 2018
  1. Fix duplicate bots displayed in Team Arena ingame add bot menu

    zturtleman committed May 6, 2018
    The key handler allowed going 2 beyond the end of the bot list and the
    display function clamped to 0 causing the first bot to be shown 3 times.
    
    Attempting to add the bot in gametypes < GT_TEAM would fallback to
    Sarge in UI_GetBotNameByNumber() (who isn't the first bot) and gametypes
    >= GT_TEAM would access characterList past known values (typically NULL
    but if teaminfo.txt contained 63 characters it would access out of
    bounds memory).
Commits on May 3, 2018
  1. Fix not closing description.txt and fix path seperator

    zturtleman committed May 3, 2018
    0 length description.txt files were not closed.
Commits on May 2, 2018
  1. Improvements for dedicated camera followers (team follow1/2)

    zturtleman committed Apr 29, 2018
    Switching to dedicated camera follower with no possible players to
    follow would spawn at the intermission point and display "connection
    interrupted" HUD message. Pmove() was not run for the client so
    ps.commandTime was too far behind. I made it so that dedicated camera
    followers and scoreboard run Pmove() but cannot move (PM_FREEZE).
    
    When all players possible to follow leave, the dedicated camera follower
    would continue to display the old player state of the player they were
    following (along with "connection interrupted" HUD message). Unlike the
    regular case of a spectator following a specific player, dedicated
    camera followers did not reset their player state to the intermission
    point after the followed player was no longer valid.
    
    Now a client can be set as 'team follow1' to automatically switch
    between displaying the intermission point and following a player when
    possible.
Commits on May 1, 2018
  1. Make s_useOpenAL be CVAR_LATCH

    zturtleman committed Apr 26, 2018
    After changing s_useOpenAL the sound needs to be restarted (snd_restart)
    for it to take affect.
Commits on Apr 26, 2018
  1. Fix clearing keys for control in Team Arena UI

    zturtleman committed Apr 26, 2018
    When a control is selected for binding a key, pressing backspace would
    clear the displayed keys in the menu but not actually unbind the keys.