Commit Graph

99 Commits

Author SHA1 Message Date
Alexis Maiquez
154fe905bc ~ brought back video support
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-09-05 21:52:16 +02:00
Alexis Maiquez
2ffb5f1b24 + added an extra render pass to render the scene upside down (so it looks fine)
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-09-03 03:24:55 +02:00
Alexis Maiquez
16ed2f30de + added FreeImage for loading all the non-compiled textures (jpg, pngs, etc)
+ set proper glViewport instead of hardcoded 1920 by 1080 (this might require some changing and instead do a glViewport of the screen/window size and then scaling the backbuffers)
~ set proper texture size for pingpong buffers (to work with the viewport fixes)
- removed FREE_IMAGE_FORMAT as it's already included in the FreeImage library

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-09-02 23:59:00 +02:00
Alexis Maiquez
9d7d344b80 - removed commented code from main.cpp that is not useful anymore
~ changed how g_Time is calculated so any shader that uses it should behave properly
~ changed how the uniforms are set to a reinterpret_cast instead of static_cast to perform a direct pointer conversion (safe as we know the types were actually those types)

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-09-02 22:30:38 +02:00
Alexis Maiquez
d9c12d0b58 - removed .idea folder as that shouldn't have been uploaded in the first place
~ changed g_Time to float instead of double

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-09-01 15:30:00 +02:00
Alexis Maiquez
dd76439901 ~ fixed a_TexCoord variable not having the correct values
- removed irrlicht functions and types from the active codebase so it's no longer required at compile time (CContext still there as the code might be still be useful)

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-08-31 02:29:28 +02:00
Alexis Maiquez
291b7e364a - removed/commented out most irrlicht-specific code
~ written close to equivalent versions in OpenGL code using GLM and GLFW
~ written replacements for texture and package loading to not use irrlicht anymore
~ updated shader compiler as we now don't need to replace attributes anymore
+ added support for texture flags in the texture header (as they're needed for opengl to get proper information)

TODO: REWRITE VIDEO PLAYER SUPPORT AS THIS UPDATE EFFECTIVELY BREAKS IT

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-08-31 01:14:08 +02:00
Alexis Maiquez
4309ca722d + properly set g_Time for shaders
+ properly set g_TextureXResolution for shaders
+ properly set g_TextureX for shaders
+ properly set g_TextureXRotation for shaders

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2021-08-08 02:02:17 +02:00
IceCryptonym
5d5ce361fe
Initial video support without audio (#14)
* Adds FFmpeg to CMake
* Refactors to allow support for other wallpaper types
* Updates README.md for compilation requirements
* Initial video support without audio
* Properly support different wallpapers
* Fixes videos not rendering
* Nitpicks
* Moves code related to rendering from Core::CVideo to Render::CVideo
2020-04-27 18:50:17 +02:00
Alexis Maiquez
98e245b4cb + added error reporting for SDL initialization
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2020-03-31 23:32:46 +02:00
Alexis Maiquez
4358e7c173 - removed shader string constants, shaders do not have any, for future reference, these might be vectors or colors
+ shader constants now should be correctly applied as values for variables whenever possible

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-10 14:54:49 +02:00
Alexis Maiquez
d7cf8af7ca + created global variable storage for shaders
+ added g_Time to global variable storage
- removed global g_Time from main
~ changed "shader parameters" to "shader variables" as it's a more apt naming

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-10 13:27:18 +02:00
Alexis Maiquez
d03edb7c1e ~ cleaned up main function and moved initialization functions to a more proper place
~ check for SDL initialization before playing audio to prevent error messages when there is not really any error
~ changed a missed iterator to auto on CSound

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-10 12:55:45 +02:00
Alexis Maiquez
ce67c0bf64 ~ moved file resolution to the Irrlicht Context class
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-10 11:32:15 +02:00
Alexis Maiquez
3587fdec1e ~ changed all iterators to auto
~ changed most pointers to const references to prevent modification, specially from the background parser

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-10 11:02:45 +02:00
Alexis Maiquez
3371e10b01 ~ fixed segmentation fault when creating a scene
+ added check for texture rendering on startup
~ fixed possibly wrong texture size for passes
~ changed camera position

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-09 16:06:28 +02:00
Alexis Maiquez
e285b313e0 ~ use clearcolor from scene instead of using black
~ camera should use it's own getters, not access the m_camera object directly

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-09 09:46:29 +02:00
Alexis Maiquez
32a6a7af65 + Added parsing of shader constants for effects
~ Improved Shader Compiler parameter list to a better approach
+ Added support for one-pass effects with shaders (only first shader/pass will be applied)

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-08 21:09:19 +02:00
Alexis Maiquez
fc8778ab64 ~ More changes to the new parser to properly load object passes from JSON (combos, elements missing, shader, etc)
+ Added camera for new renderization code
+ Added scene for new renderization code
+ Added object for new renderization code
+ Added image for new renderization code
  WARNING: THIS IS A REGRESSION AS IN SHADERS ARE NOT AS COMPLETE AS IN THE MASTER BRANCH
~ New renderization code in place

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-06 15:54:41 +02:00
Alexis Maiquez
a40a83006e Merge branch 'master' of https://github.com/Almamu/linux-wallpaperengine into data-separation
# Conflicts:
#	main.cpp

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-06 14:41:41 +02:00
Alexis Maiquez
75fd581eac Merge branch 'data-separation' of https://github.com/Almamu/linux-wallpaperengine into data-separation
# Conflicts:
#	main.cpp
#	src/WallpaperEngine/video/renderer.cpp

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-05 17:26:58 +02:00
Alexis Maiquez
b8b3c2899d ~ Removed static variables in namespace WallpaperEngine::Irrlicht and moved to a context approach
This includes changes to old code to be compatible, the externs won't be used once the renderer is rewritten and the old code removed

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-05 17:24:16 +02:00
Alexis Maiquez
0ecc8b6e61 ~ Fixed getopt string not being correct
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-05 03:05:51 +02:00
Alexis Maiquez
ec29beca90 + Added FPS capping option for laptops
~ Changed default FPS cap to 30 FPS
~ Fixed bug where the windowed mode wasn't rendering anything

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-05 03:05:15 +02:00
Alexis Maiquez
eb60ea9029 Merge branch 'master' of github.com:Almamu/linux-wallpaperengine into data-separation
# Conflicts:
#	CMakeLists.txt
#	main.cpp
#	src/WallpaperEngine/video/renderer.cpp

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-04 23:04:01 +02:00
Alexis Maiquez
ce23ca53b1 ~ Reorganized viewport detection for screens and added proper checks for XRandr extension
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-04 22:23:47 +02:00
Alexis Maiquez
be68fe209f Merge branch 'master' of github.com:Almamu/linux-wallpaperengine 2019-09-04 22:08:49 +02:00
Alexis Maiquez
82c187fa76 ~ Support for displaying on background of specific screens instead of displaying on top, please carefuly read the README.md before using
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-04 22:08:32 +02:00
Alexis Maiquez
5c56e0860b ~ Moved Shader compiler to the proper, new namespace
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-02 12:19:42 +02:00
Alexis Maiquez
db89bf2e17 Merge branch 'master' of https://github.com/Almamu/linux-wallpaperengine into data-separation
# Conflicts:
#	main.cpp

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-09-02 11:50:07 +02:00
Daniel
47fc550357
+ fix path argument 2019-09-01 19:31:46 +03:00
Alexis Maiquez
69724adfdc ~ More class name changes and namespace modifictions (fs and irr)
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-08-16 14:56:16 +02:00
Alexis Maiquez
654918904a ~ Changed namespace names for wp::core and wp to a more suited name
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-08-15 01:53:40 +02:00
Alexis Maiquez
c5797571f4 + Added help message and switch
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-08-07 22:29:59 +02:00
Alexis Maiquez
7410f238ac + Added SDL and SDL_Mixer to implement audio support
+ Added support for sound objects
  Supported formats: MP3, FLAC, OGG

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-08-07 18:27:20 +02:00
Alexis Maiquez
4a221d0e9a + Added some default shader variables
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-05-17 01:03:29 +02:00
Alexis Maiquez
24cb34145d ~ Fixed pkg loading not working properly
+ Added support for PKGV0001 pkgs (look to be identical to PKGV0002 format, but needs validation)
~ Fixed segfault on vertex variable loading

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-05-16 01:07:37 +02:00
Alexis Maiquez Murcia
6abd73e843 + Added support for constant shader values
~ Fixed shader parameter setting that wasn't properly loading the values for the shader to use

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2019-05-15 11:35:48 +02:00
Alexis Maiquez Murcia
e62ea3e2be + Updated .gitignore
- Removed config class as It's no longer used
+ Added a small readme with all the documentation needed up to now
+ Changed the way the application starts to take into account execution switches to allow the users to select a background without recompiling the software

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2019-04-05 16:41:33 +02:00
Alexis Maiquez Murcia
83caa05ebf ~ Fixed switched vertex and pixel shaders on effects. This effectively renders the water effect properly for the nier automata background
~ Updated shader pre-compiler to use the irrlicht functions to read the shaders from

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2019-04-05 10:01:17 +02:00
Alexis Maiquez
2be1bffb6f - Removed all the contents of the res folder as those weren't needed anymore
+ Added basic, single-pass-effects parsing
- Removed duplicated code for effect parsing
+ Added support for shader loading and applying to materials (might not work with every shader, still needs some more investigation)
+ Added support for TEXB0001 containers to be able to load images from the wallpaperengine original files

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2019-04-05 08:34:53 +02:00
Alexis Maiquez Murcia
9f9d44834b - Removed the whole "fileResolver" class in favour of using the actual irrlicht file-handling functions
~ Added a small utils class to read full files to ram for the purpose of parsing json files
  Most of these files are really small, so there shouldn't really be any memory concerns
+ Added support for loading backgrounds directly from PKG files


Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2019-04-04 16:51:54 +02:00
Alexis Maiquez Murcia
82682ecf02 + Added LZ4 lib to the compilation process
+ Basic draft for the texture custom loader, only ARGB (partially) supported for now

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2019-04-02 17:08:34 +02:00
Alexis Maiquez
41002682b3 ~ Fixed file detection on working directories
+ Support for multiple images format (we're missing the wallpaper-engine format)

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2018-09-21 21:44:08 +02:00
Alexis Maiquez
32c36b8aee + Support for setting orthographic camera from scene information
- Removed specific stuff for the nier automata background I was using as test

Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2018-09-21 21:10:02 +02:00
Alexis Maiquez Murcia
fe7870de40 ~ Better path resolving handling
+ Possibility to resolve paths from json data (duh weird conversions...)

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2018-07-06 14:41:15 +02:00
Alexis Maiquez Murcia
1821731d5a + Basic parsing for json files on project (just scene, project objects and basic images)
+ Re-structured some code to its (hopefully) final form (shader compiler, file finding, etc)

Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2018-07-06 13:47:11 +02:00
Alexis Maiquez Murcia
5944cb9715 + More shader compilation steps (broke with the origina, still some information to change)
Signed-off-by: Alexis Maiquez Murcia <almamu@almamu.com>
2018-07-05 15:49:00 +02:00
Alexis Maiquez
ff59fcce41 ~ Current status of the project (basic shader support and shader precompilation steps)
Signed-off-by: Alexis Maiquez <almamu@almamu.com>
2018-07-05 02:17:58 +02:00