OS4 DepotLogo by Browallia 
(anonymous IP: 18.97.14.89,2261) 
 HomeRecentStatsSearchSubmitUploadsMirrorsContactInfoDisclaimerConfigAdmin
 Menu

 Features
   Crashlogs
   Bug tracker
   Locale browser
 

 Categories

   o Audio (343)
   o Datatype (51)
   o Demo (204)
   o Development (602)
   o Document (24)
   o Driver (97)
   o Emulation (149)
   o Game (1015)
   o Graphics (502)
   o Library (118)
   o Network (234)
   o Office (66)
   o Utility (932)
   o Video (69)

Total files: 4406

Full index file
Recent index file

 Links

  Amigans.net
  OpenAmiga
  Aminet
  IntuitionBase


Support the site


 Readme for:  Graphics » Viewer » shaderjoy.lha

Shaderjoy

Description: Display fragment shaders
Download: shaderjoy.lha       (TIPS: Use the right click menu if your browser takes you back here all the time)
Size: 4Mb
Version: 1.25
Date: 10 Apr 2023
Author: Juha Niemimaki
Submitter: Juha Niemimaki
Homepage: http://capehill.kapsi.fi
Requirements: OpenGL ES 2.0, Warp3D Nova
Category: graphics/viewer
Replaces: graphics/viewer/shaderjoy.lha
License: Freeware
Distribute: yes
Min OS Version: 4.1
FileID: 12501
 
Snapshots:
 
Videos:
Comments: 6
Snapshots: 1
Videos: 1
Downloads: 128  (Current version)
899  (Accumulated)
Votes: 24 (0/0)  (30 days/7 days)

Show comments Show snapshots Show videos Show content Show crashlogs Replace file 
# Shaderjoy 1.25

Shaderjoy allows you to display and create Shadertoy (https://www.shadertoy.com)
compatible fragment shaders. Fragment shaders (sometimes called pixel shaders)
are programs that are executed per fragment (pixel) on the GPU.


## Requirements

Ogles2.library 3.2.

Warp3D Nova 54.16.


## Usage

- Load/Save/Create new shader using RMB menu.
- Load/Save/Create new project using RMB menu.
- Reload shader using RMB menu.
- Drop shader file (.frag) into the window.
- Drop project file (.sjp) into the window.
- Load texture (or select buffer) channel using RMB menu.
- Add/Remove Common/Buffer A-D tabs.
- Select VSYNC method using RMB menu.
- Toggle fullscreen mode with LMB double-click or using RMB menu.
- Toggle FPS counter using RMB menu.
- Toggle verbose logging using RMB menu.
- Toggle special shader debug logging using RMB menu (requires ogles2.library
version 3).
- Save a screenshot using RMB menu.


## Vertical sync method

- WaitTOF: interrupt-based (*)
- WaitBOVP: busyloop (*)
- Disabled: do not limit frame rate

*) as explained in the Graphics.library Autodoc.


## Supported uniform variables

- vec3 iResolution: the window size in pixels (xy).
- vec4 iMouse: x/y have the mouse coordinate if LMB is pressed, z/w have the
original mouse coordinate when "dragging" started.
- float iTime: second.microsecond.
- float iTimeDelta
- int iFrame: current frame number, starting from 0.
- float iFrameRate
- sampler2D iChannel0...3: texture.
- vec3 iChannelResolution[4]: texture width (x) and height (y).
- vec4 iDate: year (x), month (y), day (z) and seconds (w).


## Tooltypes

- LOGLEVEL: one of DETAIL, DEBUG, INFO, WARNING or ERROR.
- CHECKUNINITIALIZED: let ogles2.library find uninitialized variables in shader
code.
- SHADERDEBUG: enable detailed shader debug log.
- VSYNC: enable vertical sync.
- SHOWFPS: display FPS counter in fullscreen mode.
- FULLSCREEN: start in fullscreen mode.
- EDITORVIEW: enable shader code editor in window mode.
- SCREENMODE: override system resolution in fullscreen mode.
- FONTNAME: editor font name.
- FONTSIZE: editor font size.
- EDITORNAME: external editor, for example NotePad.
- AUTORELOAD: monitor current shader source file and reload on change.
- WINDOWSIZE: window inner size.
- FLOATTEXTURE: FBOs use floating point texture, instead of unsigned byte.
- BORDERLESS: disable window gadgets. So user can open a "fullscreen" window on
the Workbench screen.
- PUBSCREEN: public screen name.


## Multipass rendering

                                                |- iChannel0
                                                |- iChannel1
                    Common----> Buffer A/B/C/D -*- iChannel2
                       |                   |    |- iChannel3
                       |                   v
                       |     |- iChannel0 (buffer/texture)
                       v     |- iChannel1
      Window - Image shader -*- iChannel2
                             |- iChannel3


## Project files

