Re: [PD] per-pixel time based(with memory) effects, is it possible with fragment shaders?
This is entirely possible, however you would want to use a 3D texture, something on the order of dimensions 320 by 240 by x (where x is how many frames of time 'back' you want to go). This will be relatively heavy video memory wise I would imagine. However, I have a shader for you that does this. Absolutely no idea what so over if GEM can deal with 3D textures. Id assume since it has low level openGl support it should be able to, but how to get 2D video frames into that 3D texture via pix_xxx I have no idea. Here is the shader, written by Andrew Benson from Cycling74 iirc. This is sans vertex shader, but the vertex shader is basically a passthrough, so its very simple. texa is a 2d lookup table - greyscale, where the luminance of the pixel at the point determines how far back in time to go. This shader assumes a 512x512 map, but you could make that dynamic by passing a varying variable from the vertex shader that looks at the dims of the 3D texture. HTH. varying vec2 texcoord0; varying vec2 texcoord1; uniform float slice; uniform sampler3D texo; uniform sampler2DRect texa; const vec4 coeff = vec4(0.299, .587, 0.114, 0.); void main( void ) { float v1 = dot(texture2DRect(texa,texcoord0*vec2(512.)),coeff); //assumes 512 x 512 slice map. Pretty arbitrary... vec4 v0 = texture3D(texo, vec3(texcoord0.xy,v1)); gl_FragColor = v0; } On Jan 6, 2008, at 4:21 AM, Batuhan Bozkurt wrote: Hello, Let me start off by saying that I don't have much experience with computer graphics, so my knowledge is very limited on this area, I'm more of an audio guy but I have some ideas in mind that would apply to graphics well. I just want to experiment. I want to give a simple example to show my question. Suppose I have a video running and I want to delay each pixel between 0 and a maximum time seperately. This is the most basic time based effect I can think of. So for a 320x200 video for example, I would need 64000 delaying units running seperately and to be able to do this in realtime, I think I'd need to use GPU for computation. So I'm thinking of using pixel shaders. But I'm not really sure if this is possible or not with it. I grabbed the orange book to have an idea about the process, I did not have much time tolook in detail but I could not find any references to such an operation that made me think that I'm on the wrong track. So before going any further learning GLSL, I'd like to have your ideas on this. Is GLSL along with GEM is a nice way to do such an operation? Is it even possible to do it in realtime? If GPU powered realtime operation is not possible, is there any tool that you know that is capable of doing such things(realtime or offline)? I have many ideas on processes that modifies pixels which are dependant on the states of pixels before them(i.e. with memory) and I'm trying to find a way to implement them. Any help is appreciated. Thanks BB ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] dynamic patching - gui
Alexandre Quessy wrote: Hi ! Can we dynamically resize the Graph-on-parent size of an abstraction ? yes. this should be in the archives of this list (as i cannot remember exactly how it was done) mfga.sdr IOhannes ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] cooled_ for video
I am wondering how one might create a video version of sevvy's cooled extra. I would like to load in video clips and have them randomly auto-scratch at very least Just looking for some perspectives on how to approach this pp Patrick Pagano Sound and Light Technologist School of Theatre and Dance University of Florida ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] HID
Where can i find the latest HID? I jut got a logitech joystick for video filter control and want to try it. I am currently using sarlo's pd_joystick. -- Patrick Pagano Sound and Light Technologist School of Theatre and Dance University of Florida ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] PD VideoPedia Project
On 05/01/2008, at 20.29, beau wrote: Where is the place to put links on puredata.info for user created tutorials? http://puredata.info/docs/tutorials ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] PD VideoPedia Project
Steffen Juul wrote: On 05/01/2008, at 20.29, beau wrote: Where is the place to put links on puredata.info for user created tutorials? http://puredata.info/docs/tutorials and don't forget the special tutorial section in the gem-homepage: http://gem.iem.at/documentation/tutorial/ mfg.asdr IOhannes ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] mrpeach tcpclient float to string decoder, mayby str ?
Hello ! I'm testing tcpclient from mrpeach, my goal is to use julian (http://julius.sourceforge.jp/en_index.php?q=en/index.html) as an hmm decoder for realtime speech recogition. I use tcpclient to establish the link beetween julian and it works perfectly. Of course tcpclient returns lists of floats as it is designed for this, but i need to convert thoses lists of floats to list of symbols. I've guess that the str object (also from mrpeach) is there for this purpose, is it right ? Anyway I don't succed to create some outlets of the str object (I've read the doc, the lib is well installed, and some dummy str are created, even when I pass an argument to it). So here my 2 questions : 1) is STR the solution, and then how to use it ? 2) if str is not design to transforms the lists of floats into strings, does somebody has already done this and whant to share it with me ? Thanks in advance, Cheers, Damien. ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] mrpeach tcpclient float to string decoder, mayby str ?
Damien Henry - Voxler wrote: Hello ! I'm testing tcpclient from mrpeach, my goal is to use julian (http://julius.sourceforge.jp/en_index.php?q=en/index.html) as an hmm decoder for realtime speech recogition. I use tcpclient to establish the link beetween julian and it works perfectly. Of course tcpclient returns lists of floats as it is designed for this, but i need to convert thoses lists of floats to list of symbols. I've guess that the str object (also from mrpeach) is there for this purpose, is it right ? That's one reason for it. Anyway I don't succed to create some outlets of the str object (I've read the doc, the lib is well installed, and some dummy str are created, even when I pass an argument to it). If you're getting dummy strs it's because the pd you're using doesn't have strings/blobs. You need to patch the source with the add_string_support_patch, which is in cvs under packages/patches. Or use pd extended, which is built using all the patches. So here my 2 questions : 1) is STR the solution, and then how to use it ? Make a [str to_symbol] object and feed it a list of floats. Martin ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] New external for the wii remote (linux)
Hi. Just to let you know, i've rewritten the wiimote external. It needed a big rewrite to be compatible with the latest libcwiid library, which claims to have better support for IR and stuff. I've also made several other changes, but none breaks things with the old version of the external (except that you have to load it as a library). There's also experimental support for the classic controller, for example. But it would be nice to get some feedback about that since I do not have any extensions myself, so these things are untried. This is my first external for a more general audience (ie not only myself) so please mail me if you have suggestions or bug reports. check it out at: http://youngmusic.org/wiki/index.php/Wiilib Also, I've tried to contact the original author of the wiimote external, but got an error from his mailserver. So Mike, if you're on this list too, that's why i did not contact you in advance :-) Hope you don't mind. Regards, yvan ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] gem: can't load library
i figured out how to build pd, i needed the tcl-devel stuff. i was hoping that Gem built with it but alas that would be too easy. when I run: pd -lib gem i get... gem: can't load library so do I have to build Gem? that is a major pain in linux... -- --- i am an agent implanted into your unconscious when you abducted by the travelers. look for signs of me in your life. ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] MIDI on Win XP
From what I've understood in the link I've posted in this thread, you have to add audio and MIDI latency, to get the result of the delay you get with all the sound hardware. That's exactly the case. One thing I didn't figured out in this topic is that if MIDI latency is almost about one second when audio is on, then the audio latency must be be nearly this high latency as well, unless the amount of MIDI information is huge. This is caused by an error in pd. Pd needs at least as much delay as the soundcard buffer. If you go below that pd starts to stutter and does weired things like delayin audio and MIDI. A similar thing happens when you go way beyond the maximum cpu consumption e.g. 300%. Sorry if I'm picky on importance to know exactly how far the informations are delayed, I've been passing a kind of war in the computer just to get a few milliseconds in the PD processes, by reviewing how the objects [trigger] and [until] are used all along the application. I don't know what kind of buffers are used internally in pd. Maybe one of the developers can say more about this. Another point I've been thinking of that only concern latency and not MIDI nor XP, is that the player must have one meter latency (about 1000/320) if he do play with headphones, so 3ms would be perfect. With OSS driver on linux the delay goes above 5ms. I've got this result with dividing by two the output of [timer] with the two inlet connected to MIDI in and out. As mentioned earlier the actual latency is not the most important thing as long as you can keep the jitter low. Think of a large orchestra where the timpany player may easiely 5 meters away from the first violin. That's 15 ms of latency. They can still play in sync because the latency stays consistant. Same thing for acoustic church organ in a large cathedral where the instrument itself is so large that there are even latencies between the differnt notes and registers. Not even talking about mechanical delays. Ingo Scherzinger ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] per-pixel time based(with memory) effects, is it possible with fragment shaders?
This is a very elegant solution for a delay effect I should say. I've never known something called 3d texture exists but it completely makes sense. I've searched through documentation and the list for gem support for such thing but no luck yet. But thanks for the shader and the idea anyways! The problem here is that, I actually need a more generalised framework of working with time and past frames(or pixels) when dealing with time based effects. This vertex shader approach with 3D texture and a 2D map probably would not help let's say, if I wanted to use an averaging lowpass filter(depending on past pixel values) to the R G and B values of each pixel seperately. I'd like to know if there is any way to hold values back in buffers(like arrays) on shader level and make operations on that data by shader programming. So maybe I could say get current value and average it with the previous value and set it as the new current value or something like that. If there is a way, than I'd like to dig more deeply into it, but if this question looks very stupid than I'm probably getting the concept of graphics pipeline and purpose of shading language completely wrong so maybe I should stop wasting time on thinking like this and try to find other approaches. BB vade wrote: This is entirely possible, however you would want to use a 3D texture, something on the order of dimensions 320 by 240 by x (where x is how many frames of time 'back' you want to go). This will be relatively heavy video memory wise I would imagine. However, I have a shader for you that does this. Absolutely no idea what so over if GEM can deal with 3D textures. Id assume since it has low level openGl support it should be able to, but how to get 2D video frames into that 3D texture via pix_xxx I have no idea. Here is the shader, written by Andrew Benson from Cycling74 iirc. This is sans vertex shader, but the vertex shader is basically a passthrough, so its very simple. texa is a 2d lookup table - greyscale, where the luminance of the pixel at the point determines how far back in time to go. This shader assumes a 512x512 map, but you could make that dynamic by passing a varying variable from the vertex shader that looks at the dims of the 3D texture. HTH. varying vec2 texcoord0; varying vec2 texcoord1; uniform float slice; uniform sampler3D texo; uniform sampler2DRect texa; const vec4 coeff = vec4(0.299, .587, 0.114, 0.); void main( void ) { float v1 = dot(texture2DRect(texa,texcoord0*vec2(512.)),coeff); //assumes 512 x 512 slice map. Pretty arbitrary... vec4 v0 = texture3D(texo, vec3(texcoord0.xy,v1)); gl_FragColor = v0; } On Jan 6, 2008, at 4:21 AM, Batuhan Bozkurt wrote: Hello, Let me start off by saying that I don't have much experience with computer graphics, so my knowledge is very limited on this area, I'm more of an audio guy but I have some ideas in mind that would apply to graphics well. I just want to experiment. I want to give a simple example to show my question. Suppose I have a video running and I want to delay each pixel between 0 and a maximum time seperately. This is the most basic time based effect I can think of. So for a 320x200 video for example, I would need 64000 delaying units running seperately and to be able to do this in realtime, I think I'd need to use GPU for computation. So I'm thinking of using pixel shaders. But I'm not really sure if this is possible or not with it. I grabbed the orange book to have an idea about the process, I did not have much time tolook in detail but I could not find any references to such an operation that made me think that I'm on the wrong track. So before going any further learning GLSL, I'd like to have your ideas on this. Is GLSL along with GEM is a nice way to do such an operation? Is it even possible to do it in realtime? If GPU powered realtime operation is not possible, is there any tool that you know that is capable of doing such things(realtime or offline)? I have many ideas on processes that modifies pixels which are dependant on the states of pixels before them(i.e. with memory) and I'm trying to find a way to implement them. Any help is appreciated. Thanks BB ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] gem: can't load library
those *are* the things i tried... download and install pd-extended (which contains both, pd and gem http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended-planetccrma6-i386.tar.bz2 this was what I tried to do first. basically this required that I go to planet CCRMA rebuild my kernal, also get jack, once i did that i tried to run the binaries and got the floating point error, pd didnt run at all so i decided to get the extended version source code and build that... http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended.tar.bz2 it built with th following installs added yum install autoconf yum install tcl yum install tk yum install tcl-devel yum install tk-devel well that got pd running, but gem is failing. so did the extended source build gem or not? are more devel packages required that I missed? download the gem binaries from the gem site the only site I know of is http://gem.iem.at/ is this what you are talking about? I dont not see *gem binaries for linux* on windows, in fact they recommend on the site building gem, but its my understanding that this comes with pd extended, which I built, and which is not loading the gem libs. so i have now tried to build gem and it fails during configure because it *seems* to not know how to build using gcc...wierd. who uses g++, i dont even know how to get it. [EMAIL PROTECTED] src]# autoconf configure.acconfigure [EMAIL PROTECTED] src]# chmod 777 configure [EMAIL PROTECTED] src]# ./configure checking for Base/configLinux.h.in... yes checking for g++... no checking for c++... no checking for gpp... no checking for aCC... no checking for CC... no checking for cxx... no checking for cc++... no checking for cl... no checking for FCC... no checking for KCC... no checking for RCC... no checking for xlC_r... no checking for xlC... no checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. this is driving me a little crazy. On Jan 6, 2008 9:09 PM, Roman Haefeli [EMAIL PROTECTED] wrote: On Sun, 2008-01-06 at 19:13 -0800, Agent Engram wrote: i figured out how to build pd, i needed the tcl-devel stuff. i was hoping that Gem built with it but alas that would be too easy. gem is an external and not part of pd. when I run: pd -lib gem i get... gem: can't load library because there is no gem installed. so do I have to build Gem? that is a major pain in linux... this has nothing to do with linux. Gem is an extension, that provides additional funcionality to pd, which isn't in the focus of puredata itself. this is completely unrelated to the operating system. in fact, there are many ways to get Gem without having to build it. - download the gem binaries from the gem site - install a gem-package from your distro (i know that debian based distros include gem) - download and install pd-extended (which contains both, pd and gem, and a lot of other externals) just in case you decide to build gem yourself, don't forget to install also the dev-package for each dependecy. roman ___ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de -- --- i am an agent implanted into your unconscious when you abducted by the travelers. look for signs of me in your life. ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] per-pixel time based(with memory) effects, is it possible with fragment shaders?
you would copy the old frame into a different texture and then re input it into the shader. shaders address textures via texture units. you would have your new frame coming in from texture unit 0, and the old frame (the output of the shader one step earlier), copied to texture unit 1. You would then have two samplers in your shader, and do with them whatever you wanted. You bind the texture to a texture unit prior to calling the shader. in GEM you do this with the texunit message. In Jitter you do it in the XML file that describes all of your variables and the vertex/ fragment program. If you wanted to take the average it would be: setup code cut out vec4 currentframe = texture2DRect(texture0sampler, texcoord0) vec4 previousframe = texture2DRect(texture1sampler, texcoord1); gl_FragColor = (currentframe + previousframe)/2.0; handling the copying of the output of this to a texture buffer happens outside of GLSL, in your application, be it Jitter, GEM, or whatnot. And btw, fragment shaders run once for every texel or fragment (a texture mapped pixel), not once per frame :) On Jan 7, 2008, at 1:37 AM, Batuhan Bozkurt wrote: Thanks vade, your help is greatly appreciated. I'm happy to see thatthings like this are possible with shader programming. Looking through the opengl shader book and various shader tutorials online, I've actually found out how to sample a texture and access r g b a values with dot notation. But as I'm not very familiar with the process yet, I've been questioning how to buffer and access past values by shader programming. I'm not very bright when it comes to programming so it appeared to me that a shader program is simply a piece of code that is iterated for every new frame(?) from beginning to end that produces an output based on a given functional structure. I was thinking that the state of the variables are reinitialised(except for uniforms that can be passed as arguments?) each time so I'm curious about how I would store values to some depth(like maybe a static variable in C functions, so it's value is kept in a new iteration). Or maybe holding the past five values in an array or something(like the Bucket object on max or cyclone lib). Without being able to keep values I can't achieve processes that have a past memory. so vec4 mytexture = texture2DRect(textureSampler, textureCoordinate); would sample the current frame, but when the new frame comes into play, it would contain the new frame right? How would I go for accessing the old data? Sorry if this is a fundamental thing about shader programming, but I think it is a very simple process if it is really possible. So maybe you have something to say about it. Thanks! BB vade wrote: Hi You can completely do what you want on the GPU with a shader or shaders. In fact, the very shader you describe exists from cycling74 and is included with jitter. As for dealing with color planes, the RGBA values, its VERY easy to do with shaders. You simply sample a texture with: vec4 mytexture = texture2DRect(textureSampler, textureCoordinate); and then you can address you individual vector components with mytexture.a mytexture.r mytexture.g mytexture.b each as a floating point value. :) On Jan 7, 2008, at 12:28 AM, Batuhan Bozkurt wrote: This is a very elegant solution for a delay effect I should say. I've never known something called 3d texture exists but it completely makes sense. I've searched through documentation and the list for gem support for such thing but no luck yet. But thanks for the shader and the idea anyways! The problem here is that, I actually need a more generalised framework of working with time and past frames(or pixels) when dealing with time based effects. This vertex shader approach with 3D texture and a 2D map probably would not help let's say, if I wanted to use an averaging lowpass filter(depending on past pixel values) to the R G and B values of each pixel seperately. I'd like to know if there is any way to hold values back in buffers(like arrays) on shader level and make operations on that data by shader programming. So maybe I could say get current value and average it with the previous value and set it as the new current value or something like that. If there is a way, than I'd like to dig more deeply into it, but if this question looks very stupid than I'm probably getting the concept of graphics pipeline and purpose of shading language completely wrong so maybe I should stop wasting time on thinking like this and try to find other approaches. BB vade wrote: This is entirely possible, however you would want to use a 3D texture, something on the order of dimensions 320 by 240 by x (where x is how many frames of time 'back' you want to go). This will be relatively heavy video memory wise I would imagine. However, I have a shader for you that does this. Absolutely no idea what so
Re: [PD] gem: can't load library
i am on fedora here is what about said about build-essential: Definition: *build-essential*: Informational list of build-essential packages If you do not plan to build Debian packages, you don't need this package. Moreover this package is not required for building Debian packages. This package contains an informational list of packages which are considered essential for building Debian packages. is gem dependent on debian? On Jan 6, 2008 11:02 PM, Batuhan Bozkurt [EMAIL PROTECTED] wrote: I think you need to install build-essential package. BB Agent Engram wrote: those *are* the things i tried... download and install pd-extended (which contains both, pd and gem http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended-planetccrma6-i386.tar.bz2 this was what I tried to do first. basically this required that I go to planet CCRMA rebuild my kernal, also get jack, once i did that i tried to run the binaries and got the floating point error, pd didnt run at all so i decided to get the extended version source code and build that... http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended.tar.bz2 it built with th following installs added yum install autoconf yum install tcl yum install tk yum install tcl-devel yum install tk-devel well that got pd running, but gem is failing. so did the extended source build gem or not? are more devel packages required that I missed? download the gem binaries from the gem site the only site I know of is http://gem.iem.at/ is this what you are talking about? I dont not see *gem binaries for linux* on windows, in fact they recommend on the site building gem, but its my understanding that this comes with pd extended, which I built, and which is not loading the gem libs. so i have now tried to build gem and it fails during configure because it *seems* to not know how to build using gcc...wierd. who uses g++, i dont even know how to get it. [EMAIL PROTECTED] src]# autoconf configure.ac http://configure.acconfigure [EMAIL PROTECTED] src]# chmod 777 configure [EMAIL PROTECTED] src]# ./configure checking for Base/configLinux.h.in... yes checking for g++... no checking for c++... no checking for gpp... no checking for aCC... no checking for CC... no checking for cxx... no checking for cc++... no checking for cl... no checking for FCC... no checking for KCC... no checking for RCC... no checking for xlC_r... no checking for xlC... no checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. this is driving me a little crazy. On Jan 6, 2008 9:09 PM, Roman Haefeli [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On Sun, 2008-01-06 at 19:13 -0800, Agent Engram wrote: i figured out how to build pd, i needed the tcl-devel stuff. i was hoping that Gem built with it but alas that would be too easy. gem is an external and not part of pd. when I run: pd -lib gem i get... gem: can't load library because there is no gem installed. so do I have to build Gem? that is a major pain in linux... this has nothing to do with linux. Gem is an extension, that provides additional funcionality to pd, which isn't in the focus of puredata itself. this is completely unrelated to the operating system. in fact, there are many ways to get Gem without having to build it. - download the gem binaries from the gem site - install a gem-package from your distro (i know that debian based distros include gem) - download and install pd-extended (which contains both, pd and gem, and a lot of other externals) just in case you decide to build gem yourself, don't forget to install also the dev-package for each dependecy. roman ___ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de -- --- i am an agent implanted into your unconscious when you abducted by the travelers. look for signs of me in your life. ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- --- i am an agent implanted into your unconscious when you abducted by the travelers. look for signs of me in your life. ___ PD-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] per-pixel time based(with memory) effects, is it possible with fragment shaders?
Excellent! As I suspected, my view on how things were working was wrong. It makes a lot more sense now. By copying and swapping textures on texture memory and by accessing them later on, I should be able to do pretty much anything I'd like to do for now. Thanks! BB vade wrote: you would copy the old frame into a different texture and then re input it into the shader. shaders address textures via texture units. you would have your new frame coming in from texture unit 0, and the old frame (the output of the shader one step earlier), copied to texture unit 1. You would then have two samplers in your shader, and do with them whatever you wanted. You bind the texture to a texture unit prior to calling the shader. in GEM you do this with the texunit message. In Jitter you do it in the XML file that describes all of your variables and the vertex/fragment program. If you wanted to take the average it would be: setup code cut out vec4 currentframe = texture2DRect(texture0sampler, texcoord0) vec4 previousframe = texture2DRect(texture1sampler, texcoord1); gl_FragColor = (currentframe + previousframe)/2.0; handling the copying of the output of this to a texture buffer happens outside of GLSL, in your application, be it Jitter, GEM, or whatnot. And btw, fragment shaders run once for every texel or fragment (a texture mapped pixel), not once per frame :) On Jan 7, 2008, at 1:37 AM, Batuhan Bozkurt wrote: Thanks vade, your help is greatly appreciated. I'm happy to see thatthings like this are possible with shader programming. Looking through the opengl shader book and various shader tutorials online, I've actually found out how to sample a texture and access r g b a values with dot notation. But as I'm not very familiar with the process yet, I've been questioning how to buffer and access past values by shader programming. I'm not very bright when it comes to programming so it appeared to me that a shader program is simply a piece of code that is iterated for every new frame(?) from beginning to end that produces an output based on a given functional structure. I was thinking that the state of the variables are reinitialised(except for uniforms that can be passed as arguments?) each time so I'm curious about how I would store values to some depth(like maybe a static variable in C functions, so it's value is kept in a new iteration). Or maybe holding the past five values in an array or something(like the Bucket object on max or cyclone lib). Without being able to keep values I can't achieve processes that have a past memory. so vec4 mytexture = texture2DRect(textureSampler, textureCoordinate); would sample the current frame, but when the new frame comes into play, it would contain the new frame right? How would I go for accessing the old data? Sorry if this is a fundamental thing about shader programming, but I think it is a very simple process if it is really possible. So maybe you have something to say about it. Thanks! BB vade wrote: Hi You can completely do what you want on the GPU with a shader or shaders. In fact, the very shader you describe exists from cycling74 and is included with jitter. As for dealing with color planes, the RGBA values, its VERY easy to do with shaders. You simply sample a texture with: vec4 mytexture = texture2DRect(textureSampler, textureCoordinate); and then you can address you individual vector components with mytexture.a mytexture.r mytexture.g mytexture.b each as a floating point value. :) On Jan 7, 2008, at 12:28 AM, Batuhan Bozkurt wrote: This is a very elegant solution for a delay effect I should say. I've never known something called 3d texture exists but it completely makes sense. I've searched through documentation and the list for gem support for such thing but no luck yet. But thanks for the shader and the idea anyways! The problem here is that, I actually need a more generalised framework of working with time and past frames(or pixels) when dealing with time based effects. This vertex shader approach with 3D texture and a 2D map probably would not help let's say, if I wanted to use an averaging lowpass filter(depending on past pixel values) to the R G and B values of each pixel seperately. I'd like to know if there is any way to hold values back in buffers(like arrays) on shader level and make operations on that data by shader programming. So maybe I could say get current value and average it with the previous value and set it as the new current value or something like that. If there is a way, than I'd like to dig more deeply into it, but if this question looks very stupid than I'm probably getting the concept of graphics pipeline and purpose of shading language completely wrong so maybe I should stop wasting time on thinking like this and try to find other approaches. BB vade wrote: This is entirely possible, however you would want to use a
Re: [PD] gem: can't load library
Uh sorry, I've only worked with debian based linux distros and was thinking that was a global thing. I was using that for the issues with G++ and that can not build executables problem. BB Agent Engram wrote: i am on fedora here is what about said about build-essential: Definition: *build-essential*: Informational list of build-essential packages If you do not plan to build Debian packages, you don't need this package. Moreover this package is not required for building Debian packages. This package contains an informational list of packages which are considered essential for building Debian packages. is gem dependent on debian? On Jan 6, 2008 11:02 PM, Batuhan Bozkurt [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: I think you need to install build-essential package. BB Agent Engram wrote: those *are* the things i tried... download and install pd-extended (which contains both, pd and gem http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended-planetccrma6-i386.tar.bz2 this was what I tried to do first. basically this required that I go to planet CCRMA rebuild my kernal, also get jack, once i did that i tried to run the binaries and got the floating point error, pd didnt run at all so i decided to get the extended version source code and build that... http://downloads.sourceforge.net/pure-data/Pd-0.39.3-extended.tar.bz2 it built with th following installs added yum install autoconf yum install tcl yum install tk yum install tcl-devel yum install tk-devel well that got pd running, but gem is failing. so did the extended source build gem or not? are more devel packages required that I missed? download the gem binaries from the gem site the only site I know of is http://gem.iem.at/ is this what you are talking about? I dont not see *gem binaries for linux* on windows, in fact they recommend on the site building gem, but its my understanding that this comes with pd extended, which I built, and which is not loading the gem libs. so i have now tried to build gem and it fails during configure because it *seems* to not know how to build using gcc...wierd. who uses g++, i dont even know how to get it. [EMAIL PROTECTED] src]# autoconf configure.ac http://configure.ac http://configure.acconfigure [EMAIL PROTECTED] src]# chmod 777 configure [EMAIL PROTECTED] src]# ./configure checking for Base/configLinux.h.in... yes checking for g++... no checking for c++... no checking for gpp... no checking for aCC... no checking for CC... no checking for cxx... no checking for cc++... no checking for cl... no checking for FCC... no checking for KCC... no checking for RCC... no checking for xlC_r... no checking for xlC... no checking for C++ compiler default output file name... configure: error: C++ compiler cannot create executables See `config.log' for more details. this is driving me a little crazy. On Jan 6, 2008 9:09 PM, Roman Haefeli [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: On Sun, 2008-01-06 at 19:13 -0800, Agent Engram wrote: i figured out how to build pd, i needed the tcl-devel stuff. i was hoping that Gem built with it but alas that would be too easy. gem is an external and not part of pd. when I run: pd -lib gem i get... gem: can't load library because there is no gem installed. so do I have to build Gem? that is a major pain in linux... this has nothing to do with linux. Gem is an extension, that provides additional funcionality to pd, which isn't in the focus of puredata itself. this is completely unrelated to the operating system. in fact, there are many ways to get Gem without having to build it. - download the gem binaries from the gem site - install a gem-package from your distro (i know that debian based distros include gem) - download and install pd-extended (which contains both, pd and gem, and a lot of other externals) just in case you decide to build gem yourself, don't forget to install also the dev-package for each dependecy. roman ___ Telefonate ohne weitere Kosten vom PC zum PC: http://messenger.yahoo.de -- ---