Commit Graph

22 Commits

Author SHA1 Message Date
olebeck
47736862a7
Add PSVita port (#541)
* add psvita to cmake

* no PIE for vita

* add modules to vpk

* use custom pvr apphint

* select correct renderer for sdl renderer

* patch sdl3 shaders, got something on screen!

* use proper cmake patch for sdl

* add missing module

* remove test window which causes a bug in the vita sdl port to show up

* add gxm renderer (not working with display yet)

* avoid sdl renderer for vita, seems broken

* make gxm renderer work with new d3drm

* fix rendering somewhat, some geometry shows up

* support paletted textures directly to avoid copying the texture twice

* fix Draw2DImage

* make 3d work, broken lights

* clean up a bit

* fix normals matrix

* remove some unneeded changes

* forgot env var

* wrong env dest

* run clang format

* correct texture address mode, use tlsf instead of sceClibMspace

* double buffered uniforms seem to work now

* missed a line

* update GXMRenderer_EnumDevice

* hopefully actually fix uniform buffers

* run clang-format

* remove a change thats not needed

* improve fragment shader performance

* add vita to dist folder

* add base for vita config app

* add config self to vpk

* transform touch events to virtual size

* add livearea graphics

* Update cmake file to include livearea assets

* put manual in the right place

* add sample rco

* add messagebox on vita

* triple buffer textures because fences arent a thing on vita and making draw&cpu sync would be too slow

* make config app not crash on launch

* change defaults

* update gxm renderer with interface changes

* split 2d and 3d shaders completely

* update gxm renderer

* fix transition on gxm

* clang format

* move config cmake

* move CONFIG_vita

* always clear before drawing 2d image

* hopefully fix windows build

* clang-format fix broken includes

* order again

* undo moving qt cmake to its own list

* move uic search path

* use ifdefs for all d3drm backends, cpack to generate vpk

* cmake wrong escape

* small cleanups in gxm renderer

* defer texture delete to avoid overwriting the texture during a frame

* clang-format

* more of the layout for config

* remove top buttons

* use SceAppSettings instead of custom ui

* use select for back to info center on vita, to make screenshots possible again

* remove accidentally left in add_subdirectory

* adjust diskpath to be like other ports

* use vita_create_vpk and not cpack

* gxm: msaa support, fix wrong file path

* gxm: add mipmaps (disabled)

* clang-format

* fix open isle.ini with fopen

* add missing strings

* use iniparser_set not dictionary_set

* add default save path to config

* load config app after initializing ini on vita

* fix config build

* change the default disk & cd path, update the paf library

* update paf library headers

* include orders for clang-format

* clean up

* make shader compiler not required

* move asm language

* warn instead of error when shader source is changed when no compiler is found

---------

Co-authored-by: Li <li@silica.codes>
Co-authored-by: Christian Semmler <mail@csemmler.com>
2025-10-31 23:23:12 +00:00
Anders Jenbo
94c2d16180
Add OpenGL ES 2.0 renderer (#678) 2025-08-15 16:26:06 +00:00
Cookie
f06731784e
Android port (#656)
* initial files

* get building

* proper paths & default to virtual mouse

* Wrap gradle under cmake & build SDL3.aar

run cmake with  -DANDROID_NDK_PATH=/path/to/ndk to generate the .aar & run the gradle build

if using Android Studio you will have to run the aar script manually(or do the cmake cmd) then put the normal cmake args inside '-PcmakeArgs="-DCMAKE_BUILD_TYPE=Release ...."'  at `Settings > Build, Execution, Deployment > Gradle-Android Compiler > Command-line Options`
Check CMakeLists.txt Android build block for more info

* workflow and format

* dont cmake -> gradle -> cmake

* icons

* prevent first start crash due to missing isle.ini

dont force require gles3 (vulkan & software are options)

* cleanup

* cmake script & ci cleanup

use a cmake script to downoad SDL3 sources for aar building

* script cleanups & gradle stub for android studio

handle the env var setting for the sdl3 aar build script

* signing

needed repository secrets:
- keystore  :  key.jks in base64
- keystorePassword  :  Key store password
- keyAlias  :  Key alias, ex key0
- keyPassword  :  Key Password

* conditionally run action without keys

* compile SDL once & cross-platformize gradle tasks

* suggestions

* use find_package over manual configuration

* use MxString

---------

Co-authored-by: Anders Jenbo <anders@jenbo.dk>
Co-authored-by: Christian Semmler <mail@csemmler.com>
2025-08-15 15:12:35 +00:00
Christian Semmler
a5a3c4ec83
Upgrade OpenGL ES renderer to 3.0, add option for MSAA (#636) 2025-07-23 18:00:48 +00:00
olebeck
b26a707db2
put ifdefs around every d3drm backend so that any can be disabled (#569)
* put ifdefs around every d3drm backend so that any can be disabled

* make clang-format happy

* move backend selection and enum to its own functions
2025-07-10 18:19:21 +02:00
Helloyunho
04bcfde38b
Add Xbox One/Series X|S port (#526)
* chore: update README.md

*  feat: got the audio working

* 🔧 feat: add appxmanifest

* 🩹 fix: remove opengl stuff

* ⚗️ feat: add button support

* ⚗️ chore: try to make less modification from upstream

* 🩹 fix: doesnt compile

*  feat: forcibly draw cursor and map right joystick to cursor

* 🩹 fix: remap joystick

* 🎨 fix: formatting

* 🎨 fix: cmakelists formatting

* 🩹 fix: 3ds build

* 👷 feat: add xbox one ci build

* 💚 fix: github hates xbox series naming

* 💚 fix: dont run cpack for xbox one, vs does that for you

* 💚 fix: xbox one need to use vs as generator

* 💚 fix: please

* 💚 fix: it could be msix not bundle

* 💚 fix: try recursive directory search when upload release

* 🔨 feat: support cpack

* 👷 feat: better packaging

* 💚 fix: ignore if mv fails

* 🔧 feat: add mouse sensitivity config

* 🔥 chore: dont need you

* ⚗️ chore: use d3d11

*  feat: hardware acceleration!!

* 🚸 chore: change default cd path so user can easily copy the assets to xbox

* 🧑‍💻 chore: improve reusability

* 🚨 fix: formatting error

* 🚸 chore: draw cursor by default

* 🎨 chore: cmakelists formatting

* chore: match with upstream

* chore: more matching with upstream

* chore: don't need you

* 🩹 fix: apply changes

* 🔥 fix: we don't need controller map anymore

* 🩹 fix: use isle style include guard

* 🩹 fix: last newline fix

* 👷 chore: use cpack

* 💚 fix: try to fix ci

* 💚 fix: i tried my best...
2025-07-06 07:28:00 -07:00
Christian Semmler
e7c7ecf510
Add experimental WebGL support to Emscripten (#440)
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
2025-07-02 06:15:15 +00:00
Joshua Peisach
1ff768935e
3DS Port (#450)
* [WIP] 3ds port

Recommit of everything after the 2d renderer merge

* VERY AWESOME FEATURE FRFR

* Stopped CPU suicide and app crashing for now

* put in Texture3DS function thing

* Fix clear color

* Implement 2D rendering via Citro3D

* Set 3dsx smdh metadata

* Render world content, sort of

* Push mesh dynamically

* Remove Citro3D init hacks

* Clean up Citro3D implementation

* Try to upload meshes and convert matricies

* Fix 3D rendering

* Apply optimizations

* Implement lighting

* Set 3dsx smdh metadata

* Revert "Apply optimizations"

This reverts commit 6660082fef.

* Apply optimizations

* Added a cleaner icon (#4)

* Fix pure buffer clear frames (#9)

* Disable OpenGL on 3DS (#10)

* Fix tiled textures and improve UI image quality (#11)

* Create 3DS default config overrides

* 3ds: implement apt hooks

* remove unused import

* Apply suggestions from code review

Co-authored-by: Christian Semmler <mail@csemmler.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>

* Update miniwin/src/d3drm/backends/citro3d/renderer.cpp

Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>

* Separate 3DS apt hook code + move cmake 3ds into ISLE_BUILD_APP

* miniwin: use citro3dd if debugging

* Optimize texture encoding (#12)

* Cleanup

* Set correct mipmap level for UI textures (#13)

* cpack: include the .3dsx

* Add 3DS CI

* Fix CI

Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>

* syntax

* Refactor c3d renderer (#14)

* Refactor c3d renderer

* format

* Apply suggestions from code review

Co-authored-by: Anders Jenbo <anders@jenbo.dk>

---------

Co-authored-by: Anders Jenbo <anders@jenbo.dk>

* n3ds: just distribute the .3dsx

* upload 3dsx

* Skip uploading 3DS artifacts

* Update ci.yml

* Update ci.yml

* Remove extraneous ifdef

---------

Co-authored-by: MaxBrick <maximusbrick@gmail.com>
Co-authored-by: Anders Jenbo <anders@jenbo.dk>
Co-authored-by: Steven <139715581+StevenSYS@users.noreply.github.com>
Co-authored-by: Christian Semmler <mail@csemmler.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
2025-07-01 02:43:10 +00:00
David Gow
e87184b502
Fix the OpenGL backends on non-glx Linux platforms (and remove GLEW dependency) (#446)
* Work around issues with depth-buffer size on EGL-based platforms

The OpenGL 1.1 and OpenGL ES 2.0 backends can break on EGL-based platforms,
such as Wayland, or X11 with SDL_VIDEO_FORCE_EGL=1. One of the reasons for
this (the other being glew on the GL1.1 backend) is that SDL/egl get very
confused by the way we set OpenGL attributes, particularly SDL_GL_DEPTH_SIZE,
resulting in SDL_GL_CreateContext() failing with EGL_BAD_MATCH.

The exact cause of this is unknown, but it seems to be a combination of:
- SDL_GL_SetAttribute() is supposed to be called _before_ the window is
  created, and we're calling it afterward.
- Creating several test windows during the enumeration process, mixing
  and matching between OpenGL and OpenGL ES profiles.

The "most correct" solution is probably to delay creating the game window
until the backend creation process, rather than before the enumeration
occurs. But that's a real refactor, which could cause other issues.

Instead, set the 24-bit bit depth (which we've hardcoded anyway) before
creating the window, and use SDL_GL_ResetAttributes() when creating backends.

This seems to work here in all of the cases I was able to try (modulo the GLEW
dependency, which is removed in the next patch).

* miniwin: Remove GLEW dependency for OpenGL 1.1

GLEW normally backs directly onto glXGetProcAddress on Linux, which is broken
on non-GLX setups, such as Wayland (but also X11 with EGL, and presumably KMSDRM).

Replace it with manual calls to SDL_GL_GetProcAddress() for the VBO path.

Note, however, that SDL_opengl.h includes "windows.h", so conflicts with the
miniwin implementation, which breaks builds on windows.

In order to work around this, we do what the Direct3D9 implementation does and
push all of the OpenGL calls to a separate file, actual.cpp.

Going forward, it may make sense to load _all_ OpenGL entry points via SDL,
which would allow us to avoid linking directly with libGL/libOpenGL, and
therefore eliminate the separate build dependency altogether, as well as
allowing more runtime configurability as to the OpenGL library to load.

(But that's definitely a bit uglier, and also useful very rarely.)
2025-06-29 17:47:09 +02:00
Anders Jenbo
b65284a7a0
Move 2D drawing and upscaling to the renderer (#348) 2025-06-25 19:45:26 +02:00
Anders Jenbo
ea4b9ab1c9
Implement DirectX 9 backend (#332) 2025-06-18 18:10:48 +02:00
Anders Jenbo
eab95514d6
Add an OpenGL ES 2.0 renderer (#287) 2025-06-17 03:47:23 +02:00
Anders Jenbo
79726d25a4
Split framebuffer from general surfaces (#319) 2025-06-16 18:11:56 +02:00
Anders Jenbo
4c80c8d923
Add 32bit color support (#311) 2025-06-14 23:09:23 +00:00
Anders Jenbo
2c9d9ba920
Upload mesh data to GPU using VBOs when available (#275) 2025-06-10 23:33:14 +00:00
Anonymous Maarten
7e9acc8d04
Add IDirect3DRMMiniwinDevice interface (#267) 2025-06-09 16:34:37 +00:00
Anders Jenbo
cd4a24ec9e
Use indexed faces (#257) 2025-06-09 04:56:29 +02:00
David Gow
43191c7530
miniwin: Use the GLEW::GLEW target to find glew. (#246)
On some systems, the old-style GLEW_TARGET_LIBRARIES variable is not set by
find_package(GLEW), and instead we must use the newer GLEW::GLEW target, as
we do for OpenGL.

This fixes a build error on openSUSE Tumbleweed, which has a glew CMake config
in /usr/lib64/cmake/glew/glew-config.cmake.
2025-06-06 17:42:50 +02:00
Joshua Peisach
e520a47e2f
Port CONFIG to Qt (#210)
Co-authored-by: Anonymous Maarten <anonymous.maarten@gmail.com>
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
2025-06-03 03:48:04 +02:00
Anders Jenbo
b169a4d637
Implement OpenGL 1.5 backend renderer (#223) 2025-06-03 03:28:53 +02:00
Anders Jenbo
4abd404f2d Implement Software rendering 2025-05-29 04:08:01 +02:00
Anders Jenbo
ef7499bdb9 Restructure miniwin and add support for 3D backends 2025-05-29 04:07:53 +02:00