mirror of
https://github.com/mupen64plus/mupen64plus-video-glide64mk2.git
synced 2025-04-02 10:51:54 -04:00
Compare commits
42 commits
Author | SHA1 | Date | |
---|---|---|---|
|
39a8c11e8a | ||
|
1fd2673260 | ||
|
d2b699ce9e | ||
|
c7af0be397 | ||
|
2e2704194a | ||
|
368c3e7611 | ||
|
992b594207 | ||
|
140ce72829 | ||
|
347b4e48c9 | ||
|
bd747ff3e6 | ||
|
b44b0d1c43 | ||
|
d900f21915 | ||
|
5fb3193cff | ||
|
497a8255ac | ||
|
45a25a93ac | ||
|
a07050d143 | ||
|
12bf43103e | ||
|
95229fed6d | ||
|
340ab2c402 | ||
|
79809753e8 | ||
|
bab96abd07 | ||
|
3266c61cf2 | ||
|
adb41a9e51 | ||
|
5ac60b38e2 | ||
|
f0c92d93a2 | ||
|
aecf15ec20 | ||
|
629f2e99a3 | ||
|
2f9ccb13b3 | ||
|
0274f4e64b | ||
|
c277ac38e4 | ||
|
b4d4503dd0 | ||
|
06b38186a8 | ||
|
3f7640881d | ||
|
8601df82e0 | ||
|
c31ce5ca6e | ||
|
a91b7c9bed | ||
|
a61f12f78c | ||
|
1931ececfc | ||
|
93e506bd18 | ||
|
5cbf483d20 | ||
|
7c74a052c5 | ||
|
409eef76c9 |
49 changed files with 7559 additions and 719 deletions
159
.github/workflows/build.yml
vendored
Normal file
159
.github/workflows/build.yml
vendored
Normal file
|
@ -0,0 +1,159 @@
|
|||
name: Glide64mk2
|
||||
|
||||
on:
|
||||
push:
|
||||
paths-ignore:
|
||||
- '.{gitattributes,gitignore,travis.yml}'
|
||||
- '*.md,appveyor.yml,README'
|
||||
pull_request:
|
||||
paths-ignore:
|
||||
- '.{gitattributes,gitignore,travis.yml}'
|
||||
- '*.md,appveyor.yml,README'
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
|
||||
Linux:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- cc: GCC
|
||||
arch: x64
|
||||
- cc: GCC
|
||||
arch: x86
|
||||
- cc: Clang
|
||||
arch: x64
|
||||
- cc: Clang
|
||||
arch: x86
|
||||
name: Linux / ${{ matrix.cc }} / ${{ matrix.arch }}
|
||||
runs-on: ubuntu-22.04
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Get build dependencies and arrange the environment
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
export C_CLANG_SUFFIX="-15" C_GCC_SUFFIX="-12"
|
||||
export BUILD_DEPS="libgl1-mesa-dev libpng-dev libsdl2-dev zlib1g-dev"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_install_ubuntu_deps.sh ${{ matrix.arch }} ${{ matrix.cc }}
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
export C_CLANG_SUFFIX="-15" C_GCC_SUFFIX="-12"
|
||||
export OPTFLAGS="-O2 -flto -msse2"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_build.sh ${{ matrix.arch }} ${{ matrix.cc }} makepkg
|
||||
- name: Upload artifact
|
||||
if: matrix.cc == 'GCC'
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*.tar.gz
|
||||
|
||||
MSYS2:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- cc: GCC
|
||||
arch: x64
|
||||
cross: x86_64
|
||||
env: MINGW64
|
||||
- cc: GCC
|
||||
arch: x86
|
||||
cross: i686
|
||||
env: MINGW32
|
||||
name: Windows / MSYS2 ${{ matrix.cc }} / ${{ matrix.arch }}
|
||||
runs-on: windows-2022
|
||||
defaults:
|
||||
run:
|
||||
shell: msys2 {0}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: ${{ matrix.env }}
|
||||
update: true
|
||||
install: >-
|
||||
git
|
||||
libtool
|
||||
make
|
||||
mingw-w64-${{ matrix.cross }}-gcc
|
||||
mingw-w64-${{ matrix.cross }}-toolchain
|
||||
mingw-w64-${{ matrix.cross }}-glew
|
||||
mingw-w64-${{ matrix.cross }}-libpng
|
||||
mingw-w64-${{ matrix.cross }}-ntldd
|
||||
mingw-w64-${{ matrix.cross }}-SDL2
|
||||
mingw-w64-${{ matrix.cross }}-zlib
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
export OPTFLAGS="-O2 -flto -msse2"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_build.sh ${{ matrix.arch }} ${{ matrix.cc }}
|
||||
- name: Backup dependencies, etc...
|
||||
run: |
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_backup_mingw_deps.sh ${{ matrix.env }}
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*
|
||||
|
||||
MSVC:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- toolset: v143
|
||||
arch: x64
|
||||
vs: 2022
|
||||
- toolset: v141_xp
|
||||
arch: x86
|
||||
vs: 2019
|
||||
name: Windows / MSVC with ${{ matrix.toolset }} / ${{ matrix.arch }}
|
||||
runs-on: windows-${{ matrix.vs }}
|
||||
defaults:
|
||||
run:
|
||||
shell: cmd
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: microsoft/setup-msbuild@v2
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ..\mupen64plus-core
|
||||
set TOOLSET=${{ matrix.toolset }}
|
||||
.\..\mupen64plus-core\.github\workflows\scripts\ci_msvc_build.cmd ${{ matrix.arch }}
|
||||
- name: Backup dependencies, etc...
|
||||
run: |
|
||||
.\..\mupen64plus-core\.github\workflows\scripts\ci_backup_msvc_deps.cmd ${{ matrix.arch }} SDL2.dll
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*
|
||||
|
||||
Nightly-build:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.ref_name == 'master'
|
||||
needs: [Linux, MSYS2, MSVC]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: binaries
|
||||
- name: Get some tools
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install hashdeep
|
||||
- name: Creating new artifacts and update nightly-build
|
||||
run: |
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_nightly_artifacts.sh
|
||||
- name: Nightly-build
|
||||
uses: ncipollo/release-action@v1
|
||||
with:
|
||||
prerelease: true
|
||||
allowUpdates: true
|
||||
removeArtifacts: true
|
||||
replacesArtifacts: false
|
||||
tag: nightly-build
|
||||
artifacts: pkg/*
|
155
.github/workflows/schedule.yml
vendored
Normal file
155
.github/workflows/schedule.yml
vendored
Normal file
|
@ -0,0 +1,155 @@
|
|||
name: Glide64mk2 - Scheduled
|
||||
|
||||
on:
|
||||
schedule:
|
||||
- cron: '25 14 21 * *'
|
||||
|
||||
jobs:
|
||||
|
||||
Linux:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- cc: GCC
|
||||
arch: x64
|
||||
- cc: GCC
|
||||
arch: x86
|
||||
- cc: Clang
|
||||
arch: x64
|
||||
- cc: Clang
|
||||
arch: x86
|
||||
name: Linux / ${{ matrix.cc }} / ${{ matrix.arch }}
|
||||
runs-on: ubuntu-22.04
|
||||
if: github.repository == 'mupen64plus/mupen64plus-video-glide64mk2'
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Get build dependencies and arrange the environment
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
export C_CLANG_SUFFIX="-15" C_GCC_SUFFIX="-12"
|
||||
export BUILD_DEPS="libgl1-mesa-dev libpng-dev libsdl2-dev zlib1g-dev"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_install_ubuntu_deps.sh ${{ matrix.arch }} ${{ matrix.cc }}
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
export C_CLANG_SUFFIX="-15" C_GCC_SUFFIX="-12"
|
||||
export OPTFLAGS="-O2 -flto -msse2"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_build.sh ${{ matrix.arch }} ${{ matrix.cc }} makepkg
|
||||
- name: Upload artifact
|
||||
if: matrix.cc == 'GCC'
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*.tar.gz
|
||||
|
||||
MSYS2:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- cc: GCC
|
||||
arch: x64
|
||||
cross: x86_64
|
||||
env: MINGW64
|
||||
- cc: GCC
|
||||
arch: x86
|
||||
cross: i686
|
||||
env: MINGW32
|
||||
name: Windows / MSYS2 ${{ matrix.cc }} / ${{ matrix.arch }}
|
||||
runs-on: windows-2022
|
||||
if: github.repository == 'mupen64plus/mupen64plus-video-glide64mk2'
|
||||
defaults:
|
||||
run:
|
||||
shell: msys2 {0}
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: ${{ matrix.env }}
|
||||
update: true
|
||||
install: >-
|
||||
git
|
||||
libtool
|
||||
make
|
||||
mingw-w64-${{ matrix.cross }}-gcc
|
||||
mingw-w64-${{ matrix.cross }}-toolchain
|
||||
mingw-w64-${{ matrix.cross }}-glew
|
||||
mingw-w64-${{ matrix.cross }}-libpng
|
||||
mingw-w64-${{ matrix.cross }}-ntldd
|
||||
mingw-w64-${{ matrix.cross }}-SDL2
|
||||
mingw-w64-${{ matrix.cross }}-zlib
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
export OPTFLAGS="-O2 -flto -msse2"
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_build.sh ${{ matrix.arch }} ${{ matrix.cc }}
|
||||
- name: Backup dependencies, etc...
|
||||
run: |
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_backup_mingw_deps.sh ${{ matrix.env }}
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*
|
||||
|
||||
MSVC:
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
include:
|
||||
- toolset: v143
|
||||
arch: x64
|
||||
vs: 2022
|
||||
- toolset: v141_xp
|
||||
arch: x86
|
||||
vs: 2019
|
||||
name: Windows / MSVC with ${{ matrix.toolset }} / ${{ matrix.arch }}
|
||||
runs-on: windows-${{ matrix.vs }}
|
||||
if: github.repository == 'mupen64plus/mupen64plus-video-glide64mk2'
|
||||
defaults:
|
||||
run:
|
||||
shell: cmd
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- uses: microsoft/setup-msbuild@v2
|
||||
- name: Build and related stuff, backup binaries
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ..\mupen64plus-core
|
||||
set TOOLSET=${{ matrix.toolset }}
|
||||
.\..\mupen64plus-core\.github\workflows\scripts\ci_msvc_build.cmd ${{ matrix.arch }}
|
||||
- name: Backup dependencies, etc...
|
||||
run: |
|
||||
.\..\mupen64plus-core\.github\workflows\scripts\ci_backup_msvc_deps.cmd ${{ matrix.arch }} SDL2.dll
|
||||
- name: Upload artifact
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: ${{ env.PKG_NAME }}
|
||||
path: pkg/*
|
||||
|
||||
Nightly-build:
|
||||
runs-on: ubuntu-latest
|
||||
if: github.ref_name == 'master'
|
||||
needs: [Linux, MSYS2, MSVC]
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
- name: Download artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
path: binaries
|
||||
- name: Get some tools
|
||||
run: |
|
||||
git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ../mupen64plus-core
|
||||
sudo apt-get update
|
||||
sudo apt-get -y install hashdeep
|
||||
- name: Creating new artifacts and update nightly-build
|
||||
run: |
|
||||
./../mupen64plus-core/.github/workflows/scripts/ci_nightly_artifacts.sh
|
||||
- name: Nightly-build
|
||||
uses: ncipollo/release-action@v1
|
||||
with:
|
||||
prerelease: true
|
||||
allowUpdates: true
|
||||
removeArtifacts: true
|
||||
replacesArtifacts: false
|
||||
tag: nightly-build
|
||||
artifacts: pkg/*
|
|
@ -10,8 +10,6 @@ addons:
|
|||
- git
|
||||
- libsdl1.2-dev
|
||||
- libsdl2-dev
|
||||
- libboost-filesystem-dev
|
||||
- libboost-system-dev
|
||||
- libgl1-mesa-dev
|
||||
- libpng-dev
|
||||
- pkg-config
|
||||
|
@ -43,7 +41,6 @@ matrix:
|
|||
- sudo apt-get update -qq
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-gcc
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-sdl2
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-boost
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-pthreads
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-zlib
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-i686-w64-mingw32.shared-libpng
|
||||
|
@ -63,7 +60,6 @@ matrix:
|
|||
- sudo apt-get update -qq
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-gcc
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-sdl2
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-boost
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-pthreads
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-zlib
|
||||
- sudo apt-get -y --allow-unauthenticated install mxe-x86-64-w64-mingw32.shared-libpng
|
||||
|
|
82
RELEASE
82
RELEASE
|
@ -1,9 +1,85 @@
|
|||
Mupen64Plus-Video-Glide64mk2 RELEASE
|
||||
-------------------------------------
|
||||
|
||||
Mupen64Plus-Video-Glide64mk2 v2.5.9 - February 10, 2019
|
||||
-------------------------------------------------------
|
||||
- *** BETA RELEASE *** For Testing Only ***
|
||||
-----------------------------------------------------
|
||||
# Mupen64Plus-Video-Glide64mk2 v2.6.0 - July 14, 2024
|
||||
|
||||
## Merged PRs
|
||||
|
||||
* [132](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/132): CI/CD: Update to generic scripts, independent schedule, etc
|
||||
* [130](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/130): Remove Boost dependency
|
||||
* [129](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/129): Hotfix building with Boost v1.85.0
|
||||
* [125](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/125): CI/CD: Fixes Ubuntu i386 builds, among other changes
|
||||
* [124](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/124): CI/CD: Integrate scheduled builds and other...
|
||||
* [123](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/123): rdp: Avoid signed overflow during texture block loading
|
||||
* [122](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/122): CI/CD: Update MSVC
|
||||
* [121](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/121): CI/CD: Update
|
||||
* [118](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/118): CI/CD: Implement GitHub Actions and public nightly builds
|
||||
* [117](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/117): Add RISC-V Support
|
||||
* [115](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/115): build: Allow out of tree builds.
|
||||
* [111](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/111): Allow non-default compilers without resorting to symbolic links
|
||||
* [110](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/110): Allow to set custom platform toolset from commands
|
||||
* [109](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/109): Changes to have more generic project files
|
||||
* [106](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/106): Fix clang errors
|
||||
* [105](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/105): Add ppc64le support
|
||||
|
||||
|
||||
## Closed Issues
|
||||
|
||||
* [131](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/131): ci: Build failure
|
||||
* [128](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/128): Build failure with Boost 1.85.0
|
||||
* [127](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/127): Current glide64mk2 is incompatible with RMG. Can someone make a new build that works? Needs an update.
|
||||
* [126](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/126): Use `GL_NUM_EXTENSIONS` and `glGetStringi` to check OpenGL extensions
|
||||
* [77](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/77): Paper Mario Star spirit text missing
|
||||
* [120](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/120): Super Mario 64: Texture pixels appear to be swapped with adjacent pixels
|
||||
* [90](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/90): Unable to compile on MSYS2
|
||||
* [114](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/114): Unable to launch any games with plugin
|
||||
|
||||
|
||||
## Top Contributors (2 or more commits)
|
||||
1. Jj0YzL5nvJ
|
||||
2. richard42
|
||||
3. GhostlyDark
|
||||
4. Gillou68310
|
||||
|
||||
|
||||
---------------------------------------------------------
|
||||
# Mupen64Plus-Video-Glide64mk2 v2.5.9 - February 10, 2019
|
||||
|
||||
## Merged PRs
|
||||
|
||||
* [102](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/102): Added support for aarch64
|
||||
* [101](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/101): fix presumed off-by-one bug in TxQuantize::quantize
|
||||
* [99](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/99): Remove MAX_NUMCORE.
|
||||
* [98](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/98): Warnings
|
||||
* [96](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/96): Remove 'register' storage class specifier.
|
||||
* [95](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/95): Use debug callback instead of stdout
|
||||
* [94](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/94): Update homepage links
|
||||
* [92](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/92): Initialize glew before trying to use unresolved symbols
|
||||
* [91](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/91): Build MXE targets as additional tests in travis build matrix
|
||||
* [89](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/89): Use uintptr_t type for pointer to integer conversion.
|
||||
* [88](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/88): Fix compilation on clang. Fixes issue 87.
|
||||
* [86](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/86): Use faster container based Travis CI
|
||||
* [79](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/79): Add Zelda MM ucode from GLideN64
|
||||
* [78](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/78): Don't use SSE on PowerPC.
|
||||
* [70](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/70): Use Ubuntu Trusty as base system for Travis CI
|
||||
* [69](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/69): Add raspberry pi build option
|
||||
* [65](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/65): Fix black screen when wrpFBO is set to False
|
||||
* [64](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/64): Added x64 configuration to VisualStudio2013 project file
|
||||
* [59](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/59): Remove unnecessary OpenBSD warning.
|
||||
* [57](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/pull/57): flto reverts, second attempt
|
||||
|
||||
|
||||
## Closed Issues
|
||||
|
||||
* [77](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/77): Paper Mario Star spirit text missing
|
||||
* [103](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/103): Build fails in Visual Studio 2013
|
||||
* [100](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/100): potential issue in TxQuantize.cpp
|
||||
* [87](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/87): Change __builtin_ia32_storeups() use in favor of _mm_storeu_ps()
|
||||
* [85](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/85): Build fails on OpenBSD
|
||||
* [58](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/58): Please use regression test with GCC/Clang sanitizer
|
||||
* [54](https://github.com/mupen64plus/mupen64plus-video-glide64mk2/issues/54): Different colors in kirby arms
|
||||
|
||||
|
||||
Mupen64Plus-Video-Glide64mk2 v2.5 - April 26, 2015
|
||||
--------------------------------------------------
|
||||
|
|
43
appveyor.yml
Normal file
43
appveyor.yml
Normal file
|
@ -0,0 +1,43 @@
|
|||
version: 1.0.{build}
|
||||
|
||||
image: Visual Studio 2022
|
||||
|
||||
skip_tags: true
|
||||
|
||||
skip_commits:
|
||||
files:
|
||||
- '**/*.md'
|
||||
- .github/
|
||||
- data/*
|
||||
- .gitattributes
|
||||
- .gitignore
|
||||
- .travis.yml
|
||||
- README
|
||||
|
||||
configuration:
|
||||
- Release
|
||||
platform:
|
||||
- Win32
|
||||
- x64
|
||||
|
||||
before_build:
|
||||
- git tag --delete nightly-build
|
||||
- git clone --depth 1 https://github.com/mupen64plus/mupen64plus-win32-deps.git ..\mupen64plus-win32-deps
|
||||
- git clone --depth 1 https://github.com/mupen64plus/mupen64plus-core.git ..\mupen64plus-core
|
||||
|
||||
build_script:
|
||||
- msbuild projects\msvc\mupen64plus-video-glide64mk2.vcxproj /p:Configuration=%configuration%;Platform=%platform%
|
||||
|
||||
after_build:
|
||||
- ps: $env:rev1 = git describe --tags
|
||||
- set rev2=%platform%
|
||||
- if "%rev2%"=="Win32" set rev2=x86
|
||||
- set filepkg=mupen64plus-video-glide64mk2_v%rev1%_%rev2%
|
||||
- cd projects\msvc\%platform%\%configuration%
|
||||
- copy *.dll ..\..\..\..\data
|
||||
- cd ..\..\..\..\data
|
||||
- 7z a -t7z ..\build\%filepkg%.7z *
|
||||
|
||||
artifacts:
|
||||
- path: build\$(filepkg).7z
|
||||
name: $(filepkg)
|
|
@ -1,413 +0,0 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{A4D13408-A794-4199-8FC7-4A9A32505005}</ProjectGuid>
|
||||
<RootNamespace>n64Glide</RootNamespace>
|
||||
<ProjectName>mupen64plus-video-glide64mk2</ProjectName>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<PlatformToolset>v120_xp</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<UseOfMfc>false</UseOfMfc>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<PlatformToolset>v120</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
<Import Project="$(VCTargetsPath)Microsoft.CPP.UpgradeFromVC60.props" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>10.0.40219.1</_ProjectFileVersion>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">true</LinkIncremental>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</LinkIncremental>
|
||||
<OutDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(SolutionDir)$(Configuration)\</OutDir>
|
||||
<IntDir Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(Configuration)\</IntDir>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">false</LinkIncremental>
|
||||
<LinkIncremental Condition="'$(Configuration)|$(Platform)'=='Release|x64'">false</LinkIncremental>
|
||||
<GenerateManifest Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">true</GenerateManifest>
|
||||
<GenerateManifest Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</GenerateManifest>
|
||||
<IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">F:\Code\Third Party\boost;$(IncludePath)</IncludePath>
|
||||
<IncludePath Condition="'$(Configuration)|$(Platform)'=='Release|x64'">F:\Code\Third Party\boost;$(IncludePath)</IncludePath>
|
||||
<LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">F:\Code\Third Party\boost\stage\lib;$(LibraryPath)</LibraryPath>
|
||||
<LibraryPath Condition="'$(Configuration)|$(Platform)'=='Release|x64'">F:\Code\Third Party\boost\stage\lib;$(LibraryPath)</LibraryPath>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>Win32</TargetEnvironment>
|
||||
<TypeLibraryName>.\Debug/n64Glide.tlb</TypeLibraryName>
|
||||
<HeaderFileName>
|
||||
</HeaderFileName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\boost-1.57.0\;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Async</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<PrecompiledHeaderOutputFile>.\Debug/n64Glide.pch</PrecompiledHeaderOutputFile>
|
||||
<AssemblerListingLocation>.\Debug/</AssemblerListingLocation>
|
||||
<ObjectFileName>.\Debug/</ObjectFileName>
|
||||
<ProgramDataBaseFileName>.\Debug/</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\boost-1.57.0\boost\libs;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\lib\x86;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\lib\x86;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\lib\x86;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<ProgramDatabaseFile>.\Debug/Glide64.pdb</ProgramDatabaseFile>
|
||||
<ImportLibrary>.\Debug/Glide64.lib</ImportLibrary>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<OutputFile>.\Debug/n64Glide.bsc</OutputFile>
|
||||
</Bscmake>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TypeLibraryName>.\Debug/n64Glide.tlb</TypeLibraryName>
|
||||
<HeaderFileName>
|
||||
</HeaderFileName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\boost-1.57.0\;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;NO_ASM;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Async</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<PrecompiledHeaderOutputFile>.\Debug/n64Glide.pch</PrecompiledHeaderOutputFile>
|
||||
<AssemblerListingLocation>.\Debug/</AssemblerListingLocation>
|
||||
<ObjectFileName>.\Debug/</ObjectFileName>
|
||||
<ProgramDataBaseFileName>.\Debug/</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.18\lib\x64;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\lib\x64;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\lib\x64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<ProgramDatabaseFile>.\Debug/Glide64.pdb</ProgramDatabaseFile>
|
||||
<ImportLibrary>.\Debug/Glide64.lib</ImportLibrary>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<OutputFile>.\Debug/n64Glide.bsc</OutputFile>
|
||||
</Bscmake>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TargetEnvironment>Win32</TargetEnvironment>
|
||||
<TypeLibraryName>.\Release/n64Glide.tlb</TypeLibraryName>
|
||||
<HeaderFileName>
|
||||
</HeaderFileName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<EnableFiberSafeOptimizations>false</EnableFiberSafeOptimizations>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\boost-1.57.0\;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;__VISUALC__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<StringPooling>true</StringPooling>
|
||||
<ExceptionHandling>Async</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
|
||||
<PrecompiledHeaderOutputFile>.\Release/n64Glide.pch</PrecompiledHeaderOutputFile>
|
||||
<AssemblerListingLocation>.\Release/</AssemblerListingLocation>
|
||||
<ObjectFileName>.\Release/</ObjectFileName>
|
||||
<ProgramDataBaseFileName>.\Release/</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\boost-1.57.0\boost\libs;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\lib\x86;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\lib\x86;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\lib\x86;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<ProgramDatabaseFile>$(TargetDir)$(TargetName).pdb</ProgramDatabaseFile>
|
||||
<ImportLibrary>
|
||||
</ImportLibrary>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<IgnoreAllDefaultLibraries>false</IgnoreAllDefaultLibraries>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<OutputFile>.\Release/n64Glide.bsc</OutputFile>
|
||||
</Bscmake>
|
||||
<MASM>
|
||||
<EnableMASM51Compatibility>true</EnableMASM51Compatibility>
|
||||
</MASM>
|
||||
<PostBuildEvent>
|
||||
<Message>Copying shared data and libraries to build directory...</Message>
|
||||
<Command>copy ..\..\data\* "$(OutDir)"</Command>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<MkTypLibCompatible>true</MkTypLibCompatible>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<TypeLibraryName>.\Release/n64Glide.tlb</TypeLibraryName>
|
||||
<HeaderFileName>
|
||||
</HeaderFileName>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<FavorSizeOrSpeed>Speed</FavorSizeOrSpeed>
|
||||
<EnableFiberSafeOptimizations>false</EnableFiberSafeOptimizations>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\boost-1.57.0\;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.18\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;__VISUALC__;NO_ASM;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<StringPooling>true</StringPooling>
|
||||
<ExceptionHandling>Async</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<EnableEnhancedInstructionSet>NotSet</EnableEnhancedInstructionSet>
|
||||
<PrecompiledHeaderOutputFile>.\Release/n64Glide.pch</PrecompiledHeaderOutputFile>
|
||||
<AssemblerListingLocation>.\Release/</AssemblerListingLocation>
|
||||
<ObjectFileName>.\Release/</ObjectFileName>
|
||||
<ProgramDataBaseFileName>.\Release/</ProgramDataBaseFileName>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<OutputFile>$(OutDir)$(TargetName)$(TargetExt)</OutputFile>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.18\lib\x64;..\..\..\mupen64plus-win32-deps\zlib-1.2.8\lib\x64;..\..\..\mupen64plus-win32-deps\SDL-1.2.15\lib\x64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<ProgramDatabaseFile>$(TargetDir)$(TargetName).pdb</ProgramDatabaseFile>
|
||||
<ImportLibrary>
|
||||
</ImportLibrary>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<OutputFile>.\Release/n64Glide.bsc</OutputFile>
|
||||
</Bscmake>
|
||||
<MASM>
|
||||
<EnableMASM51Compatibility>true</EnableMASM51Compatibility>
|
||||
</MASM>
|
||||
<PostBuildEvent>
|
||||
<Message>Copying shared data and libraries to build directory...</Message>
|
||||
<Command>copy ..\..\data\* "$(OutDir)"</Command>
|
||||
</PostBuildEvent>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\src\Glide64\3dmath.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Combine.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Config.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\CRC.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Debugger.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\DepthBufferRender.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\FBtoScreen.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Ini.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Keys.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Main.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\osal_dynamiclib_win32.c" />
|
||||
<ClCompile Include="..\..\src\Glide64\rdp.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\TexBuffer.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\TexCache.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Util.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\Ext_TxFilter.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\fxt1.c">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_algorithm.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_libtxc_dxtn.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\texstore.c">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\wrapper.c">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_2xsai.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_hq2x.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_hq4x.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxDbg.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxFilter.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxFilterExport.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxHiResCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxImage.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxQuantize.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxReSample.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxTexCache.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxUtil.cpp">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLcombiner.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLgeometry.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLglitchmain.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLtextures.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_algorithm.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_common.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_license.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\txc_dxtn.h">
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</ExcludedFromBuild>
|
||||
<ExcludedFromBuild Condition="'$(Configuration)|$(Platform)'=='Release|x64'">true</ExcludedFromBuild>
|
||||
</ClInclude>
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
197
projects/msvc/mupen64plus-video-glide64mk2.vcxproj
Normal file
197
projects/msvc/mupen64plus-video-glide64mk2.vcxproj
Normal file
|
@ -0,0 +1,197 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{A4D13408-A794-4199-8FC7-4A9A32505005}</ProjectGuid>
|
||||
<RootNamespace>mupen64plusvideoglide64mk2</RootNamespace>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(WindowsTargetPlatformVersion)'=='' and '$(VisualStudioVersion)' != '14.0'">
|
||||
<LatestTargetPlatformVersion>$([Microsoft.Build.Utilities.ToolLocationHelper]::GetLatestSDKTargetPlatformVersion('Windows', '10.0'))</LatestTargetPlatformVersion>
|
||||
<WindowsTargetPlatformVersion>$(LatestTargetPlatformVersion)</WindowsTargetPlatformVersion>
|
||||
<TargetPlatformVersion>$(WindowsTargetPlatformVersion)</TargetPlatformVersion>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(PlatformToolset)'=='' or '$(PlatformToolset)'=='v100'" Label="Configuration">
|
||||
<PlatformToolset>$(DefaultPlatformToolset)</PlatformToolset>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<OutDir>$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>$(Platform)\$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<WholeProgramOptimization>true</WholeProgramOptimization>
|
||||
<OutDir>$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>$(Platform)\$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<OutDir>$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>$(Platform)\$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>DynamicLibrary</ConfigurationType>
|
||||
<CharacterSet>MultiByte</CharacterSet>
|
||||
<OutDir>$(SolutionDir)$(Platform)\$(Configuration)\</OutDir>
|
||||
<IntDir>$(Platform)\$(Configuration)\</IntDir>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings" />
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.39\include;..\..\..\mupen64plus-win32-deps\opengl\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_DEBUG;_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL2.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.39\lib\x86;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\lib\x86;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\lib\x86;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.39\include;..\..\..\mupen64plus-win32-deps\opengl\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>_DEBUG;_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;NO_ASM;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL2.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.39\lib\x64;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\lib\x64;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\lib\x64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.39\include;..\..\..\mupen64plus-win32-deps\opengl\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>NDEBUG;_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;__VISUALC__;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL2.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.39\lib\x86;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\lib\x86;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\lib\x86;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<ClCompile>
|
||||
<AdditionalIncludeDirectories>..\..\src\Glide64;..\..\src\Glide64\inc;..\..\src\GlideHQ;..\..\src\GlideHQ\tc-1.1+;..\..\src\Glitch64;..\..\src\Glitch64\inc;..\..\..\mupen64plus-core\src\api;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\include;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\include;..\..\..\mupen64plus-win32-deps\libpng-1.6.39\include;..\..\..\mupen64plus-win32-deps\opengl\include;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>NDEBUG;_VARIADIC_MAX=10;_CRT_SECURE_NO_WARNINGS;__MSC__;WIN32;__VISUALC__;NO_ASM;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<WarningLevel>Level3</WarningLevel>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<FunctionLevelLinking>true</FunctionLevelLinking>
|
||||
<IntrinsicFunctions>true</IntrinsicFunctions>
|
||||
<LanguageStandard>stdcpp17</LanguageStandard>
|
||||
</ClCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>opengl32.lib;glu32.lib;SDL2.lib;libpng16.lib;zlib.lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<AdditionalLibraryDirectories>..\..\..\mupen64plus-win32-deps\libpng-1.6.39\lib\x64;..\..\..\mupen64plus-win32-deps\zlib-1.2.13\lib\x64;..\..\..\mupen64plus-win32-deps\SDL2-2.26.3\lib\x64;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
</Link>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\src\Glide64\3dmath.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Combine.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Config.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\CRC.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Debugger.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\DepthBufferRender.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\FBtoScreen.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Ini.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Keys.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Main.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\osal_dynamiclib_win32.c" />
|
||||
<ClCompile Include="..\..\src\Glide64\rdp.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\TexBuffer.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\TexCache.cpp" />
|
||||
<ClCompile Include="..\..\src\Glide64\Util.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\Ext_TxFilter.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\osal_files_win32.c" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\fxt1.c" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_algorithm.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_libtxc_dxtn.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\texstore.c" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\wrapper.c" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_2xsai.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_hq2x.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_hq4x.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxCache.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxDbg.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxFilter.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxFilterExport.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxHiResCache.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxImage.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxQuantize.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxReSample.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxTexCache.cpp" />
|
||||
<ClCompile Include="..\..\src\GlideHQ\TxUtil.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLcombiner.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLgeometry.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLglitchmain.cpp" />
|
||||
<ClCompile Include="..\..\src\Glitch64\OGLtextures.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_algorithm.h" />
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_common.h" />
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_license.h" />
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\txc_dxtn.h" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets" />
|
||||
</Project>
|
|
@ -19,6 +19,9 @@
|
|||
<Filter Include="GlideHQ\tc-1.1+\s2tc">
|
||||
<UniqueIdentifier>{2cc583d4-7f35-421e-93d1-42b27587c3de}</UniqueIdentifier>
|
||||
</Filter>
|
||||
<Filter Include="GlideHQ\Windows">
|
||||
<UniqueIdentifier>{09258efe-2a3d-4c7c-825f-c2c0881048f0}</UniqueIdentifier>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="..\..\src\GlideHQ\TextureFilters_hq4x.cpp">
|
||||
|
@ -138,6 +141,9 @@
|
|||
<ClCompile Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_libtxc_dxtn.cpp">
|
||||
<Filter>GlideHQ\tc-1.1+\s2tc</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="..\..\src\GlideHQ\osal_files_win32.c">
|
||||
<Filter>GlideHQ\Windows</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClInclude Include="..\..\src\GlideHQ\tc-1.1+\s2tc\s2tc_algorithm.h">
|
|
@ -44,7 +44,6 @@ ifeq ("$(UNAME)","Darwin")
|
|||
OS = OSX
|
||||
SO_EXTENSION = dylib
|
||||
SHARED = -bundle
|
||||
BOOST_SUFFIX = -mt
|
||||
endif
|
||||
ifeq ("$(UNAME)","FreeBSD")
|
||||
OS = FREEBSD
|
||||
|
@ -66,7 +65,6 @@ ifeq ("$(patsubst MINGW%,MINGW,$(UNAME))","MINGW")
|
|||
SO_EXTENSION = dll
|
||||
SHARED = -shared
|
||||
PIC = 0
|
||||
BOOST_SUFFIX = -mt
|
||||
CPPFLAGS += -DNO_FILTER_THREAD
|
||||
endif
|
||||
ifeq ("$(OS)","NONE")
|
||||
|
@ -108,6 +106,15 @@ ifneq ("$(filter ppc64 powerpc64,$(HOST_CPU))","")
|
|||
NO_ASM := 1
|
||||
$(warning Architecture "$(HOST_CPU)" not officially supported.')
|
||||
endif
|
||||
ifneq ("$(filter ppc64le powerpc64le,$(HOST_CPU))","")
|
||||
CPU := PPC
|
||||
ARCH_DETECTED := 64BITS
|
||||
BIG_ENDIAN := 0
|
||||
PIC ?= 1
|
||||
NO_ASM := 1
|
||||
NO_SSE := 1
|
||||
$(warning Architecture "$(HOST_CPU)" not officially supported.')
|
||||
endif
|
||||
ifneq ("$(filter arm%,$(HOST_CPU))","")
|
||||
ifeq ("$(filter arm%b,$(HOST_CPU))","")
|
||||
CPU := ARM
|
||||
|
@ -126,18 +133,27 @@ ifneq ("$(filter aarch64,$(HOST_CPU))","")
|
|||
NO_ASM := 1
|
||||
NO_SSE := 1
|
||||
endif
|
||||
|
||||
ifneq ("$(filter riscv64,$(HOST_CPU))","")
|
||||
CPU := RISCV64
|
||||
ARCH_DETECTED := 64BITS
|
||||
PIC ?= 1
|
||||
NO_ASM := 1
|
||||
NO_SSE := 1
|
||||
$(warning Architecture "$(HOST_CPU)" not officially supported.)
|
||||
endif
|
||||
ifeq ("$(CPU)","NONE")
|
||||
$(error CPU type "$(HOST_CPU)" not supported. Please file bug report at 'https://github.com/mupen64plus/mupen64plus-core/issues')
|
||||
endif
|
||||
|
||||
SRCDIR = ../../src
|
||||
OBJDIR = _obj$(POSTFIX)
|
||||
|
||||
# base CFLAGS, LDLIBS, and LDFLAGS
|
||||
OPTFLAGS ?= -O3 -flto
|
||||
WARNFLAGS ?= -Wall -Wno-unused-function
|
||||
CFLAGS += $(OPTFLAGS) $(WARNFLAGS) -ffast-math -fno-strict-aliasing -fvisibility=hidden -I../../src -I../../src/Glitch64/inc -DGCC
|
||||
CXXFLAGS += -fvisibility-inlines-hidden -std=gnu++0x
|
||||
CFLAGS += $(OPTFLAGS) $(WARNFLAGS) -ffast-math -fno-strict-aliasing -fvisibility=hidden -I$(SRCDIR) -I$(SRCDIR)/Glitch64/inc -DGCC
|
||||
CXXFLAGS += -fvisibility-inlines-hidden -std=gnu++17
|
||||
LDFLAGS += $(SHARED)
|
||||
BOOST_SUFFIX ?=
|
||||
|
||||
ifeq ($(CPU), X86)
|
||||
CFLAGS += -mmmx -msse
|
||||
|
@ -160,8 +176,20 @@ ifeq ($(ARCH_DETECTED), 64BITS_32)
|
|||
ifeq ($(OS), FREEBSD)
|
||||
$(error Do not use the BITS=32 option with FreeBSD, use -m32 and -m elf_i386)
|
||||
endif
|
||||
CFLAGS += -m32
|
||||
LDFLAGS += -Wl,-m,elf_i386
|
||||
ifneq ($(OS), OSX)
|
||||
ifeq ($(OS), MINGW)
|
||||
LDFLAGS += -Wl,-m,i386pe
|
||||
else
|
||||
CFLAGS += -m32
|
||||
LDFLAGS += -Wl,-m,elf_i386
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(ARCH_DETECTED), 64BITS)
|
||||
ifeq ($(OS), MINGW)
|
||||
LDFLAGS += -Wl,-m,i386pep
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(origin PKG_CONFIG), undefined)
|
||||
|
@ -184,9 +212,9 @@ ifeq ($(OS), OSX)
|
|||
CXXFLAGS += -stdlib=libc++
|
||||
LDLIBS += -ldl
|
||||
ifeq ($(ARCH_DETECTED), 64BITS)
|
||||
CFLAGS += -pipe -I /opt/local/include -arch x86_64 -mmacosx-version-min=10.7 -isysroot $(OSX_SDK_PATH)
|
||||
CFLAGS += -pipe -I /opt/local/include -arch x86_64 -mmacosx-version-min=10.13 -isysroot $(OSX_SDK_PATH)
|
||||
else
|
||||
CFLAGS += -pipe -I /opt/local/include -mmmx -msse -fomit-frame-pointer -arch i686 -mmacosx-version-min=10.7 -isysroot $(OSX_SDK_PATH)
|
||||
CFLAGS += -pipe -I /opt/local/include -mmmx -msse -fomit-frame-pointer -arch i686 -mmacosx-version-min=10.13 -isysroot $(OSX_SDK_PATH)
|
||||
endif
|
||||
endif
|
||||
# use system zlib on OSX
|
||||
|
@ -351,9 +379,6 @@ ifeq ($(PLUGINDIR),)
|
|||
PLUGINDIR := $(LIBDIR)/mupen64plus
|
||||
endif
|
||||
|
||||
SRCDIR = ../../src
|
||||
OBJDIR = _obj$(POSTFIX)
|
||||
|
||||
# list of source files to compile
|
||||
SOURCE = \
|
||||
$(SRCDIR)/Glide64/3dmath.cpp \
|
||||
|
@ -412,7 +437,6 @@ SOURCE += \
|
|||
$(SRCDIR)/GlideHQ/tc-1.1+/texstore.c
|
||||
|
||||
CPPFLAGS += -DTEXTURE_FILTER -DDUMP_CACHE
|
||||
LDLIBS += -lboost_filesystem$(BOOST_SUFFIX) -lboost_system$(BOOST_SUFFIX)
|
||||
|
||||
ifeq ($(TXCDXTN), 1)
|
||||
CPPFLAGS += -DTXCDXTN_EXTERNAL
|
||||
|
@ -424,9 +448,13 @@ LDLIBS += -lboost_filesystem$(BOOST_SUFFIX) -lboost_system$(BOOST_SUFFIX)
|
|||
endif
|
||||
|
||||
ifeq ($(OS),MINGW)
|
||||
SOURCE += $(SRCDIR)/Glide64/osal_dynamiclib_win32.c
|
||||
SOURCE += \
|
||||
$(SRCDIR)/Glide64/osal_dynamiclib_win32.c \
|
||||
$(SRCDIR)/GlideHQ/osal_files_win32.c
|
||||
else
|
||||
SOURCE += $(SRCDIR)/Glide64/osal_dynamiclib_unix.c
|
||||
SOURCE += \
|
||||
$(SRCDIR)/Glide64/osal_dynamiclib_unix.c \
|
||||
$(SRCDIR)/GlideHQ/osal_files_unix.c
|
||||
endif
|
||||
|
||||
|
||||
|
@ -478,7 +506,7 @@ install: $(TARGET)
|
|||
$(INSTALL) -d "$(DESTDIR)$(PLUGINDIR)"
|
||||
$(INSTALL) -m 0644 $(INSTALL_STRIP_FLAG) $(TARGET) "$(DESTDIR)$(PLUGINDIR)"
|
||||
$(INSTALL) -d "$(DESTDIR)$(SHAREDIR)"
|
||||
$(INSTALL) -m 0644 "../../data/Glide64mk2.ini" "$(DESTDIR)$(SHAREDIR)"
|
||||
$(INSTALL) -m 0644 "$(SRCDIR)/../data/Glide64mk2.ini" "$(DESTDIR)$(SHAREDIR)"
|
||||
|
||||
uninstall:
|
||||
$(RM) "$(DESTDIR)$(PLUGINDIR)/$(TARGET)"
|
||||
|
|
|
@ -15537,11 +15537,11 @@ void CountCombine ()
|
|||
|
||||
void Combine ()
|
||||
{
|
||||
FRDP (" | |- color combine: %08lx, #1: (%s-%s)*%s+%s, #2: (%s-%s)*%s+%s\n",
|
||||
FRDP (" | |- color combine: %08x, #1: (%s-%s)*%s+%s, #2: (%s-%s)*%s+%s\n",
|
||||
((rdp.cycle1 & 0xFFFF) << 16) | (rdp.cycle2 & 0xFFFF),
|
||||
Mode0[rdp.cycle1&0xF], Mode1[(rdp.cycle1>>4)&0xF], Mode2[(rdp.cycle1>>8)&0x1F], Mode3[(rdp.cycle1>>13)&7],
|
||||
Mode0[rdp.cycle2&0xF], Mode1[(rdp.cycle2>>4)&0xF], Mode2[(rdp.cycle2>>8)&0x1F], Mode3[(rdp.cycle2>>13)&7]);
|
||||
FRDP (" | |- alpha combine: %08lx, #1: (%s-%s)*%s+%s, #2: (%s-%s)*%s+%s\n",
|
||||
FRDP (" | |- alpha combine: %08x, #1: (%s-%s)*%s+%s, #2: (%s-%s)*%s+%s\n",
|
||||
(rdp.cycle1 & 0x0FFF0000) | ((rdp.cycle2 & 0x0FFF0000) >> 16),
|
||||
Alpha0[(rdp.cycle1>>16)&7], Alpha1[(rdp.cycle1>>19)&7], Alpha2[(rdp.cycle1>>22)&7], Alpha3[(rdp.cycle1>>25)&7],
|
||||
Alpha0[(rdp.cycle2>>16)&7], Alpha1[(rdp.cycle2>>19)&7], Alpha2[(rdp.cycle2>>22)&7], Alpha3[(rdp.cycle2>>25)&7]);
|
||||
|
|
|
@ -493,29 +493,30 @@ void debug_capture ()
|
|||
static const char *cycle_mode_s[4] = { "1 cycle (0)", "2 cycle (1)", "copy (2)", "fill (3)" };
|
||||
|
||||
#define OUTPUT(fmt,other) output(642,(float)i,1,fmt,other); i-=16;
|
||||
#define OUTPUT0(fmt) output(642,(float)i,1,fmt); i-=16;
|
||||
#define OUTPUT1(fmt,other,other1) output(642,(float)i,1,fmt,other,other1); i-=16;
|
||||
#define OUTPUT_(fmt,cc) COL_SEL(cc); x=642; output(x,(float)i,1,fmt,0); x+=8*(strlen(fmt)+1)
|
||||
#define _OUTPUT(fmt,cc) COL_SEL(cc); output(x,(float)i,1,fmt,0); x+=8*(strlen(fmt)+1)
|
||||
#define OUTPUT_(fmt,cc) COL_SEL(cc); x=642; output(x,(float)i,1,fmt); x+=8*(strlen(fmt)+1)
|
||||
#define _OUTPUT(fmt,cc) COL_SEL(cc); output(x,(float)i,1,fmt); x+=8*(strlen(fmt)+1)
|
||||
i = 740;
|
||||
float x;
|
||||
if (_debugger.page == PAGE_GENERAL && _debugger.tri_sel)
|
||||
{
|
||||
COL_CATEGORY();
|
||||
OUTPUT ("GENERAL (page 1):",0);
|
||||
OUTPUT0 ("GENERAL (page 1):");
|
||||
COL_TEXT();
|
||||
OUTPUT ("tri #%d", _debugger.tri_sel->tri_n);
|
||||
OUTPUT ("type: %s", tri_type[_debugger.tri_sel->type]);
|
||||
OUTPUT ("geom: 0x%08lx", _debugger.tri_sel->geom_mode);
|
||||
OUTPUT ("othermode_h: 0x%08lx", _debugger.tri_sel->othermode_h);
|
||||
OUTPUT ("othermode_l: 0x%08lx", _debugger.tri_sel->othermode_l);
|
||||
OUTPUT ("flags: 0x%08lx", _debugger.tri_sel->flags);
|
||||
OUTPUT ("",0);
|
||||
OUTPUT ("geom: 0x%08x", _debugger.tri_sel->geom_mode);
|
||||
OUTPUT ("othermode_h: 0x%08x", _debugger.tri_sel->othermode_h);
|
||||
OUTPUT ("othermode_l: 0x%08x", _debugger.tri_sel->othermode_l);
|
||||
OUTPUT ("flags: 0x%08x", _debugger.tri_sel->flags);
|
||||
OUTPUT ("%s", "");
|
||||
COL_CATEGORY();
|
||||
OUTPUT ("COMBINE:",0);
|
||||
OUTPUT0 ("COMBINE:");
|
||||
COL_TEXT();
|
||||
OUTPUT ("cycle_mode: %s", cycle_mode_s[_debugger.tri_sel->cycle_mode]);
|
||||
OUTPUT ("cycle1: 0x%08lx", _debugger.tri_sel->cycle1);
|
||||
OUTPUT ("cycle2: 0x%08lx", _debugger.tri_sel->cycle2);
|
||||
OUTPUT ("cycle1: 0x%08x", _debugger.tri_sel->cycle1);
|
||||
OUTPUT ("cycle2: 0x%08x", _debugger.tri_sel->cycle2);
|
||||
if (_debugger.tri_sel->uncombined & 1)
|
||||
COL_UCC();
|
||||
else
|
||||
|
@ -585,20 +586,20 @@ void debug_capture ()
|
|||
if (_debugger.page == PAGE_COLORS && _debugger.tri_sel)
|
||||
{
|
||||
COL_CATEGORY();
|
||||
OUTPUT ("COLORS (page 4)", 0);
|
||||
OUTPUT0 ("COLORS (page 4)");
|
||||
COL_TEXT();
|
||||
OUTPUT ("fill: %08lx", _debugger.tri_sel->fill_color);
|
||||
OUTPUT ("prim: %08lx", _debugger.tri_sel->prim_color);
|
||||
OUTPUT ("blend: %08lx", _debugger.tri_sel->blend_color);
|
||||
OUTPUT ("env: %08lx", _debugger.tri_sel->env_color);
|
||||
OUTPUT ("fog: %08lx", _debugger.tri_sel->fog_color);
|
||||
OUTPUT ("fill: %08x", _debugger.tri_sel->fill_color);
|
||||
OUTPUT ("prim: %08x", _debugger.tri_sel->prim_color);
|
||||
OUTPUT ("blend: %08x", _debugger.tri_sel->blend_color);
|
||||
OUTPUT ("env: %08x", _debugger.tri_sel->env_color);
|
||||
OUTPUT ("fog: %08x", _debugger.tri_sel->fog_color);
|
||||
OUTPUT ("prim_lodmin: %d", _debugger.tri_sel->prim_lodmin);
|
||||
OUTPUT ("prim_lodfrac: %d", _debugger.tri_sel->prim_lodfrac);
|
||||
}
|
||||
if (_debugger.page == PAGE_FBL && _debugger.tri_sel)
|
||||
{
|
||||
COL_CATEGORY();
|
||||
OUTPUT ("BLENDER", 0);
|
||||
OUTPUT0 ("BLENDER");
|
||||
COL_TEXT();
|
||||
OUTPUT ("fbl_a0: %s", FBLa[(_debugger.tri_sel->othermode_l>>30)&0x3]);
|
||||
OUTPUT ("fbl_b0: %s", FBLb[(_debugger.tri_sel->othermode_l>>26)&0x3]);
|
||||
|
@ -608,16 +609,16 @@ void debug_capture ()
|
|||
OUTPUT ("fbl_b1: %s", FBLb[(_debugger.tri_sel->othermode_l>>24)&0x3]);
|
||||
OUTPUT ("fbl_c1: %s", FBLc[(_debugger.tri_sel->othermode_l>>20)&0x3]);
|
||||
OUTPUT ("fbl_d1: %s", FBLd[(_debugger.tri_sel->othermode_l>>16)&0x3]);
|
||||
OUTPUT ("", 0);
|
||||
OUTPUT ("fbl: %08lx", _debugger.tri_sel->othermode_l&0xFFFF0000);
|
||||
OUTPUT ("fbl #1: %08lx", _debugger.tri_sel->othermode_l&0xCCCC0000);
|
||||
OUTPUT ("fbl #2: %08lx", _debugger.tri_sel->othermode_l&0x33330000);
|
||||
OUTPUT ("%s", "");
|
||||
OUTPUT ("fbl: %08x", _debugger.tri_sel->othermode_l&0xFFFF0000);
|
||||
OUTPUT ("fbl #1: %08x", _debugger.tri_sel->othermode_l&0xCCCC0000);
|
||||
OUTPUT ("fbl #2: %08x", _debugger.tri_sel->othermode_l&0x33330000);
|
||||
}
|
||||
if (_debugger.page == PAGE_OTHERMODE_L && _debugger.tri_sel)
|
||||
{
|
||||
wxUint32 othermode_l = _debugger.tri_sel->othermode_l;
|
||||
COL_CATEGORY ();
|
||||
OUTPUT ("OTHERMODE_L: %08lx", othermode_l);
|
||||
OUTPUT ("OTHERMODE_L: %08x", othermode_l);
|
||||
OUTPUT_ ("AC_NONE", (othermode_l & 3) == 0);
|
||||
_OUTPUT ("AC_THRESHOLD", (othermode_l & 3) == 1);
|
||||
_OUTPUT ("AC_DITHER", (othermode_l & 3) == 3);
|
||||
|
@ -626,7 +627,7 @@ void debug_capture ()
|
|||
_OUTPUT ("ZS_PRIM", (othermode_l & 4));
|
||||
i -= 32;
|
||||
COL_CATEGORY ();
|
||||
OUTPUT ("RENDERMODE: %08lx", othermode_l);
|
||||
OUTPUT ("RENDERMODE: %08x", othermode_l);
|
||||
OUTPUT_ ("AA_EN", othermode_l & 0x08);
|
||||
i -= 16;
|
||||
OUTPUT_ ("Z_CMP", othermode_l & 0x10);
|
||||
|
@ -657,7 +658,7 @@ void debug_capture ()
|
|||
{
|
||||
wxUint32 othermode_h = _debugger.tri_sel->othermode_h;
|
||||
COL_CATEGORY ();
|
||||
OUTPUT ("OTHERMODE_H: %08lx", othermode_h);
|
||||
OUTPUT ("OTHERMODE_H: %08x", othermode_h);
|
||||
OUTPUT_ ("CK_NONE", (othermode_h & 0x100) == 0);
|
||||
_OUTPUT ("CK_KEY", (othermode_h & 0x100) == 1);
|
||||
i -= 16;
|
||||
|
@ -696,13 +697,13 @@ void debug_capture ()
|
|||
// change these to output whatever you need, ou for triangles, or u0 for texrects
|
||||
COL_TEXT();
|
||||
OUTPUT ("n: %d", _debugger.tri_sel->nv);
|
||||
OUTPUT ("",0);
|
||||
OUTPUT ("%s", "");
|
||||
for (j=0; j<_debugger.tri_sel->nv; j++)
|
||||
{
|
||||
OUTPUT1 ("v[%d].s0: %f", j, _debugger.tri_sel->v[j].ou);
|
||||
OUTPUT1 ("v[%d].t0: %f", j, _debugger.tri_sel->v[j].ov);
|
||||
}
|
||||
OUTPUT ("",0);
|
||||
OUTPUT ("%s", "");
|
||||
for (j=0; j<_debugger.tri_sel->nv; j++)
|
||||
{
|
||||
OUTPUT1 ("v[%d].s1: %f", j, _debugger.tri_sel->v[j].u0);
|
||||
|
@ -729,21 +730,21 @@ void debug_capture ()
|
|||
if (_debugger.page == PAGE_TEX_INFO && _debugger.tex_sel < (wxUint32)rdp.n_cached[_debugger.tmu])
|
||||
{
|
||||
COL_CATEGORY();
|
||||
OUTPUT ("CACHE (page 0)", 0);
|
||||
OUTPUT0 ("CACHE (page 0)");
|
||||
COL_TEXT();
|
||||
//OUTPUT ("t_mem: %08lx", rdp.cache[0][_debugger.tex_sel].t_mem);
|
||||
//OUTPUT ("crc: %08lx", rdp.cache[0][_debugger.tex_sel].crc);
|
||||
OUTPUT ("addr: %08lx", cache[_debugger.tex_sel].addr);
|
||||
//OUTPUT ("t_mem: %08x", rdp.cache[0][_debugger.tex_sel].t_mem);
|
||||
//OUTPUT ("crc: %08x", rdp.cache[0][_debugger.tex_sel].crc);
|
||||
OUTPUT ("addr: %08x", cache[_debugger.tex_sel].addr);
|
||||
OUTPUT ("scale_x: %f", cache[_debugger.tex_sel].scale_x);
|
||||
OUTPUT ("scale_y: %f", cache[_debugger.tex_sel].scale_y);
|
||||
OUTPUT ("tmem_addr: %08lx", cache[_debugger.tex_sel].tmem_addr);
|
||||
OUTPUT ("palette: %08lx", cache[_debugger.tex_sel].palette);
|
||||
OUTPUT ("set_by: %08lx", cache[_debugger.tex_sel].set_by);
|
||||
OUTPUT ("tmem_addr: %08x", cache[_debugger.tex_sel].tmem_addr);
|
||||
OUTPUT ("palette: %08x", cache[_debugger.tex_sel].palette);
|
||||
OUTPUT ("set_by: %08x", cache[_debugger.tex_sel].set_by);
|
||||
OUTPUT ("texrecting: %d", cache[_debugger.tex_sel].texrecting);
|
||||
|
||||
OUTPUT ("mod: %08lx", cache[_debugger.tex_sel].mod);
|
||||
OUTPUT ("mod_col: %08lx", cache[_debugger.tex_sel].mod_color);
|
||||
OUTPUT ("mod_col1: %08lx", cache[_debugger.tex_sel].mod_color1);
|
||||
OUTPUT ("mod: %08x", cache[_debugger.tex_sel].mod);
|
||||
OUTPUT ("mod_col: %08x", cache[_debugger.tex_sel].mod_color);
|
||||
OUTPUT ("mod_col1: %08x", cache[_debugger.tex_sel].mod_color1);
|
||||
i=740;
|
||||
output(800,(float)i,1,"width: %d", cache[_debugger.tex_sel].width);
|
||||
i-=16;
|
||||
|
@ -753,19 +754,19 @@ void debug_capture ()
|
|||
i-=16;
|
||||
output(800,(float)i,1,"size: %d", cache[_debugger.tex_sel].size);
|
||||
i-=16;
|
||||
output(800,(float)i,1,"crc: %08lx", cache[_debugger.tex_sel].crc);
|
||||
output(800,(float)i,1,"crc: %08x", cache[_debugger.tex_sel].crc);
|
||||
i-=16;
|
||||
#ifdef TEXTURE_FILTER
|
||||
output(800,(float)i,1,"RiceCrc: %08lx", (wxUint32)(rdp.cache[_debugger.tmu][_debugger.tex_sel].ricecrc&0xFFFFFFFF));
|
||||
output(800,(float)i,1,"RiceCrc: %08x", (wxUint32)(rdp.cache[_debugger.tmu][_debugger.tex_sel].ricecrc&0xFFFFFFFF));
|
||||
i-=16;
|
||||
output(800,(float)i,1,"RicePalCrc: %08lx", (wxUint32)(rdp.cache[_debugger.tmu][_debugger.tex_sel].ricecrc>>32));
|
||||
output(800,(float)i,1,"RicePalCrc: %08x", (wxUint32)(rdp.cache[_debugger.tmu][_debugger.tex_sel].ricecrc>>32));
|
||||
i-=16;
|
||||
#endif
|
||||
output(800,(float)i,1,"flags: %08lx", cache[_debugger.tex_sel].flags);
|
||||
output(800,(float)i,1,"flags: %08x", cache[_debugger.tex_sel].flags);
|
||||
i-=16;
|
||||
output(800,(float)i,1,"line: %d", cache[_debugger.tex_sel].line);
|
||||
i-=16;
|
||||
output(800,(float)i,1,"mod_factor: %08lx", cache[_debugger.tex_sel].mod_factor);
|
||||
output(800,(float)i,1,"mod_factor: %08x", cache[_debugger.tex_sel].mod_factor);
|
||||
i-=32;
|
||||
|
||||
output(800,(float)i,1,"lod: %s", str_lod[cache[_debugger.tex_sel].lod]);
|
||||
|
|
|
@ -37,6 +37,12 @@
|
|||
//
|
||||
//****************************************************************
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#define ATTR_FMT(fmtpos, attrpos) __attribute__ ((format (printf, fmtpos, attrpos)))
|
||||
#else
|
||||
#define ATTR_FMT(fmtpos, attrpos)
|
||||
#endif
|
||||
|
||||
#define SELECTED_NONE 0x00000000
|
||||
#define SELECTED_TRI 0x00000001
|
||||
#define SELECTED_TEX 0x00000002
|
||||
|
@ -134,4 +140,5 @@ void debug_capture ();
|
|||
void debug_cacheviewer ();
|
||||
void debug_mouse ();
|
||||
void debug_keys ();
|
||||
void output (float x, float y, int scale, const char *fmt, ...);
|
||||
void output (float x, float y, int scale, const char *fmt, ...) ATTR_FMT(4,5);
|
||||
|
||||
|
|
|
@ -149,7 +149,7 @@ static void DrawRE2Video(FB_TO_SCREEN_INFO & fb_info, float scale)
|
|||
|
||||
static void DrawRE2Video256(FB_TO_SCREEN_INFO & fb_info)
|
||||
{
|
||||
FRDP("DrawRE2Video256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawRE2Video256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
wxUint32 * src = (wxUint32*)(gfx.RDRAM+fb_info.addr);
|
||||
GrTexInfo t_info;
|
||||
t_info.smallLodLog2 = GR_LOD_LOG2_256;
|
||||
|
@ -196,7 +196,7 @@ static void DrawFrameBufferToScreen256(FB_TO_SCREEN_INFO & fb_info)
|
|||
DrawRE2Video256(fb_info);
|
||||
return;
|
||||
}
|
||||
FRDP("DrawFrameBufferToScreen256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawFrameBufferToScreen256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
wxUint32 width = fb_info.lr_x - fb_info.ul_x + 1;
|
||||
wxUint32 height = fb_info.lr_y - fb_info.ul_y + 1;
|
||||
GrTexInfo t_info;
|
||||
|
@ -314,7 +314,7 @@ bool DrawFrameBufferToScreen(FB_TO_SCREEN_INFO & fb_info)
|
|||
DrawFrameBufferToScreen256(fb_info);
|
||||
return true;
|
||||
}
|
||||
FRDP("DrawFrameBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawFrameBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
GrTexInfo t_info;
|
||||
wxUint8 * image = gfx.RDRAM+fb_info.addr;
|
||||
wxUint32 texwidth;
|
||||
|
@ -430,7 +430,7 @@ bool DrawFrameBufferToScreen(FB_TO_SCREEN_INFO & fb_info)
|
|||
|
||||
static void DrawDepthBufferToScreen256(FB_TO_SCREEN_INFO & fb_info)
|
||||
{
|
||||
FRDP("DrawDepthBufferToScreen256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawDepthBufferToScreen256. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
wxUint32 width = fb_info.lr_x - fb_info.ul_x + 1;
|
||||
wxUint32 height = fb_info.lr_y - fb_info.ul_y + 1;
|
||||
GrTexInfo t_info;
|
||||
|
@ -502,7 +502,7 @@ static void DrawDepthBufferToScreen256(FB_TO_SCREEN_INFO & fb_info)
|
|||
|
||||
static void DrawHiresDepthBufferToScreen(FB_TO_SCREEN_INFO & fb_info)
|
||||
{
|
||||
FRDP("DrawHiresDepthBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawHiresDepthBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
GrTexInfo t_info;
|
||||
float scale = 0.25f;
|
||||
GrLOD_t LOD = GR_LOD_LOG2_1024;
|
||||
|
@ -583,7 +583,7 @@ void DrawDepthBufferToScreen(FB_TO_SCREEN_INFO & fb_info)
|
|||
DrawHiresDepthBufferToScreen(fb_info);
|
||||
return;
|
||||
}
|
||||
FRDP("DrawDepthBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08lx\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
FRDP("DrawDepthBufferToScreen. ul_x=%d, ul_y=%d, lr_x=%d, lr_y=%d, size=%d, addr=%08x\n", fb_info.ul_x, fb_info.ul_y, fb_info.lr_x, fb_info.lr_y, fb_info.size, fb_info.addr);
|
||||
GrTexInfo t_info;
|
||||
wxUint8 * image = gfx.RDRAM+fb_info.addr;
|
||||
wxUint32 texwidth;
|
||||
|
|
|
@ -244,7 +244,10 @@ extern std::ofstream rdp_err;
|
|||
#define RDP_E(x)
|
||||
#endif
|
||||
|
||||
__inline void FRDP (const char *fmt, ...)
|
||||
__inline void FRDP (const char *fmt, ...) ATTR_FMT(1,2);
|
||||
__inline void FRDP_E (const char *fmt, ...) ATTR_FMT(1,2);
|
||||
|
||||
void FRDP (const char *fmt, ...)
|
||||
{
|
||||
#ifdef RDP_LOGGING
|
||||
if (!settings.logging || !log_open) return;
|
||||
|
@ -260,7 +263,8 @@ __inline void FRDP (const char *fmt, ...)
|
|||
va_end(ap);
|
||||
#endif
|
||||
}
|
||||
__inline void FRDP_E (const char *fmt, ...)
|
||||
|
||||
void FRDP_E (const char *fmt, ...)
|
||||
{
|
||||
#ifdef RDP_ERROR_LOG
|
||||
if (!settings.elogging || !elog_open) return;
|
||||
|
|
|
@ -196,7 +196,7 @@ BOOL INI_Open ()
|
|||
#endif // _WIN32
|
||||
break;
|
||||
}
|
||||
if (path == 0) return FALSE;
|
||||
if (i == 0) return FALSE;
|
||||
path[i+1] = 0;
|
||||
|
||||
#ifndef _WIN32
|
||||
|
|
|
@ -1071,7 +1071,7 @@ void DisplayLoadProgress(const wchar_t *format, ...)
|
|||
output (382, 380, 1, "LOADING TEXTURES. PLEASE WAIT...");
|
||||
int len = min (strlen(buf)*8, 1024);
|
||||
x = (1024-len)/2.0f;
|
||||
output (x, 360, 1, buf);
|
||||
output (x, 360, 1, "%s", buf);
|
||||
grBufferSwap (0);
|
||||
grColorMask (FXTRUE, FXTRUE);
|
||||
grBufferClear (0, 0, 0xFFFF);
|
||||
|
@ -2100,7 +2100,7 @@ EXPORT void CALL UpdateScreen (void)
|
|||
#endif
|
||||
char out_buf[128];
|
||||
sprintf (out_buf, "UpdateScreen (). Origin: %08x, Old origin: %08x, width: %d\n", *gfx.VI_ORIGIN_REG, rdp.vi_org_reg, *gfx.VI_WIDTH_REG);
|
||||
VLOG (out_buf);
|
||||
VLOG ("%s", out_buf);
|
||||
LRDP(out_buf);
|
||||
|
||||
wxUint32 width = (*gfx.VI_WIDTH_REG) << 1;
|
||||
|
@ -2270,7 +2270,7 @@ void newSwapBuffers()
|
|||
else
|
||||
sprintf (out_buf, " %.4s %s", asctime(cur_time) + 12, ampm);
|
||||
}
|
||||
output ((float)(settings.res_x - 68), y, 0, out_buf, 0);
|
||||
output ((float)(settings.res_x - 68), y, 0, "%s", out_buf);
|
||||
}
|
||||
//hotkeys
|
||||
if (CheckKeyPressed(G64_VK_BACK, 0x0001))
|
||||
|
@ -2336,7 +2336,7 @@ void newSwapBuffers()
|
|||
}
|
||||
hotkey_info.hk_filtering--;
|
||||
}
|
||||
output (120.0f, (float)settings.res_y, 0, message, 0);
|
||||
output (120.0f, (float)settings.res_y, 0, "%s", message);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -209,7 +209,7 @@ static TBUFF_COLOR_IMAGE * AllocateTextureBuffer(COLOR_IMAGE & cimage)
|
|||
|
||||
int OpenTextureBuffer(COLOR_IMAGE & cimage)
|
||||
{
|
||||
FRDP("OpenTextureBuffer. cur_tex_buf: %d, addr: %08lx, width: %d, height: %d", rdp.cur_tex_buf, cimage.addr, cimage.width, cimage.height);
|
||||
FRDP("OpenTextureBuffer. cur_tex_buf: %d, addr: %08x, width: %d, height: %d", rdp.cur_tex_buf, cimage.addr, cimage.width, cimage.height);
|
||||
if (!fullscreen) return FALSE;
|
||||
|
||||
int found = FALSE, search = TRUE;
|
||||
|
@ -335,7 +335,7 @@ int OpenTextureBuffer(COLOR_IMAGE & cimage)
|
|||
}
|
||||
//*/
|
||||
// memset(gfx.RDRAM+cimage.addr, 0, cimage.width*cimage.height*cimage.size);
|
||||
FRDP(" texaddr: %08lx, tex_width: %d, tex_height: %d, cur_tex_buf: %d, texformat: %d, motionblur: %d\n", rdp.cur_image->tex_addr, rdp.cur_image->tex_width, rdp.cur_image->tex_height, rdp.cur_tex_buf, rdp.cur_image->info.format, rdp.motionblur);
|
||||
FRDP(" texaddr: %08x, tex_width: %d, tex_height: %d, cur_tex_buf: %d, texformat: %d, motionblur: %d\n", rdp.cur_image->tex_addr, rdp.cur_image->tex_width, rdp.cur_image->tex_height, rdp.cur_tex_buf, rdp.cur_image->info.format, rdp.motionblur);
|
||||
if (!rdp.offset_x_bak)
|
||||
{
|
||||
rdp.offset_x_bak = rdp.offset_x;
|
||||
|
@ -690,7 +690,7 @@ int FindTextureBuffer(wxUint32 addr, wxUint16 width)
|
|||
{
|
||||
if (rdp.skip_drawing)
|
||||
return FALSE;
|
||||
FRDP("FindTextureBuffer. addr: %08lx, width: %d, scale_x: %f\n", addr, width, rdp.scale_x);
|
||||
FRDP("FindTextureBuffer. addr: %08x, width: %d, scale_x: %f\n", addr, width, rdp.scale_x);
|
||||
int found = FALSE;
|
||||
wxUint32 shift = 0;
|
||||
for (int i = 0; i < voodoo.num_tmu && !found; i++)
|
||||
|
@ -743,7 +743,7 @@ int FindTextureBuffer(wxUint32 addr, wxUint16 width)
|
|||
rdp.tbuff_tex->u_shift = 0;
|
||||
}
|
||||
FRDP("FindTextureBuffer, found, u_shift: %d, v_shift: %d, format: %s\n", rdp.tbuff_tex->u_shift, rdp.tbuff_tex->v_shift, str_format[rdp.tbuff_tex->format]);
|
||||
//FRDP("Buffer, addr=%08lx, end_addr=%08lx, width: %d, height: %d\n", rdp.tbuff_tex->addr, rdp.tbuff_tex->end_addr, rdp.tbuff_tex->width, rdp.tbuff_tex->height);
|
||||
//FRDP("Buffer, addr=%08x, end_addr=%08x, width: %d, height: %d\n", rdp.tbuff_tex->addr, rdp.tbuff_tex->end_addr, rdp.tbuff_tex->width, rdp.tbuff_tex->height);
|
||||
return TRUE;
|
||||
}
|
||||
rdp.tbuff_tex = 0;
|
||||
|
|
|
@ -306,7 +306,7 @@ void GetTexInfo (int id, int tile)
|
|||
}
|
||||
|
||||
LRDP(" | | |-+ Texture approved:\n");
|
||||
FRDP (" | | | |- tmem: %08lx\n", rdp.tiles[tile].t_mem);
|
||||
FRDP (" | | | |- tmem: %08x\n", rdp.tiles[tile].t_mem);
|
||||
FRDP (" | | | |- load width: %d\n", width);
|
||||
FRDP (" | | | |- load height: %d\n", height);
|
||||
FRDP (" | | | |- actual width: %d\n", rdp.tiles[tile].width);
|
||||
|
@ -411,7 +411,7 @@ void GetTexInfo (int id, int tile)
|
|||
crc += rdp.pal_256_crc;
|
||||
}
|
||||
|
||||
FRDP ("Done. CRC is: %08lx.\n", crc);
|
||||
FRDP ("Done. CRC is: %08x.\n", crc);
|
||||
|
||||
wxUint32 flags = (rdp.tiles[tile].clamp_s << 23) | (rdp.tiles[tile].mirror_s << 22) |
|
||||
(rdp.tiles[tile].mask_s << 18) | (rdp.tiles[tile].clamp_t << 17) |
|
||||
|
@ -519,6 +519,8 @@ static void SelectTBuffTex(TBUFF_COLOR_IMAGE * pTBuffTex)
|
|||
grTexSource(pTBuffTex->tile, pTBuffTex->tex_addr, GR_MIPMAPLEVELMASK_BOTH, &(pTBuffTex->info) );
|
||||
}
|
||||
|
||||
extern void DisplayLoadProgress(const wchar_t *format, ...);
|
||||
|
||||
//****************************************************************
|
||||
// TexCache - does texture loading after combiner is set
|
||||
int SwapTextureBuffer();
|
||||
|
@ -534,14 +536,13 @@ void TexCache ()
|
|||
}
|
||||
/* Turn on texture dump */
|
||||
else if (CheckKeyPressed(G64_VK_D, 0x0001)) {
|
||||
extern void DisplayLoadProgress(const wchar_t *format, ...);
|
||||
ghq_dmptex_toggle_key = !ghq_dmptex_toggle_key;
|
||||
if (ghq_dmptex_toggle_key) {
|
||||
DisplayLoadProgress(L"Texture dump - ON\n");
|
||||
DisplayLoadProgress(L"Texture dump - ON\n",0);
|
||||
ClearCache();
|
||||
SDL_Delay(1000);
|
||||
} else {
|
||||
DisplayLoadProgress(L"Texture dump - OFF\n");
|
||||
DisplayLoadProgress(L"Texture dump - OFF\n",0);
|
||||
SDL_Delay(1000);
|
||||
}
|
||||
}
|
||||
|
@ -884,9 +885,7 @@ void TexCache ()
|
|||
{
|
||||
for (int i=0; i<2; i++)
|
||||
{
|
||||
int tmu;
|
||||
if (i==0) tmu=tmu_0;
|
||||
else if (i==1) tmu=tmu_1;
|
||||
int tmu = (i==0) ? tmu_0 : tmu_1;
|
||||
|
||||
if (tmu >= voodoo.num_tmu) continue;
|
||||
|
||||
|
@ -1347,7 +1346,7 @@ void LoadTex (int id, int tmu)
|
|||
g64_crc = CRC32( g64_crc, &cache->mod_factor, 4 );
|
||||
|
||||
cache->ricecrc = ext_ghq_checksum(addr, tile_width, tile_height, (unsigned short)(rdp.tiles[td].format << 8 | rdp.tiles[td].size), bpl, paladdr);
|
||||
FRDP("CI RICE CRC. format: %d, size: %d, CRC: %08lx, PalCRC: %08lx\n", rdp.tiles[td].format, rdp.tiles[td].size, (wxUint32)(cache->ricecrc&0xFFFFFFFF), (wxUint32)(cache->ricecrc>>32));
|
||||
FRDP("CI RICE CRC. format: %d, size: %d, CRC: %08x, PalCRC: %08x\n", rdp.tiles[td].format, rdp.tiles[td].size, (wxUint32)(cache->ricecrc&0xFFFFFFFF), (wxUint32)(cache->ricecrc>>32));
|
||||
if (ext_ghq_hirestex((uint64)g64_crc, cache->ricecrc, palette, &ghqTexInfo))
|
||||
{
|
||||
cache->is_hires_tex = ghqTexInfo.is_hires_tex;
|
||||
|
|
|
@ -349,7 +349,7 @@ void draw_tri (VERTEX **vtx, wxUint16 linew)
|
|||
else // prim color
|
||||
{
|
||||
#ifdef EXTREME_LOGGING
|
||||
FRDP(" * Prim shaded %08lx\n", rdp.prim_color);
|
||||
FRDP(" * Prim shaded %08x\n", rdp.prim_color);
|
||||
#endif
|
||||
v->a = (wxUint8)(rdp.prim_color & 0xFF);
|
||||
v->b = (wxUint8)((rdp.prim_color >> 8) & 0xFF);
|
||||
|
@ -1875,7 +1875,7 @@ void update ()
|
|||
// Force blend
|
||||
if (rdp.render_mode_changed & 0xFFFF0000)
|
||||
{
|
||||
FRDP (" |- render_mode_changed force_blend - %08lx\n", rdp.othermode_l&0xFFFF0000);
|
||||
FRDP (" |- render_mode_changed force_blend - %08x\n", rdp.othermode_l&0xFFFF0000);
|
||||
rdp.render_mode_changed &= 0x0000FFFF;
|
||||
|
||||
rdp.fbl_a0 = (wxUint8)((rdp.othermode_l>>30)&0x3);
|
||||
|
@ -1980,7 +1980,7 @@ void update ()
|
|||
wxUint8 reference = (wxUint8)(rdp.blend_color&0xFF);
|
||||
grAlphaTestFunction (reference ? GR_CMP_GEQUAL : GR_CMP_GREATER);
|
||||
grAlphaTestReferenceValue (reference);
|
||||
FRDP (" |- alpha compare: blend: %02lx\n", reference);
|
||||
FRDP (" |- alpha compare: blend: %02x\n", reference);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -1998,7 +1998,7 @@ void update ()
|
|||
if (rdp.acmp == 3)
|
||||
{
|
||||
grAlphaTestReferenceValue ((wxUint8)(rdp.blend_color&0xFF));
|
||||
FRDP (" |- alpha compare: blend: %02lx\n", rdp.blend_color&0xFF);
|
||||
FRDP (" |- alpha compare: blend: %02x\n", rdp.blend_color&0xFF);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -31,15 +31,21 @@
|
|||
#include <stdio.h>
|
||||
|
||||
#define PLUGIN_NAME "Glide64mk2 Video Plugin"
|
||||
#define PLUGIN_VERSION 0x020509
|
||||
#define PLUGIN_VERSION 0x020600
|
||||
#define VIDEO_PLUGIN_API_VERSION 0x020200
|
||||
#define CONFIG_API_VERSION 0x020000
|
||||
#define VIDEXT_API_VERSION 0x030000
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#define ATTR_FMT(fmtpos, attrpos) __attribute__ ((format (printf, fmtpos, attrpos)))
|
||||
#else
|
||||
#define ATTR_FMT(fmtpos, attrpos)
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
void WriteLog(m64p_msg_level level, const char *msg, ...);
|
||||
void WriteLog(m64p_msg_level level, const char *msg, ...) ATTR_FMT(2,3);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -311,7 +311,7 @@ void microcheck ()
|
|||
uc_crc += ((wxUint32*)microcode)[i];
|
||||
}
|
||||
|
||||
FRDP_E ("crc: %08lx\n", uc_crc);
|
||||
FRDP_E ("crc: %08x\n", uc_crc);
|
||||
|
||||
#ifdef LOG_UCODE
|
||||
std::ofstream ucf;
|
||||
|
@ -325,12 +325,12 @@ void microcheck ()
|
|||
ucf.close ();
|
||||
#endif
|
||||
|
||||
FRDP("ucode = %08lx\n", uc_crc);
|
||||
FRDP("ucode = %08x\n", uc_crc);
|
||||
|
||||
Ini * ini = Ini::OpenIni();
|
||||
ini->SetPath("UCODE");
|
||||
char str[9];
|
||||
sprintf (str, "%08lx", (unsigned long)uc_crc);
|
||||
sprintf (str, "%08x", uc_crc);
|
||||
int uc = ini->Read(str, -2);
|
||||
|
||||
if (uc == -2 && ucode_error_report)
|
||||
|
@ -338,7 +338,7 @@ void microcheck ()
|
|||
settings.ucode = Config_ReadInt("ucode", "Force microcode", 0, TRUE, FALSE);
|
||||
|
||||
ReleaseGfx ();
|
||||
ERRLOG("Error: uCode crc not found in INI, using currently selected uCode\n\n%08lx", (unsigned long)uc_crc);
|
||||
ERRLOG("Error: uCode crc not found in INI, using currently selected uCode\n\n%08x", uc_crc);
|
||||
|
||||
ucode_error_report = FALSE; // don't report any more ucode errors from this game
|
||||
}
|
||||
|
@ -347,7 +347,7 @@ void microcheck ()
|
|||
settings.ucode = ini->Read(_T("/SETTINGS/ucode"), 0);
|
||||
|
||||
ReleaseGfx ();
|
||||
ERRLOG("Error: Unsupported uCode!\n\ncrc: %08lx", (unsigned long)uc_crc);
|
||||
ERRLOG("Error: Unsupported uCode!\n\ncrc: %08x", uc_crc);
|
||||
|
||||
ucode_error_report = FALSE; // don't report any more ucode errors from this game
|
||||
}
|
||||
|
@ -418,7 +418,7 @@ static void CopyFrameBuffer (GrBuffer_t buffer = GR_BUFFER_BACKBUFFER)
|
|||
{
|
||||
if (!fullscreen)
|
||||
return;
|
||||
FRDP ("CopyFrameBuffer: %08lx... ", rdp.cimg);
|
||||
FRDP ("CopyFrameBuffer: %08x... ", rdp.cimg);
|
||||
|
||||
// don't bother to write the stuff in asm... the slow part is the read from video card,
|
||||
// not the copy.
|
||||
|
@ -736,8 +736,8 @@ EXPORT void CALL ProcessDList(void)
|
|||
// Get the start of the display list and the length of it
|
||||
wxUint32 dlist_start = *(wxUint32*)(gfx.DMEM+0xFF0);
|
||||
wxUint32 dlist_length = *(wxUint32*)(gfx.DMEM+0xFF4);
|
||||
FRDP("--- NEW DLIST --- crc: %08lx, ucode: %d, fbuf: %08lx, fbuf_width: %d, dlist start: %08lx, dlist_length: %d, x_scale: %f, y_scale: %f\n", uc_crc, settings.ucode, *gfx.VI_ORIGIN_REG, *gfx.VI_WIDTH_REG, dlist_start, dlist_length, (*gfx.VI_X_SCALE_REG & 0xFFF)/1024.0f, (*gfx.VI_Y_SCALE_REG & 0xFFF)/1024.0f);
|
||||
FRDP_E("--- NEW DLIST --- crc: %08lx, ucode: %d, fbuf: %08lx\n", uc_crc, settings.ucode, *gfx.VI_ORIGIN_REG);
|
||||
FRDP("--- NEW DLIST --- crc: %08x, ucode: %d, fbuf: %08x, fbuf_width: %d, dlist start: %08x, dlist_length: %d, x_scale: %f, y_scale: %f\n", uc_crc, settings.ucode, *gfx.VI_ORIGIN_REG, *gfx.VI_WIDTH_REG, dlist_start, dlist_length, (*gfx.VI_X_SCALE_REG & 0xFFF)/1024.0f, (*gfx.VI_Y_SCALE_REG & 0xFFF)/1024.0f);
|
||||
FRDP_E("--- NEW DLIST --- crc: %08x, ucode: %d, fbuf: %08x\n", uc_crc, settings.ucode, *gfx.VI_ORIGIN_REG);
|
||||
|
||||
// Do nothing if dlist is empty
|
||||
if (dlist_start == 0)
|
||||
|
@ -782,9 +782,9 @@ EXPORT void CALL ProcessDList(void)
|
|||
|
||||
// Output the address before the command
|
||||
#ifdef LOG_COMMANDS
|
||||
FRDP ("%08lx (c0:%08lx, c1:%08lx): ", a, rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("%08x (c0:%08x, c1:%08x): ", a, rdp.cmd0, rdp.cmd1);
|
||||
#else
|
||||
FRDP ("%08lx: ", a);
|
||||
FRDP ("%08x: ", a);
|
||||
#endif
|
||||
|
||||
// Go to the next instruction
|
||||
|
@ -811,7 +811,7 @@ EXPORT void CALL ProcessDList(void)
|
|||
|
||||
#ifdef PERFORMANCE
|
||||
perf_next = wxDateTime::UNow();
|
||||
sprintf (out_buf, "perf %08lx: %016I64d\n", a-8, (perf_next-perf_cur).Format(_T("%l")).mb_str());
|
||||
sprintf (out_buf, "perf %08x: %016I64d\n", a-8, (perf_next-perf_cur).Format(_T("%l")).mb_str());
|
||||
rdp_log << out_buf;
|
||||
#endif
|
||||
|
||||
|
@ -867,8 +867,8 @@ EXPORT void CALL ProcessDList(void)
|
|||
// undef - undefined instruction, always ignore
|
||||
static void undef()
|
||||
{
|
||||
FRDP_E("** undefined ** (%08lx)\n", rdp.cmd0);
|
||||
FRDP("** undefined ** (%08lx) - IGNORED\n", rdp.cmd0);
|
||||
FRDP_E("** undefined ** (%08x)\n", rdp.cmd0);
|
||||
FRDP("** undefined ** (%08x) - IGNORED\n", rdp.cmd0);
|
||||
#ifdef _ENDUSER_RELEASE_
|
||||
*gfx.MI_INTR_REG |= 0x20;
|
||||
gfx.CheckInterrupts();
|
||||
|
@ -953,7 +953,7 @@ static void pd_zcopy ()
|
|||
c = ptr_src[x];
|
||||
c = ((c<<8)&0xFF00) | (c >> 8);
|
||||
ptr_dst[SHORTADDR(ul_x+x)] = c;
|
||||
// FRDP("dst[%d]=%04lx \n", SHORTADDR(x + ul_x), c);
|
||||
// FRDP("dst[%d]=%04x \n", SHORTADDR(x + ul_x), c);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1021,7 +1021,7 @@ static void rdp_texrect()
|
|||
|
||||
if ((settings.ucode == ucode_CBFD) && rdp.cur_image && rdp.cur_image->format)
|
||||
{
|
||||
//FRDP("Wrong Texrect. texaddr: %08lx, cimg: %08lx, cimg_end: %08lx\n", rdp.timg.addr, rdp.maincimg[1].addr, rdp.maincimg[1].addr+rdp.ci_width*rdp.ci_height*rdp.ci_size);
|
||||
//FRDP("Wrong Texrect. texaddr: %08x, cimg: %08x, cimg_end: %08x\n", rdp.timg.addr, rdp.maincimg[1].addr, rdp.maincimg[1].addr+rdp.ci_width*rdp.ci_height*rdp.ci_size);
|
||||
LRDP("Shadow texrect is skipped.\n");
|
||||
rdp.tri_n += 2;
|
||||
return;
|
||||
|
@ -1045,7 +1045,7 @@ static void rdp_texrect()
|
|||
return;
|
||||
}
|
||||
|
||||
// FRDP ("rdp.cycle1 %08lx, rdp.cycle2 %08lx\n", rdp.cycle1, rdp.cycle2);
|
||||
// FRDP ("rdp.cycle1 %08x, rdp.cycle2 %08x\n", rdp.cycle1, rdp.cycle2);
|
||||
|
||||
float ul_x, ul_y, lr_x, lr_y;
|
||||
if (rdp.cycle_mode == 2)
|
||||
|
@ -1100,7 +1100,7 @@ static void rdp_texrect()
|
|||
d.imageH = (wxUint16)rdp.tbuff_tex->height;
|
||||
d.frameY = (wxUint16)ul_y;
|
||||
d.frameH = (wxUint16)(rdp.tbuff_tex->height);
|
||||
FRDP("texrect. ul_x: %d, ul_y: %d, lr_x: %d, lr_y: %d, width: %d, height: %d\n", ul_x, ul_y, lr_x, lr_y, rdp.tbuff_tex->width, rdp.tbuff_tex->height);
|
||||
FRDP("texrect. ul_x: %lf, ul_y: %lf, lr_x: %lf, lr_y: %lf, width: %d, height: %d\n", ul_x, ul_y, lr_x, lr_y, rdp.tbuff_tex->width, rdp.tbuff_tex->height);
|
||||
d.scaleX = 1.0f;
|
||||
d.scaleY = 1.0f;
|
||||
DrawHiresImage(d, rdp.tbuff_tex->width == rdp.ci_width);
|
||||
|
@ -1117,7 +1117,7 @@ static void rdp_texrect()
|
|||
//hack for Zelda MM. it removes black texrects which cover all geometry in "Link meets Zelda" cut scene
|
||||
if ((settings.hacks&hack_Zelda) && rdp.timg.addr >= rdp.cimg && rdp.timg.addr < rdp.ci_end)
|
||||
{
|
||||
FRDP("Wrong Texrect. texaddr: %08lx, cimg: %08lx, cimg_end: %08lx\n", rdp.cur_cache[0]->addr, rdp.cimg, rdp.cimg+rdp.ci_width*rdp.ci_height*2);
|
||||
FRDP("Wrong Texrect. texaddr: %08x, cimg: %08x, cimg_end: %08x\n", rdp.cur_cache[0]->addr, rdp.cimg, rdp.cimg+rdp.ci_width*rdp.ci_height*2);
|
||||
rdp.tri_n += 2;
|
||||
return;
|
||||
}
|
||||
|
@ -1136,7 +1136,7 @@ static void rdp_texrect()
|
|||
if (fb_emulation_enabled)
|
||||
if (rdp.ci_count > 0 && rdp.frame_buffers[rdp.ci_count-1].status == ci_copy_self)
|
||||
{
|
||||
//FRDP("Wrong Texrect. texaddr: %08lx, cimg: %08lx, cimg_end: %08lx\n", rdp.timg.addr, rdp.maincimg[1], rdp.maincimg[1]+rdp.ci_width*rdp.ci_height*rdp.ci_size);
|
||||
//FRDP("Wrong Texrect. texaddr: %08x, cimg: %08x, cimg_end: %08x\n", rdp.timg.addr, rdp.maincimg[1], rdp.maincimg[1]+rdp.ci_width*rdp.ci_height*rdp.ci_size);
|
||||
LRDP("Wrong Texrect.\n");
|
||||
rdp.tri_n += 2;
|
||||
return;
|
||||
|
@ -1559,7 +1559,7 @@ static void rdp_setkeygb()
|
|||
wxUint32 cG = (rdp.cmd1>>24)&0xFF;
|
||||
rdp.SCALE = (rdp.SCALE&0xFF0000FF) | (sG<<16) | (sB<<8);
|
||||
rdp.CENTER = (rdp.CENTER&0xFF0000FF) | (cG<<16) | (cB<<8);
|
||||
FRDP("setkeygb. cG=%02lx, sG=%02lx, cB=%02lx, sB=%02lx\n", cG, sG, cB, sB);
|
||||
FRDP("setkeygb. cG=%02x, sG=%02x, cB=%02x, sB=%02x\n", cG, sG, cB, sB);
|
||||
}
|
||||
|
||||
static void rdp_setkeyr()
|
||||
|
@ -1568,7 +1568,7 @@ static void rdp_setkeyr()
|
|||
wxUint32 cR = (rdp.cmd1>>8)&0xFF;
|
||||
rdp.SCALE = (rdp.SCALE&0x00FFFFFF) | (sR<<24);
|
||||
rdp.CENTER = (rdp.CENTER&0x00FFFFFF) | (cR<<24);
|
||||
FRDP("setkeyr. cR=%02lx, sR=%02lx\n", cR, sR);
|
||||
FRDP("setkeyr. cR=%02x, sR=%02x\n", cR, sR);
|
||||
}
|
||||
|
||||
static void rdp_setconvert()
|
||||
|
@ -1583,7 +1583,7 @@ static void rdp_setconvert()
|
|||
rdp.K4 = (wxUint8)(rdp.cmd1>>9)&0x1FF;
|
||||
rdp.K5 = (wxUint8)(rdp.cmd1&0x1FF);
|
||||
// RDP_E("setconvert - IGNORED\n");
|
||||
FRDP("setconvert. K4=%02lx K5=%02lx\n", rdp.K4, rdp.K5);
|
||||
FRDP("setconvert. K4=%02x K5=%02x\n", rdp.K4, rdp.K5);
|
||||
}
|
||||
|
||||
//
|
||||
|
@ -1668,7 +1668,7 @@ void load_palette (wxUint32 addr, wxUint16 start, wxUint16 count)
|
|||
{
|
||||
*(dpal++) = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr)];
|
||||
#ifdef TLUT_LOGGING
|
||||
FRDP ("%d: %08lx\n", i, ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr)]);
|
||||
FRDP ("%d: %08x\n", i, ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr)]);
|
||||
#endif
|
||||
addr++;
|
||||
}
|
||||
|
@ -1700,7 +1700,7 @@ static void rdp_loadtlut()
|
|||
|
||||
if (start+count > 256) count = 256-start;
|
||||
|
||||
FRDP("loadtlut: tile: %d, start: %d, count: %d, from: %08lx\n", tile, start, count,
|
||||
FRDP("loadtlut: tile: %d, start: %d, count: %d, from: %08x\n", tile, start, count,
|
||||
rdp.timg.addr);
|
||||
|
||||
load_palette (rdp.timg.addr, start, count);
|
||||
|
@ -1901,7 +1901,17 @@ dxt_test:
|
|||
--v15;
|
||||
if ( !v15 )
|
||||
break;
|
||||
v16 += dxt;
|
||||
|
||||
/* use unsigned overflow handling because signed integer might trigger
|
||||
* "undefined" compiler behavior
|
||||
*/
|
||||
unsigned int t = v16;
|
||||
unsigned int _dxt = dxt;
|
||||
t += _dxt;
|
||||
|
||||
/* convert back to signed integer */
|
||||
v16 = t;
|
||||
|
||||
if ( v16 < 0 )
|
||||
{
|
||||
while ( 1 )
|
||||
|
@ -2009,7 +2019,7 @@ static void rdp_loadblock()
|
|||
cnt <<= 1;
|
||||
|
||||
if (((rdp.tiles[tile].t_mem + cnt) << 3) > sizeof(rdp.tmem)) {
|
||||
WriteLog(M64MSG_INFO, "rdp_loadblock wanted to write %u bytes after the end of tmem", ((rdp.tiles[tile].t_mem + cnt) << 3) - sizeof(rdp.tmem));
|
||||
WriteLog(M64MSG_INFO, "rdp_loadblock wanted to write %lu bytes after the end of tmem", ((rdp.tiles[tile].t_mem + cnt) << 3) - sizeof(rdp.tmem));
|
||||
cnt = (sizeof(rdp.tmem) >> 3) - (rdp.tiles[tile].t_mem);
|
||||
}
|
||||
|
||||
|
@ -2023,7 +2033,7 @@ static void rdp_loadblock()
|
|||
|
||||
rdp.update |= UPDATE_TEXTURE;
|
||||
|
||||
FRDP ("loadblock: tile: %d, ul_s: %d, ul_t: %d, lr_s: %d, dxt: %08lx -> %08lx\n",
|
||||
FRDP ("loadblock: tile: %d, ul_s: %d, ul_t: %d, lr_s: %d, dxt: %08x -> %08x\n",
|
||||
tile, ul_s, ul_t, lr_s,
|
||||
dxt, _dxt);
|
||||
|
||||
|
@ -2287,7 +2297,7 @@ static void rdp_settile()
|
|||
rdp.update |= UPDATE_TEXTURE;
|
||||
|
||||
FRDP ("settile: tile: %d, format: %s, size: %s, line: %d, "
|
||||
"t_mem: %08lx, palette: %d, clamp_t/mirror_t: %s, mask_t: %d, "
|
||||
"t_mem: %08x, palette: %d, clamp_t/mirror_t: %s, mask_t: %d, "
|
||||
"shift_t: %d, clamp_s/mirror_s: %s, mask_s: %d, shift_s: %d\n",
|
||||
rdp.last_tile, str_format[tile->format], str_size[tile->size], tile->line,
|
||||
tile->t_mem, tile->palette, str_cm[(tile->clamp_t<<1)|tile->mirror_t], tile->mask_t,
|
||||
|
@ -2550,7 +2560,7 @@ static void rdp_setfillcolor()
|
|||
rdp.fill_color = rdp.cmd1;
|
||||
rdp.update |= UPDATE_ALPHA_COMPARE | UPDATE_COMBINE;
|
||||
|
||||
FRDP("setfillcolor: %08lx\n", rdp.cmd1);
|
||||
FRDP("setfillcolor: %08x\n", rdp.cmd1);
|
||||
}
|
||||
|
||||
static void rdp_setfogcolor()
|
||||
|
@ -2558,7 +2568,7 @@ static void rdp_setfogcolor()
|
|||
rdp.fog_color = rdp.cmd1;
|
||||
rdp.update |= UPDATE_COMBINE | UPDATE_FOG_ENABLED;
|
||||
|
||||
FRDP("setfogcolor - %08lx\n", rdp.cmd1);
|
||||
FRDP("setfogcolor - %08x\n", rdp.cmd1);
|
||||
}
|
||||
|
||||
static void rdp_setblendcolor()
|
||||
|
@ -2566,7 +2576,7 @@ static void rdp_setblendcolor()
|
|||
rdp.blend_color = rdp.cmd1;
|
||||
rdp.update |= UPDATE_COMBINE;
|
||||
|
||||
FRDP("setblendcolor: %08lx\n", rdp.cmd1);
|
||||
FRDP("setblendcolor: %08x\n", rdp.cmd1);
|
||||
}
|
||||
|
||||
static void rdp_setprimcolor()
|
||||
|
@ -2576,7 +2586,7 @@ static void rdp_setprimcolor()
|
|||
rdp.prim_lodfrac = max(rdp.cmd0 & 0xFF, rdp.prim_lodmin);
|
||||
rdp.update |= UPDATE_COMBINE;
|
||||
|
||||
FRDP("setprimcolor: %08lx, lodmin: %d, lodfrac: %d\n", rdp.cmd1, rdp.prim_lodmin,
|
||||
FRDP("setprimcolor: %08x, lodmin: %d, lodfrac: %d\n", rdp.cmd1, rdp.prim_lodmin,
|
||||
rdp.prim_lodfrac);
|
||||
}
|
||||
|
||||
|
@ -2585,7 +2595,7 @@ static void rdp_setenvcolor()
|
|||
rdp.env_color = rdp.cmd1;
|
||||
rdp.update |= UPDATE_COMBINE;
|
||||
|
||||
FRDP("setenvcolor: %08lx\n", rdp.cmd1);
|
||||
FRDP("setenvcolor: %08x\n", rdp.cmd1);
|
||||
}
|
||||
|
||||
static void rdp_setcombine()
|
||||
|
@ -2668,7 +2678,7 @@ static void rdp_settextureimage()
|
|||
if (fb_hwfbe_enabled) //search this texture among drawn texture buffers
|
||||
FindTextureBuffer(rdp.timg.addr, rdp.timg.width);
|
||||
|
||||
FRDP("settextureimage: format: %s, size: %s, width: %d, addr: %08lx\n",
|
||||
FRDP("settextureimage: format: %s, size: %s, width: %d, addr: %08x\n",
|
||||
format[rdp.timg.format], size[rdp.timg.size],
|
||||
rdp.timg.width, rdp.timg.addr);
|
||||
}
|
||||
|
@ -2677,7 +2687,7 @@ static void rdp_setdepthimage()
|
|||
{
|
||||
rdp.zimg = segoffset(rdp.cmd1) & BMASK;
|
||||
rdp.zi_width = rdp.ci_width;
|
||||
FRDP("setdepthimage - %08lx\n", rdp.zimg);
|
||||
FRDP("setdepthimage - %08x\n", rdp.zimg);
|
||||
}
|
||||
|
||||
int SwapOK = TRUE;
|
||||
|
@ -2718,7 +2728,7 @@ static void rdp_setcolorimage()
|
|||
|
||||
if (rdp.ci_count == 0)
|
||||
{
|
||||
if ((rdp.ci_status == ci_aux)) //for PPL
|
||||
if (rdp.ci_status == ci_aux) //for PPL
|
||||
{
|
||||
float sx = rdp.scale_x;
|
||||
float sy = rdp.scale_y;
|
||||
|
@ -3015,8 +3025,8 @@ static void rdp_setcolorimage()
|
|||
wxUint32 format = (rdp.cmd0 >> 21) & 0x7;
|
||||
rdp.ci_size = (rdp.cmd0 >> 19) & 0x3;
|
||||
rdp.ci_end = rdp.cimg + ((rdp.ci_width*rdp.ci_height)<<(rdp.ci_size-1));
|
||||
FRDP("setcolorimage - %08lx, width: %d, height: %d, format: %d, size: %d\n", rdp.cmd1, rdp.ci_width, rdp.ci_height, format, rdp.ci_size);
|
||||
FRDP("cimg: %08lx, ocimg: %08lx, SwapOK: %d\n", rdp.cimg, rdp.ocimg, SwapOK);
|
||||
FRDP("setcolorimage - %08x, width: %d, height: %d, format: %d, size: %d\n", rdp.cmd1, rdp.ci_width, rdp.ci_height, format, rdp.ci_size);
|
||||
FRDP("cimg: %08x, ocimg: %08x, SwapOK: %d\n", rdp.cimg, rdp.ocimg, SwapOK);
|
||||
|
||||
if (format != 0) //can't draw into non RGBA buffer
|
||||
{
|
||||
|
@ -3058,7 +3068,7 @@ static void rdp_setcolorimage()
|
|||
if (rdp.copy_ci_index && rdp.ci_count > 0 && (rdp.frame_buffers[rdp.ci_count-1].status != ci_zimg))
|
||||
{
|
||||
int idx = (rdp.frame_buffers[rdp.ci_count].status == ci_aux_copy) ? rdp.main_ci_index : rdp.copy_ci_index;
|
||||
FRDP("attempt open tex buffer. status: %s, addr: %08lx\n", CIStatus[rdp.frame_buffers[idx].status], rdp.frame_buffers[idx].addr);
|
||||
FRDP("attempt open tex buffer. status: %s, addr: %08x\n", CIStatus[rdp.frame_buffers[idx].status], rdp.frame_buffers[idx].addr);
|
||||
OpenTextureBuffer(rdp.frame_buffers[idx]);
|
||||
if (rdp.frame_buffers[rdp.copy_ci_index].status == ci_main) //tidal wave
|
||||
rdp.copy_ci_index = 0;
|
||||
|
@ -3078,7 +3088,7 @@ static void rsp_reserved0()
|
|||
{
|
||||
ucode5_texshiftaddr = segoffset(rdp.cmd1);
|
||||
ucode5_texshiftcount = 0;
|
||||
FRDP("uc5_texshift. addr: %08lx\n", ucode5_texshiftaddr);
|
||||
FRDP("uc5_texshift. addr: %08x\n", ucode5_texshiftaddr);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -3208,7 +3218,7 @@ EXPORT void CALL FBRead(wxUint32 addr)
|
|||
}
|
||||
cpu_fb_read_called = TRUE;
|
||||
wxUint32 a = segoffset(addr);
|
||||
FRDP("FBRead. addr: %08lx\n", a);
|
||||
FRDP("FBRead. addr: %08x\n", a);
|
||||
if (!rdp.fb_drawn && (a >= rdp.cimg) && (a < rdp.ci_end))
|
||||
{
|
||||
fbreads_back++;
|
||||
|
@ -3282,7 +3292,7 @@ EXPORT void CALL FBWrite(wxUint32 addr, wxUint32 size)
|
|||
}
|
||||
cpu_fb_write_called = TRUE;
|
||||
wxUint32 a = segoffset(addr);
|
||||
FRDP("FBWrite. addr: %08lx\n", a);
|
||||
FRDP("FBWrite. addr: %08x\n", a);
|
||||
if (a < rdp.cimg || a > rdp.ci_end)
|
||||
return;
|
||||
cpu_fb_write = TRUE;
|
||||
|
@ -3500,7 +3510,7 @@ void DetectFrameBufferUsage ()
|
|||
LRDP("detect fb final results: \n");
|
||||
for (i = 0; i < rdp.ci_count; i++)
|
||||
{
|
||||
FRDP("rdp.frame_buffers[%d].status = %s, addr: %08lx, height: %d\n", i, CIStatus[rdp.frame_buffers[i].status], rdp.frame_buffers[i].addr, rdp.frame_buffers[i].height);
|
||||
FRDP("rdp.frame_buffers[%d].status = %s, addr: %08x, height: %d\n", i, CIStatus[rdp.frame_buffers[i].status], rdp.frame_buffers[i].addr, rdp.frame_buffers[i].height);
|
||||
}
|
||||
|
||||
rdp.cimg = ci;
|
||||
|
|
|
@ -105,7 +105,7 @@ static void t3dProcessRDP(wxUint32 a)
|
|||
static void t3dLoadGlobState(wxUint32 pgstate)
|
||||
{
|
||||
t3dGlobState *gstate = (t3dGlobState*)&gfx.RDRAM[segoffset(pgstate)];
|
||||
FRDP ("Global state. pad0: %04lx, perspNorm: %04lx, flag: %08lx\n", gstate->pad0, gstate->perspNorm, gstate->flag);
|
||||
FRDP ("Global state. pad0: %04x, perspNorm: %04x, flag: %08x\n", gstate->pad0, gstate->perspNorm, gstate->flag);
|
||||
rdp.cmd0 = gstate->othermode0;
|
||||
rdp.cmd1 = gstate->othermode1;
|
||||
rdp_setothermode();
|
||||
|
@ -113,7 +113,7 @@ static void t3dLoadGlobState(wxUint32 pgstate)
|
|||
for (int s = 0; s < 16; s++)
|
||||
{
|
||||
rdp.segment[s] = gstate->segBases[s];
|
||||
FRDP ("segment: %08lx -> seg%d\n", rdp.segment[s], s);
|
||||
FRDP ("segment: %08x -> seg%d\n", rdp.segment[s], s);
|
||||
}
|
||||
|
||||
short scale_x = gstate->vsacle0 / 4;
|
||||
|
@ -197,7 +197,7 @@ static void t3dLoadObject(wxUint32 pstate, wxUint32 pvtx, wxUint32 ptri)
|
|||
rdp.tiles[rdp.cur_tile].t_scale = 0.015625;
|
||||
|
||||
#ifdef EXTREME_LOGGING
|
||||
FRDP("renderState: %08lx, textureState: %08lx, othermode0: %08lx, othermode1: %08lx, rdpCmds: %08lx, triCount : %d, v0: %d, vn: %d\n", ostate->renderState, ostate->textureState,
|
||||
FRDP("renderState: %08x, textureState: %08x, othermode0: %08x, othermode1: %08x, rdpCmds: %08x, triCount : %d, v0: %d, vn: %d\n", ostate->renderState, ostate->textureState,
|
||||
ostate->othermode0, ostate->othermode1, ostate->rdpCmds, ostate->triCount, ostate->vtxV0, ostate->vtxCount);
|
||||
#endif
|
||||
|
||||
|
@ -259,7 +259,7 @@ static void Turbo3D()
|
|||
pstate = ((wxUint32*)gfx.RDRAM)[(a>>2)+1];
|
||||
pvtx = ((wxUint32*)gfx.RDRAM)[(a>>2)+2];
|
||||
ptri = ((wxUint32*)gfx.RDRAM)[(a>>2)+3];
|
||||
FRDP("GlobalState: %08lx, Object: %08lx, Vertices: %08lx, Triangles: %08lx\n", pgstate, pstate, pvtx, ptri);
|
||||
FRDP("GlobalState: %08x, Object: %08x, Vertices: %08x, Triangles: %08x\n", pgstate, pstate, pvtx, ptri);
|
||||
if (!pstate)
|
||||
{
|
||||
rdp.halt = 1;
|
||||
|
|
|
@ -81,7 +81,7 @@ static void rsp_vertex(int v0, int n)
|
|||
}
|
||||
}
|
||||
|
||||
FRDP ("rsp:vertex v0:%d, n:%d, from: %08lx\n", v0, n, addr);
|
||||
FRDP ("rsp:vertex v0:%d, n:%d, from: %08x\n", v0, n, addr);
|
||||
|
||||
for (i=0; i < (n<<4); i+=16)
|
||||
{
|
||||
|
@ -273,7 +273,7 @@ void projection_mul (float m[4][4])
|
|||
|
||||
void load_matrix (float m[4][4], wxUint32 addr)
|
||||
{
|
||||
FRDP ("matrix - addr: %08lx\n", addr);
|
||||
FRDP ("matrix - addr: %08x\n", addr);
|
||||
int x,y; // matrix index
|
||||
addr >>= 1;
|
||||
wxUint16 * src = (wxUint16*)gfx.RDRAM;
|
||||
|
@ -337,8 +337,8 @@ static void uc0_matrix()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E ("Unknown matrix command, %02lx", command);
|
||||
FRDP ("Unknown matrix command, %02lx", command);
|
||||
FRDP_E ("Unknown matrix command, %02x", command);
|
||||
FRDP ("Unknown matrix command, %02x", command);
|
||||
}
|
||||
|
||||
#ifdef EXTREME_LOGGING
|
||||
|
@ -395,7 +395,7 @@ static void uc0_movemem()
|
|||
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08lx\n", scale_x, scale_y, scale_z,
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08x\n", scale_x, scale_y, scale_z,
|
||||
trans_x, trans_y, trans_z, rdp.cmd1);
|
||||
}
|
||||
break;
|
||||
|
@ -495,8 +495,8 @@ static void uc0_movemem()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E ("uc0:movemem unknown (index: 0x%08lx)\n", (rdp.cmd0 >> 16) & 0xFF);
|
||||
FRDP ("unknown (index: 0x%08lx)\n", (rdp.cmd0 >> 16) & 0xFF);
|
||||
FRDP_E ("uc0:movemem unknown (index: 0x%08x)\n", (rdp.cmd0 >> 16) & 0xFF);
|
||||
FRDP ("unknown (index: 0x%08x)\n", (rdp.cmd0 >> 16) & 0xFF);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -512,8 +512,8 @@ static void uc0_displaylist()
|
|||
|
||||
wxUint32 push = (rdp.cmd0 >> 16) & 0xFF; // push the old location?
|
||||
|
||||
FRDP("uc0:displaylist: %08lx, push:%s", addr, push?"no":"yes");
|
||||
FRDP(" (seg %d, offset %08lx)\n", (rdp.cmd1>>24)&0x0F, rdp.cmd1&0x00FFFFFF);
|
||||
FRDP("uc0:displaylist: %08x, push:%s", addr, push?"no":"yes");
|
||||
FRDP(" (seg %d, offset %08x)\n", (rdp.cmd1>>24)&0x0F, rdp.cmd1&0x00FFFFFF);
|
||||
|
||||
switch (push)
|
||||
{
|
||||
|
@ -634,8 +634,8 @@ static void uc0_popmatrix()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E ("Unknown uc0:popmatrix command: 0x%08lx\n", param);
|
||||
FRDP ("Unknown uc0:popmatrix command: 0x%08lx\n", param);
|
||||
FRDP_E ("Unknown uc0:popmatrix command: 0x%08x\n", param);
|
||||
FRDP ("Unknown uc0:popmatrix command: 0x%08x\n", param);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -669,7 +669,7 @@ static void uc0_modifyvtx(wxUint8 where, wxUint16 vtx, wxUint32 val)
|
|||
v->uv_calculated = 0xFFFFFFFF;
|
||||
v->uv_scaled = 1;
|
||||
}
|
||||
FRDP ("u/v: (%04lx, %04lx), (%f, %f)\n", (short)(val>>16), (short)(val&0xFFFF),
|
||||
FRDP ("u/v: (%04x, %04x), (%f, %f)\n", (short)(val>>16), (short)(val&0xFFFF),
|
||||
v->ou, v->ov);
|
||||
break;
|
||||
|
||||
|
@ -743,11 +743,11 @@ static void uc0_moveword()
|
|||
rdp.clip_ratio = sqrt((float)rdp.cmd1);
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
}
|
||||
FRDP ("clip %08lx, %08lx\n", rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("clip %08x, %08x\n", rdp.cmd0, rdp.cmd1);
|
||||
break;
|
||||
|
||||
case 0x06: // segment
|
||||
FRDP ("segment: %08lx -> seg%d\n", rdp.cmd1, (rdp.cmd0 >> 10) & 0x0F);
|
||||
FRDP ("segment: %08x -> seg%d\n", rdp.cmd1, (rdp.cmd0 >> 10) & 0x0F);
|
||||
if ((rdp.cmd1&BMASK)<BMASK)
|
||||
rdp.segment[(rdp.cmd0 >> 10) & 0x0F] = rdp.cmd1;
|
||||
break;
|
||||
|
@ -763,7 +763,7 @@ static void uc0_moveword()
|
|||
case 0x0a: // moveword LIGHTCOL
|
||||
{
|
||||
int n = (rdp.cmd0&0xE000) >> 13;
|
||||
FRDP ("lightcol light:%d, %08lx\n", n, rdp.cmd1);
|
||||
FRDP ("lightcol light:%d, %08x\n", n, rdp.cmd1);
|
||||
|
||||
rdp.light[n].r = (float)((rdp.cmd1 >> 24) & 0xFF) / 255.0f;
|
||||
rdp.light[n].g = (float)((rdp.cmd1 >> 16) & 0xFF) / 255.0f;
|
||||
|
@ -778,7 +778,7 @@ static void uc0_moveword()
|
|||
wxUint16 vtx = val / 40;
|
||||
wxUint8 where = val%40;
|
||||
uc0_modifyvtx(where, vtx, rdp.cmd1);
|
||||
FRDP ("uc0:modifyvtx: vtx: %d, where: 0x%02lx, val: %08lx - ", vtx, where, rdp.cmd1);
|
||||
FRDP ("uc0:modifyvtx: vtx: %d, where: 0x%02x, val: %08x - ", vtx, where, rdp.cmd1);
|
||||
}
|
||||
break;
|
||||
|
||||
|
@ -787,8 +787,8 @@ static void uc0_moveword()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E ("uc0:moveword unknown (index: 0x%08lx)\n", rdp.cmd0 & 0xFF);
|
||||
FRDP ("unknown (index: 0x%08lx)\n", rdp.cmd0 & 0xFF);
|
||||
FRDP_E ("uc0:moveword unknown (index: 0x%08x)\n", rdp.cmd0 & 0xFF);
|
||||
FRDP ("unknown (index: 0x%08x)\n", rdp.cmd0 & 0xFF);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -901,7 +901,7 @@ static void uc0_setothermode_h()
|
|||
wxUint32 unk = mask & 0x0FFC60F0F;
|
||||
if (unk) // unknown portions, LARGE
|
||||
{
|
||||
FRDP ("UNKNOWN PORTIONS: shift: %d, len: %d, unknowns: %08lx\n", shift, len, unk);
|
||||
FRDP ("UNKNOWN PORTIONS: shift: %d, len: %d, unknowns: %08x\n", shift, len, unk);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -943,7 +943,7 @@ static void uc0_setothermode_l()
|
|||
{
|
||||
rdp.zsrc = (rdp.othermode_l & 0x00000004) >> 2;
|
||||
FRDP ("z-src sel: %s\n", str_zs[rdp.zsrc]);
|
||||
FRDP ("z-src sel: %08lx\n", rdp.zsrc);
|
||||
FRDP ("z-src sel: %08x\n", rdp.zsrc);
|
||||
rdp.update |= UPDATE_ZBUF_ENABLED;
|
||||
}
|
||||
|
||||
|
@ -954,7 +954,7 @@ static void uc0_setothermode_l()
|
|||
rdp.rm = rdp.othermode_l;
|
||||
if (settings.flame_corona && (rdp.rm == 0x00504341)) //hack for flame's corona
|
||||
rdp.othermode_l |= /*0x00000020 |*/ 0x00000010;
|
||||
FRDP ("rendermode: %08lx\n", rdp.othermode_l); // just output whole othermode_l
|
||||
FRDP ("rendermode: %08x\n", rdp.othermode_l); // just output whole othermode_l
|
||||
}
|
||||
|
||||
// there is not one setothermode_l that's not handled :)
|
||||
|
@ -963,7 +963,7 @@ static void uc0_setothermode_l()
|
|||
static void uc0_setgeometrymode()
|
||||
{
|
||||
rdp.geom_mode |= rdp.cmd1;
|
||||
FRDP("uc0:setgeometrymode %08lx; result: %08lx\n", rdp.cmd1, rdp.geom_mode);
|
||||
FRDP("uc0:setgeometrymode %08x; result: %08x\n", rdp.cmd1, rdp.geom_mode);
|
||||
|
||||
if (rdp.cmd1 & 0x00000001) // Z-Buffer enable
|
||||
{
|
||||
|
@ -1003,7 +1003,7 @@ static void uc0_setgeometrymode()
|
|||
|
||||
static void uc0_cleargeometrymode()
|
||||
{
|
||||
FRDP("uc0:cleargeometrymode %08lx\n", rdp.cmd1);
|
||||
FRDP("uc0:cleargeometrymode %08x\n", rdp.cmd1);
|
||||
|
||||
rdp.geom_mode &= (~rdp.cmd1);
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ static void uc1_tri1()
|
|||
LRDP("uc1:tri1. skipped\n");
|
||||
return;
|
||||
}
|
||||
FRDP("uc1:tri1 #%d - %d, %d, %d - %08lx - %08lx\n", rdp.tri_n,
|
||||
FRDP("uc1:tri1 #%d - %d, %d, %d - %08x - %08x\n", rdp.tri_n,
|
||||
((rdp.cmd1 >> 17) & 0x7F),
|
||||
((rdp.cmd1 >> 9) & 0x7F),
|
||||
((rdp.cmd1 >> 1) & 0x7F), rdp.cmd0, rdp.cmd1);
|
||||
|
@ -154,7 +154,7 @@ static void uc1_rdphalf_1()
|
|||
static void uc1_branch_z()
|
||||
{
|
||||
wxUint32 addr = segoffset(branch_dl);
|
||||
FRDP ("uc1:branch_less_z, addr: %08lx\n", addr);
|
||||
FRDP ("uc1:branch_less_z, addr: %08x\n", addr);
|
||||
wxUint32 vtx = (rdp.cmd0 >> 1) & 0x7FF;
|
||||
const wxUint32 zTest = wxUint32((rdp.vtx[vtx].z / rdp.vtx[vtx].w) * 1023.0f);
|
||||
if (zTest > 0x03FF || zTest <= rdp.cmd1)
|
||||
|
|
|
@ -116,7 +116,7 @@ static void uc2_vertex ()
|
|||
rdp.vn = n = (rdp.cmd0 >> 12) & 0xFF;
|
||||
rdp.v0 = v0 = ((rdp.cmd0 >> 1) & 0x7F) - n;
|
||||
|
||||
FRDP ("uc2:vertex n: %d, v0: %d, from: %08lx\n", n, v0, addr);
|
||||
FRDP ("uc2:vertex n: %d, v0: %d, from: %08x\n", n, v0, addr);
|
||||
|
||||
if (v0 < 0)
|
||||
{
|
||||
|
@ -222,7 +222,7 @@ static void uc2_modifyvtx ()
|
|||
wxUint8 where = (wxUint8)((rdp.cmd0 >> 16) & 0xFF);
|
||||
wxUint16 vtx = (wxUint16)((rdp.cmd0 >> 1) & 0xFFFF);
|
||||
|
||||
FRDP ("uc2:modifyvtx: vtx: %d, where: 0x%02lx, val: %08lx - ", vtx, where, rdp.cmd1);
|
||||
FRDP ("uc2:modifyvtx: vtx: %d, where: 0x%02x, val: %08x - ", vtx, where, rdp.cmd1);
|
||||
uc0_modifyvtx(where, vtx, rdp.cmd1);
|
||||
}
|
||||
|
||||
|
@ -255,7 +255,7 @@ static void uc2_culldl ()
|
|||
//*/
|
||||
|
||||
#ifdef EXTREME_LOGGING
|
||||
FRDP (" v[%d] = (%02f, %02f, %02f, 0x%02lx)\n", i, rdp.vtx[i].x, rdp.vtx[i].y, rdp.vtx[i].w, rdp.vtx[i].scr_off);
|
||||
FRDP (" v[%d] = (%02f, %02f, %02f, 0x%02x)\n", i, rdp.vtx[i].x, rdp.vtx[i].y, rdp.vtx[i].w, rdp.vtx[i].scr_off);
|
||||
#endif
|
||||
|
||||
cond |= (~rdp.vtx[i].scr_off) & 0x1F;
|
||||
|
@ -389,7 +389,7 @@ static void uc2_dma_io ()
|
|||
|
||||
static void uc2_pop_matrix ()
|
||||
{
|
||||
FRDP ("uc2:pop_matrix %08lx, %08lx\n", rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("uc2:pop_matrix %08x, %08x\n", rdp.cmd0, rdp.cmd1);
|
||||
|
||||
// Just pop the modelview matrix
|
||||
modelview_pop (rdp.cmd1 >> 6);
|
||||
|
@ -405,12 +405,12 @@ static void uc2_geom_mode ()
|
|||
((rdp.cmd1 & 0x00000600) << 3) |
|
||||
((rdp.cmd1 & 0x00200000) >> 12);
|
||||
|
||||
FRDP("uc2:geom_mode c:%08lx, s:%08lx ", clr_mode, set_mode);
|
||||
FRDP("uc2:geom_mode c:%08x, s:%08x ", clr_mode, set_mode);
|
||||
|
||||
rdp.geom_mode &= clr_mode;
|
||||
rdp.geom_mode |= set_mode;
|
||||
|
||||
FRDP ("result:%08lx\n", rdp.geom_mode);
|
||||
FRDP ("result:%08x\n", rdp.geom_mode);
|
||||
|
||||
if (rdp.geom_mode & 0x00000001) // Z-Buffer enable
|
||||
{
|
||||
|
@ -531,8 +531,8 @@ static void uc2_matrix ()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E ("Unknown matrix command, %02lx", command);
|
||||
FRDP ("Unknown matrix command, %02lx", command);
|
||||
FRDP_E ("Unknown matrix command, %02x", command);
|
||||
FRDP ("Unknown matrix command, %02x", command);
|
||||
}
|
||||
|
||||
#ifdef EXTREME_LOGGING
|
||||
|
@ -613,12 +613,12 @@ static void uc2_moveword ()
|
|||
rdp.clip_ratio = sqrt((float)rdp.cmd1);
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
}
|
||||
FRDP ("mw_clip %08lx, %08lx\n", rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("mw_clip %08x, %08x\n", rdp.cmd0, rdp.cmd1);
|
||||
break;
|
||||
|
||||
case 0x06: // moveword SEGMENT
|
||||
{
|
||||
FRDP ("SEGMENT %08lx -> seg%d\n", data, offset >> 2);
|
||||
FRDP ("SEGMENT %08x -> seg%d\n", data, offset >> 2);
|
||||
if ((data&BMASK)<BMASK)
|
||||
rdp.segment[(offset >> 2) & 0xF] = data;
|
||||
}
|
||||
|
@ -641,7 +641,7 @@ static void uc2_moveword ()
|
|||
case 0x0a: // moveword LIGHTCOL
|
||||
{
|
||||
int n = offset / 24;
|
||||
FRDP ("lightcol light:%d, %08lx\n", n, data);
|
||||
FRDP ("lightcol light:%d, %08x\n", n, data);
|
||||
|
||||
rdp.light[n].r = (float)((data >> 24) & 0xFF) / 255.0f;
|
||||
rdp.light[n].g = (float)((data >> 16) & 0xFF) / 255.0f;
|
||||
|
@ -660,8 +660,8 @@ static void uc2_moveword ()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E("uc2:moveword unknown (index: 0x%08lx, offset 0x%08lx)\n", index, offset);
|
||||
FRDP ("unknown (index: 0x%08lx, offset 0x%08lx)\n", index, offset);
|
||||
FRDP_E("uc2:moveword unknown (index: 0x%08x, offset 0x%08x)\n", index, offset);
|
||||
FRDP ("unknown (index: 0x%08x, offset 0x%08x)\n", index, offset);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -700,7 +700,7 @@ static void uc2_movemem ()
|
|||
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08lx\n", scale_x, scale_y, scale_z,
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08x\n", scale_x, scale_y, scale_z,
|
||||
trans_x, trans_y, trans_z, a);
|
||||
}
|
||||
break;
|
||||
|
@ -797,7 +797,7 @@ static void uc2_dlist_cnt ()
|
|||
{
|
||||
wxUint32 addr = segoffset(rdp.cmd1) & BMASK;
|
||||
int count = rdp.cmd0 & 0x000000FF;
|
||||
FRDP ("dl_count - addr: %08lx, count: %d\n", addr, count);
|
||||
FRDP ("dl_count - addr: %08x, count: %d\n", addr, count);
|
||||
if (addr == 0)
|
||||
return;
|
||||
|
||||
|
|
|
@ -61,7 +61,7 @@ static void uc3_vertex()
|
|||
|
||||
static void uc3_tri1()
|
||||
{
|
||||
FRDP("uc3:tri1 #%d - %d, %d, %d - %08lx - %08lx\n", rdp.tri_n,
|
||||
FRDP("uc3:tri1 #%d - %d, %d, %d - %08x - %08x\n", rdp.tri_n,
|
||||
((rdp.cmd1 >> 16) & 0xFF)/5,
|
||||
((rdp.cmd1 >> 8) & 0xFF)/5,
|
||||
((rdp.cmd1 ) & 0xFF)/5, rdp.cmd0, rdp.cmd1);
|
||||
|
|
|
@ -48,7 +48,7 @@ static void uc5_dma_offsets ()
|
|||
dma_offset_mtx = rdp.cmd0 & 0x00FFFFFF;
|
||||
dma_offset_vtx = rdp.cmd1 & 0x00FFFFFF;
|
||||
vtx_last = 0;
|
||||
FRDP("uc5:dma_offsets - mtx: %08lx, vtx: %08lx\n", dma_offset_mtx, dma_offset_vtx);
|
||||
FRDP("uc5:dma_offsets - mtx: %08x, vtx: %08x\n", dma_offset_mtx, dma_offset_vtx);
|
||||
}
|
||||
|
||||
static void uc5_matrix ()
|
||||
|
@ -71,7 +71,7 @@ static void uc5_matrix ()
|
|||
|
||||
cur_mtx = n;
|
||||
|
||||
FRDP("uc5:matrix - #%d, addr: %08lx\n", n, addr);
|
||||
FRDP("uc5:matrix - #%d, addr: %08x\n", n, addr);
|
||||
|
||||
if (multiply)
|
||||
{
|
||||
|
@ -128,7 +128,7 @@ static void uc5_vertex ()
|
|||
vtx_last = 0;
|
||||
|
||||
int first = ((rdp.cmd0 >> 9) & 0x1F) + vtx_last;
|
||||
FRDP ("uc5:vertex - addr: %08lx, first: %d, count: %d, matrix: %08lx\n", addr, first, n, cur_mtx);
|
||||
FRDP ("uc5:vertex - addr: %08x, first: %d, count: %d, matrix: %08x\n", addr, first, n, cur_mtx);
|
||||
|
||||
int prj = cur_mtx;
|
||||
|
||||
|
@ -202,7 +202,7 @@ static void uc5_tridma ()
|
|||
wxUint32 addr = segoffset(rdp.cmd1) & BMASK;
|
||||
int num = (rdp.cmd0 & 0xFFF0) >> 4;
|
||||
//int num = ((rdp.cmd0 & 0x00F00000) >> 20) + 1; // same thing!
|
||||
FRDP("uc5:tridma #%d - addr: %08lx, count: %d\n", rdp.tri_n, addr, num);
|
||||
FRDP("uc5:tridma #%d - addr: %08x, count: %d\n", rdp.tri_n, addr, num);
|
||||
|
||||
int start, v0, v1, v2, flags;
|
||||
for (int i=0; i<num; i++)
|
||||
|
@ -266,7 +266,7 @@ static void uc5_dl_in_mem ()
|
|||
{
|
||||
wxUint32 addr = segoffset(rdp.cmd1) & BMASK;
|
||||
int count = (rdp.cmd0 & 0x00FF0000) >> 16;
|
||||
FRDP ("uc5:dl_in_mem - addr: %08lx, count: %d\n", addr, count);
|
||||
FRDP ("uc5:dl_in_mem - addr: %08x, count: %d\n", addr, count);
|
||||
|
||||
if (rdp.pc_i >= 9) {
|
||||
RDP_E ("** DL stack overflow **\n");
|
||||
|
@ -296,11 +296,11 @@ static void uc5_moveword()
|
|||
rdp.clip_ratio = sqrt((float)rdp.cmd1);
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
}
|
||||
FRDP ("clip %08lx, %08lx\n", rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("clip %08x, %08x\n", rdp.cmd0, rdp.cmd1);
|
||||
break;
|
||||
|
||||
case 0x06: // segment (verified same)
|
||||
FRDP ("segment: %08lx -> seg%d\n", rdp.cmd1, (rdp.cmd0 >> 10) & 0x0F);
|
||||
FRDP ("segment: %08x -> seg%d\n", rdp.cmd1, (rdp.cmd0 >> 10) & 0x0F);
|
||||
rdp.segment[(rdp.cmd0 >> 10) & 0x0F] = rdp.cmd1;
|
||||
break;
|
||||
|
||||
|
@ -319,13 +319,13 @@ static void uc5_moveword()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP ("(unknown) %02lx - IGNORED\n", rdp.cmd0&0xFF);
|
||||
FRDP ("(unknown) %02x - IGNORED\n", rdp.cmd0&0xFF);
|
||||
}
|
||||
}
|
||||
|
||||
static void uc5_setgeometrymode()
|
||||
{
|
||||
FRDP("uc0:setgeometrymode %08lx\n", rdp.cmd1);
|
||||
FRDP("uc0:setgeometrymode %08x\n", rdp.cmd1);
|
||||
|
||||
rdp.geom_mode |= rdp.cmd1;
|
||||
|
||||
|
@ -351,7 +351,7 @@ static void uc5_setgeometrymode()
|
|||
|
||||
static void uc5_cleargeometrymode()
|
||||
{
|
||||
FRDP("uc0:cleargeometrymode %08lx\n", rdp.cmd1);
|
||||
FRDP("uc0:cleargeometrymode %08x\n", rdp.cmd1);
|
||||
|
||||
rdp.geom_mode &= (~rdp.cmd1);
|
||||
|
||||
|
|
|
@ -747,7 +747,7 @@ static void uc6_read_background_data (DRAWIMAGE & d, bool bReadScale)
|
|||
int imageYorig= ((int *)gfx.RDRAM)[(addr+16)>>1] >> 5;
|
||||
rdp.last_bg = d.imagePtr;
|
||||
|
||||
FRDP ("imagePtr: %08lx\n", d.imagePtr);
|
||||
FRDP ("imagePtr: %08x\n", d.imagePtr);
|
||||
FRDP ("frameX: %f, frameW: %d, frameY: %f, frameH: %d\n", d.frameX, d.frameW, d.frameY, d.frameH);
|
||||
FRDP ("imageX: %d, imageW: %d, imageY: %d, imageH: %d\n", d.imageX, d.imageW, d.imageY, d.imageH);
|
||||
FRDP ("imageYorig: %d, scaleX: %f, scaleY: %f\n", imageYorig, d.scaleX, d.scaleY);
|
||||
|
@ -1058,7 +1058,7 @@ static void uc6_obj_rectangle ()
|
|||
|
||||
if (d.imageAdrs > 4096)
|
||||
{
|
||||
FRDP("tmem: %08lx is out of bounds! return\n", d.imageAdrs);
|
||||
FRDP("tmem: %08x is out of bounds! return\n", d.imageAdrs);
|
||||
return;
|
||||
}
|
||||
if (!rdp.s2dex_tex_loaded)
|
||||
|
@ -1367,7 +1367,7 @@ static void uc6_obj_loadtxtr ()
|
|||
wxUint16 phead = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 4)] - 256; // 4
|
||||
wxUint16 pnum = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 5)] + 1; // 5
|
||||
|
||||
FRDP ("palette addr: %08lx, start: %d, num: %d\n", image, phead, pnum);
|
||||
FRDP ("palette addr: %08x, start: %d, num: %d\n", image, phead, pnum);
|
||||
load_palette (image, phead, pnum);
|
||||
}
|
||||
else if (type == 0x00001033) { // TxtrBlock
|
||||
|
@ -1376,7 +1376,7 @@ static void uc6_obj_loadtxtr ()
|
|||
wxUint16 tsize = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 5)]; // 5
|
||||
wxUint16 tline = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 6)]; // 6
|
||||
|
||||
FRDP ("addr: %08lx, tmem: %08lx, size: %d\n", image, tmem, tsize);
|
||||
FRDP ("addr: %08x, tmem: %08x, size: %d\n", image, tmem, tsize);
|
||||
rdp.timg.addr = image;
|
||||
rdp.timg.width = 1;
|
||||
rdp.timg.size = 1;
|
||||
|
@ -1394,7 +1394,7 @@ static void uc6_obj_loadtxtr ()
|
|||
wxUint16 twidth = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 5)]; // 5
|
||||
wxUint16 theight = ((wxUint16 *)gfx.RDRAM)[SHORTADDR(addr + 6)]; // 6
|
||||
|
||||
FRDP ("tile addr: %08lx, tmem: %08lx, twidth: %d, theight: %d\n", image, tmem, twidth, theight);
|
||||
FRDP ("tile addr: %08x, tmem: %08x, twidth: %d, theight: %d\n", image, tmem, twidth, theight);
|
||||
|
||||
int line = (twidth + 1) >> 2;
|
||||
|
||||
|
@ -1413,8 +1413,8 @@ static void uc6_obj_loadtxtr ()
|
|||
}
|
||||
else
|
||||
{
|
||||
FRDP ("UNKNOWN (0x%08lx)\n", type);
|
||||
FRDP_E ("uc6:obj_loadtxtr UNKNOWN (0x%08lx)\n", type);
|
||||
FRDP ("UNKNOWN (0x%08x)\n", type);
|
||||
FRDP_E ("uc6:obj_loadtxtr UNKNOWN (0x%08x)\n", type);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1541,7 +1541,7 @@ void uc6_sprite2d ()
|
|||
stride *= scaleY;
|
||||
d.scaleY = 1.0f;
|
||||
}
|
||||
FRDP ("imagePtr: %08lx\n", d.imagePtr);
|
||||
FRDP ("imagePtr: %08x\n", d.imagePtr);
|
||||
FRDP ("frameX: %f, frameW: %d, frameY: %f, frameH: %d\n", d.frameX, d.frameW, d.frameY, d.frameH);
|
||||
FRDP ("imageX: %d, imageW: %d, imageY: %d, imageH: %d\n", d.imageX, d.imageW, d.imageY, d.imageH);
|
||||
FRDP ("imageFmt: %d, imageSiz: %d, imagePal: %d, imageStride: %d\n", d.imageFmt, d.imageSiz, d.imagePal, stride);
|
||||
|
|
|
@ -93,7 +93,7 @@ static void uc7_vertex ()
|
|||
rdp.v0 = v0 = (rdp.cmd0 & 0x0F0000) >> 16;
|
||||
rdp.vn = n = ((rdp.cmd0 & 0xF00000) >> 20) + 1;
|
||||
|
||||
FRDP ("uc7:vertex n: %d, v0: %d, from: %08lx\n", n, v0, addr);
|
||||
FRDP ("uc7:vertex n: %d, v0: %d, from: %08x\n", n, v0, addr);
|
||||
|
||||
vtx_uc7 *vertex = (vtx_uc7 *)&gfx.RDRAM[addr];
|
||||
|
||||
|
@ -109,7 +109,7 @@ static void uc7_vertex ()
|
|||
v->uv_scaled = 0;
|
||||
|
||||
#ifdef EXTREME_LOGGING
|
||||
// FRDP ("before: v%d - x: %f, y: %f, z: %f, flags: %04lx, ou: %f, ov: %f\n", i>>4, x, y, z, v->flags, v->ou, v->ov);
|
||||
// FRDP ("before: v%d - x: %f, y: %f, z: %f, flags: %04x, ou: %f, ov: %f\n", i>>4, x, y, z, v->flags, v->ou, v->ov);
|
||||
#endif
|
||||
|
||||
v->x = x*rdp.combined[0][0] + y*rdp.combined[1][0] + z*rdp.combined[2][0] + rdp.combined[3][0];
|
||||
|
|
|
@ -59,7 +59,7 @@ static void uc8_vertex ()
|
|||
rdp.vn = n = (rdp.cmd0 >> 12) & 0xFF;
|
||||
rdp.v0 = v0 = ((rdp.cmd0 >> 1) & 0x7F) - n;
|
||||
|
||||
FRDP ("uc8:vertex n: %d, v0: %d, from: %08lx\n", n, v0, addr);
|
||||
FRDP ("uc8:vertex n: %d, v0: %d, from: %08x\n", n, v0, addr);
|
||||
|
||||
if (v0 < 0)
|
||||
{
|
||||
|
@ -129,7 +129,7 @@ static void uc8_vertex ()
|
|||
v->g = ((wxUint8*)gfx.RDRAM)[BYTEADDR(addr+i + 13)];
|
||||
v->b = ((wxUint8*)gfx.RDRAM)[BYTEADDR(addr+i + 14)];
|
||||
#ifdef EXTREME_LOGGING
|
||||
FRDP ("r: %02lx, g: %02lx, b: %02lx, a: %02lx\n", v->r, v->g, v->b, v->a);
|
||||
FRDP ("r: %02x, g: %02x, b: %02x, a: %02x\n", v->r, v->g, v->b, v->a);
|
||||
#endif
|
||||
|
||||
if ((rdp.geom_mode & 0x00020000))
|
||||
|
@ -153,8 +153,8 @@ static void uc8_vertex ()
|
|||
FRDP ("calc sphere: v%d - u: %f, v: %f\n", i>>4, v->ou, v->ov);
|
||||
#endif
|
||||
}
|
||||
// FRDP("calc light. r: 0x%02lx, g: 0x%02lx, b: 0x%02lx, nx: %.3f, ny: %.3f, nz: %.3f\n", v->r, v->g, v->b, v->vec[0], v->vec[1], v->vec[2]);
|
||||
FRDP("v[%d] calc light. r: 0x%02lx, g: 0x%02lx, b: 0x%02lx\n", i>>4, v->r, v->g, v->b);
|
||||
// FRDP("calc light. r: 0x%02x, g: 0x%02x, b: 0x%02x, nx: %.3f, ny: %.3f, nz: %.3f\n", v->r, v->g, v->b, v->vec[0], v->vec[1], v->vec[2]);
|
||||
FRDP("v[%d] calc light. r: 0x%02x, g: 0x%02x, b: 0x%02x\n", i>>4, v->r, v->g, v->b);
|
||||
float color[3] = {rdp.light[rdp.num_lights].r, rdp.light[rdp.num_lights].g, rdp.light[rdp.num_lights].b};
|
||||
FRDP("ambient light. r: %f, g: %f, b: %f\n", color[0], color[1], color[2]);
|
||||
float light_intensity = 0.0f;
|
||||
|
@ -227,7 +227,7 @@ static void uc8_vertex ()
|
|||
v->g = (wxUint8)(((float)v->g)*color[1]);
|
||||
v->b = (wxUint8)(((float)v->b)*color[2]);
|
||||
#ifdef EXTREME_LOGGING
|
||||
FRDP("color after light: r: 0x%02lx, g: 0x%02lx, b: 0x%02lx\n", v->r, v->g, v->b);
|
||||
FRDP("color after light: r: 0x%02x, g: 0x%02x, b: 0x%02x\n", v->r, v->g, v->b);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
@ -258,12 +258,12 @@ static void uc8_moveword ()
|
|||
rdp.clip_ratio = sqrt((float)rdp.cmd1);
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
}
|
||||
FRDP ("mw_clip %08lx, %08lx\n", rdp.cmd0, rdp.cmd1);
|
||||
FRDP ("mw_clip %08x, %08x\n", rdp.cmd0, rdp.cmd1);
|
||||
break;
|
||||
|
||||
case 0x06: // moveword SEGMENT
|
||||
{
|
||||
FRDP ("SEGMENT %08lx -> seg%d\n", data, offset >> 2);
|
||||
FRDP ("SEGMENT %08x -> seg%d\n", data, offset >> 2);
|
||||
rdp.segment[(offset >> 2) & 0xF] = data;
|
||||
}
|
||||
break;
|
||||
|
@ -289,7 +289,7 @@ static void uc8_moveword ()
|
|||
{
|
||||
wxUint8 n = offset >> 2;
|
||||
|
||||
FRDP ("coord mod:%d, %08lx\n", n, data);
|
||||
FRDP ("coord mod:%d, %08x\n", n, data);
|
||||
if (rdp.cmd0&8)
|
||||
return;
|
||||
wxUint32 idx = (rdp.cmd0>>1)&3;
|
||||
|
@ -326,8 +326,8 @@ static void uc8_moveword ()
|
|||
break;
|
||||
|
||||
default:
|
||||
FRDP_E("uc8:moveword unknown (index: 0x%08lx, offset 0x%08lx)\n", index, offset);
|
||||
FRDP ("unknown (index: 0x%08lx, offset 0x%08lx)\n", index, offset);
|
||||
FRDP_E("uc8:moveword unknown (index: 0x%08x, offset 0x%08x)\n", index, offset);
|
||||
FRDP ("unknown (index: 0x%08x, offset 0x%08x)\n", index, offset);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -359,7 +359,7 @@ static void uc8_movemem ()
|
|||
|
||||
rdp.update |= UPDATE_VIEWPORT;
|
||||
|
||||
FRDP ("viewport scale(%d, %d), trans(%d, %d), from:%08lx\n", scale_x, scale_y,
|
||||
FRDP ("viewport scale(%d, %d), trans(%d, %d), from:%08x\n", scale_x, scale_y,
|
||||
trans_x, trans_y, a);
|
||||
}
|
||||
break;
|
||||
|
@ -417,7 +417,7 @@ static void uc8_movemem ()
|
|||
#ifdef EXTREME_LOGGING
|
||||
for (int t=0; t < 24; t++)
|
||||
{
|
||||
FRDP ("light[%d] = 0x%04lx \n", t, ((wxUint16*)gfx.RDRAM)[SHORTADDR(a+t)]);
|
||||
FRDP ("light[%d] = 0x%04x \n", t, ((wxUint16*)gfx.RDRAM)[SHORTADDR(a+t)]);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
@ -426,7 +426,7 @@ static void uc8_movemem ()
|
|||
case 14: //Normales
|
||||
{
|
||||
uc8_normale_addr = segoffset(rdp.cmd1);
|
||||
FRDP ("Normale - addr: %08lx\n", uc8_normale_addr);
|
||||
FRDP ("Normale - addr: %08x\n", uc8_normale_addr);
|
||||
#ifdef EXTREME_LOGGING
|
||||
int i;
|
||||
for (i = 0; i < 32; i++)
|
||||
|
@ -438,7 +438,7 @@ static void uc8_movemem ()
|
|||
wxUint32 a = uc8_normale_addr >> 1;
|
||||
for (i = 0; i < 32; i++)
|
||||
{
|
||||
FRDP ("n[%d] = 0x%04lx \n", i, ((wxUint16*)gfx.RDRAM)[SHORTADDR(a+i)]);
|
||||
FRDP ("n[%d] = 0x%04x \n", i, ((wxUint16*)gfx.RDRAM)[SHORTADDR(a+i)]);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -252,7 +252,7 @@ static void uc9_fmlight ()
|
|||
int mid = rdp.cmd0&0xFF;
|
||||
rdp.num_lights = 1 + ((rdp.cmd1>>12)&0xFF);
|
||||
wxUint32 a = -1024 + (rdp.cmd1&0xFFF);
|
||||
FRDP ("uc9:fmlight matrix: %d, num: %d, dmem: %04lx\n", mid, rdp.num_lights, a);
|
||||
FRDP ("uc9:fmlight matrix: %d, num: %d, dmem: %04x\n", mid, rdp.num_lights, a);
|
||||
|
||||
M44 *m = NULL;
|
||||
switch (mid) {
|
||||
|
@ -320,7 +320,7 @@ static void uc9_light ()
|
|||
wxUint32 tdest = -1024 + (rdp.cmd1&0xFFF);
|
||||
int use_material = (csrs != 0x0ff0);
|
||||
tdest >>= 1;
|
||||
FRDP ("uc9:light n: %d, colsrs: %04lx, normales: %04lx, coldst: %04lx, texdst: %04lx\n", num, csrs, nsrs, cdest, tdest);
|
||||
FRDP ("uc9:light n: %d, colsrs: %04x, normales: %04x, coldst: %04x, texdst: %04x\n", num, csrs, nsrs, cdest, tdest);
|
||||
VERTEX v;
|
||||
for (wxUint32 i = 0; i < num; i++)
|
||||
{
|
||||
|
@ -466,7 +466,7 @@ static void uc9_mult_mpmtx ()
|
|||
int num = 1+ ((rdp.cmd1>>24)&0xFF);
|
||||
int src = -1024 + ((rdp.cmd1>>12)&0xFFF);
|
||||
int dst = -1024 + (rdp.cmd1&0xFFF);
|
||||
FRDP ("uc9:mult_mpmtx from: %04lx to: %04lx n: %d\n", src, dst, num);
|
||||
FRDP ("uc9:mult_mpmtx from: %04x to: %04x n: %d\n", src, dst, num);
|
||||
short * saddr = (short*)(gfx.DMEM+src);
|
||||
zSortVDest * daddr = (zSortVDest*)(gfx.DMEM+dst);
|
||||
int idx = 0;
|
||||
|
@ -511,7 +511,7 @@ static void uc9_mult_mpmtx ()
|
|||
daddr[i] = v;
|
||||
//memcpy(gfx.DMEM+dst+sizeof(zSortVDest)*i, &v, sizeof(zSortVDest));
|
||||
// FRDP("v%d x: %d, y: %d, z: %d -> sx: %d, sy: %d, w: %d, xi: %d, yi: %d, wi: %d, fog: %d\n", i, sx, sy, sz, v.sx, v.sy, v.invw, v.xi, v.yi, v.wi, v.fog);
|
||||
FRDP("v%d x: %d, y: %d, z: %d -> sx: %04lx, sy: %04lx, invw: %08lx - %f, xi: %04lx, yi: %04lx, wi: %04lx, fog: %04lx\n", i, sx, sy, sz, v.sx, v.sy, v.invw, w, v.xi, v.yi, v.wi, v.fog);
|
||||
FRDP("v%d x: %d, y: %d, z: %d -> sx: %04x, sy: %04x, invw: %08x - %f, xi: %04x, yi: %04x, wi: %04x, fog: %04x\n", i, sx, sy, sz, v.sx, v.sy, v.invw, w, v.xi, v.yi, v.wi, v.fog);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -551,13 +551,13 @@ void uc9_movemem ()
|
|||
if (flag == 0)
|
||||
{
|
||||
int dmem_addr = (idx<<3) + ofs;
|
||||
FRDP ("Load to DMEM. %08lx -> %08lx\n", addr, dmem_addr);
|
||||
FRDP ("Load to DMEM. %08x -> %08x\n", addr, dmem_addr);
|
||||
memcpy(gfx.DMEM + dmem_addr, gfx.RDRAM + addr, len);
|
||||
}
|
||||
else
|
||||
{
|
||||
int dmem_addr = (idx<<3) + ofs;
|
||||
FRDP ("Load from DMEM. %08lx -> %08lx\n", dmem_addr, addr);
|
||||
FRDP ("Load from DMEM. %08x -> %08x\n", dmem_addr, addr);
|
||||
memcpy(gfx.RDRAM + addr, gfx.DMEM + dmem_addr, len);
|
||||
}
|
||||
break;
|
||||
|
@ -642,7 +642,7 @@ void uc9_movemem ()
|
|||
|
||||
rdp.geom_mode |= 0x0200;
|
||||
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08lx\n", scale_x, scale_y, scale_z,
|
||||
FRDP ("viewport scale(%d, %d, %d), trans(%d, %d, %d), from:%08x\n", scale_x, scale_y, scale_z,
|
||||
trans_x, trans_y, trans_z, a);
|
||||
FRDP ("fog: multiplier: %f, offset: %f\n", rdp.fog_multiplier, rdp.fog_offset);
|
||||
}
|
||||
|
|
|
@ -44,7 +44,7 @@
|
|||
void uc9_rpdcmd ()
|
||||
{
|
||||
wxUint32 a = segoffset(rdp.cmd1) >> 2;
|
||||
FRDP ("uc9:rdpcmd addr: %08lx\n", a);
|
||||
FRDP ("uc9:rdpcmd addr: %08x\n", a);
|
||||
if (a)
|
||||
{
|
||||
rdp.LLE = 1;
|
||||
|
|
|
@ -44,7 +44,7 @@
|
|||
static void uc10_branch_w()
|
||||
{
|
||||
wxUint32 addr = segoffset(branch_dl);
|
||||
FRDP ("uc10:branch_less_w, addr: %08lx\n", addr);
|
||||
FRDP ("uc10:branch_less_w, addr: %08x\n", addr);
|
||||
|
||||
wxUint32 vtx = (rdp.cmd0 >> 1) & 0x7F;
|
||||
|
||||
|
|
|
@ -62,14 +62,14 @@ static void fb_bg_copy ()
|
|||
if (rdp.main_ci == 0)
|
||||
return;
|
||||
CI_STATUS status = rdp.frame_buffers[rdp.ci_count-1].status;
|
||||
if ( (status == ci_copy) )
|
||||
if (status == ci_copy)
|
||||
return;
|
||||
|
||||
wxUint32 addr = segoffset(rdp.cmd1) >> 1;
|
||||
wxUint8 imageFmt = ((wxUint8 *)gfx.RDRAM)[BYTEADDR(((addr+11)<<1)+0)];
|
||||
wxUint8 imageSiz = ((wxUint8 *)gfx.RDRAM)[BYTEADDR(((addr+11)<<1)+1)];
|
||||
wxUint32 imagePtr = segoffset(((wxUint32*)gfx.RDRAM)[(addr+8)>>1]);
|
||||
FRDP ("fb_bg_copy. fmt: %d, size: %d, imagePtr %08lx, main_ci: %08lx, cur_ci: %08lx \n", imageFmt, imageSiz, imagePtr, rdp.main_ci, rdp.frame_buffers[rdp.ci_count-1].addr);
|
||||
FRDP ("fb_bg_copy. fmt: %d, size: %d, imagePtr %08x, main_ci: %08x, cur_ci: %08x \n", imageFmt, imageSiz, imagePtr, rdp.main_ci, rdp.frame_buffers[rdp.ci_count-1].addr);
|
||||
|
||||
if (status == ci_main)
|
||||
{
|
||||
|
@ -95,7 +95,7 @@ static void fb_bg_copy ()
|
|||
rdp.motionblur = TRUE;
|
||||
}
|
||||
|
||||
FRDP ("Detect FB usage. texture addr is inside framebuffer: %08lx - %08lx \n", imagePtr, rdp.main_ci);
|
||||
FRDP ("Detect FB usage. texture addr is inside framebuffer: %08x - %08x \n", imagePtr, rdp.main_ci);
|
||||
}
|
||||
else if (imagePtr == rdp.zimg)
|
||||
{
|
||||
|
@ -184,7 +184,7 @@ static void fb_settextureimage()
|
|||
wxUint32 addr = segoffset(rdp.cmd1);
|
||||
if ( tex_format == 0 )
|
||||
{
|
||||
FRDP ("fb_settextureimage. fmt: %d, size: %d, imagePtr %08lx, main_ci: %08lx, cur_ci: %08lx \n", ((rdp.cmd0 >> 21) & 0x07), ((rdp.cmd0 >> 19) & 0x03), addr, rdp.main_ci, rdp.frame_buffers[rdp.ci_count-1].addr);
|
||||
FRDP ("fb_settextureimage. fmt: %d, size: %d, imagePtr %08x, main_ci: %08x, cur_ci: %08x \n", ((rdp.cmd0 >> 21) & 0x07), ((rdp.cmd0 >> 19) & 0x03), addr, rdp.main_ci, rdp.frame_buffers[rdp.ci_count-1].addr);
|
||||
if (cur_fb.status == ci_main)
|
||||
{
|
||||
rdp.main_ci_last_tex_addr = addr;
|
||||
|
@ -237,7 +237,7 @@ static void fb_settextureimage()
|
|||
FRDP("rdp.frame_buffers[%d].status = ci_aux\n", rdp.copy_ci_index);
|
||||
}
|
||||
}
|
||||
FRDP ("Detect FB usage. texture addr is inside framebuffer: %08lx - %08lx \n", addr, rdp.main_ci);
|
||||
FRDP ("Detect FB usage. texture addr is inside framebuffer: %08x - %08x \n", addr, rdp.main_ci);
|
||||
}
|
||||
///*
|
||||
else if ((cur_fb.status != ci_main) && (addr >= rdp.zimg && addr < rdp.zimg_end))
|
||||
|
@ -253,7 +253,7 @@ static void fb_settextureimage()
|
|||
if (cur_fb.status != ci_main)
|
||||
{
|
||||
cur_fb.status = ci_old_copy;
|
||||
FRDP("rdp.frame_buffers[%d].status = ci_old_copy 1, addr:%08lx\n", rdp.ci_count-1, rdp.last_drawn_ci_addr);
|
||||
FRDP("rdp.frame_buffers[%d].status = ci_old_copy 1, addr:%08x\n", rdp.ci_count-1, rdp.last_drawn_ci_addr);
|
||||
}
|
||||
rdp.read_previous_ci = TRUE;
|
||||
LRDP("read_previous_ci = TRUE\n");
|
||||
|
@ -263,7 +263,7 @@ static void fb_settextureimage()
|
|||
if (cur_fb.status != ci_main)
|
||||
{
|
||||
cur_fb.status = ci_old_copy;
|
||||
FRDP("rdp.frame_buffers[%d].status = ci_old_copy 2, addr:%08lx\n", rdp.ci_count-1, rdp.last_drawn_ci_addr);
|
||||
FRDP("rdp.frame_buffers[%d].status = ci_old_copy 2, addr:%08x\n", rdp.ci_count-1, rdp.last_drawn_ci_addr);
|
||||
}
|
||||
rdp.read_previous_ci = TRUE;
|
||||
LRDP("read_previous_ci = TRUE\n");
|
||||
|
@ -300,7 +300,7 @@ static void fb_setdepthimage()
|
|||
{
|
||||
rdp.zimg = segoffset(rdp.cmd1) & BMASK;
|
||||
rdp.zimg_end = rdp.zimg + rdp.ci_width*rdp.ci_height*2;
|
||||
FRDP ("fb_setdepthimage. addr %08lx - %08lx\n", rdp.zimg, rdp.zimg_end);
|
||||
FRDP ("fb_setdepthimage. addr %08x - %08x\n", rdp.zimg, rdp.zimg_end);
|
||||
if (rdp.zimg == rdp.main_ci) //strange, but can happen
|
||||
{
|
||||
rdp.frame_buffers[rdp.main_ci_index].status = ci_unknown;
|
||||
|
@ -362,7 +362,7 @@ static void fb_setcolorimage()
|
|||
if (rdp.frame_buffers[0].addr == rdp.cimg)
|
||||
rdp.frame_buffers[0].height = rdp.scissor_o.lr_y;
|
||||
*/
|
||||
FRDP ("fb_setcolorimage. width: %d, height: %d, fmt: %d, size: %d, addr %08lx\n", cur_fb.width, cur_fb.height, cur_fb.format, cur_fb.size, cur_fb.addr);
|
||||
FRDP ("fb_setcolorimage. width: %d, height: %d, fmt: %d, size: %d, addr %08x\n", cur_fb.width, cur_fb.height, cur_fb.format, cur_fb.size, cur_fb.addr);
|
||||
if (rdp.cimg == rdp.zimg)
|
||||
{
|
||||
cur_fb.status = ci_zimg;
|
||||
|
|
|
@ -25,12 +25,13 @@
|
|||
#pragma warning(disable: 4786)
|
||||
#endif
|
||||
|
||||
#include <boost/filesystem.hpp>
|
||||
#include "ghc/fs_std.hpp"
|
||||
#include <zlib.h>
|
||||
#include "TxCache.h"
|
||||
#include "TxDbg.h"
|
||||
#include "../Glide64/m64p.h"
|
||||
#include "../Glide64/Gfx_1.3.h"
|
||||
#include "osal_files.h"
|
||||
|
||||
TxCache::~TxCache()
|
||||
{
|
||||
|
@ -237,11 +238,11 @@ TxCache::save(const wchar_t *path, const wchar_t *filename, int config)
|
|||
/* dump cache to disk */
|
||||
char cbuf[MAX_PATH];
|
||||
|
||||
boost::filesystem::wpath cachepath(path);
|
||||
boost::filesystem::create_directory(cachepath);
|
||||
fs::path cachepath(path);
|
||||
osal_mkdirp(cachepath.wstring().c_str());
|
||||
|
||||
/* Ugly hack to enable fopen/gzopen in Win9x */
|
||||
#ifdef BOOST_WINDOWS_API
|
||||
#ifdef _WIN32
|
||||
wchar_t curpath[MAX_PATH];
|
||||
GETCWD(MAX_PATH, curpath);
|
||||
CHDIR(cachepath.wstring().c_str());
|
||||
|
@ -330,9 +331,9 @@ TxCache::load(const wchar_t *path, const wchar_t *filename, int config)
|
|||
/* find it on disk */
|
||||
char cbuf[MAX_PATH];
|
||||
|
||||
boost::filesystem::wpath cachepath(path);
|
||||
fs::path cachepath(path);
|
||||
|
||||
#ifdef BOOST_WINDOWS_API
|
||||
#ifdef _WIN32
|
||||
wchar_t curpath[MAX_PATH];
|
||||
GETCWD(MAX_PATH, curpath);
|
||||
CHDIR(cachepath.wstring().c_str());
|
||||
|
|
|
@ -36,6 +36,8 @@
|
|||
#define swprintf _snwprintf
|
||||
#endif
|
||||
|
||||
#include "osal_files.h"
|
||||
|
||||
typedef struct {
|
||||
uint32 *src;
|
||||
uint32 srcwidth;
|
||||
|
@ -658,18 +660,18 @@ TxFilter::dmptx(uint8 *src, int width, int height, int rowStridePixel, uint16 gf
|
|||
|
||||
/* create directories */
|
||||
tmpbuf.assign(_datapath + L"/texture_dump");
|
||||
if (!boost::filesystem::exists(tmpbuf) &&
|
||||
!boost::filesystem::create_directory(tmpbuf))
|
||||
if (!osal_path_existsW(tmpbuf.c_str()) &&
|
||||
!osal_mkdirp(tmpbuf.c_str()))
|
||||
return 0;
|
||||
|
||||
tmpbuf.append(L"/" + _ident);
|
||||
if (!boost::filesystem::exists(tmpbuf) &&
|
||||
!boost::filesystem::create_directory(tmpbuf))
|
||||
if (!osal_path_existsW(tmpbuf.c_str()) &&
|
||||
!osal_mkdirp(tmpbuf.c_str()))
|
||||
return 0;
|
||||
|
||||
tmpbuf.append(L"/GlideHQ");
|
||||
if (!boost::filesystem::exists(tmpbuf) &&
|
||||
!boost::filesystem::create_directory(tmpbuf))
|
||||
if (!osal_path_existsW(tmpbuf.c_str()) &&
|
||||
!osal_mkdirp(tmpbuf.c_str()))
|
||||
return 0;
|
||||
|
||||
if ((n64fmt >> 8) == 0x2) {
|
||||
|
|
|
@ -58,6 +58,8 @@
|
|||
#include "TxHiResCache.h"
|
||||
#include "TxDbg.h"
|
||||
#include "../Glide64/Gfx_1.3.h"
|
||||
#include "osal_files.h"
|
||||
|
||||
|
||||
TxHiResCache::~TxHiResCache()
|
||||
{
|
||||
|
@ -65,8 +67,8 @@ TxHiResCache::~TxHiResCache()
|
|||
if ((_options & DUMP_HIRESTEXCACHE) && !_haveCache && !_abortLoad) {
|
||||
/* dump cache to disk */
|
||||
std::wstring filename = _ident + L"_HIRESTEXTURES.dat";
|
||||
boost::filesystem::wpath cachepath(_cachepath);
|
||||
cachepath /= boost::filesystem::wpath(L"glidehq");
|
||||
fs::path cachepath(_cachepath);
|
||||
cachepath /= fs::path(L"glidehq");
|
||||
int config = _options & (HIRESTEXTURES_MASK|COMPRESS_HIRESTEX|COMPRESSION_MASK|TILE_HIRESTEX|FORCE16BPP_HIRESTEX|GZ_HIRESTEXCACHE|LET_TEXARTISTS_FLY);
|
||||
|
||||
TxCache::save(cachepath.wstring().c_str(), filename.c_str(), config);
|
||||
|
@ -107,8 +109,8 @@ TxHiResCache::TxHiResCache(int maxwidth, int maxheight, int maxbpp, int options,
|
|||
if (_options & DUMP_HIRESTEXCACHE) {
|
||||
/* find it on disk */
|
||||
std::wstring filename = _ident + L"_HIRESTEXTURES.dat";
|
||||
boost::filesystem::wpath cachepath(_cachepath);
|
||||
cachepath /= boost::filesystem::wpath(L"glidehq");
|
||||
fs::path cachepath(_cachepath);
|
||||
cachepath /= fs::path(L"glidehq");
|
||||
int config = _options & (HIRESTEXTURES_MASK|COMPRESS_HIRESTEX|COMPRESSION_MASK|TILE_HIRESTEX|FORCE16BPP_HIRESTEX|GZ_HIRESTEXCACHE|LET_TEXARTISTS_FLY);
|
||||
|
||||
_haveCache = TxCache::load(cachepath.wstring().c_str(), filename.c_str(), config);
|
||||
|
@ -132,7 +134,7 @@ TxHiResCache::load(boolean replace) /* 0 : reload, 1 : replace partial */
|
|||
|
||||
if (!replace) TxCache::clear();
|
||||
|
||||
boost::filesystem::wpath dir_path(_datapath);
|
||||
fs::path dir_path(_datapath);
|
||||
|
||||
switch (_options & HIRESTEXTURES_MASK) {
|
||||
case GHQ_HIRESTEXTURES:
|
||||
|
@ -149,8 +151,8 @@ TxHiResCache::load(boolean replace) /* 0 : reload, 1 : replace partial */
|
|||
INFO(80, L" usage of only 2) and 3) highly recommended!\n");
|
||||
INFO(80, L" folder names must be in US-ASCII characters!\n");
|
||||
|
||||
dir_path /= boost::filesystem::wpath(L"hires_texture");
|
||||
dir_path /= boost::filesystem::wpath(_ident);
|
||||
dir_path /= fs::path(L"hires_texture");
|
||||
dir_path /= fs::path(_ident);
|
||||
loadHiResTextures(dir_path, replace);
|
||||
break;
|
||||
case JABO_HIRESTEXTURES:
|
||||
|
@ -164,7 +166,7 @@ TxHiResCache::load(boolean replace) /* 0 : reload, 1 : replace partial */
|
|||
}
|
||||
|
||||
boolean
|
||||
TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean replace)
|
||||
TxHiResCache::loadHiResTextures(fs::path dir_path, boolean replace)
|
||||
{
|
||||
uint32_t last, now, diff;
|
||||
DBG_INFO(80, L"-----\n");
|
||||
|
@ -172,7 +174,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
last = SDL_GetTicks();
|
||||
|
||||
/* find it on disk */
|
||||
if (!boost::filesystem::exists(dir_path)) {
|
||||
if (!osal_path_existsW(dir_path.wstring().c_str())) {
|
||||
INFO(80, L"Error: path not found!\n");
|
||||
return 0;
|
||||
}
|
||||
|
@ -205,8 +207,8 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
*
|
||||
* RULE OF THUMB: NEVER save texture packs in NON-ASCII names!!
|
||||
*/
|
||||
boost::filesystem::directory_iterator it(dir_path);
|
||||
boost::filesystem::directory_iterator end_it; /* default construction yields past-the-end */
|
||||
fs::directory_iterator it(dir_path);
|
||||
fs::directory_iterator end_it; /* default construction yields past-the-end */
|
||||
|
||||
for (; it != end_it; ++it) {
|
||||
|
||||
|
@ -218,13 +220,13 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
if (_abortLoad) break;
|
||||
|
||||
/* recursive read into sub-directory */
|
||||
if (boost::filesystem::is_directory(it->status())) {
|
||||
if (fs::is_directory(it->status())) {
|
||||
loadHiResTextures(it->path(), replace);
|
||||
continue;
|
||||
}
|
||||
|
||||
DBG_INFO(80, L"-----\n");
|
||||
DBG_INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
DBG_INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
|
||||
int width = 0, height = 0;
|
||||
uint16 format = 0;
|
||||
|
@ -257,8 +259,8 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
/* read in Rice's file naming convention */
|
||||
#define CRCFMTSIZ_LEN 13
|
||||
#define PALCRC_LEN 9
|
||||
//wcstombs(fname, it->path().leaf().c_str(), MAX_PATH);
|
||||
strncpy(fname, it->path().leaf().string().c_str(), sizeof(fname));
|
||||
//wcstombs(fname, it->path().filename().c_str(), MAX_PATH);
|
||||
strncpy(fname, it->path().filename().string().c_str(), sizeof(fname));
|
||||
fname[sizeof(fname) - 1] = '\0';
|
||||
/* XXX case sensitivity fiasco!
|
||||
* files must use _a, _rgb, _all, _allciByRGBA, _ciByRGBA, _ci
|
||||
|
@ -276,7 +278,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: not png or bmp or dds!\n");
|
||||
continue;
|
||||
|
@ -295,7 +297,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: not Rice texture naming convention!\n");
|
||||
continue;
|
||||
|
@ -304,7 +306,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: crc32 = 0!\n");
|
||||
continue;
|
||||
|
@ -319,7 +321,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: already cached! duplicate texture!\n");
|
||||
continue;
|
||||
|
@ -349,13 +351,13 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
*/
|
||||
if (pfname == strstr(fname, "_rgb.") || pfname == strstr(fname, "_a.")) {
|
||||
strcpy(pfname, "_rgb.png");
|
||||
if (!boost::filesystem::exists(fname)) {
|
||||
if (!osal_path_existsA(fname)) {
|
||||
strcpy(pfname, "_rgb.bmp");
|
||||
if (!boost::filesystem::exists(fname)) {
|
||||
if (!osal_path_existsA(fname)) {
|
||||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: missing _rgb.*! _a.* must be paired with _rgb.*!\n");
|
||||
continue;
|
||||
|
@ -396,7 +398,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
if (!tex) {
|
||||
INFO(80, L"Error: missing _rgb.*!\n");
|
||||
|
@ -448,7 +450,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Warning: missing _a.*! only using _rgb.*. treat as opaque texture.\n");
|
||||
int i;
|
||||
|
@ -495,7 +497,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: W:H aspect ratio range not 8:1 - 1:8!\n");
|
||||
continue;
|
||||
|
@ -507,7 +509,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: not power of 2 size!\n");
|
||||
continue;
|
||||
|
@ -520,7 +522,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: load failed!\n");
|
||||
continue;
|
||||
|
@ -539,7 +541,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
INFO(80, L"Error: not width * height > 4 or 8bit palette color or 32bpp or dxt1 or dxt3 or dxt5!\n");
|
||||
continue;
|
||||
|
@ -1017,7 +1019,7 @@ TxHiResCache::loadHiResTextures(boost::filesystem::wpath dir_path, boolean repla
|
|||
#if !DEBUG
|
||||
INFO(80, L"-----\n");
|
||||
INFO(80, L"path: %ls\n", dir_path.string().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().leaf().c_str());
|
||||
INFO(80, L"file: %ls\n", it->path().filename().c_str());
|
||||
#endif
|
||||
if (tex) {
|
||||
free(tex);
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
#include "TxQuantize.h"
|
||||
#include "TxImage.h"
|
||||
#include "TxReSample.h"
|
||||
#include <boost/filesystem.hpp>
|
||||
#include "ghc/fs_std.hpp"
|
||||
|
||||
class TxHiResCache : public TxCache
|
||||
{
|
||||
|
@ -47,7 +47,7 @@ private:
|
|||
TxImage *_txImage;
|
||||
TxQuantize *_txQuantize;
|
||||
TxReSample *_txReSample;
|
||||
boolean loadHiResTextures(boost::filesystem::wpath dir_path, boolean replace);
|
||||
boolean loadHiResTextures(fs::path dir_path, boolean replace);
|
||||
public:
|
||||
~TxHiResCache();
|
||||
TxHiResCache(int maxwidth, int maxheight, int maxbpp, int options,
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
#include "TxDbg.h"
|
||||
#include <zlib.h>
|
||||
#include <string>
|
||||
#include <boost/filesystem.hpp>
|
||||
#include "ghc/fs_std.hpp"
|
||||
|
||||
TxTexCache::~TxTexCache()
|
||||
{
|
||||
|
@ -37,8 +37,8 @@ TxTexCache::~TxTexCache()
|
|||
if (_options & DUMP_TEXCACHE) {
|
||||
/* dump cache to disk */
|
||||
std::wstring filename = _ident + L"_MEMORYCACHE.dat";
|
||||
boost::filesystem::wpath cachepath(_cachepath);
|
||||
cachepath /= boost::filesystem::wpath(L"glidehq");
|
||||
fs::path cachepath(_cachepath);
|
||||
cachepath /= fs::path(L"glidehq");
|
||||
int config = _options & (FILTER_MASK|ENHANCEMENT_MASK|COMPRESS_TEX|COMPRESSION_MASK|FORCE16BPP_TEX|GZ_TEXCACHE);
|
||||
|
||||
TxCache::save(cachepath.wstring().c_str(), filename.c_str(), config);
|
||||
|
@ -58,8 +58,8 @@ TxTexCache::TxTexCache(int options, int cachesize, const wchar_t *datapath, cons
|
|||
if (_options & DUMP_TEXCACHE) {
|
||||
/* find it on disk */
|
||||
std::wstring filename = _ident + L"_MEMORYCACHE.dat";
|
||||
boost::filesystem::wpath cachepath(_cachepath);
|
||||
cachepath /= boost::filesystem::wpath(L"glidehq");
|
||||
fs::path cachepath(_cachepath);
|
||||
cachepath /= fs::path(L"glidehq");
|
||||
int config = _options & (FILTER_MASK|ENHANCEMENT_MASK|COMPRESS_TEX|COMPRESSION_MASK|FORCE16BPP_TEX|GZ_TEXCACHE);
|
||||
|
||||
TxCache::load(cachepath.wstring().c_str(), filename.c_str(), config);
|
||||
|
|
6075
src/GlideHQ/ghc/filesystem.hpp
Normal file
6075
src/GlideHQ/ghc/filesystem.hpp
Normal file
File diff suppressed because it is too large
Load diff
77
src/GlideHQ/ghc/fs_std.hpp
Normal file
77
src/GlideHQ/ghc/fs_std.hpp
Normal file
|
@ -0,0 +1,77 @@
|
|||
//---------------------------------------------------------------------------------------
|
||||
//
|
||||
// ghc::filesystem - A C++17-like filesystem implementation for C++11/C++14
|
||||
//
|
||||
//---------------------------------------------------------------------------------------
|
||||
//
|
||||
// Copyright (c) 2018, Steffen Schümann <s.schuemann@pobox.com>
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
// of this software and associated documentation files (the "Software"), to deal
|
||||
// in the Software without restriction, including without limitation the rights
|
||||
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
// copies of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included in all
|
||||
// copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
// SOFTWARE.
|
||||
//
|
||||
//---------------------------------------------------------------------------------------
|
||||
// fs_std.hpp - The dynamic switching header that includes std::filesystem if detected
|
||||
// or ghc::filesystem if not, and makes the resulting API available in the
|
||||
// namespace fs.
|
||||
//---------------------------------------------------------------------------------------
|
||||
#ifndef GHC_FILESYSTEM_STD_H
|
||||
#define GHC_FILESYSTEM_STD_H
|
||||
|
||||
#if _MSVC_LANG >= 201703L || __cplusplus >= 201703L && defined(__has_include)
|
||||
// ^ Supports MSVC prior to 15.7 without setting /Zc:__cplusplus to fix __cplusplus
|
||||
// _MSVC_LANG works regardless. But without the switch, the compiler always reported 199711L: https://blogs.msdn.microsoft.com/vcblog/2018/04/09/msvc-now-correctly-reports-__cplusplus/
|
||||
#if __has_include(<filesystem>) // Two stage __has_include needed for MSVC 2015 and per https://gcc.gnu.org/onlinedocs/cpp/_005f_005fhas_005finclude.html
|
||||
#define GHC_USE_STD_FS
|
||||
|
||||
// Old Apple OSs don't support std::filesystem, though the header is available at compile
|
||||
// time. In particular, std::filesystem is unavailable before macOS 10.15, iOS/tvOS 13.0,
|
||||
// and watchOS 6.0.
|
||||
#ifdef __APPLE__
|
||||
#include <Availability.h>
|
||||
// Note: This intentionally uses std::filesystem on any new Apple OS, like visionOS
|
||||
// released after std::filesystem, where std::filesystem is always available.
|
||||
// (All other __<platform>_VERSION_MIN_REQUIREDs will be undefined and thus 0.)
|
||||
#if __MAC_OS_X_VERSION_MIN_REQUIRED && __MAC_OS_X_VERSION_MIN_REQUIRED < 101500 \
|
||||
|| __IPHONE_OS_VERSION_MIN_REQUIRED && __IPHONE_OS_VERSION_MIN_REQUIRED < 130000 \
|
||||
|| __TV_OS_VERSION_MIN_REQUIRED && __TV_OS_VERSION_MIN_REQUIRED < 130000 \
|
||||
|| __WATCH_OS_VERSION_MAX_ALLOWED && __WATCH_OS_VERSION_MAX_ALLOWED < 60000
|
||||
#undef GHC_USE_STD_FS
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
#endif
|
||||
|
||||
#ifdef GHC_USE_STD_FS
|
||||
#include <filesystem>
|
||||
namespace fs {
|
||||
using namespace std::filesystem;
|
||||
using ifstream = std::ifstream;
|
||||
using ofstream = std::ofstream;
|
||||
using fstream = std::fstream;
|
||||
}
|
||||
#else
|
||||
#include "filesystem.hpp"
|
||||
namespace fs {
|
||||
using namespace ghc::filesystem;
|
||||
using ifstream = ghc::filesystem::ifstream;
|
||||
using ofstream = ghc::filesystem::ofstream;
|
||||
using fstream = ghc::filesystem::fstream;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // GHC_FILESYSTEM_STD_H
|
12
src/GlideHQ/osal_export.h
Normal file
12
src/GlideHQ/osal_export.h
Normal file
|
@ -0,0 +1,12 @@
|
|||
#if !defined(OSAL_EXPORT_H)
|
||||
#define OSAL_EXPORT_H
|
||||
|
||||
#if defined(WIN32)
|
||||
#define EXPORT __declspec(dllexport)
|
||||
#define CALL __cdecl
|
||||
#else /* Not WINDOWS */
|
||||
#define EXPORT __attribute__((visibility("default")))
|
||||
#define CALL
|
||||
#endif
|
||||
|
||||
#endif /* #define OSAL_EXPORT_H */
|
71
src/GlideHQ/osal_files.h
Normal file
71
src/GlideHQ/osal_files.h
Normal file
|
@ -0,0 +1,71 @@
|
|||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Mupen64plus-ui-console - osal_files.h *
|
||||
* Mupen64Plus homepage: https://mupen64plus.org/ *
|
||||
* Copyright (C) 2009 Richard Goedeken *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/* This header file is for all kinds of system-dependent file handling
|
||||
*
|
||||
*/
|
||||
|
||||
#if !defined(OSAL_FILES_H)
|
||||
#define OSAL_FILES_H
|
||||
|
||||
#include "osal_export.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#define OSAL_DIR_SEPARATOR_STR L"/"
|
||||
#define OSAL_DIR_SEPARATOR_CHAR L'/'
|
||||
|
||||
#if defined(WIN32)
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX _MAX_PATH
|
||||
#endif
|
||||
#define strdup _strdup
|
||||
#else /* Not WINDOWS */
|
||||
#ifndef PATH_MAX
|
||||
#define PATH_MAX 260
|
||||
#endif
|
||||
#endif
|
||||
|
||||
// Returns 1 if name contains path to a directory, 0 otherwise
|
||||
EXPORT int CALL osal_is_directory(const wchar_t* name);
|
||||
// Returns 1 if name contains an absolute path, 0 otherwise. Path validity not tested.
|
||||
EXPORT int CALL osal_is_absolute_path(const wchar_t* name);
|
||||
// Returns 1 if path points to file or directory, 0 otherwise
|
||||
EXPORT int CALL osal_path_existsA(const char *path);
|
||||
// Returns 1 if path points to file or directory, 0 otherwise
|
||||
EXPORT int CALL osal_path_existsW(const wchar_t *path);
|
||||
// Returns 0 if all directories on the path exist or successfully created
|
||||
// Returns 1 if path is bad
|
||||
// Returns 2 if we can't create some directory on the path
|
||||
EXPORT int CALL osal_mkdirp(const wchar_t *dirpath);
|
||||
|
||||
EXPORT void * CALL osal_search_dir_open(const wchar_t *_pathname);
|
||||
EXPORT const wchar_t * CALL osal_search_dir_read_next(void * dir_handle);
|
||||
EXPORT void CALL osal_search_dir_close(void * dir_handle);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* #define OSAL_FILES_H */
|
||||
|
153
src/GlideHQ/osal_files_unix.c
Normal file
153
src/GlideHQ/osal_files_unix.c
Normal file
|
@ -0,0 +1,153 @@
|
|||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Mupen64plus-core - osal_files_unix.c *
|
||||
* Mupen64Plus homepage: https://mupen64plus.org/ *
|
||||
* Copyright (C) 2009 Richard Goedeken *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/* This file contains the definitions for the unix-specific file handling
|
||||
* functions
|
||||
*/
|
||||
|
||||
#include <dirent.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include "osal_files.h"
|
||||
|
||||
/* global functions */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"{
|
||||
#endif
|
||||
|
||||
EXPORT int CALL osal_path_existsA(const char *path)
|
||||
{
|
||||
struct stat fileinfo;
|
||||
return stat(path, &fileinfo) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_path_existsW(const wchar_t *_path)
|
||||
{
|
||||
char path[PATH_MAX];
|
||||
wcstombs(path, _path, PATH_MAX);
|
||||
struct stat fileinfo;
|
||||
return stat(path, &fileinfo) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_is_absolute_path(const wchar_t* name)
|
||||
{
|
||||
return name[0] == L'/';
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_is_directory(const wchar_t * _name)
|
||||
{
|
||||
char name[PATH_MAX + 1];
|
||||
wcstombs(name, _name, PATH_MAX);
|
||||
DIR* dir;
|
||||
dir = opendir(name);
|
||||
if(dir != NULL)
|
||||
{
|
||||
closedir(dir);
|
||||
return 1;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_mkdirp(const wchar_t *_dirpath)
|
||||
{
|
||||
char dirpath[PATH_MAX];
|
||||
wcstombs(dirpath, _dirpath, PATH_MAX);
|
||||
struct stat fileinfo;
|
||||
int dirpathlen = strlen(dirpath);
|
||||
char *currpath = strdup(dirpath);
|
||||
|
||||
/* first, break the path into pieces by replacing all of the slashes wil NULL chars */
|
||||
while (strlen(currpath) > 1)
|
||||
{
|
||||
char *lastslash = strrchr(currpath, '/');
|
||||
if (lastslash == NULL)
|
||||
break;
|
||||
*lastslash = 0;
|
||||
}
|
||||
|
||||
/* then re-assemble the path from left to right until we get to a directory that doesn't exist */
|
||||
while (strlen(currpath) < dirpathlen)
|
||||
{
|
||||
if (strlen(currpath) > 0 && stat(currpath, &fileinfo) != 0)
|
||||
break;
|
||||
currpath[strlen(currpath)] = '/';
|
||||
}
|
||||
|
||||
/* then walk up the path chain, creating directories along the way */
|
||||
do
|
||||
{
|
||||
if (stat(currpath, &fileinfo) != 0)
|
||||
{
|
||||
if (mkdir(currpath, 0700) != 0)
|
||||
{
|
||||
free(currpath);
|
||||
return 1; /* mkdir failed */
|
||||
}
|
||||
}
|
||||
if (strlen(currpath) == dirpathlen)
|
||||
break;
|
||||
else
|
||||
currpath[strlen(currpath)] = '/';
|
||||
} while (1);
|
||||
|
||||
free(currpath);
|
||||
return 0;
|
||||
}
|
||||
|
||||
EXPORT void * CALL osal_search_dir_open(const wchar_t *_pathname)
|
||||
{
|
||||
char pathname[PATH_MAX];
|
||||
wcstombs(pathname, _pathname, PATH_MAX);
|
||||
DIR *dir;
|
||||
dir = opendir(pathname);
|
||||
return dir;
|
||||
}
|
||||
|
||||
EXPORT const wchar_t * CALL osal_search_dir_read_next(void * dir_handle)
|
||||
{
|
||||
static wchar_t last_filename[PATH_MAX];
|
||||
DIR *dir = (DIR *) dir_handle;
|
||||
struct dirent *entry;
|
||||
|
||||
if (dir_handle == NULL)
|
||||
return NULL;
|
||||
|
||||
entry = readdir(dir);
|
||||
if (entry == NULL)
|
||||
return NULL;
|
||||
mbstowcs(last_filename, entry->d_name, PATH_MAX);
|
||||
return last_filename;
|
||||
}
|
||||
|
||||
EXPORT void CALL osal_search_dir_close(void * dir_handle)
|
||||
{
|
||||
closedir((DIR *) dir_handle);
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
167
src/GlideHQ/osal_files_win32.c
Normal file
167
src/GlideHQ/osal_files_win32.c
Normal file
|
@ -0,0 +1,167 @@
|
|||
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
|
||||
* Mupen64plus-core - osal_files_win32.c *
|
||||
* Mupen64Plus homepage: https://mupen64plus.org/ *
|
||||
* Copyright (C) 2009 Richard Goedeken *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
|
||||
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
|
||||
|
||||
/* This file contains the definitions for the unix-specific file handling
|
||||
* functions
|
||||
*/
|
||||
|
||||
#include <direct.h>
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <sys/stat.h>
|
||||
#include <sys/types.h>
|
||||
#include <windows.h>
|
||||
|
||||
#include "osal_files.h"
|
||||
|
||||
/* global functions */
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"{
|
||||
#endif
|
||||
|
||||
EXPORT int CALL osal_path_existsA(const char *path)
|
||||
{
|
||||
struct _stat fileinfo;
|
||||
return _stat(path, &fileinfo) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_path_existsW(const wchar_t *path)
|
||||
{
|
||||
struct _stat fileinfo;
|
||||
return _wstat(path, &fileinfo) == 0 ? 1 : 0;
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_is_absolute_path(const wchar_t* name)
|
||||
{
|
||||
return wcschr(name, L':') != NULL || name[0] == L'\\' || name[0] == L'/';
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_is_directory(const wchar_t* _name)
|
||||
{
|
||||
wchar_t DirName[MAX_PATH + 1];
|
||||
int namelen = 0;
|
||||
|
||||
/* we must remove any trailing backslash on the end of the pathname, or this will fail */
|
||||
wcsncpy(DirName, _name, MAX_PATH);
|
||||
DirName[MAX_PATH] = 0;
|
||||
namelen = wcslen(DirName);
|
||||
if (namelen > 0 && DirName[namelen - 1] == OSAL_DIR_SEPARATOR_CHAR)
|
||||
DirName[namelen - 1] = L'\0';
|
||||
return (GetFileAttributesW(DirName) & FILE_ATTRIBUTE_DIRECTORY);
|
||||
}
|
||||
|
||||
EXPORT int CALL osal_mkdirp(const wchar_t * dirpath)
|
||||
{
|
||||
struct _stat fileinfo;
|
||||
size_t dirpathlen = wcslen(dirpath);
|
||||
wchar_t *currpath = _wcsdup(dirpath);
|
||||
|
||||
/* first, remove sub-dirs on the end (by replacing slashes with NULL chars) until we find an existing directory */
|
||||
while (wcslen(currpath) > 1 && _wstat(currpath, &fileinfo) != 0) {
|
||||
wchar_t *lastslash = wcsrchr(currpath, OSAL_DIR_SEPARATOR_CHAR);
|
||||
if (lastslash == NULL) {
|
||||
free(currpath);
|
||||
return 1; /* error: we never found an existing directory, this path is bad */
|
||||
}
|
||||
*lastslash = 0;
|
||||
}
|
||||
|
||||
/* then walk up the path chain, creating directories along the way */
|
||||
do {
|
||||
if (currpath[wcslen(currpath) - 1] != OSAL_DIR_SEPARATOR_CHAR && _wstat(currpath, &fileinfo) != 0)
|
||||
{
|
||||
if (_wmkdir(currpath) != 0)
|
||||
{
|
||||
free(currpath);
|
||||
return 2; /* mkdir failed */
|
||||
}
|
||||
}
|
||||
if (wcslen(currpath) == dirpathlen)
|
||||
break;
|
||||
else
|
||||
currpath[wcslen(currpath)] = OSAL_DIR_SEPARATOR_CHAR;
|
||||
} while (1);
|
||||
|
||||
free(currpath);
|
||||
return 0;
|
||||
}
|
||||
|
||||
typedef struct {
|
||||
HANDLE hFind;
|
||||
WIN32_FIND_DATAW find_data;
|
||||
} dir_search_info;
|
||||
|
||||
EXPORT void * CALL osal_search_dir_open(const wchar_t *pathname)
|
||||
{
|
||||
wchar_t SearchString[MAX_PATH + 1];
|
||||
dir_search_info *pInfo = (dir_search_info *)malloc(sizeof(dir_search_info));
|
||||
|
||||
if (pInfo == NULL)
|
||||
return NULL;
|
||||
|
||||
pInfo->hFind = INVALID_HANDLE_VALUE;
|
||||
pInfo->find_data.cFileName[0] = 0;
|
||||
|
||||
if (pathname[wcslen(pathname) - 1] == OSAL_DIR_SEPARATOR_CHAR)
|
||||
swprintf(SearchString, MAX_PATH, L"%ls*", pathname);
|
||||
else
|
||||
swprintf(SearchString, MAX_PATH, L"%ls%ls*", pathname, OSAL_DIR_SEPARATOR_STR);
|
||||
SearchString[MAX_PATH] = 0;
|
||||
|
||||
pInfo->hFind = FindFirstFileW(SearchString, &pInfo->find_data);
|
||||
return (void *) pInfo;
|
||||
}
|
||||
|
||||
EXPORT const wchar_t * CALL osal_search_dir_read_next(void * search_info)
|
||||
{
|
||||
static wchar_t last_filename[_MAX_PATH];
|
||||
dir_search_info *pInfo = (dir_search_info *) search_info;
|
||||
|
||||
if (pInfo == NULL || pInfo->hFind == INVALID_HANDLE_VALUE || pInfo->find_data.cFileName[0] == 0)
|
||||
return NULL;
|
||||
|
||||
wcscpy(last_filename, pInfo->find_data.cFileName);
|
||||
|
||||
if (FindNextFileW(pInfo->hFind, &pInfo->find_data) == 0)
|
||||
{
|
||||
pInfo->find_data.cFileName[0] = 0;
|
||||
}
|
||||
|
||||
return last_filename;
|
||||
}
|
||||
|
||||
EXPORT void CALL osal_search_dir_close(void * search_info)
|
||||
{
|
||||
dir_search_info *pInfo = (dir_search_info *) search_info;
|
||||
|
||||
if (pInfo != NULL)
|
||||
{
|
||||
if (pInfo->hFind != INVALID_HANDLE_VALUE)
|
||||
FindClose(pInfo->hFind);
|
||||
free(pInfo);
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
|
@ -226,7 +226,7 @@ void check_compile(GLuint shader)
|
|||
{
|
||||
char log[1024];
|
||||
glGetShaderInfoLog(shader,1024,NULL,log);
|
||||
LOGINFO(log);
|
||||
LOGINFO("%s", log);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -238,7 +238,7 @@ void check_link(GLuint program)
|
|||
{
|
||||
char log[1024];
|
||||
glGetProgramInfoLog(program,1024,NULL,log);
|
||||
LOGINFO(log);
|
||||
LOGINFO("%s", log);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -221,7 +221,7 @@ void display_warning(const char *text, ...)
|
|||
vsprintf(buf, text, ap);
|
||||
va_end(ap);
|
||||
first_message--;
|
||||
LOGINFO(buf);
|
||||
LOGINFO("%s", buf);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -257,11 +257,11 @@ void init_combiner()
|
|||
if(!log_length)
|
||||
{
|
||||
glGetInfoLogARB(fragment_shader_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(vertex_shader_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(program_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
}
|
||||
|
||||
texture0_location = glGetUniformLocationARB(program_object, "texture0");
|
||||
|
@ -281,11 +281,11 @@ void init_combiner()
|
|||
if(!log_length)
|
||||
{
|
||||
glGetInfoLogARB(fragment_shader_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(vertex_shader_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(program_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
}
|
||||
|
||||
texture0_location = glGetUniformLocationARB(program_object, "texture0");
|
||||
|
@ -497,12 +497,12 @@ void compile_shader()
|
|||
{
|
||||
glGetInfoLogARB(shader_programs[number_of_programs].fragment_shader_object,
|
||||
2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(vertex_shader_object, 2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
glGetInfoLogARB(program_object,
|
||||
2048, &log_length, shader_log);
|
||||
if(log_length) display_warning(shader_log);
|
||||
if(log_length) display_warning("%s", shader_log);
|
||||
}
|
||||
|
||||
texture0_location = glGetUniformLocationARB(program_object, "texture0");
|
||||
|
|
|
@ -23,11 +23,17 @@
|
|||
|
||||
#include <m64p_types.h>
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#define ATTR_FMT(fmtpos, attrpos) __attribute__ ((format (printf, fmtpos, attrpos)))
|
||||
#else
|
||||
#define ATTR_FMT(fmtpos, attrpos)
|
||||
#endif
|
||||
|
||||
#define LOGINFO(...) WriteLog(M64MSG_INFO, __VA_ARGS__)
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
void WriteLog(m64p_msg_level level, const char *msg, ...);
|
||||
void WriteLog(m64p_msg_level level, const char *msg, ...) ATTR_FMT(2,3);
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
@ -73,7 +79,8 @@ extern int buffer_cleared; // mark that the buffer has been cleared, used to che
|
|||
#if defined(_WIN32) && !defined(__MINGW32__) && !defined(__MINGW64__)
|
||||
#include <windows.h>
|
||||
extern "C" {
|
||||
#include <SDL_opengl.h>
|
||||
#include <GL/gl.h>
|
||||
#include <GL/glext.h>
|
||||
extern PFNGLACTIVETEXTUREARBPROC glActiveTextureARB;
|
||||
extern PFNGLATTACHOBJECTARBPROC glAttachObjectARB;
|
||||
extern PFNGLBINDFRAMEBUFFEREXTPROC glBindFramebufferEXT;
|
||||
|
@ -128,8 +135,7 @@ extern "C" {
|
|||
#endif // _WIN32
|
||||
#include "glide.h"
|
||||
|
||||
void display_warning(const unsigned char *text, ...);
|
||||
void display_warning(const char *text, ...);
|
||||
void display_warning(const char *text, ...) ATTR_FMT(1,2);
|
||||
void init_geometry();
|
||||
void init_textures();
|
||||
void init_combiner();
|
||||
|
@ -387,7 +393,7 @@ grConstantColorValueExt(GrChipID_t tmu,
|
|||
#ifdef LOGGING
|
||||
void OPEN_LOG();
|
||||
void CLOSE_LOG();
|
||||
void LOG(const char *text, ...);
|
||||
void LOG(const char *text, ...) ATTR_FMT(1,2);
|
||||
#else // LOGGING
|
||||
#define OPEN_LOG()
|
||||
#define CLOSE_LOG()
|
||||
|
|
Loading…
Add table
Reference in a new issue