Search Unity

PSXEffects - PlayStation One Graphics in Unity

Discussion in 'Assets and Asset Store' started by ckosmic, Nov 8, 2018.

  1. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    Overview
    PSXEffects is an all-in-one package that allows you to simulate all of the original PlayStation One's graphics quirks accurately and easily. Setup is simple and only requires one script and a canvas to render to.

    Screenshots/Media















    Key features
    • Adjustable aliased resolution
    • Two separate downscaling workflows
    • Fixed downscale resolution
    • Framerate limiting
    • Camera position inaccuracy
    • Affine texture mapping (texture distortion)
    • Draw distance for entire polygons
    • Vertex snapping
    • Lack of Z-Buffer simulation
    • Color depth
    • Scanlines (Vertical and Horizontal)
    • Dithering
    • Material color tinting
    • Unlit toggle
    • Backface culling toggle
    • Specular support
    • Cubemap support
    • Normal mapping
    • Metal/smoothness mapping
    • Emission mapping
    • Specular mapping
    • Vertex color support
    • Fog support
    • Per-vertex lighting
    • Saturated diffuse
    • Contrast-enhanced fade in/out effects
    • Original PSX lighting techniques
    • Plenty of shader properties
    • Works with multi-camera setups
    • All adjustable settings
    Links
    Asset Store
    Playable Demos
     
    Last edited: Jun 25, 2019
  2. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    I just released a small demo game using PSXEffects called Ship Battle 2. It's just a short and bare-bones game demonstrating what is possible with PSXEffects (and a sequel to a game I made yeaaarrss ago in Unity).

    Check it out here!
     
  3. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    kev000 likes this.
  4. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    PSXEffects version 1.5 is here, bringing a lot of new cool features:
    • Metallic values that can be controlled with a texture
    • Smoothness values that can be controlled with a texture
    • Normal mapping
    • Specular mapping
    • Improved specular lighting
    • Emission values that can be controlled with a texture
    • Realtime shadow support
     
  5. Lesnikus5

    Lesnikus5

    Joined:
    May 20, 2016
    Posts:
    131
    Not bad, not bad. Looks very authentic. Probably I will use it for my project.
     
  6. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    An easy to use all in one prefab that includes the PS1Camera and PS1Canvas will soon be included in PSXEffects! This allows you to drag one object into the scene and PSXEffects will be set up!
     
    Lesnikus5 likes this.
  7. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    PSXEffects 1.8 will be released shortly. Here are some features since 1.5:
    • Togglable world-space vertex snapping
    • New Gouraud specular shading model
    • Camera position imprecision
    • Original subtraction-based fade-out
    • Multi-camera support
    • Fixed resolution downscale
    • And much much more
    PSXEffects can be downloaded here.
     
  8. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    PSXEffects 1.9 was released finally removing the need of a second camera and a canvas in the scene! All that you need to do now is attach the PSXEffects script to a camera.

    View PSXEffects on the Asset Store
     
    Lesnikus5 likes this.
  9. derkoi

    derkoi

    Joined:
    Jul 3, 2012
    Posts:
    2,260
    Hi, I'm trying to run this on a Nintendo Switch but if I have the post processing enabled it gives me a blank screen. Is there anything I can do about that? Thanks
     
  10. derkoi

    derkoi

    Joined:
    Jul 3, 2012
    Posts:
    2,260
    Also, I'm trying to have my 3d models really dark and light with just a point light, is this possible? Thanks
     
  11. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    Hi, the blank screen is due to the shaders not being included in the build. To include them in the build, follow these steps from the documentation included with PSXEffects:

    If you build your game and just see a black screen, this is because Unity
    doesn't include the PSXEffects shaders by default. To fix this, go to
    Edit>Project Settings>Graphics and under Built-in Shader Settings, expand
    Always Included Shaders and add "Hidden/PS1ColorDepth" and
    "PSXEffects/PS1Shader" to the array.

    In the latest update of PSXEffects, correct spherical harmonics lighting was introduced making the shader look similar to the Standard shader, using the skybox to light it up. To disable this, you can simply go into the lighting settings of the scene and change the mode from skybox to color. And I assume bringing the intensity of the point light really up will make it bright.
     
  12. derkoi

    derkoi

    Joined:
    Jul 3, 2012
    Posts:
    2,260
    I tried that and it still doesn't work.

    Also, I'm noticing some characters in my game do not get lit with the flashlight (spotlight) where others do, any idea why that might be? Thanks
     
    DigitalFear likes this.
  13. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    Hmm... what version of Unity and PSXEffects are you using (the current version of PSXEffects at the time of writing this is 1.10.5)? I recently added spotlight and point light support into the asset.

    You can email me at support@tripleaxis.net if you want to send me your scene so I can take a look as well. :)
     
    derkoi likes this.
  14. derkoi

    derkoi

    Joined:
    Jul 3, 2012
    Posts:
    2,260
    Thanks, I'm using the latest version. I've sent you an email with a repro package.
     
  15. TheNathanParable

    TheNathanParable

    Joined:
    Mar 21, 2014
    Posts:
    17
    Hi, what would be the best way to force a square aspect ratio (with pillarboxing) while using PSXEffects?
     
  16. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
  17. Zebbi

    Zebbi

    Joined:
    Jan 17, 2017
    Posts:
    521
    I just bought PSXEffects, working really nicely for camera effects, but I was wondering, why when I convert my probuilder material over to PS1Shader does it just show blank? Here is the road material before:


    And after applying the PS1shader:

    It just appears blank? I've also turned off lightmap static:

    And static:

    The shaders are also included by Unity:

    Any ideas why it appears this way?
     
  18. HeyItsLollie

    HeyItsLollie

    Joined:
    May 16, 2015
    Posts:
    68
    Hi ckosmic, I sent an email to your support address last week, just checking that it was received!

    It was regarding the framerate limiter: Since the framerate limiter functions at the engine level, it ends up affecting the framerate at which additional post-process effects are able to update. If PSXEffects had an additional post-process version of the framerate limiter (update every second frame to simulate 30fps, or every third frame to simulate 20fps, etc), it would solve this issue.
     
  19. Zebbi

    Zebbi

    Joined:
    Jan 17, 2017
    Posts:
    521
    I haven't tried the framerate limiter, but if it just uses application target framerate, it'll change everything. I managed once to do a framerate limiter using a rendertexture that refreshed it on a coroutine, but I couldn't think of a good way to do it cleanly, so I gave up. Which way does this do the limiter?
     
  20. HeyItsLollie

    HeyItsLollie

    Joined:
    May 16, 2015
    Posts:
    68
    I'm assuming PSXEffects uses application target framerate. Try setting it to a low value (eg: 5 fps) in the Unity Editor, hit Play, and watch the entirety of Unity (not just the game) slow down to the framerate it's been told to target — until you exit Play mode, of course.

    I believe the framerate limiter is working as intended! I'd just like to be able to do something like say, limit the framerate to 60fps, and then simulate a lower framerate for in-game visuals. This would allow for UI and post-effects on top of PSXEffects, without them also being bound to any desired lower framerate.
     
  21. Zebbi

    Zebbi

    Joined:
    Jan 17, 2017
    Posts:
    521
    Yeah, my issue was the mouse, if you limit application framerate, unless using hardware mouse rendering, the mouse speed is slow, but then you can't use big cursors like you can with software rendering.
     
  22. RB_lashman

    RB_lashman

    Joined:
    Aug 15, 2013
    Posts:
    92
    is there a special "procedure" to make vertex lighting work? because it sure doesn't with point lights

    i did apply the script to the camera ... and all objects are using the PS1 shader

    Edit: also - would there be a possibility to move the resolution effect to the post-processing stack? i'm asking because right now it is being applied after any of the post-processing effects ... and i would like it to be applied before those ... because without that post-processing stuff like CRT simulations etc. don't really work since they're supposed to be applied after the low-resolution, not before
     
    Last edited: Apr 20, 2020
  23. RB_lashman

    RB_lashman

    Joined:
    Aug 15, 2013
    Posts:
    92
    @ckosmic so ... are you planning on replying or are we all left to figure stuff out on our own?
     
  24. ckosmic

    ckosmic

    Joined:
    Jun 19, 2013
    Posts:
    21
    Hi, I’m sorry I didn’t reply, I almost never check this forum and mostly respond by email.

    Regarding the point lights, have you tried setting their Render Modes to “Not Important”? This makes the lights turn into vertex lights instead of fragment lights. If you have done this already, you may have to turn its intensity up quite a bit since vertex lights interpolate intensity between vertices and bigger meshes will be affected by this. It’s also worth checking what your light limit is for your project.

    As for the low-res effect, unfortunately since this is done through a script and not post-processing, it can’t be moved to PP unless you use an existing pixelization post-processing effect. This is what I tried to do with PSXEffects early on, but I found that downscaling through PP would retain anti-aliasing type effects instead of staying true to the PS1’s screen rendering look, so I went with the render texture method instead.

    If you have any questions or issues please don’t hesitate to email me at support@tripleaxis.net. Thank you. :)
     
    RB_lashman likes this.
  25. Zebbi

    Zebbi

    Joined:
    Jan 17, 2017
    Posts:
    521
    Out of curiosity, what is the performance of PSX1Shader in compared to using a standard material shader? Obviously there's a lot of calculations to do, but does having many meshes and models using it cause noticeably lower framerates and processing?
     
  26. Animator

    Animator

    Joined:
    Apr 6, 2012
    Posts:
    38
    i absolutely love the asset exactly what i needed. just one thing, since my game is super barebones atm i get about 1200 frames per second. with the asset on its about the same but if i enable post processing (dithering etc) i drop to about 55 frames per second. anybody else having this problem? i tryed changing the specific things inside post processing to determin if its like just the clour range function or the dithering etc but even with everything disabled inside of it, when i check the post processing box the frame drops crazy. and its not my pc i have a high end PC running red dead redemption on max with 60frames so yea, what on earth could it be that this small function slows down so much?
     
  27. Foxaphantsum

    Foxaphantsum

    Joined:
    Jul 5, 2013
    Posts:
    139
    I was able to get the gouraud shading working with a directional light but does it work for point lights? I can't seem to get that working.
     
  28. DEDZET

    DEDZET

    Joined:
    Jun 21, 2021
    Posts:
    1
    I'm having the exact same problem, my FPS more than halves with post processing enabled and I have no idea how to fix it. It sucks because it gives such a nice effect but I guess I just have to turn it off for now
     
  29. EpicMcDude

    EpicMcDude

    Joined:
    Apr 15, 2013
    Posts:
    117
    I was having the same problem, the issue was I had the dithering method set to PSX (Slow), once I turned it off or put it on the fastest my frames were much better.
     
  30. CTA-00A

    CTA-00A

    Joined:
    Dec 25, 2019
    Posts:
    1
    Hey! I'd love to buy this I really like the whole package, but I haven't seen a tutorial for this anywhere maybe I'm blind or something idk. I'm new to the whole blender/unity scene and I'd love to learn this to make some ps1 style games for myself and others to enjoy but I can't figure this out by myself. Any advice or link or something where I can learn the method behind PSXEffects? Thank you in advance.
     
  31. chaver28

    chaver28

    Joined:
    Jan 26, 2020
    Posts:
    1
    hey zebbi did you ever find out why objects go blank when using the psx shader??
     
  32. toprakf

    toprakf

    Joined:
    Apr 19, 2021
    Posts:
    3
    Hello, I just grabbed this but when I enable Post Processing from the PSX Effects Script that I attached to the camera, the whole screen becomes pink. I tried generating a post processing volume and layer but it didn't do anything. How can I fix this?
     
  33. the_unity_saga

    the_unity_saga

    Joined:
    Sep 17, 2016
    Posts:
    273
    Hello, Dev.

    Your work is amazing,

    5/5

    Please, can you add GPU Instancing to the shader?

    its mostly all it is missing.

    (if you have spare time, some kind of animation scripts or maybe dual material shaders (blending alpha from multiple input, shfting frames from UV coordinates, might be nice, not required)
     
  34. dock

    dock

    Joined:
    Jan 2, 2008
    Posts:
    605
    Using Unity 2021.3.8 and PSX Effects fails when I try to build. I tried adding the shaders directly, but that doesn't fix it.
    Any suggestions? It's blocking me from making builds of the game.

    Code (CSharp):
    1. Shader error in 'PSXEffects/PS1Shader': redefinition of '_ShadowMapTexture' at Files/Unity/Hub/Editor/2021.3.8f1/Editor/Data/CGIncludes/AutoLight.cginc(40) (on d3d11)
    2.  
    3. Compiling Subshader: 0, Pass: Pass 2, Vertex program with OPAQUE SHADOWS_DEPTH SHADOWS_SCREEN SPOT _LOD_TEX
    4. Platform defines: SHADER_API_DESKTOP UNITY_COLORSPACE_GAMMA UNITY_ENABLE_DETAIL_NORMALMAP UNITY_ENABLE_REFLECTION_BUFFERS UNITY_LIGHTMAP_FULL_HDR UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_PASS_FORWARDADD UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BLENDING UNITY_SPECCUBE_BOX_PROJECTION UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS
    5. Disabled keywords: AFFINE_MAPPING CLAMP_AFFINE CUTOUT DIRECTIONAL DIRECTIONAL_COOKIE FOG_EXP FOG_EXP2 FOG_LINEAR LIGHTMAP_ON LIGHTMAP_SHADOW_MIXING POINT POINT_COOKIE SHADER_API_GLES30 SHADOWS_CUBE SHADOWS_SHADOWMASK SHADOWS_SOFT TRANSPARENT UNITY_ASTC_NORMALMAP_ENCODING UNITY_ENABLE_NATIVE_SHADOW_LOOKUPS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_DXT5nm UNITY_NO_FULL_STANDARD_SHADER UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_UNIFIED_SHADER_PRECISION_MODEL UNITY_VIRTUAL_TEXTURING VERTEXLIGHT_ON WORLD_SPACE_SNAPPING
    6.  
    7. Error building Player: Shader error in 'PSXEffects/PS1Shader': redefinition of '_ShadowMapTexture' at Files/Unity/Hub/Editor/2021.3.8f1/Editor/Data/CGIncludes/AutoLight.cginc(40) (on d3d11)
    8.  
    9. Compiling Subshader: 0, Pass: Pass 2, Vertex program with OPAQUE SHADOWS_DEPTH SHADOWS_SCREEN SPOT _LOD_TEX
    10. Platform defines: SHADER_API_DESKTOP UNITY_COLORSPACE_GAMMA UNITY_ENABLE_DETAIL_NORMALMAP UNITY_ENABLE_REFLECTION_BUFFERS UNITY_LIGHTMAP_FULL_HDR UNITY_LIGHT_PROBE_PROXY_VOLUME UNITY_PASS_FORWARDADD UNITY_PBS_USE_BRDF1 UNITY_SPECCUBE_BLENDING UNITY_SPECCUBE_BOX_PROJECTION UNITY_USE_DITHER_MASK_FOR_ALPHABLENDED_SHADOWS
    11. Disabled keywords: AFFINE_MAPPING CLAMP_AFFINE CUTOUT DIRECTIONAL DIRECTIONAL_COOKIE FOG_EXP FOG_EXP2 FOG_LINEAR LIGHTMAP_ON LIGHTMAP_SHADOW_MIXING POINT POINT_COOKIE SHADER_API_GLES30 SHADOWS_CUBE SHADOWS_SHADOWMASK SHADOWS_SOFT TRANSPARENT UNITY_ASTC_NORMALMAP_ENCODING UNITY_ENABLE_NATIVE_SHADOW_LOOKUPS UNITY_FRAMEBUFFER_FETCH_AVAILABLE UNITY_HALF_PRECISION_FRAGMENT_SHADER_REGISTERS UNITY_HARDWARE_TIER1 UNITY_HARDWARE_TIER2 UNITY_HARDWARE_TIER3 UNITY_LIGHTMAP_DLDR_ENCODING UNITY_LIGHTMAP_RGBM_ENCODING UNITY_METAL_SHADOWS_USE_POINT_FILTERING UNITY_NO_DXT5nm UNITY_NO_FULL_STANDARD_SHADER UNITY_NO_SCREENSPACE_SHADOWS UNITY_PBS_USE_BRDF2 UNITY_PBS_USE_BRDF3 UNITY_PRETRANSFORM_TO_DISPLAY_ORIENTATION UNITY_UNIFIED_SHADER_PRECISION_MODEL UNITY_VIRTUAL_TEXTURING VERTEXLIGHT_ON WORLD_SPACE_SNAPPING
    12.  
    13. Build completed with a result of 'Failed' in 9 seconds (8818 ms)
    14. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun ()
    15.  
    16. UnityEditor.BuildPlayerWindow+BuildMethodException: 2 errors
    17.   at UnityEditor.BuildPlayerWindow+DefaultBuildMethods.BuildPlayer (UnityEditor.BuildPlayerOptions options) [0x002da] in <5f40cdb07bd44d76a23dad985a4ec283>:0
    18.   at UnityEditor.BuildPlayerWindow.CallBuildMethods (System.Boolean askForBuildLocation, UnityEditor.BuildOptions defaultBuildOptions) [0x00080] in <5f40cdb07bd44d76a23dad985a4ec283>:0
    19. UnityEditor.BuildPlayerWindow:BuildPlayerAndRun ()
    20.  
    21.  
     
  35. dock

    dock

    Joined:
    Jan 2, 2008
    Posts:
    605



    Turns out the fix I needed was in the asset store reviews section! It now works okay.
    Please update this when you can.
     
    ejsingson likes this.