Shaderjoy project files (.sjp) are text files that connect shaders and channel
inputs together. Project
file can be created by loading shader program(s) and textures and then saving
the project file.

If you end up modifying project files by hand, be careful: file parser is
case-sensitive and simple.


## ARexx commands

- QUIT: example: rx "ADDRESS SHADERJOY.1 QUIT".
- SAVE_SCREENSHOT: example: rx "ADDRESS SHADERJOY.1 SAVE_SCREENSHOT".
- LOAD_PROJECT: example: rx "ADDRESS SHADERJOY.1 LOAD_PROJECT
'shaders/example.sjp'".


## Known issues

- Some Shadertoy shaders don't work properly:
  - Future driver update may improve situation.
  - Some shaders rely on undefined behaviour.
- Buffer A...D dynamic range is limited to 0...1.0, because floating point
textures are not used yet.
- Rendering order is from Buffer A to D (instead of the loading order).


## TODO

- Audio support (sound shaders, audio playing, FFT...)
- Better Shadertoy compatibility


## Changes

1.25
- Add keyboard channel. Also remove some keyboard shortcuts to avoid conflicts.
- Add projects files (.sjp) for those example shaders that require textures.
- Replace text buttons with more compact images.
- Show busy pointer during shader compilation.
- Disable uninitialized variable check (in icon) due to glCompileShader issue
with some shaders:
  future ogles2.library should fix this.
- Fix loading of arexx.class.
- Fix busy looping of ChannelWindows.
- Refactor some GUI code.

1.24
- Add GLSL Help button: an URL (khronos.org) will be opened.
- Add PUBSCREEN tooltype.
- Add editor toggle menu option in window mode.
- Disable blanker using application.library.
- Fix some CppCheck findings.
- Fix "GetAttr fail" issue which happened when user dropped a file without
editor view.
- Compile with GCC 11 - thanks to all people working on the SDK!

1.23
- Start using stb_image_write.h to save PNG screenshot.
- Add LOAD_PROJECT and SAVE_SCREENSHOT ARexx commands.
- Make About window asynchronous.
- Add BORDERLESS tooltype.
- Remove support for ogles2.library versions older than 3.0
- Disable vertical flipping of FBOs when ogles2.library version is greater than
3.1.
- Remove workarounds for older library versions.

1.22
- Add LOGLEVEL tooltype.
- Add ARexx port.
- Add twister and tunnel shaders.
- Check CTRL-C signal during event handling.
- Display VSYNC status on window info bar.
- Fix issue with FPS counter when starting in fullscreen mode.

1.21
- Revert "hard-coded alpha value" change which broke some multipass shaders.
- Save screenshots using mskNone to avoid alpha channel issues.
- Try to handle space characters in shader paths of project file.

1.20
- Fix channel window issue where input selection misbehaved.
- Convert potential CR codes to LF when loading project file.
- Add one more way to combine paths when loading shaders.
- Add info log if project files entries are not recognized.

1.19
- Add screenshot support.
- About: display RadeonHD/RX.chip version.
- Improve double-click toggling (reset timer on toggle).
- Use hard-coded alpha value of 1.0f.
- Refactor channel management internally.
- Treat project file location as a secondary path when looking for shaders.
- Work on audio support internally (not finished).
- Compiled with GCC 10 - thanks to all people working on the compiler!

1.18
- Add project file support (.sjp).
- Activate the most recently loaded tab.
- Blank mouse pointer completely in fullscreen mode.
- Reorganize RMB menus due to project file.
- Rename "Channels" menu to "Shaders and Channels".
- Rename "Shaders" menu to "Debug".
- Refactor code dealing with file handling.
- Reset frame counter on rewind.

