A new version of the Tweak-OpenGL package is on the Hedgehog
PublicContribs repository. The required package OpenGL-OpenGL needs an "OGLExtManager initialize" to be done after it is loaded. From the package comments: ----------------------------- Name: Tweak-OpenGL-daf.6 Author: daf Time: 4 July 2007, 11:17:06 am Ancestors: Tweak-OpenGL-daf.5 A few fragment shaders to choose from. Requires the OpenGL-OpenGL package from the PublicContribs repository to be installed first. Install both packages, then in Squeak open a Tweak Project, enter it, get a Workspace from the Tools menu, enter "Wrinkle1 open" and doIt. Don't complain if your video card doesn't support GLSL shader programs. A Tweak Project Window can be used instead for better debugging, but the offsets are screwed up a bit. ----------------------------- Try it out and let me know what you think. |
Rats! I knew I forgot something! This also depends on a fix for
Mantis #6553, which can temporarily be a pretty trivial do-it-yourself kind of thing. Just change VectorColor#asVector4 so that it returns a Vector4 instance instead of a Vector3. On 7/6/07, David Faught <[hidden email]> wrote: > A new version of the Tweak-OpenGL package is on the Hedgehog > PublicContribs repository. The required package OpenGL-OpenGL needs > an "OGLExtManager initialize" to be done after it is loaded. From the > package comments: > > ----------------------------- > Name: Tweak-OpenGL-daf.6 > Author: daf > Time: 4 July 2007, 11:17:06 am > Ancestors: Tweak-OpenGL-daf.5 > > A few fragment shaders to choose from. > > Requires the OpenGL-OpenGL package from the PublicContribs repository > to be installed first. > > Install both packages, then in Squeak open a Tweak Project, enter it, > get a Workspace from the Tools menu, enter "Wrinkle1 open" and doIt. > Don't complain if your video card doesn't support GLSL shader > programs. > > A Tweak Project Window can be used instead for better debugging, but > the offsets are screwed up a bit. > ----------------------------- > > Try it out and let me know what you think. > |
In reply to this post by David Faught
Another new version. Let me know what you think. I crave feedback, +1 or
-100. From the package comments: ----- Some error handling that actually works and a few fragment shaders to choose from. Requires the OpenGL-OpenGL package from the PublicContribs repository to be installed first. It is necessary to manually do "OGLExtManager initialize" after loading the OpenGL-OpenGL package. This package also depends on a fix for Mantis #6553, which can temporarily be a pretty trivial do-it-yourself kind of thing. Just change VectorColor#asVector4 so that it returns a Vector4 instance instead of a Vector3. Install both packages, do the couple of manual items above, then in Squeak open a Tweak Project, enter it, get a Workspace from the Tools menu, enter "GPUInfo new chkGLSLSupport" and doIt. If this says that you have GLSL support, then enter "Wrinkle1 open" and doIt. A Tweak Project Window can be used instead of a Tweak Project for somewhat better debugging, but the offsets are screwed up a bit. ----- It takes a couple of minutes to do the GLSL compiles on my machine. |
Hi David, followed your instructions on 1.0.18 image (updated, on WinXP SP2, AMD 64 3000+, see
below for gfx) in a Tweak project window and it worked, so +1 for that :) However on creating a tweak project I first entered the project then went immediately back to morphic to save the image. Shortly after the save completed Croquet hung or went into an endless loop or something. I can interrupt it but cannot gain any further control, ie, it is now unresponsive to mouse clicks. Unfortunately I hadn't done much in this image except apply updates and run a few tests so I had not got around to backing it up. Same situation even if I restart the vm, not even time to take remedial action. I let it run for a minute or two and while it does not appear to be eating memory it does hog the CPU at around 99%. If you know of any way to gain back control and figure out what has gone wrong then I'm happy to help track down the bug, otherwise I'll start with a fresh image sometime. > GPUInfo new chkGLSLSupport OpenGL drivers version: 2.0.6590 WinXP Release vendor: ATI Technologies Inc. renderer: ATI MOBILITY RADEON X700 x86/MMX/3DNow!/SSE2 GLSL is supported, hurray! _____________________________________________________ Do not compromise. Get unlimited storage and first rate spam protection with Yahoo! Mail. http://uk.mail.yahoo.com |
Hhmm, how do I answer this without ruffling feathers? I don't know,
but I would certainly prefer that the TweakMeister and friends not take particular offense to this. Yes, I too have had problems when switching back out of a Tweak Project to Morphic, and I have for the moment elected not to deep dive into assisting with the debugging in this area. It is my understanding that the area of interaction between Tweak and Morphic is volatile and (like the rest of Croquet) subject to change at any time. Note that there is an environmental difference in opening a "Tweak Project" and opening a "Tweak Project Window" from the open menu. I have not had the same problems with a Tweak Project Window, and in fact it generally seems to cooperate with Morphic more cleanly. It is actually much easier to develop and test code using a Tweak Project Window because of this cleaner interaction with Morphic. The only problem with this approach is that I can't seem to figure out the proper screen offsets for the OpenGL player in this environment. So to have a workable environment, the way I go about developing with the OpenGL player in Tweak is to make my code changes with the Morphic class browser and other nice Morphic code tools, test out the code with a Tweak Project Window (which can remain open or minimized while going back to the Morphic browser for more changes). When I think the code is relatively clean, then I save the image, close the Tweak Project Window, and then open and go into a Tweak Project to try it out. After trying it out, then I just close the whole thing and start all over by freshly loading the saved image. This won't help recover your image, but might help with building a new one that won't have the same problem. Cheers, Dave On 7/14/07, dmoc <[hidden email]> wrote: > Hi David, followed your instructions on 1.0.18 image (updated, on WinXP SP2, AMD 64 3000+, see > below for gfx) in a Tweak project window and it worked, so +1 for that :) However on creating a > tweak project I first entered the project then went immediately back to morphic to save the image. > Shortly after the save completed Croquet hung or went into an endless loop or something. I can > interrupt it but cannot gain any further control, ie, it is now unresponsive to mouse clicks. > Unfortunately I hadn't done much in this image except apply updates and run a few tests so I had > not got around to backing it up. Same situation even if I restart the vm, not even time to take > remedial action. I let it run for a minute or two and while it does not appear to be eating memory > it does hog the CPU at around 99%. > > If you know of any way to gain back control and figure out what has gone wrong then I'm happy to > help track down the bug, otherwise I'll start with a fresh image sometime. > > > GPUInfo new chkGLSLSupport > > OpenGL drivers > version: 2.0.6590 WinXP Release > vendor: ATI Technologies Inc. > renderer: ATI MOBILITY RADEON X700 x86/MMX/3DNow!/SSE2 > GLSL is supported, hurray! > > > > > > _____________________________________________________ > Do not compromise. Get unlimited storage and first rate spam protection with Yahoo! Mail. > http://uk.mail.yahoo.com > |
In reply to this post by David Faught
Looks great David. Any idea why it takes so long to set up?
On Jul 14, 2007, at 10:10 AM, David Faught wrote: > Another new version. Let me know what you think. I crave > feedback, +1 or > -100. From the package comments: > ----- > Some error handling that actually works and a few fragment shaders > to choose > from. > > Requires the OpenGL-OpenGL package from the PublicContribs > repository to be > installed first. It is necessary to manually do "OGLExtManager > initialize" > after loading the OpenGL-OpenGL package. > > This package also depends on a fix for Mantis #6553, which can > temporarily be a > pretty trivial do-it-yourself kind of thing. Just change > VectorColor#asVector4 > so that it returns a Vector4 instance instead of a Vector3. > > Install both packages, do the couple of manual items above, then in > Squeak open > a Tweak Project, enter it, get a Workspace from the Tools menu, > enter "GPUInfo > new chkGLSLSupport" and doIt. If this says that you have GLSL > support, then > enter "Wrinkle1 open" and doIt. > > A Tweak Project Window can be used instead of a Tweak Project for > somewhat > better debugging, but the offsets are screwed up a bit. > ----- > It takes a couple of minutes to do the GLSL compiles on my machine. |
I have not done any profiling to find out, but my guess is that the
GLSL compiler just isn't very swift. I have seen some comments to that effect on some of the OGL/GLSL support lists. It seems to get noticably longer with longer shader programs, which is a bad thing since you can't really save the compiled programs. On 7/16/07, Peter Moore <[hidden email]> wrote: > Looks great David. Any idea why it takes so long to set up? > > On Jul 14, 2007, at 10:10 AM, David Faught wrote: > > > Another new version. Let me know what you think. I crave > > feedback, +1 or > > -100. From the package comments: > > ----- > > Some error handling that actually works and a few fragment shaders > > to choose > > from. > > > > Requires the OpenGL-OpenGL package from the PublicContribs > > repository to be > > installed first. It is necessary to manually do "OGLExtManager > > initialize" > > after loading the OpenGL-OpenGL package. > > > > This package also depends on a fix for Mantis #6553, which can > > temporarily be a > > pretty trivial do-it-yourself kind of thing. Just change > > VectorColor#asVector4 > > so that it returns a Vector4 instance instead of a Vector3. > > > > Install both packages, do the couple of manual items above, then in > > Squeak open > > a Tweak Project, enter it, get a Workspace from the Tools menu, > > enter "GPUInfo > > new chkGLSLSupport" and doIt. If this says that you have GLSL > > support, then > > enter "Wrinkle1 open" and doIt. > > > > A Tweak Project Window can be used instead of a Tweak Project for > > somewhat > > better debugging, but the offsets are screwed up a bit. > > ----- > > It takes a couple of minutes to do the GLSL compiles on my machine. > > |
In reply to this post by David Faught
David Faught wrote:
> Hhmm, how do I answer this without ruffling feathers? I don't know, > but I would certainly prefer that the TweakMeister and friends not > take particular offense to this. No feathers ruffled ;-) > Yes, I too have had problems when switching back out of a Tweak > Project to Morphic, and I have for the moment elected not to deep dive > into assisting with the debugging in this area. It is my > understanding that the area of interaction between Tweak and Morphic > is volatile and (like the rest of Croquet) subject to change at any > time. Not really. Much of this work is simply incomplete and I haven't had the time to go through it carefully and fix the remaining issues. If you have patches that address problems at hand please do send them. > Note that there is an environmental difference in opening a "Tweak > Project" and opening a "Tweak Project Window" from the open menu. I > have not had the same problems with a Tweak Project Window, and in > fact it generally seems to cooperate with Morphic more cleanly. It is > actually much easier to develop and test code using a Tweak Project > Window because of this cleaner interaction with Morphic. The only > problem with this approach is that I can't seem to figure out the > proper screen offsets for the OpenGL player in this environment. This is actually easy to fix. All you need to do is to use a subclass of CPanel which will automatically get its "window" iVar to be populated with the CProjectMorph you are using. So, for example: CPanel subclass: #COpenGLPanel instanceVariableNames: '' classVariableNames: '' poolDictionaries: '' category: 'Tweak-OpenGL' COpenGLPanel>>oglBounds "Answer the bounds for OpenGL rendering" ^self globalBounds translateBy: (window boundsInWorld origin + window borderWidth). This is really all you need. Cheers, - Andreas |
On Jul 16, 2007, at 20:33 , Andreas Raab wrote:
> David Faught wrote: > >> Note that there is an environmental difference in opening a "Tweak >> Project" and opening a "Tweak Project Window" from the open menu. I >> have not had the same problems with a Tweak Project Window, and in >> fact it generally seems to cooperate with Morphic more cleanly. >> It is >> actually much easier to develop and test code using a Tweak Project >> Window because of this cleaner interaction with Morphic. The only >> problem with this approach is that I can't seem to figure out the >> proper screen offsets for the OpenGL player in this environment. > > This is actually easy to fix. All you need to do is to use a > subclass of CPanel which will automatically get its "window" iVar > to be populated with the CProjectMorph you are using. So, for example: > > CPanel subclass: #COpenGLPanel > instanceVariableNames: '' > classVariableNames: '' > poolDictionaries: '' > category: 'Tweak-OpenGL' > > COpenGLPanel>>oglBounds > "Answer the bounds for OpenGL rendering" > ^self globalBounds translateBy: (window boundsInWorld origin + > window borderWidth). > > This is really all you need. I wonder why my Sensor/hand hack doesn't work anymore. "self hand" appears to be nil in the drawOn: method. Why? - Bert - |
In reply to this post by David Faught
> I have not done any profiling to find out, but my guess is that the
> GLSL compiler just isn't very swift. I have seen some comments to > that effect on some of the OGL/GLSL support lists. It seems to get > noticably longer with longer shader programs, which is a bad thing > since you can't really save the compiled programs. Hey David, In the C++ programs I've written they load and compile almost instantly (at least on the Mac) for even some decently long shaders. When working with shaders in Croquet I notice performance is roughly equal for everything but creating the first Program Object (eg the first piece of code to be created when setting up shaders). I assume this has to do with deeper elements of Croquet preparing/initializing the GL layer in some way before the GL driver comes into play. So my question is, what's going on there. Cheers, Derek > > On 7/16/07, Peter Moore <[hidden email]> wrote: >> Looks great David. Any idea why it takes so long to set up? >> >> On Jul 14, 2007, at 10:10 AM, David Faught wrote: >> >> > Another new version. Let me know what you think. I crave >> > feedback, +1 or >> > -100. From the package comments: >> > ----- >> > Some error handling that actually works and a few fragment shaders >> > to choose >> > from. >> > >> > Requires the OpenGL-OpenGL package from the PublicContribs >> > repository to be >> > installed first. It is necessary to manually do "OGLExtManager >> > initialize" >> > after loading the OpenGL-OpenGL package. >> > >> > This package also depends on a fix for Mantis #6553, which can >> > temporarily be a >> > pretty trivial do-it-yourself kind of thing. Just change >> > VectorColor#asVector4 >> > so that it returns a Vector4 instance instead of a Vector3. >> > >> > Install both packages, do the couple of manual items above, then in >> > Squeak open >> > a Tweak Project, enter it, get a Workspace from the Tools menu, >> > enter "GPUInfo >> > new chkGLSLSupport" and doIt. If this says that you have GLSL >> > support, then >> > enter "Wrinkle1 open" and doIt. >> > >> > A Tweak Project Window can be used instead of a Tweak Project for >> > somewhat >> > better debugging, but the offsets are screwed up a bit. >> > ----- >> > It takes a couple of minutes to do the GLSL compiles on my machine. >> >> |
In reply to this post by Bert Freudenberg
On 7/16/07, Bert Freudenberg <[hidden email]> wrote:
> On Jul 16, 2007, at 20:33 , Andreas Raab wrote: > > David Faught wrote: > > > >> Note that there is an environmental difference in opening a "Tweak > >> Project" and opening a "Tweak Project Window" from the open menu. I > >> have not had the same problems with a Tweak Project Window, and in > >> fact it generally seems to cooperate with Morphic more cleanly. > >> It is > >> actually much easier to develop and test code using a Tweak Project > >> Window because of this cleaner interaction with Morphic. The only > >> problem with this approach is that I can't seem to figure out the > >> proper screen offsets for the OpenGL player in this environment. > > > > This is actually easy to fix. All you need to do is to use a > > subclass of CPanel which will automatically get its "window" iVar > > to be populated with the CProjectMorph you are using. So, for example: > > > > CPanel subclass: #COpenGLPanel > > instanceVariableNames: '' > > classVariableNames: '' > > poolDictionaries: '' > > category: 'Tweak-OpenGL' > > > > COpenGLPanel>>oglBounds > > "Answer the bounds for OpenGL rendering" > > ^self globalBounds translateBy: (window boundsInWorld origin + > > window borderWidth). > > > > This is really all you need. > > I wonder why my Sensor/hand hack doesn't work anymore. "self hand" > appears to be nil in the drawOn: method. Why? Your hack works fine in a Tweak Project, but not in a Tweak Project Window. I have not looked too deeply into the differences between the two, but I can tell that there are differences. Andreas' approach is a little cleaner, but I haven't yet gotten it to work in a Tweak Project Window either. |
In reply to this post by Derek Arndt
Okay, here is a simple profile of my loadshader method, which should
happen just once for the first render. This looks pretty hinkey to me, but I'm not sure exactly what to make of it. Someone more knowledgable care to comment? - 77160 tallies, 80837 msec. **Tree** 99.3% {80271ms} OGLWin32(OpenGL)>>glCreateShaderObjectARB: 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>doesNotUnderstand: 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>loadExtension: 99.2% {80190ms} *OGLExtManager class(Behavior)>>addSelector:withMethod: 99.2% {80190ms} *OGLExtManager class(ClassDescription)>>addSelector:withMethod:notifying: 99.2% {80190ms} SystemChangeNotifier>>methodAdded:selector:inClass:requestor: 99.2% {80190ms} SystemChangeNotifier>>trigger: 99.2% {80190ms} AddedEvent(AbstractEvent)>>trigger: 99.2% {80190ms} SystemEventManager(Object)>>triggerEvent:with: 99.2% {80190ms} SystemEventManager(Object)>>triggerEvent:withArguments: 99.2% {80190ms} WeakActionSequenceTrappingErrors>>valueWithArguments: 99.2% {80190ms} WeakActionSequenceTrappingErrors>>valueWithArgum...startingFrom: 99.2% {80190ms} WeakMessageSend>>valueWithArguments: 99.2% {80190ms} MCWorkingCopy class(MCPackageManager class)>>methodModified: 99.2% {80190ms} MCWorkingCopy class(MCPackageManager class)>>managersForClass:selector:do: 99.2% {80190ms} MCWorkingCopy class(MCPackageManager class)>>managersForClass:category:do: 99.2% {80190ms} MCWorkingCopy class(MCPackageManager class)>>managersForClass:do: [98.8% {79867ms} PackageInfo>>includesClass: [ 98.7% {79786ms} *OGLExtManager class(Class)>>category [ 89.5% {72349ms} SystemOrganizer(Categorizer)>>categoryOfElement: [ |89.5% {72349ms} SystemOrganizer(Categorizer)>>numberOfCategoryOfElement: [ | 51.8% {41874ms} ByteString(String)>>= [ | |36.4% {29425ms} primitives [ | |15.4% {12449ms} ByteString(String)>>compare:caseSensitive: [ | 37.8% {30556ms} primitives [ 9.0% {7275ms} SystemOrganizer(Categorizer)>>listAtCategoryNamed: [ 9.0% {7275ms} Array(SequenceableCollection)>>indexOf:ifAbsent: [ 9.0% {7275ms} Array(SequenceableCollection)>>indexOf:startingAt:ifAbsent: [ 6.0% {4850ms} ByteSymbol(Symbol)>>= [ |3.3% {2668ms} primitives [ |2.7% {2183ms} ByteSymbol(String)>>= [ 3.0% {2425ms} primitives **Leaves** 39.2% {31688ms} ByteSymbol(String)>>= 37.8% {30556ms} SystemOrganizer(Categorizer)>>numberOfCategoryOfElement: 15.4% {12449ms} ByteString(String)>>compare:caseSensitive: 3.3% {2668ms} ByteSymbol(Symbol)>>= 3.0% {2425ms} Array(SequenceableCollection)>>indexOf:startingAt:ifAbsent: **Memory** old +0 bytes young +298,768 bytes used +298,768 bytes free -298,768 bytes **GCs** full 0 totalling 0ms (0.0% uptime) incr 1948 totalling 3,992ms (5.0% uptime), avg 2.0ms tenures 0 root table 0 overflows On 7/16/07, Derek Arndt <[hidden email]> wrote: > > I have not done any profiling to find out, but my guess is that the > > GLSL compiler just isn't very swift. I have seen some comments to > > that effect on some of the OGL/GLSL support lists. It seems to get > > noticably longer with longer shader programs, which is a bad thing > > since you can't really save the compiled programs. > > Hey David, > > In the C++ programs I've written they load and compile almost > instantly (at least on the Mac) for even some decently long shaders. > When working with shaders in Croquet I notice performance is roughly > equal for everything but creating the first Program Object (eg the > first piece of code to be created when setting up shaders). I assume > this has to do with deeper elements of Croquet preparing/initializing > the GL layer in some way before the GL driver comes into play. > > So my question is, what's going on there. > > Cheers, > Derek > > > > > On 7/16/07, Peter Moore <[hidden email]> wrote: > >> Looks great David. Any idea why it takes so long to set up? > >> > >> On Jul 14, 2007, at 10:10 AM, David Faught wrote: > >> > >> > Another new version. Let me know what you think. I crave > >> > feedback, +1 or > >> > -100. From the package comments: > >> > ----- > >> > Some error handling that actually works and a few fragment shaders > >> > to choose > >> > from. > >> > > >> > Requires the OpenGL-OpenGL package from the PublicContribs > >> > repository to be > >> > installed first. It is necessary to manually do "OGLExtManager > >> > initialize" > >> > after loading the OpenGL-OpenGL package. > >> > > >> > This package also depends on a fix for Mantis #6553, which can > >> > temporarily be a > >> > pretty trivial do-it-yourself kind of thing. Just change > >> > VectorColor#asVector4 > >> > so that it returns a Vector4 instance instead of a Vector3. > >> > > >> > Install both packages, do the couple of manual items above, then in > >> > Squeak open > >> > a Tweak Project, enter it, get a Workspace from the Tools menu, > >> > enter "GPUInfo > >> > new chkGLSLSupport" and doIt. If this says that you have GLSL > >> > support, then > >> > enter "Wrinkle1 open" and doIt. > >> > > >> > A Tweak Project Window can be used instead of a Tweak Project for > >> > somewhat > >> > better debugging, but the offsets are screwed up a bit. > >> > ----- > >> > It takes a couple of minutes to do the GLSL compiles on my machine. > >> > >> > > |
In reply to this post by David Faught
David Faught wrote:
> Your hack works fine in a Tweak Project, but not in a Tweak Project > Window. I have not looked too deeply into the differences between the > two, but I can tell that there are differences. Andreas' approach is > a little cleaner, but I haven't yet gotten it to work in a Tweak > Project Window either. So what's the problem? You should be able to calculate the offset simply via "window boundsInWorld origin". Perhaps you're not launching your app correctly? The panel needs to be fired up via CProjectMorph open: COpenGLPanel. In any case, let me know what the problem is. Cheers, - Andreas |
On 7/16/07, Andreas Raab <[hidden email]> wrote:
> David Faught wrote: > > Your hack works fine in a Tweak Project, but not in a Tweak Project > > Window. I have not looked too deeply into the differences between the > > two, but I can tell that there are differences. Andreas' approach is > > a little cleaner, but I haven't yet gotten it to work in a Tweak > > Project Window either. > > So what's the problem? You should be able to calculate the offset simply > via "window boundsInWorld origin". Perhaps you're not launching your app > correctly? The panel needs to be fired up via > > CProjectMorph open: COpenGLPanel. > > In any case, let me know what the problem is. Thanks for your help! The error that I get in your oglBounds method is: MessageNotUnderstood: CWindow>>boundsInWorld |
Well, I have to apologize to anyone that is trying to directly use the
more basic original COpenGLPlayer class in this new package, rather than one of the subclasses. It appears to be broken at the moment as the result of moving the glLoadIdentity() call to a different method to make it more compatible with the subclasses. I already have the fix for this particular problem and hopefully I'll get it put in the repository in the next couple of days. I found this when trying out Andreas' proposed fix for the OGL offset, which I still can't get to work. I vaguely recall Bert saying something to the effect that there is no official way to refer to the Morphic environment from Tweak, although there used to be a simple way in Jasmine. Maybe this has something to do with it? |
In reply to this post by David Faught
David Faught wrote:
> Okay, here is a simple profile of my loadshader method, which should > happen just once for the first render. This looks pretty hinkey to > me, but I'm not sure exactly what to make of it. Someone more > knowledgable care to comment? Ouch. This is a bug that I had long fixed and just forgotten. I just posted it again to the Hedgehog repository. If you load the updated OpenGL package this problem will be gone. Cheers, - Andreas > - 77160 tallies, 80837 msec. > > **Tree** > 99.3% {80271ms} OGLWin32(OpenGL)>>glCreateShaderObjectARB: > 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>doesNotUnderstand: > 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>loadExtension: > 99.2% {80190ms} *OGLExtManager > class(Behavior)>>addSelector:withMethod: > 99.2% {80190ms} *OGLExtManager > class(ClassDescription)>>addSelector:withMethod:notifying: > 99.2% {80190ms} > SystemChangeNotifier>>methodAdded:selector:inClass:requestor: > 99.2% {80190ms} SystemChangeNotifier>>trigger: > 99.2% {80190ms} AddedEvent(AbstractEvent)>>trigger: > 99.2% {80190ms} > SystemEventManager(Object)>>triggerEvent:with: > 99.2% {80190ms} > SystemEventManager(Object)>>triggerEvent:withArguments: > 99.2% {80190ms} > WeakActionSequenceTrappingErrors>>valueWithArguments: > 99.2% {80190ms} > WeakActionSequenceTrappingErrors>>valueWithArgum...startingFrom: > 99.2% {80190ms} WeakMessageSend>>valueWithArguments: > 99.2% {80190ms} MCWorkingCopy > class(MCPackageManager class)>>methodModified: > 99.2% {80190ms} MCWorkingCopy > class(MCPackageManager class)>>managersForClass:selector:do: > 99.2% {80190ms} MCWorkingCopy > class(MCPackageManager class)>>managersForClass:category:do: > 99.2% {80190ms} MCWorkingCopy > class(MCPackageManager class)>>managersForClass:do: > [98.8% {79867ms} PackageInfo>>includesClass: > [ 98.7% {79786ms} *OGLExtManager class(Class)>>category > [ 89.5% {72349ms} SystemOrganizer(Categorizer)>>categoryOfElement: > [ |89.5% {72349ms} > SystemOrganizer(Categorizer)>>numberOfCategoryOfElement: > [ | 51.8% {41874ms} ByteString(String)>>= > [ | |36.4% {29425ms} primitives > [ | |15.4% {12449ms} ByteString(String)>>compare:caseSensitive: > [ | 37.8% {30556ms} primitives > [ 9.0% {7275ms} SystemOrganizer(Categorizer)>>listAtCategoryNamed: > [ 9.0% {7275ms} Array(SequenceableCollection)>>indexOf:ifAbsent: > [ 9.0% {7275ms} > Array(SequenceableCollection)>>indexOf:startingAt:ifAbsent: > [ 6.0% {4850ms} ByteSymbol(Symbol)>>= > [ |3.3% {2668ms} primitives > [ |2.7% {2183ms} ByteSymbol(String)>>= > [ 3.0% {2425ms} primitives > > **Leaves** > 39.2% {31688ms} ByteSymbol(String)>>= > 37.8% {30556ms} SystemOrganizer(Categorizer)>>numberOfCategoryOfElement: > 15.4% {12449ms} ByteString(String)>>compare:caseSensitive: > 3.3% {2668ms} ByteSymbol(Symbol)>>= > 3.0% {2425ms} Array(SequenceableCollection)>>indexOf:startingAt:ifAbsent: > > **Memory** > old +0 bytes > young +298,768 bytes > used +298,768 bytes > free -298,768 bytes > > **GCs** > full 0 totalling 0ms (0.0% uptime) > incr 1948 totalling 3,992ms (5.0% uptime), avg 2.0ms > tenures 0 > root table 0 overflows > > > > On 7/16/07, Derek Arndt <[hidden email]> wrote: >> > I have not done any profiling to find out, but my guess is that the >> > GLSL compiler just isn't very swift. I have seen some comments to >> > that effect on some of the OGL/GLSL support lists. It seems to get >> > noticably longer with longer shader programs, which is a bad thing >> > since you can't really save the compiled programs. >> >> Hey David, >> >> In the C++ programs I've written they load and compile almost >> instantly (at least on the Mac) for even some decently long shaders. >> When working with shaders in Croquet I notice performance is roughly >> equal for everything but creating the first Program Object (eg the >> first piece of code to be created when setting up shaders). I assume >> this has to do with deeper elements of Croquet preparing/initializing >> the GL layer in some way before the GL driver comes into play. >> >> So my question is, what's going on there. >> >> Cheers, >> Derek >> >> > >> > On 7/16/07, Peter Moore <[hidden email]> wrote: >> >> Looks great David. Any idea why it takes so long to set up? >> >> >> >> On Jul 14, 2007, at 10:10 AM, David Faught wrote: >> >> >> >> > Another new version. Let me know what you think. I crave >> >> > feedback, +1 or >> >> > -100. From the package comments: >> >> > ----- >> >> > Some error handling that actually works and a few fragment shaders >> >> > to choose >> >> > from. >> >> > >> >> > Requires the OpenGL-OpenGL package from the PublicContribs >> >> > repository to be >> >> > installed first. It is necessary to manually do "OGLExtManager >> >> > initialize" >> >> > after loading the OpenGL-OpenGL package. >> >> > >> >> > This package also depends on a fix for Mantis #6553, which can >> >> > temporarily be a >> >> > pretty trivial do-it-yourself kind of thing. Just change >> >> > VectorColor#asVector4 >> >> > so that it returns a Vector4 instance instead of a Vector3. >> >> > >> >> > Install both packages, do the couple of manual items above, then in >> >> > Squeak open >> >> > a Tweak Project, enter it, get a Workspace from the Tools menu, >> >> > enter "GPUInfo >> >> > new chkGLSLSupport" and doIt. If this says that you have GLSL >> >> > support, then >> >> > enter "Wrinkle1 open" and doIt. >> >> > >> >> > A Tweak Project Window can be used instead of a Tweak Project for >> >> > somewhat >> >> > better debugging, but the offsets are screwed up a bit. >> >> > ----- >> >> > It takes a couple of minutes to do the GLSL compiles on my machine. >> >> >> >> >> >> > |
In reply to this post by David Faught
David Faught wrote:
>> In any case, let me know what the problem is. > > Thanks for your help! The error that I get in your oglBounds method is: > > MessageNotUnderstood: CWindow>>boundsInWorld Oh. You must have launched this from within Tweak project builder. This is not what I meant. The example was meant as a sort of "standalone app" in Morphic that gets run without the overhead implied by CProjectBuilder. In other words you need to launch it from Morphic not from inside Tweak. Cheers, - Andreas |
In reply to this post by Andreas.Raab
> Ouch. This is a bug that I had long fixed and just forgotten. I
> just posted it again to the Hedgehog repository. If you load the > updated OpenGL package this problem will be gone. 30ish second load time to 1ish on one of my demos - <borat> very nice! </borat>. Thanks Andreas, Derek On Jul 17, 2007, at 11:26 AM, Andreas Raab wrote: > David Faught wrote: >> Okay, here is a simple profile of my loadshader method, which should >> happen just once for the first render. This looks pretty hinkey to >> me, but I'm not sure exactly what to make of it. Someone more >> knowledgable care to comment? > > Ouch. This is a bug that I had long fixed and just forgotten. I > just posted it again to the Hedgehog repository. If you load the > updated OpenGL package this problem will be gone. > > Cheers, > - Andreas > >> - 77160 tallies, 80837 msec. >> **Tree** >> 99.3% {80271ms} OGLWin32(OpenGL)>>glCreateShaderObjectARB: >> 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>doesNotUnderstand: >> 99.3% {80271ms} *OGLExtManager(OGLExtManager)>>loadExtension: >> 99.2% {80190ms} *OGLExtManager class(Behavior) >> >>addSelector:withMethod: >> 99.2% {80190ms} *OGLExtManager >> class(ClassDescription)>>addSelector:withMethod:notifying: >> 99.2% {80190ms} >> SystemChangeNotifier>>methodAdded:selector:inClass:requestor: >> 99.2% {80190ms} SystemChangeNotifier>>trigger: >> 99.2% {80190ms} AddedEvent(AbstractEvent)>>trigger: >> 99.2% {80190ms} SystemEventManager(Object) >> >>triggerEvent:with: >> 99.2% {80190ms} >> SystemEventManager(Object)>>triggerEvent:withArguments: >> 99.2% {80190ms} >> WeakActionSequenceTrappingErrors>>valueWithArguments: >> 99.2% {80190ms} >> WeakActionSequenceTrappingErrors>>valueWithArgum...startingFrom: >> 99.2% {80190ms} >> WeakMessageSend>>valueWithArguments: >> 99.2% {80190ms} MCWorkingCopy >> class(MCPackageManager class)>>methodModified: >> 99.2% {80190ms} MCWorkingCopy >> class(MCPackageManager class)>>managersForClass:selector:do: >> 99.2% {80190ms} MCWorkingCopy >> class(MCPackageManager class)>>managersForClass:category:do: >> 99.2% {80190ms} MCWorkingCopy >> class(MCPackageManager class)>>managersForClass:do: >> [98.8% {79867ms} PackageInfo>>includesClass: >> [ 98.7% {79786ms} *OGLExtManager class(Class)>>category >> [ 89.5% {72349ms} SystemOrganizer(Categorizer)>>categoryOfElement: >> [ |89.5% {72349ms} SystemOrganizer(Categorizer) >> >>numberOfCategoryOfElement: >> [ | 51.8% {41874ms} ByteString(String)>>= >> [ | |36.4% {29425ms} primitives >> [ | |15.4% {12449ms} ByteString(String) >> >>compare:caseSensitive: >> [ | 37.8% {30556ms} primitives >> [ 9.0% {7275ms} SystemOrganizer(Categorizer)>>listAtCategoryNamed: >> [ 9.0% {7275ms} Array(SequenceableCollection)>>indexOf:ifAbsent: >> [ 9.0% {7275ms} >> Array(SequenceableCollection)>>indexOf:startingAt:ifAbsent: >> [ 6.0% {4850ms} ByteSymbol(Symbol)>>= >> [ |3.3% {2668ms} primitives >> [ |2.7% {2183ms} ByteSymbol(String)>>= >> [ 3.0% {2425ms} primitives >> **Leaves** >> 39.2% {31688ms} ByteSymbol(String)>>= >> 37.8% {30556ms} SystemOrganizer(Categorizer) >> >>numberOfCategoryOfElement: >> 15.4% {12449ms} ByteString(String)>>compare:caseSensitive: >> 3.3% {2668ms} ByteSymbol(Symbol)>>= >> 3.0% {2425ms} Array(SequenceableCollection) >> >>indexOf:startingAt:ifAbsent: >> **Memory** >> old +0 bytes >> young +298,768 bytes >> used +298,768 bytes >> free -298,768 bytes >> **GCs** >> full 0 totalling 0ms (0.0% uptime) >> incr 1948 totalling 3,992ms (5.0% uptime), avg 2.0ms >> tenures 0 >> root table 0 overflows >> On 7/16/07, Derek Arndt <[hidden email]> wrote: >>> > I have not done any profiling to find out, but my guess is that >>> the >>> > GLSL compiler just isn't very swift. I have seen some comments to >>> > that effect on some of the OGL/GLSL support lists. It seems to >>> get >>> > noticably longer with longer shader programs, which is a bad thing >>> > since you can't really save the compiled programs. >>> >>> Hey David, >>> >>> In the C++ programs I've written they load and compile almost >>> instantly (at least on the Mac) for even some decently long shaders. >>> When working with shaders in Croquet I notice performance is roughly >>> equal for everything but creating the first Program Object (eg the >>> first piece of code to be created when setting up shaders). I >>> assume >>> this has to do with deeper elements of Croquet preparing/ >>> initializing >>> the GL layer in some way before the GL driver comes into play. >>> >>> So my question is, what's going on there. >>> >>> Cheers, >>> Derek >>> >>> > >>> > On 7/16/07, Peter Moore <[hidden email]> wrote: >>> >> Looks great David. Any idea why it takes so long to set up? >>> >> >>> >> On Jul 14, 2007, at 10:10 AM, David Faught wrote: >>> >> >>> >> > Another new version. Let me know what you think. I crave >>> >> > feedback, +1 or >>> >> > -100. From the package comments: >>> >> > ----- >>> >> > Some error handling that actually works and a few fragment >>> shaders >>> >> > to choose >>> >> > from. >>> >> > >>> >> > Requires the OpenGL-OpenGL package from the PublicContribs >>> >> > repository to be >>> >> > installed first. It is necessary to manually do "OGLExtManager >>> >> > initialize" >>> >> > after loading the OpenGL-OpenGL package. >>> >> > >>> >> > This package also depends on a fix for Mantis #6553, which can >>> >> > temporarily be a >>> >> > pretty trivial do-it-yourself kind of thing. Just change >>> >> > VectorColor#asVector4 >>> >> > so that it returns a Vector4 instance instead of a Vector3. >>> >> > >>> >> > Install both packages, do the couple of manual items above, >>> then in >>> >> > Squeak open >>> >> > a Tweak Project, enter it, get a Workspace from the Tools menu, >>> >> > enter "GPUInfo >>> >> > new chkGLSLSupport" and doIt. If this says that you have GLSL >>> >> > support, then >>> >> > enter "Wrinkle1 open" and doIt. >>> >> > >>> >> > A Tweak Project Window can be used instead of a Tweak >>> Project for >>> >> > somewhat >>> >> > better debugging, but the offsets are screwed up a bit. >>> >> > ----- >>> >> > It takes a couple of minutes to do the GLSL compiles on my >>> machine. >>> >> >>> >> >>> >>> |
In reply to this post by Andreas.Raab
On 7/17/07, Andreas Raab <[hidden email]> wrote:
> David Faught wrote: > >> In any case, let me know what the problem is. > > > > Thanks for your help! The error that I get in your oglBounds method is: > > > > MessageNotUnderstood: CWindow>>boundsInWorld > > Oh. You must have launched this from within Tweak project builder. This > is not what I meant. The example was meant as a sort of "standalone app" > in Morphic that gets run without the overhead implied by > CProjectBuilder. In other words you need to launch it from Morphic not > from inside Tweak. This is also the result when I use the statement: CProjectMorph open: COpenGLPanel from your previous note. |
David Faught wrote:
>> Oh. You must have launched this from within Tweak project builder. This >> is not what I meant. The example was meant as a sort of "standalone app" >> in Morphic that gets run without the overhead implied by >> CProjectBuilder. In other words you need to launch it from Morphic not >> from inside Tweak. > > This is also the result when I use the statement: > > CProjectMorph open: COpenGLPanel > >> from your previous note. against the SDK. If you launch it via CProjectMorph open: COpenGLPanel it will display a morphic window with a red opengl panel in it (which works just the way I described). And if you still get that error then please send me a screenshot (or post a youtube video ;-) because there must be something big I'm missing from your description. Cheers, - Andreas COpenGLPanel.st (1K) Download Attachment |
Free forum by Nabble | Edit this page |