Gamestudio Links
Zorro Links
Newest Posts
New FXCM FIX Plugin
by flink. 06/04/24 07:30
AlpacaZorroPlugin v1.3.0 Released
by kzhao. 05/22/24 13:41
Free Live Data for Zorro with Paper Trading?
by AbrahamR. 05/18/24 13:28
Change chart colours
by 7th_zorro. 05/11/24 09:25
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (Akow, AndrewAMD), 1,640 guests, and 13 spiders.
Key: Admin, Global Mod, Mod
Newest Members
AemStones, LucasJoshua, Baklazhan, Hanky27, firatv
19058 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Get the last render in a post process shader #376764
07/06/11 15:15
07/06/11 15:15
Joined: Feb 2010
Posts: 320
TANA/Madagascar
3dgs_snake Offline OP
Senior Member
3dgs_snake  Offline OP
Senior Member

Joined: Feb 2010
Posts: 320
TANA/Madagascar
Hi,

I'm a noob in shader development, I wanted to know how to get the last rendered image in a shader (for implementing a motion blur ).

Thanks.

Best regards.

Re: Get the last render in a post process shader [Re: 3dgs_snake] #376787
07/06/11 18:52
07/06/11 18:52
Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Superku Offline
Senior Expert
Superku  Offline
Senior Expert

Joined: Sep 2003
Posts: 6,861
Kiel (Germany)
Are you looking for "TargetMap" ?

(I think the TargetMap feature is a bit buggy, you may prefer to create your own render target (view.bmap and bmap_create)).


"Falls das Resultat nicht einfach nur dermassen gut aussieht, sollten Sie nochmal von vorn anfangen..." - Manual

Check out my new game: Pogostuck: Rage With Your Friends
Re: Get the last render in a post process shader [Re: Superku] #376807
07/06/11 20:24
07/06/11 20:24
Joined: Mar 2006
Posts: 2,252
Hummel Offline
Expert
Hummel  Offline
Expert

Joined: Mar 2006
Posts: 2,252
I think he wants to access the content of the previous backbuffer to mix it with the current. There must be a view flag to prevent the backbuffer from getting cleared. Btw. this is usually not a good way to simulate motion blur. Also as a shader noob, you should start with simpler effects.

Last edited by Hummel; 07/06/11 21:26.
Re: Get the last render in a post process shader [Re: Hummel] #376824
07/06/11 20:55
07/06/11 20:55
Joined: Mar 2006
Posts: 3,538
WA, Australia
J
JibbSmart Offline
Expert
JibbSmart  Offline
Expert
J

Joined: Mar 2006
Posts: 3,538
WA, Australia
Quote:
There must be a view flag to prevent the backbuffer from getting cleared.
The NOSKY flag could do it. Do all your rendering to one target, but have the final view shown on screen have the NOSKY flag set, and use a pp-shader to mix the render target into this view with an alpha < 1.0.

Jibb

EDIT: I wonder if NOSKY is perhaps useless in PROCESS_TARGET. It's not working here.

Last edited by JibbSmart; 07/06/11 21:44.

Formerly known as JulzMighty.
I made KarBOOM!
Re: Get the last render in a post process shader [Re: JibbSmart] #376857
07/07/11 05:26
07/07/11 05:26
Joined: Feb 2010
Posts: 320
TANA/Madagascar
3dgs_snake Offline OP
Senior Member
3dgs_snake  Offline OP
Senior Member

Joined: Feb 2010
Posts: 320
TANA/Madagascar
Hi,

Thanks for all the answers, I just saw a documentation about it and wondered how to achieve it with gamestudio. I will try to begin with simpler effects.

Thanks again.

Best regards.


Moderated by  Blink, Hummel, Superku 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1