1.17
- Add FLOATTEXTURE tooltype. Note: there is an open driver issue #610.
- Fix mouse Y position (info bar height wasn't taken into account).
- Change iFrame uniform type from float to int.
- Load dropped shader file into Image slot when there is no editor view (tabs).
- Add sobel.frag.
- Refactor logging.

1.16
- Improve AppWindow feature: load file into currently active page.
- Improve Channel window by moving input selection above other gadgets.
- Disable texture file selection gadget when Buffer is chosen.
- Display message box when Buffer compilation fails.
- Compile all programs (Image + Buffers) when compile button is clicked.
- Sync shader code from GUI when compile button is clicked.
- Remove Buffer references in channels when some buffer tab is closed.
- Implement different logging levels. (Not used widely yet.)
- Improve debug logging, especially related to OpenGL resources.
- Fix a bug (of the year) that prevented Buffer channel configuration.
- Add one more rendering pass: render Image to an FBO.
- Use the latest rendered buffer instead of generating new frames in pause mode.
- Clear FBO textures on window resize.

1.15
- Add tab support (Common, Image and Buffers A, B, C, D).
- Allow editing of Common/Buffers A-D.
- Monitor changes of Common/Buffers A-D.
- Change Buffer logic: they are loaded outside the iChannel selection.
- Add Buffer selection to iChannel window: select either texture or Buffer A, B,
C or D.
- Fix path issue related to '/' handling.
- Flush stdout to make real-time log filtering possible.
- Rewrite rendering logic for improved frame buffer support.

1.14
- Add Common support. Common file is "included" before shader programs.
- Refactor GUI code.
- Display shader info log always when available. In case of errors and warnings
display also a requester.

1.13
- Make channel windows asynchronous and allow opening them simultaneously.
- Make load and save requesters asynchronous.
- On quit or fullscreen toggle, wait for save requester to finish. Otherwise try
to close extra windows.
- Do not advance iDate uniform in pause mode.
- Update shader name when filename is passed as a startup argument.
- Set GL viewport during startup.
- Add multipass rendering concept: allow loading of shader programs as
iChannels, and
allow loading of textures for those shader programs.

1.12
- Duplicate input / output streams when starting an external text editor.
- Add WINDOWSIZE tooltype.
- Add AUTORELOAD tooltype.
- Display shader name on info element.
- Display info element regardless of EDITORVIEW setting.
- Add channel window for setting up the textures.
- Clear mouse position when loading a new shader.

1.11
- Fix issue with texteditor.gadget creation (caused by missing OpenClass calls).
- Combine Play and Pause buttons.
- Display FPS and time info in a separate GUI element instead of window title
bar.
- Monitor shader source file and reload it on change.
- Add Control menu (Play/Pause, Rewind, Compile).
- Rename EDITOR tooltype to EDITORVIEW.

1.10
- Add tooltype EDITOR. When enabled, allow editing in window mode.
- Add tooltype FONTNAME and FONTSIZE, to configure editor font.
- Add tooltype EDITORNAME, to define external editor tool.
- Blank mouse pointer in fullscreen mode, when mouse is inactive.
- Allow pause mode toggling with SPACE key.
- Unpause when loading a shader.
- Update display also during pause mode, but on a slower rate.
- Re-enable reload functionality.

1.9
- Allow shader editing in window mode.
- Add play, pause, rewind and compile buttons in window mode.
- Allow saving of shaders.
- Remember window size when coming back from fullscreen mode.
- Add possibility to check uninitialized variables (requires ogles2.library
version 3).
- Add tooltype CHECKUNINITIALIZED.
- Add possibility to dump verbose Nova-level compilation logs (requires
ogles2.library version 3).
- Add tooltype SHADERDEBUG.
- Log shader info log always when available (in verbose mode).
- Time and log shader compilation (when in verbose mode).
- Remove possibility to reload shader.

1.8
- Use vertex buffer objects (VBOs).
- Add iTimeDelta and iFrameRate uniforms.
- Add AppWindow support: shaders can be dropped into the window.
- Shader filename can be passed as an argument.
- Improve About box: display GL information.
- Fix issue with blitting over window borders.
- Initialize fragment colour because some shaders do not.
- Reverse iMouse.y.

1.7
- Open all screens with SA_LikeWorkbench tag.
- Disable optimized bitmap allocation.
- Log OpenGL information during startup.
- Display version number on screen title bar.
- Fix an issue where FPS counter was not visible when started in fullscreen
mode.

1.6
- Improve VSYNC mechanism.
- Remove FPS counter flickering in fullscreen mode.
- Allow toggling of FPS counter.
- Add SHOWFPS tooltype.
- Add SCREENMODE tooltype.
- Disable Iconify menu option in fullscreen mode.
- Drop command-line argument support in favor of icon tooltypes.

1.5
- Fullscreen mode. Created using SA_LikeWorkbench so it's likely larger and
slower than default window mode!
- Improve logger: buffer is no more limited to 16 kilobytes.
- Change default texture path to "textures/shadertoy" for improve usage.
- User-selectable VSYNC mode (WaitTOF, WaitBOVP or disabled).
- Change default window size to 800 x 450.
- Display running time on window title bar.
- Display window size on window title bar.
- Use window pointer in ASL requesters.
- Add FULLSCREEN tooltype.

1.4
- Add icon tooltypes.

1.3
- Add iDate support.
- Add verbose logging.
- Fix: window pointer is now cleared when close gadget is used.
- Keep textures (iChannels) active when switching shaders.

1.2
- Fix: iChannelResolution is an array of vec3s.
- Workaround: use GL_LINEAR texture filtering to avoid diagonal line where
triangles meet.

1.1
- Add iChannel0...3 texture support. Each channel must be loaded manually at the
moment.
- Add iChannelResolution0...3 support.
- Add stack cookie and log stack usage at the exit.
- Display a message box in case shader or texture loading fails, instead of
exiting.

1.0
- First version


Copyright © 2004-2024 by Björn Hagström All Rights Reserved