Pete´s Messageboard... No ISO/BIOS requests!

Homepage Members Register Login Search Old board


Neuer Thread ...


AuthorTopics » Book an abo for this threadClose Thread Move Thread Fix the thread Print view Delete this thread

kurokaze 



...

Status:Offline
Date registered: 02.08.2008
Post:1
Send Message
...   Created on 02.08.2008 - 03:45Jump to top Quote this post Report this post Edit Delete


I'm adding support for these shaders into another program (RemoteJoy, which outputs PSP display to your PC through USB). I don't need help getting shaders working or anything like that; everything seems to be running fine. However, the shaders aren't acting -exactly- as they do in gpupeteogl2. I suspect I am not declaring the uniforms in the same way.

Specifically, I've been using (1/width)*level for params.x and likewise for height/y; this results in no visible shader activity on most shaders when set to minimum shader intensity level since params.x, params.y, and params.z all end up as 0. What is it supposed to be?

If you're interested in my project you can get more info and releases here, though note that if you do not own a PSP with custom firmware you'll be treated to some white error text on a black screen with nice shaders applied to it.




guest ...
Real addict
.........

...

Status:Offline
Date registered: 30.07.2004
Post:856
Send Message
...   Created on 02.08.2008 - 21:36Jump to top Quote this post Report this post Edit Delete


Most of scalers are using 0.5/width and 0.5/height texel offsets for desired effect.
The 2xSai is using 1/width and 1/height, 2xSaL is bit different, it can be tried with 0.25/width, 0.25/height.

Otherwise i didn't put much more 'ingame' control to my shaders. In the speciffic OGL2 case the OGL2Param.z variable can be alterd from ingame - it is the one interesting for variety of effects.

If the offset is determined through the OGL2Param.xy theese params already present usable valuest for the offset. If it's calculated by any other mean or taken from the OGL2InvSize.xy then they have no other greater importance.

If i would have any advices how to use the shaders - the best of them would be to implement a very cool resample filter as the last pass, especially for downsampling. The radeon fam., for example, has built in bicubic filtering support since hd2x00.

[Dieser Beitrag wurde am 08.08.2008 - 07:59 von guest aktualisiert]




VerGreeneyes 
Strong supporter
......

...

Status:Offline
Date registered: 26.04.2007
Post:89
Send Message
...   Created on 12.08.2008 - 15:20Jump to top Quote this post Report this post Edit Delete


I once made some notes on how this appears to work in Pete's plugin. The only file I could find appears to have been mangled somewhat during testing, so I filled in some blanks from memory. As I made this a number of months ago, please take the following with a grain of salt.

Code:
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
 
Can't remember how internal_?_res is stored, so this assumes low == 1, high == 2 et cetera.

OGL2Size.x: 1024 * internal_x_res;
OGL2Size.y:  512 * internal_y_res;
OGL2Size.z: (game_x_res - 1) / 1024; // not (game_x_res * internal_x_res - 1) / OGL2Size.x
OGL2Size.w: (game_y_res - 1) /  512; // not (game_y_res * internal_y_res - 1) / OGL2Size.y

OGL2Param.x: OGL2Param.z / 4096;
OGL2Param.y: OGL2Param.z / 2048;
OGL2Param.z: shader_level - 1;
OGL2Param.w: 0;

gl_FragCoord.x: 1 to screen_x_res;
gl_FragCoord.y: screen_y_res to 1;
gl_FragCoord.z: 0.5;
gl_FragCoord.w: 1;

Particular to Chrono Trigger, though I was working on generalising this:
gl_TexCoord[0].x: 0 to OGL2Size.z;
gl_TexCoord[0].y: 0 to OGL2Size.w and 0.5 to 0.5 + OGL2Size.w;
gl_TexCoord[0].z: 0;
gl_TexCoord[0].w: 1;


[Dieser Beitrag wurde am 12.08.2008 - 15:26 von VerGreeneyes aktualisiert]





Similarly threads:
Topics Created by Replies Boardname
Natural Vision Shader + AA Shader v2.o = Best Shader for 2d !! zaykho 10 pete_bernert
porting ??? chris 12 scooter_parts
Shader Aquamarin 0 schaddi
MMJ's 4-in-1 Shader MegaManJuno 10 pete_bernert
What's a Shader Near 1 pete_bernert
Neuer Thread ...





Masthead

This forum is a free service of razyboard.com powered by:
Geizkragen Price Comparison. Top product in the price comparison: Krups Nespresso Essenza (XN2001)
Do you want a free forum in less than two minutes? Then click here!



Verwandte Suchbegriffe:
remotejoy shader | 2xsai remotejoy | remotejoy 2xsai
blank