From nicole at bwh.harvard.edu Tue Jul 1 16:57:22 2014 From: nicole at bwh.harvard.edu (Nicole Aucoin) Date: Tue, 01 Jul 2014 16:57:22 -0400 Subject: [vtk-developers] an abstract class to manage groups of widgets? Message-ID: <53B320B2.8050805@bwh.harvard.edu> Hello, In 3D Slicer we're currently using a vtkSeedWidget to represent a list of points, and I'd like to extend my module[1] to work with lists of rulers, angles, bidimensional widgets etc. I want to eventually have many types of lists that contain elements with >1 points and have VTK widgets to interact with them. In the code that manages the mapping between the widgets and the stored point values, having one vtkSeedWidget per list of points is working well, but I'm finding that I have many special cases when trying to use many vtkDistanceWidgets to represent a list of pairs of points. I need a generalisation of a vtkSeedWidget that will manage a set of general widgets rather than being restricted to a set of handle widgets. I noticed that in VTK 6 there's a new class called vtkWidgetSet, but the documentation[2] states that it synchronises a set of widgets across render windows, which is not quite what I need (I have separate widgets in each render window, synchronised via the point(s) list). I was going to start working on the abstract widget group (list?) class and representation[3] that I need and at first integrate it into Slicer's fork of VTK then contribute it back into VTK. Before I start, I wanted to ask if there was any effort in this direction already, or if there's a grouping method in VTK6 that might work out of the box. thanks, Nicole [1] http://www.slicer.org/slicerWiki/index.php/Documentation/4.3/Modules/Markups [2] http://www.vtk.org/doc/nightly/html/classvtkWidgetSet.html#details [3] Working from the example of the seed representation as the base and extending to support Nth point set/get, which will probably require some superclass additions to generalise the representations. DistanceRepresentation uses [Get|Set]Point[1|2][World|Display]Position which could be updated to call a new virtual method [Get|Set]NthPoint[World|Display]Position(unsigned int n, ...). The vtkContourRepresentation has some generalisation already in [Get|Set]NthNode[World|Display]Position(int n, ...), while the vtkSeedRepresentation uses [Get|Set]Seed[World|Display]Position(unsigned int n, ...), so an effort to make it uniform could be worthwhile, but would likely be phase 2 of my project. The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine at http://www.partners.org/complianceline . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail. From jatinparekh93 at gmail.com Thu Jul 3 02:53:24 2014 From: jatinparekh93 at gmail.com (Jatin Parekh) Date: Thu, 3 Jul 2014 12:23:24 +0530 Subject: [vtk-developers] Adding External Data for Testing to a Fork Message-ID: Hi! I have written a test for a GeoJSON format reader for vtk. My test has a baseline image (lets say test.png) and another input data (lets say input.json in Testing/Data folder) for my implemented vtkGeoJSONReader. After I run cmake and make, My input data gets converted into corresponding md5 hashes and the referenced data is stored in my .ExternalData folder of the source. Now, when I git push my local copy to my own vtk fork with this test.png.md5 and input.txt.md5, How is the referenced data uploaded on git? Should I push only the original data (baseline image and input.json) or the md5 files and the actual data both? What is the ideal approach in this case where I wish to add testing data and external data to my own fork? Since the data is to be added only to my fork and not the original VTK, I don't think gerrit would be useful. Would it? Here is the GeoJSON reader & VTK fork that I am working on https://github.com/OpenGeoscience/VTK/tree/master/IO/GeoJSON If anymore information is required, I'll be glad to provide them. Thanks! Jatin Parekh -------------- next part -------------- An HTML attachment was scrubbed... URL: From brad.king at kitware.com Thu Jul 3 10:13:52 2014 From: brad.king at kitware.com (Brad King) Date: Thu, 03 Jul 2014 10:13:52 -0400 Subject: [vtk-developers] Adding External Data for Testing to a Fork In-Reply-To: References: Message-ID: <53B56520.4070709@kitware.com> On 07/03/2014 02:53 AM, Jatin Parekh wrote: > What is the ideal approach in this case where I wish to add > testing data and external data to my own fork? I've just extended the VTK developer documentation on external data with a section for this case: http://www.vtk.org/Wiki/VTK/Git/Develop/Data#Publishing_Data_for_an_External_Branch -Brad From dave.demarle at kitware.com Thu Jul 3 14:13:47 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 3 Jul 2014 14:13:47 -0400 Subject: [vtk-developers] announce: Kitware is hiring - now with more web! Message-ID: Howdy, If you are talented researcher and developer with strong C++ and/or web services development skills, please consider applying to Kitware. We are particularly interested now in developers who have significant web service development talent to help us expand the frontiers of visualization and analytics delivered over the web. At Kitware you will join a fun and talented team and work on many interesting and challenging technical problems - always aiming to deliver robust and widely used software solutions. Specifically, the scientific visualization and medical groups at Kitware is looking for these people: * Scientific Visualization Web Developer (see below) * GUI and Application Software Developer * Informatics Researcher * Informatics Software Developer * HPC Visualization and Data Analysis Software Developer * Scientific Visualization Developer * Research and Development Involving Machine Learning and Medical Image Analysis * Technical Lead in Biomedical Image Analysis and Visualization * Biomechanical Modeling and Surgical Simulation Software Developer Go to http://jobs.kitware.com/opportunities.html for more details and to apply. SCIENTIFIC VISUALIZATION WEB DEVELOPER Job Description: By joining our team you will participate in a dynamic work environment with exceptionally talented coworkers who are committed to high-quality development practices. You will collaborate with esteemed researchers from around the world to create next-generation, open-source software for web applications for data management, analysis, and visualization; design and produce full-featured, modern web interfaces for cutting-edge applications; and will deploy software applications and infrastructure that are used by people, every day, around the world, to improve the world. Work will be performed in the context of an open-source and highly collaborative development model. Qualifications: An ideal candidate should have at least four years of experience in HTML, CSS, and JavaScript, with an undergraduate or higher degree in Computer Science or a related field. Strong software development skills are a must, and familiarity with website UI/UX aesthetics and design as well as JavaScript libraries such as JQuery, Underscore, Backbone, and/or Angular is highly desirable. Candidates should be familiar with tools for good software practice such as git and web testing frameworks. Also desirable is experience with server scripting languages like Python, and server components such as Apache, Node.js, Django, and CherryPy. Strong candidates will also have experience with web visualization libraries such as D3, WebGL, and HTML5 Canvas. C++ experience is a plus. thanks and good luck! David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 -------------- next part -------------- An HTML attachment was scrubbed... URL: From sean at rogue-research.com Thu Jul 3 14:51:24 2014 From: sean at rogue-research.com (Sean McBride) Date: Thu, 3 Jul 2014 14:51:24 -0400 Subject: [vtk-developers] Gerrit and OpenID Message-ID: <20140703185124.574802027@mail.rogue-research.com> Hi all, Guess it's been a while since I used gerrit because I discovered MyOpenID (that I used for my OpenID) has closed down. In fact, seems like OpenID itself is going the way of the dodo... Anyone know an OpenID provider? Or how else can I log back into gerrit? Thanks, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From jmerkow at gmail.com Thu Jul 3 18:30:10 2014 From: jmerkow at gmail.com (jmerkow) Date: Thu, 3 Jul 2014 15:30:10 -0700 (PDT) Subject: [vtk-developers] Problems with git, and setup scripts Message-ID: <1404426610508-5727747.post@n5.nabble.com> Hello, I am working on pushing some changes to gerrit, but the Setup scripts seem to be breaking on my system... I've made the changes, and I can add them but git commit is broken. use of git commit (i.e. git commit, git commit -m 'message', git commit -a), do nothing except print the following message ": No such file or directory" I haven't been able to track down what changes the setup scripts are making to cause this to happen. -Jameson -- View this message in context: http://vtk.1045678.n5.nabble.com/Problems-with-git-and-setup-scripts-tp5727747.html Sent from the VTK - Dev mailing list archive at Nabble.com. From ben.boeckel at kitware.com Thu Jul 3 20:35:57 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 3 Jul 2014 20:35:57 -0400 Subject: [vtk-developers] Gerrit and OpenID In-Reply-To: <20140703185124.574802027@mail.rogue-research.com> References: <20140703185124.574802027@mail.rogue-research.com> Message-ID: <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> On Thu, Jul 03, 2014 at 14:51:24 -0400, Sean McBride wrote: > Guess it's been a while since I used gerrit because I discovered > MyOpenID (that I used for my OpenID) has closed down. In fact, seems > like OpenID itself is going the way of the dodo... Google has been rumored to be ending support as a provider Soon. Seems they really want to be another Apple-like silo :( (albeit one that actually acknowledges that something other than their precious silo might exist). > Anyone know an OpenID provider? Or how else can I log back into > gerrit? Many of the "social networks" provide OpenID (e.g., Google, Facebook, Yahoo!, and more; StackOverflow has an example list[1] on their signup page). The OpenID site has a list[2] as well. If you can host something, there are also multiple ways; at least Janrain[3] and Fedora's provider is FOSS[4] as well (though I've deployed neither, so I have no information on which would be easier to setup). --Ben [1]https://stackoverflow.com/users/signup [2]http://openid.net/get-an-openid/ [3]http://developers.janrain.com/how-to/identity-services/integrate-identity-services/#appendix [4]https://fedoraproject.org/wiki/OpenID From sean at rogue-research.com Fri Jul 4 18:03:54 2014 From: sean at rogue-research.com (Sean McBride) Date: Fri, 4 Jul 2014 18:03:54 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <20140704220354.1112198926@mail.rogue-research.com> Hi all, The vtkGPUInfo class: uses vtkIdType, which is sometimes 32 bit and sometimes 64, to count the number of bytes of memory. This is a problem since these days you can have more than 2^32 bytes of memory. :) It seems something like size_t should be used instead of vtkIdType. Would such a change count as API breakage, or is it minor enough? Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From dlrdave at aol.com Sat Jul 5 15:06:57 2014 From: dlrdave at aol.com (David Cole) Date: Sat, 5 Jul 2014 15:06:57 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <20140704220354.1112198926@mail.rogue-research.com> References: <20140704220354.1112198926@mail.rogue-research.com> Message-ID: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> If you need more than 2^32 bytes of memory, you likely need to build VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit wide type, too... So is a change really necessary? Or..... you *can* build a 32-bit build of VTK, but explicitly set its id type to be 64-bits anyway, even in the 32-bit build. I'm not sure I see the advantage of using size_t over vtkIdType, as they both vary in size based on CMake/compiler settings. Can you elaborate on why you think it would be better to use size_t instead of vtkIdType? David C. From david.thompson at kitware.com Sat Jul 5 21:50:08 2014 From: david.thompson at kitware.com (David Thompson) Date: Sat, 5 Jul 2014 21:50:08 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> References: <20140704220354.1112198926@mail.rogue-research.com> <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> Message-ID: <6914A3D3-C4D3-4132-BCD1-0DEA6CDC3EFA@kitware.com> > If you need more than 2^32 bytes of memory, you likely need to build VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit wide type, too... So is a change really necessary? > > Or..... you *can* build a 32-bit build of VTK, but explicitly set its id type to be 64-bits anyway, even in the 32-bit build. > > I'm not sure I see the advantage of using size_t over vtkIdType, as they both vary in size based on CMake/compiler settings. > > Can you elaborate on why you think it would be better to use size_t instead of vtkIdType? Well, to be a contrarian, I think both those options are guilty of mixing metaphors: - vtkIdType is meant to hold IDs, not pointers or pointer offsets. For people using unstructured grids as opposed to image data, a 32-bit cell ID may be fine and the name of the type does not imply that it will be used as a pointer offset, so they may not be in the right frame of mind to realize what the problem is when their GPU memory is misreported. Those people might still want to know how much memory is on the GPU if they want to render to large textures, for instance. - If the class weren't named vtkGPUInfo, size_t would be appropriate since it is meant to serve as a pointer offset. But the GPU drivers could potentially be built to expose more memory than the host system libraries are configured to address, so it is also (just barely) misusing a typedef. - Why not use vtkTypeInt64? That is what it's there for. Then there is no chance that the memory will be misreported until vtkTypeInt128 is required. I doubt anyone is going to use vtkGPUInfo in a tight loop, so the overhead is negligible. Developers who don't have to hunt down why GPU memory is being misreported on some weird system their uncle's friend uses for his collection of cat X-rays will be happy you chose vtkTypeInt64. - Another alternative is to report GPU memory in saner units, like kiB or MiB. - That's the Good and the Bad. The Ugly would be to report memory as a double, which has a 53-bit mantissa. But then someone would surely ask how to access the fractional bits. :-) David From nex.public at gmail.com Sun Jul 6 06:07:29 2014 From: nex.public at gmail.com (Public Acc) Date: Sun, 6 Jul 2014 12:07:29 +0200 Subject: [vtk-developers] Problem with SetAnaglyphColorMask Message-ID: Dear everyone, Function SetAnaglyphColorMask (vtkRenderWindow Class) seems to be not working for me. Regardless of input values for SetAnaglyphColorMask, when using GetAnaglyphColorMask to check current mask I always receive the same values - 5 and 3 respectively. I am using VTK 5.8. Regards, -------------- next part -------------- An HTML attachment was scrubbed... URL: From sean at rogue-research.com Sun Jul 6 22:26:53 2014 From: sean at rogue-research.com (Sean McBride) Date: Sun, 6 Jul 2014 22:26:53 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> References: <20140704220354.1112198926@mail.rogue-research.com> <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> Message-ID: <20140707022653.205313894@mail.rogue-research.com> On Sat, 5 Jul 2014 15:06:57 -0400, David Cole said: >If you need more than 2^32 bytes of memory, you likely need to build >VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit >wide type, too... So is a change really necessary? > >Or..... you *can* build a 32-bit build of VTK, but explicitly set its >id type to be 64-bits anyway, even in the 32-bit build. > >I'm not sure I see the advantage of using size_t over vtkIdType, as >they both vary in size based on CMake/compiler settings. > >Can you elaborate on why you think it would be better to use size_t >instead of vtkIdType? "The other David"? said much of what I was thinking. To answer more directly, I brought this up because I made this change the other day: and noticed the possibility of overflow. It's doesn't actually affect me, so I don't really care. :) Just thought to fix it while nearby. What rubs me wrong, as David said, is that vtkIdType doesn't seem at all appropriate semantically, as there are no "id"s involved, just a size count, for which size_t seems the best type (as it's what sizeof() returns). Changing the return value to mebibytes is a good idea too, but a worse API/ABI breakage than changing from one kind of integer to another, I think. Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From brad.king at kitware.com Mon Jul 7 09:11:57 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 09:11:57 -0400 Subject: [vtk-developers] Gerrit and OpenID In-Reply-To: <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> References: <20140703185124.574802027@mail.rogue-research.com> <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> Message-ID: <53BA9C9D.5040002@kitware.com> On 07/03/2014 08:35 PM, Ben Boeckel wrote: > The OpenID site has a list[2] as well. > > [2]http://openid.net/get-an-openid/ Once you get a new OpenID then I can work with our admins to associate it with your account. Contact me off-list. -Brad From brad.king at kitware.com Mon Jul 7 09:16:52 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 09:16:52 -0400 Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <1404426610508-5727747.post@n5.nabble.com> References: <1404426610508-5727747.post@n5.nabble.com> Message-ID: <53BA9DC4.4060901@kitware.com> On Thu, Jul 3, 2014 at 6:30 PM, jmerkow wrote: > I've made the changes, and I can add them but git commit is broken. use of > git commit (i.e. git commit, git commit -m 'message', git commit -a), do > nothing except print the following message ": No such file or directory" To get verbose information about the execution of the pre-commit hook, try running this from the top of the source tree: bash -x .git/hooks/pre-commit That might show the command that fails in more detail. -Brad From dlrdave at aol.com Mon Jul 7 09:34:22 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 7 Jul 2014 09:34:22 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> > "The other David"? :-) > To answer more directly, I > brought this up because I made this change the other day: > > > > and noticed the possibility of overflow. > > ... > ... just a size count, for which size_t seems the best type (as it's > what sizeof() returns). Right, but using size_t will still give you a potential overflow problem in a 32-bit pointer build... Shouldn't the type *always* be large enough to represent expected actual memory sizes encountered in the wild? And therefore, shouldn't it be something that's always at least 64-bits wide as "the other David" suggested...? Don't even get me started on what vtkIdType *is* correct for semantically... "id" to me implies something that can identify an object across a wide swath of operations. Since it's almost always just an index into some array, a vtkIdType value does not really "id" anything, *except* in a given container filled once with data and no inserts or removes allowed. Fortunately for VTK, that's the main use case when visualizing a large data set. David C. From sean at rogue-research.com Mon Jul 7 13:06:50 2014 From: sean at rogue-research.com (Sean McBride) Date: Mon, 7 Jul 2014 13:06:50 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: <20140707170650.1063395070@mail.rogue-research.com> On Mon, 7 Jul 2014 09:34:22 -0400, David Cole said: >Right, but using size_t will still give you a potential overflow >problem in a 32-bit pointer build... Shouldn't the type *always* be >large enough to represent expected actual memory sizes encountered in >the wild? And therefore, shouldn't it be something that's always at >least 64-bits wide as "the other David" suggested...? That's fine with me too. So back to the original question: is such a change minor enough to not count as breaking API/ABI? Or is it all just not worth it? :) Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From dlrdave at aol.com Mon Jul 7 13:29:52 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 7 Jul 2014 13:29:52 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <8D1682031B18678-978-D6D2@webmail-m167.sysops.aol.com> >>the wild? And therefore, shouldn't it be something that's always at >>least 64-bits wide as "the other David" suggested...? > So back to the original question: is such a change minor enough to > not count as breaking API/ABI? Or is it all just not worth it? :) Well if you change the signature of the existing method, then it's definitely a breaking change. As for whether it's "minor enough" or not, I'll leave that to the VTK legacy police. I'm sure one of them will chime in eventually. And even if it's not "minor enough"... maybe just document its limitations, mark it as a legacy method, and invent a new method with a new signature that's wide enough for the foreseeable future. HTH, David C. From jmerkow at gmail.com Mon Jul 7 15:06:33 2014 From: jmerkow at gmail.com (jmerkow) Date: Mon, 7 Jul 2014 12:06:33 -0700 (PDT) Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <53BA9DC4.4060901@kitware.com> References: <1404426610508-5727747.post@n5.nabble.com> <53BA9DC4.4060901@kitware.com> Message-ID: <1404759993399-5727782.post@n5.nabble.com> Brad, Thanks for the reply. At some point in figuring out what went wrong, I saw an error with command not found $/r, which suggested that it was a crlf problem. I ran dos2unix on all the scripts and hooks etc and re-setup wit the developer script, and it worked fine. For some reason my crlf settings were setup wrong on this machine, so git added /r to some of the line endings. Anyway, fixed now. Thanks for the help! Jameson -- View this message in context: http://vtk.1045678.n5.nabble.com/Problems-with-git-and-setup-scripts-tp5727747p5727782.html Sent from the VTK - Dev mailing list archive at Nabble.com. From brad.king at kitware.com Mon Jul 7 15:27:59 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 15:27:59 -0400 Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <1404759993399-5727782.post@n5.nabble.com> References: <1404426610508-5727747.post@n5.nabble.com> <53BA9DC4.4060901@kitware.com> <1404759993399-5727782.post@n5.nabble.com> Message-ID: <53BAF4BF.7070405@kitware.com> On 07/07/2014 03:06 PM, jmerkow wrote: > For some reason my crlf settings were setup wrong on this machine, > so git added /r to some of the line endings. I'm glad you have it working locally. I fixed the hooks branch to use LF newlines regardless of local configuration: http://vtk.org/gitweb?p=VTK.git;a=commitdiff;h=b9b95219 Thanks, -Brad From berk.geveci at kitware.com Mon Jul 7 15:53:33 2014 From: berk.geveci at kitware.com (Berk Geveci) Date: Mon, 7 Jul 2014 15:53:33 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <20140707170650.1063395070@mail.rogue-research.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> <20140707170650.1063395070@mail.rogue-research.com> Message-ID: Bugs in the API are fair game to fix even if they break compatibility. I'd say fix it. I would go with a 64 bit type like Dave T. suggested. -berk On Mon, Jul 7, 2014 at 1:06 PM, Sean McBride wrote: > On Mon, 7 Jul 2014 09:34:22 -0400, David Cole said: > > >Right, but using size_t will still give you a potential overflow > >problem in a 32-bit pointer build... Shouldn't the type *always* be > >large enough to represent expected actual memory sizes encountered in > >the wild? And therefore, shouldn't it be something that's always at > >least 64-bits wide as "the other David" suggested...? > > That's fine with me too. > > So back to the original question: is such a change minor enough to not > count as breaking API/ABI? Or is it all just not worth it? :) > > Cheers, > > -- > ____________________________________________________________ > Sean McBride, B. Eng sean at rogue-research.com > Rogue Research www.rogue-research.com > Mac Software Developer Montr?al, Qu?bec, Canada > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From berk.geveci at kitware.com Mon Jul 7 16:01:42 2014 From: berk.geveci at kitware.com (Berk Geveci) Date: Mon, 7 Jul 2014 16:01:42 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: > Don't even get me started on what vtkIdType *is* correct for > semantically... "id" to me implies something that can identify an > object across a wide swath of operations. Since it's almost always just > an index into some array, a vtkIdType value does not really "id" > anything, *except* in a given container filled once with data and no > inserts or removes allowed. Fortunately for VTK, that's the main use > case when visualizing a large data set. I disagree. vtkIdType is supposed to be the type of the id that identifies things like points and cells. The fact that the most common data structures in VTK store these in contiguous arrays is irrelevant to the validity of the term. VTK can easily support a vtkDataSet subclass that stores a map of (ids -> cell objects) for connectivity. The API abstracts away the underlying storage details (for the most part). My main issue with the current vtkIdType usage is that it is also used to define the size of the integer used in cell arrays to refer to points. So even if you have less than 2^31 point, you end up using 64 bits in the cell array to store the ids. Which doubles the storage. In my opinion, this should be run-time configurable. Furthermore, we should use size_t when defining offsets into these arrays, not vtkIdType. (See the Locations data member of vtkUnstructuredGrid for example). Best, -berk On Mon, Jul 7, 2014 at 9:34 AM, David Cole via vtk-developers < vtk-developers at vtk.org> wrote: > > "The other David"? > > :-) > > > > To answer more directly, I > > brought this up because I made this change the other day: > > > > > > > > and noticed the possibility of overflow. > > > > ... > > ... just a size count, for which size_t seems the best type (as it's > > what sizeof() returns). > > Right, but using size_t will still give you a potential overflow > problem in a 32-bit pointer build... Shouldn't the type *always* be > large enough to represent expected actual memory sizes encountered in > the wild? And therefore, shouldn't it be something that's always at > least 64-bits wide as "the other David" suggested...? > > Don't even get me started on what vtkIdType *is* correct for > semantically... "id" to me implies something that can identify an > object across a wide swath of operations. Since it's almost always just > an index into some array, a vtkIdType value does not really "id" > anything, *except* in a given container filled once with data and no > inserts or removes allowed. Fortunately for VTK, that's the main use > case when visualizing a large data set. > > > David C. > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.gobbi at gmail.com Mon Jul 7 16:29:39 2014 From: david.gobbi at gmail.com (David Gobbi) Date: Mon, 7 Jul 2014 14:29:39 -0600 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: On Mon, Jul 7, 2014 at 2:01 PM, Berk Geveci wrote: > My main issue with the current vtkIdType usage is that it is also used > to define the size of the integer used in cell arrays to refer to points. So > even if you have less than 2^31 point, you end up using 64 bits in the cell > array to store the ids. Which doubles the storage. In my opinion, this should > be run-time configurable. Furthermore, we should use size_t when defining > offsets into these arrays, not vtkIdType. (See the Locations data member > of vtkUnstructuredGrid for example). If it is made to be configurable, I would vote to switch many of the core VTK filters to templated execute methods (templated over float vs. double and 64-bit IDs vs. 32-bit IDs). This would avoid the performance hit of accessing all points and point IDs through virtual methods. - Yet another David (sorry 'bout that...) From carlinhosmp87 at gmail.com Tue Jul 8 03:15:27 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Tue, 8 Jul 2014 00:15:27 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) Message-ID: <1404803727578-5727788.post@n5.nabble.com> Hi all, I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. I have an assembly with different actors into a vtkRenderWindow. I load a shader with the class vtkShader2, and create the program with vtkShaderProgram2, all ok with this. After that, i wanted to attach the shader to the actors (i'm going to use different shaders, depending on the actors). The problem is i didn't find examples or documentation to do this and i'm not capable to use the classes for the shaders correctly. I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 with the method "SetPropProgram" and i set the property of the actors with that one, but vtk shows me a warning window with a conflict between the default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). Can someone help me? Thanks in advance!! -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html Sent from the VTK - Dev mailing list archive at Nabble.com. From simon.esneault at gmail.com Tue Jul 8 05:41:01 2014 From: simon.esneault at gmail.com (Simon ESNEAULT) Date: Tue, 8 Jul 2014 11:41:01 +0200 Subject: [vtk-developers] [vtkusers] About vtkImageReslice interpolation Message-ID: Hi All, We use vtkImageResample/vtkImageReslice (from vtk 5.8.1) quite a lot here, and I've noticed a strange behavior. If we down sample a volume by a factor of 2 in all 3 directions, the output image will be the exact same if we use a nearest neighborhood, linear or cubic interpolation. There seems to be no interpolation at all if the reduction factor is a power of two. If the reduction factor is set to 2.00001, the interpolation is performed correctly when asked for linear or cubic. Is this an intended behavior ? After some debugging : In the file vtkImageReslice.cxx, method vtkTricubicInterpCoeffs (line 1503) with a power of 2 factor we always fall back to the part with the comment // no interpolation (line 1510), but I don't understand why. And last question : there is a new vtkImageResize that was introduced in vtk 5.10, will the behavior be the same ? Thanks for your help -Simon -- ------------------------------------------------------------------ Simon Esneault 13 rue Vasselot 35000 Rennes, France Tel : 06 64 61 30 94 Mail : simon.esneault at gmail.com ------------------------------------------------------------------ -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Tue Jul 8 12:25:17 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Tue, 8 Jul 2014 12:25:17 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: <1404803727578-5727788.post@n5.nabble.com> References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. - Aashish On Tue, Jul 8, 2014 at 3:15 AM, carlinhos wrote: > Hi all, > > I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. > > I have an assembly with different actors into a vtkRenderWindow. > > I load a shader with the class vtkShader2, and create the program with > vtkShaderProgram2, all ok with this. After that, i wanted to attach the > shader to the actors (i'm going to use different shaders, depending on the > actors). The problem is i didn't find examples or documentation to do this > and i'm not capable to use the classes for the shaders correctly. > > I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 > with the method "SetPropProgram" and i set the property of the actors with > that one, but vtk shows me a warning window with a conflict between the > default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). > > Can someone help me? Thanks in advance!! > > > > -- > View this message in context: > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html > Sent from the VTK - Dev mailing list archive at Nabble.com. > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Tue Jul 8 14:14:23 2014 From: carlinhosmp87 at gmail.com (Carlos Martinez) Date: Tue, 8 Jul 2014 20:14:23 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: Thanks for your answer, i thought it wasn't the right way! What do you mean when you say i have to load the shaders manually? The steps i'm doing are: 1- Create a vtkShaderProgram2 2- Create the vtkShader2 (VertexShader) and load it from the file with SetSourceCode. 3- Add my VertexShader to the vtkShaderProgram2 with "GetShaders()->AddItem()". 4- Repeat 2 and 3 with the FragmentShader. 5- Build the vtkShaderProgram and check the Build Status (to check if everything is ok). 6- Create a vtkActor and obtain his property(with GetProperty()). 7- Put ShadingOn to the property and SetPropProgram with the vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the 2 shaders I put in). When the actors are going to display into the screen, the warning window shows up and tells me that the main is defined twice (and shows me the Default shaders and mine). Thanks again!! 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary : > vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. > > - Aashish > > > > On Tue, Jul 8, 2014 at 3:15 AM, carlinhos wrote: > >> Hi all, >> >> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >> >> I have an assembly with different actors into a vtkRenderWindow. >> >> I load a shader with the class vtkShader2, and create the program with >> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >> shader to the actors (i'm going to use different shaders, depending on the >> actors). The problem is i didn't find examples or documentation to do this >> and i'm not capable to use the classes for the shaders correctly. >> >> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >> with the method "SetPropProgram" and i set the property of the actors with >> that one, but vtk shows me a warning window with a conflict between the >> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >> >> Can someone help me? Thanks in advance!! >> >> >> >> -- >> View this message in context: >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >> Sent from the VTK - Dev mailing list archive at Nabble.com. >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> > > > -- > > > > *| Aashish Chaudhary | Technical Leader | Kitware Inc. * > *| http://www.kitware.com/company/team/chaudhary.html > * > -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Tue Jul 8 15:07:39 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Tue, 8 Jul 2014 15:07:39 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: I can reply in detail layer bu*t on this note, you may want to use the new VTK rendering code for it. Marcus or Ken hopefully reply to you on that.* - Aashish On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez wrote: > Thanks for your answer, i thought it wasn't the right way! > > What do you mean when you say i have to load the shaders manually? The > steps i'm doing are: > > 1- Create a vtkShaderProgram2 > 2- Create the vtkShader2 (VertexShader) and load it from the file with > SetSourceCode. > 3- Add my VertexShader to the vtkShaderProgram2 with > "GetShaders()->AddItem()". > 4- Repeat 2 and 3 with the FragmentShader. > 5- Build the vtkShaderProgram and check the Build Status (to check if > everything is ok). > 6- Create a vtkActor and obtain his property(with GetProperty()). > 7- Put ShadingOn to the property and SetPropProgram with the > vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the > 2 shaders I put in). > > When the actors are going to display into the screen, the warning window > shows up and tells me that the main is defined twice (and shows me the > Default shaders and mine). > > Thanks again!! > > > 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary < > aashish.chaudhary at kitware.com>: > > vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. >> >> - Aashish >> >> >> >> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos >> wrote: >> >>> Hi all, >>> >>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >>> >>> I have an assembly with different actors into a vtkRenderWindow. >>> >>> I load a shader with the class vtkShader2, and create the program with >>> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >>> shader to the actors (i'm going to use different shaders, depending on >>> the >>> actors). The problem is i didn't find examples or documentation to do >>> this >>> and i'm not capable to use the classes for the shaders correctly. >>> >>> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >>> with the method "SetPropProgram" and i set the property of the actors >>> with >>> that one, but vtk shows me a warning window with a conflict between the >>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >>> >>> Can someone help me? Thanks in advance!! >>> >>> >>> >>> -- >>> View this message in context: >>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >>> Sent from the VTK - Dev mailing list archive at Nabble.com. >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/vtk-developers >>> >>> >> >> >> -- >> >> >> >> *| Aashish Chaudhary | Technical Leader | Kitware Inc. >> * >> *| http://www.kitware.com/company/team/chaudhary.html >> * >> > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From marcus.hanwell at kitware.com Tue Jul 8 15:40:30 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Tue, 8 Jul 2014 15:40:30 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: I don't think that would be useful at this time - whilst the new rendering code is shader based we have not yet started to add functionality to add your own or modify our shader code. On Tue, Jul 8, 2014 at 3:07 PM, Aashish Chaudhary wrote: > I can reply in detail layer but on this note, you may want to use the new > VTK rendering code for it. Marcus or Ken hopefully reply to you on that. > > - Aashish > > > On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez > wrote: >> >> Thanks for your answer, i thought it wasn't the right way! >> >> What do you mean when you say i have to load the shaders manually? The >> steps i'm doing are: >> >> 1- Create a vtkShaderProgram2 >> 2- Create the vtkShader2 (VertexShader) and load it from the file with >> SetSourceCode. >> 3- Add my VertexShader to the vtkShaderProgram2 with >> "GetShaders()->AddItem()". >> 4- Repeat 2 and 3 with the FragmentShader. >> 5- Build the vtkShaderProgram and check the Build Status (to check if >> everything is ok). >> 6- Create a vtkActor and obtain his property(with GetProperty()). >> 7- Put ShadingOn to the property and SetPropProgram with the >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the 2 >> shaders I put in). >> >> When the actors are going to display into the screen, the warning window >> shows up and tells me that the main is defined twice (and shows me the >> Default shaders and mine). >> >> Thanks again!! >> >> >> 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary >> : >> >>> vtkOpenGLProperty::SetPropProgram is the right function but you have load >>> your shaders manually now. I believe the error you are getting is because it >>> is still trying to use the last shader code. >>> >>> - Aashish >>> >>> >>> >>> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos >>> wrote: >>>> >>>> Hi all, >>>> >>>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >>>> >>>> I have an assembly with different actors into a vtkRenderWindow. >>>> >>>> I load a shader with the class vtkShader2, and create the program with >>>> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >>>> shader to the actors (i'm going to use different shaders, depending on >>>> the >>>> actors). The problem is i didn't find examples or documentation to do >>>> this >>>> and i'm not capable to use the classes for the shaders correctly. >>>> >>>> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >>>> with the method "SetPropProgram" and i set the property of the actors >>>> with >>>> that one, but vtk shows me a warning window with a conflict between the >>>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >>>> >>>> Can someone help me? Thanks in advance!! >>>> >>>> >>>> >>>> -- >>>> View this message in context: >>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >>>> Sent from the VTK - Dev mailing list archive at Nabble.com. >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/vtk-developers >>>> >>> >>> >>> >>> -- >>> | Aashish Chaudhary >>> | Technical Leader >>> | Kitware Inc. >>> | http://www.kitware.com/company/team/chaudhary.html >> >> > > > > -- > | Aashish Chaudhary > | Technical Leader > | Kitware Inc. > | http://www.kitware.com/company/team/chaudhary.html > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > From carlinhosmp87 at gmail.com Wed Jul 9 04:06:18 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 9 Jul 2014 01:06:18 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: Thanks for your answer, i thought to use them to give my actors metallic visualization. Maybe i could use textures to show actors with that kind of visualization. Carlos. 2014-07-08 21:41 GMT+02:00 Marcus D. Hanwell-2 [via VTK] < ml-node+s1045678n5727800h40 at n5.nabble.com>: > I don't think that would be useful at this time - whilst the new > rendering code is shader based we have not yet started to add > functionality to add your own or modify our shader code. > > On Tue, Jul 8, 2014 at 3:07 PM, Aashish Chaudhary > <[hidden email] > > wrote: > > > I can reply in detail layer but on this note, you may want to use the > new > > VTK rendering code for it. Marcus or Ken hopefully reply to you on that. > > > > - Aashish > > > > > > On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez <[hidden email] > > > > wrote: > >> > >> Thanks for your answer, i thought it wasn't the right way! > >> > >> What do you mean when you say i have to load the shaders manually? The > >> steps i'm doing are: > >> > >> 1- Create a vtkShaderProgram2 > >> 2- Create the vtkShader2 (VertexShader) and load it from the file with > >> SetSourceCode. > >> 3- Add my VertexShader to the vtkShaderProgram2 with > >> "GetShaders()->AddItem()". > >> 4- Repeat 2 and 3 with the FragmentShader. > >> 5- Build the vtkShaderProgram and check the Build Status (to check if > >> everything is ok). > >> 6- Create a vtkActor and obtain his property(with GetProperty()). > >> 7- Put ShadingOn to the property and SetPropProgram with the > >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only > the 2 > >> shaders I put in). > >> > >> When the actors are going to display into the screen, the warning > window > >> shows up and tells me that the main is defined twice (and shows me the > >> Default shaders and mine). > >> > >> Thanks again!! > >> > >> > >> 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary > >> <[hidden email] >: > > >> > >>> vtkOpenGLProperty::SetPropProgram is the right function but you have > load > >>> your shaders manually now. I believe the error you are getting is > because it > >>> is still trying to use the last shader code. > >>> > >>> - Aashish > >>> > >>> > >>> > >>> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos <[hidden email] > > > >>> wrote: > >>>> > >>>> Hi all, > >>>> > >>>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. > >>>> > >>>> I have an assembly with different actors into a vtkRenderWindow. > >>>> > >>>> I load a shader with the class vtkShader2, and create the program > with > >>>> vtkShaderProgram2, all ok with this. After that, i wanted to attach > the > >>>> shader to the actors (i'm going to use different shaders, depending > on > >>>> the > >>>> actors). The problem is i didn't find examples or documentation to do > >>>> this > >>>> and i'm not capable to use the classes for the shaders correctly. > >>>> > >>>> I searched into the class vtkOpenGLProperty to set the > vtkShaderProgram2 > >>>> with the method "SetPropProgram" and i set the property of the actors > >>>> with > >>>> that one, but vtk shows me a warning window with a conflict between > the > >>>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). > >>>> > >>>> Can someone help me? Thanks in advance!! > >>>> > >>>> > >>>> > >>>> -- > >>>> View this message in context: > >>>> > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html > >>>> Sent from the VTK - Dev mailing list archive at Nabble.com. > >>>> _______________________________________________ > >>>> Powered by www.kitware.com > >>>> > >>>> Visit other Kitware open-source projects at > >>>> http://www.kitware.com/opensource/opensource.html > >>>> > >>>> Follow this link to subscribe/unsubscribe: > >>>> http://public.kitware.com/mailman/listinfo/vtk-developers > >>>> > >>> > >>> > >>> > >>> -- > >>> | Aashish Chaudhary > >>> | Technical Leader > >>> | Kitware Inc. > >>> | http://www.kitware.com/company/team/chaudhary.html > >> > >> > > > > > > > > -- > > | Aashish Chaudhary > > | Technical Leader > > | Kitware Inc. > > | http://www.kitware.com/company/team/chaudhary.html > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727800.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727802.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Thu Jul 10 04:00:15 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Thu, 10 Jul 2014 10:00:15 +0200 Subject: [vtk-developers] ANN: VTK/ParaView Training Course in Lyon, France, September 30th & October 1st, 2014 Message-ID: Kitware will be holding a 2-day VTK and ParaView course on September 30th and October 1st, 2014 in Lyon, France. Please visit our web site for more information and registration details at either: http://training.kitware.fr/browse/24 (in English) or http://formations.kitware.fr/browse/24 (in French) Note that the course will be taught in English. If you have any question, please contact us at formations at http://www.kitware.fr Thank you, *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * -------------- next part -------------- An HTML attachment was scrubbed... URL: From iven87 at gmx.de Thu Jul 10 16:40:09 2014 From: iven87 at gmx.de (iven87 at gmx.de) Date: Thu, 10 Jul 2014 22:40:09 +0200 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL Message-ID: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Hi vtk developers, I?m trying to implement stereo rendering via quad-buffer-stereo. Unfortunately, I can?t just use the crystal eye setting in the vtkRenderWindow, because I use headtracking and thus have special model+view and projection matrices. So i need a place to implement the following logic: -set the modelview and projection matrix for the left eye -render the scene in GL_BACK_LEFT Buffer -set the modelview and projection matrix for the right eye -render the scene in GL_BACK_RIGHT Buffer I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I should override. Should I even use existing vtk stereo functionality or would it be wiser to ?just? extend monoscopic render behavior? Any tips would be greatly appreciated. Best regards, Iven -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Thu Jul 10 16:54:20 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Thu, 10 Jul 2014 16:54:20 -0400 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL In-Reply-To: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> References: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Message-ID: Hi Iven, We already have a code for it in ParaView. Actually most of the classes are VTK classes so in theory we can move them to VTK. If this sounds interesting to you let me know and I can help you with the code. - Aashish On Thu, Jul 10, 2014 at 4:40 PM, wrote: > Hi vtk developers, > > I?m trying to implement stereo rendering via quad-buffer-stereo. > Unfortunately, I can?t just use the crystal eye setting in the > vtkRenderWindow, because I use headtracking and thus have special > model+view and projection matrices. > > So i need a place to implement the following logic: > -set the modelview and projection matrix for the left eye > -render the scene in GL_BACK_LEFT Buffer > -set the modelview and projection matrix for the right eye > -render the scene in GL_BACK_RIGHT Buffer > > I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, > vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I > should override. Should I even use existing vtk stereo functionality or > would it be wiser to ?just? extend monoscopic render behavior? > > Any tips would be greatly appreciated. > > Best regards, > Iven > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From iven87 at gmx.de Thu Jul 10 17:19:14 2014 From: iven87 at gmx.de (iven87 at gmx.de) Date: Thu, 10 Jul 2014 23:19:14 +0200 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL In-Reply-To: References: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Message-ID: Hi Aashish, that sounds good! If you can point me to relevant classes that would be great. Thanks and best regards, Iven From: Aashish Chaudhary Sent: Thursday, July 10, 2014 10:54 PM To: iven87 at gmx.de Cc: VTK Developers Subject: Re: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL Hi Iven, We already have a code for it in ParaView. Actually most of the classes are VTK classes so in theory we can move them to VTK. If this sounds interesting to you let me know and I can help you with the code. - Aashish On Thu, Jul 10, 2014 at 4:40 PM, wrote: Hi vtk developers, I?m trying to implement stereo rendering via quad-buffer-stereo. Unfortunately, I can?t just use the crystal eye setting in the vtkRenderWindow, because I use headtracking and thus have special model+view and projection matrices. So i need a place to implement the following logic: -set the modelview and projection matrix for the left eye -render the scene in GL_BACK_LEFT Buffer -set the modelview and projection matrix for the right eye -render the scene in GL_BACK_RIGHT Buffer I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I should override. Should I even use existing vtk stereo functionality or would it be wiser to ?just? extend monoscopic render behavior? Any tips would be greatly appreciated. Best regards, Iven _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/vtk-developers -- | Aashish Chaudhary | Technical Leader | Kitware Inc. | http://www.kitware.com/company/team/chaudhary.html -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Wed Jul 16 11:14:32 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 16 Jul 2014 08:14:32 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance Message-ID: <1405523672762-5727880.post@n5.nabble.com> Hello, I'm developing an app to measure the euclidean distance from a 3D point on the surface of an object to another and show the distance with a line. To accomplish that, i use *vtkLineWidget2 *with the representation associated. First time i place it , it shows correctly fit on the surface of the sphere (or any other object i place into the render window). But when i'm moving the widget from one of the handler points of the *vtkLineRepresentation *, it doesn't put the point on the surface of the sphere. The method i use sometimes work, sometimes not. I'm getting the pick every time the *vtkLineWidget2 *throws an Interaction event, and getting the 3d point of the picked position to set it to the selected handler of the *vtkLineRepresentation *. Sometimes it works, but other times, it shows the border of the *vtkLineRepresentation *in a wrong place (its correctly situated where i picked, but not on the surface of the object). It seems random to me when it works or not. I paste the code i call when the Interaction Event of the Widget is thrown. *///If the selected point is the 1st if ( state == vtkLineRepresentation::OnP1 ) { this->m_rwi->GetPicker()->Pick(m_rwi->GetLastEventPosition()[0], m_rwi->GetLastEventPosition()[1], 0, // always zero. this->m_rwi->GetRenderWindow()->GetRenderers()->GetFirstRenderer()); double picked[3]; this->m_rwi->GetPicker()->GetPickPosition(picked); lineRepresentation->SetPoint1WorldPosition(picked); } //If the selected point is the 2nd else if (state == vtkLineRepresentation::OnP2) { this->m_rwi->GetPicker()->Pick(m_rwi->GetLastEventPosition()[0], m_rwi->GetLastEventPosition()[1], 0, this->m_rwi->GetRenderWindow()->GetRenderers()->GetFirstRenderer()); double picked[3]; this->m_rwi->GetPicker()->GetPickPosition(picked); lineRepresentation->SetPoint2WorldPosition(picked); }/* Does anyone know why is not working in all the cases? Thanks in advance. -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880.html Sent from the VTK - Dev mailing list archive at Nabble.com. From dlrdave at aol.com Wed Jul 16 11:57:56 2014 From: dlrdave at aol.com (David Cole) Date: Wed, 16 Jul 2014 11:57:56 -0400 (EDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <1405523672762-5727880.post@n5.nabble.com> References: <1405523672762-5727880.post@n5.nabble.com> Message-ID: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> The documentation for "Pick" says "Return non-zero if something was successfully picked." But you are ignoring the return value of Pick. So how do you know if something was successfully picked or not? Calling GetPickPosition is only well-defined, and will only give you a good value if Pick returned non-zero..... HTH, David C From carlinhosmp87 at gmail.com Wed Jul 16 12:17:22 2014 From: carlinhosmp87 at gmail.com (Carlos Martinez) Date: Wed, 16 Jul 2014 18:17:22 +0200 Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: Hi David, Thanks for your answer but i think isn't the problem here.This is a dummy project and I'm moving the handlers only inside the area of the sphere and pick doesn't return 0 in any of the calls to the method. I checked it previously and now (just in case). I sent 3 captures: 1- First 2 clicks, the 2 white spheres are from the vtklinewidget2. 2- Wrong case (you can see the line because the points are not on the surface of the sphere). I checked it with the camera. 3- Correct case (you can't see the line between the points because they are on the surface of the sphere). I don't know what's happening here! Thanks in advance. 2014-07-16 17:57 GMT+02:00 David Cole : > The documentation for "Pick" says "Return non-zero if something was > successfully picked." > > But you are ignoring the return value of Pick. > > So how do you know if something was successfully picked or not? > > Calling GetPickPosition is only well-defined, and will only give you a > good value if Pick returned non-zero..... > > > HTH, > David C > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.png Type: image/png Size: 58636 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 2.png Type: image/png Size: 57843 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 3.png Type: image/png Size: 54628 bytes Desc: not available URL: From carlinhosmp87 at gmail.com Wed Jul 16 12:22:48 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 16 Jul 2014 09:22:48 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: <1405527768358-5727883.post@n5.nabble.com> Hi David,Thanks for your answer but i think isn't the problem here.This is a dummy project and I'm moving the handlers only inside the area of the sphere and pick doesn't return 0 in any of the calls to the method. I checked it previously and now (just in case).I sent 3 captures:1- First 2 clicks, the 2 white spheres are from the vtklinewidget2. 2- Wrong case (you can see the line because the points are not on the surface of the sphere). I checked it with the camera. 3- Correct case (you can't see the line between the points because they are on the surface of the sphere). I don't know what's happening here!Thanks in advance. -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880p5727883.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Wed Jul 16 19:54:51 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Thu, 17 Jul 2014 09:54:51 +1000 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON Message-ID: What are these options and what do they do? They have appeared in the recent master. To amplify: 1) I am wondering why KITS are being brought back and how linking will work. In the case of the usual modular VTK you can, in your CMakeLists.txt file, specify a minimal set of libraries. Will this change if KITS are used? If it does, I see more problems in supporting the two different versions of VTK i.e VTK and VTK with kits, in the CMakeLists.txt files. 2) Why is there a need to specify that vtkpython and pvtkpython be built? I would have thought that once Python is selected that these are built as a matter of course. Also I see some work is being done to support Python 3. Will there be an option to select which version of Python to use? As for the tests, I think most of the tests should run in Python 3 the only tests I can think that wont are those with a print statement and this is easily fixed for both Python 2.6+/3. Regards Andrew -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Thu Jul 17 04:13:09 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Thu, 17 Jul 2014 01:13:09 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: <1405584789439-5727886.post@n5.nabble.com> Hi all! Finally, i solved it using a vtkCellPicker explicit to get the world point where the mouse is, in case I use the picker returned by the interactor the coordinates seem wrong many times. This is the new code: *vtkSmartPointer picker = vtkSmartPointer::New(); int* clickPos = m_rwi->GetEventPosition(); if ( state == vtkLineRepresentation::OnP1 ) { if (picker->Pick(clickPos[0], clickPos[1], clickPos[2], m_renderer)) { double picked[3]; picker->GetPickPosition(picked); lineRepresentation->SetPoint1WorldPosition(picked); PrintPointsPosition(oldLineRepresentation); } }else if ( state == vtkLineRepresentation::OnP2 ) { if (picker->Pick(clickPos[0], clickPos[1], clickPos[2], m_renderer)) { double picked[3]; picker->GetPickPosition(picked); lineRepresentation->SetPoint2WorldPosition(picked); PrintPointsPosition(oldLineRepresentation); } }* Thanks to everyone!!! :) -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880p5727886.html Sent from the VTK - Dev mailing list archive at Nabble.com. From ben.boeckel at kitware.com Thu Jul 17 09:39:42 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 17 Jul 2014 09:39:42 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: Message-ID: <20140717133942.GA1787@megas.kitwarein.com> Hi, On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: > What are these options and what do they do? They have appeared in the recent > master. These are meant for ParaView, in two different use cases, explained below. > To amplify: > 1) I am wondering why KITS are being brought back and how linking will work. In > the case of the usual modular VTK you can, in your CMakeLists.txt file, specify > a minimal set of libraries. Will this change if KITS are used? If it does, I > see more problems in supporting the two different versions of VTK i.e VTK and > VTK with kits, in the CMakeLists.txt files. This is meant to help reduce the number of shared libraries built with ParaView. The problem is that on OS X 10.9 has too large of a library loader path (it used to be a dynamic buffer in the loader, but is now of a static size). This is triggered by either linking too many libraries or the paths to the libraries being too long. Due to the variables available with modular VTK, there should be no difference between the two (either linking directly to the target or using ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE libraries so that target linking works transparently. It is meant to be a purely internal thing and isn't necessary in the normal course of using VTK. > 2) Why is there a need to specify that vtkpython and pvtkpython be built? I > would have thought that once Python is selected that these are built as a > matter of course. This is because, in ParaView, we are looking to build a purely static build with Python and NumPy support. This brings in extra requirements when linking of Python which (p)vtkpython would need to link (e.g., ssl, crypto, util, and some others). The solution was to either turn off vtkpython in this case or to add a magic variable which ParaView sets for extra libraries (p)vtkpython needs to link to work properly. It was decided that for ParaView, turning off vtkpython makes the most sense since pvpython and pvbatch exist. > Also I see some work is being done to support Python 3. Will there be an option > to select which version of Python to use? I hope so (I'm just watching the branch for now). > As for the tests, I think most of the tests should run in Python 3 the only > tests I can think that wont are those with a print statement and this is easily > fixed for both Python 2.6+/3. Anything that catches exceptions will likely need updated as well (and the minimum version bumped as there isn't a nice way to catch an exception that isn't a syntax error in either 2.4 or 3.0 without just catching a type and asking sys.exc_info() for the actual object). Other than that, I think we just need to watch for integer division now being floating point in Python 3. --Ben From andrew.amaclean at gmail.com Thu Jul 17 19:16:17 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Fri, 18 Jul 2014 09:16:17 +1000 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: <20140717133942.GA1787@megas.kitwarein.com> References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: Thanks for the update Ben. I didn't realise that this was triggered by OSX10.9 Let me know what I can do in the way of reconfiguring the python tests so that they run on both Python 3.x and Python 2.6+. I'm happy to spend time doing this. I think you are going to have to ultimately bump up the Python version especially if we want to support Python 3. Currently I think it is 2.5 so going to 2.6 would be Ok or even 2.7!!! I remember trying to make Python code run on earlier versions by testing for the Python version, unfortunately the python interpreter seems to precompile all branches so this approach failed. I never found a solution. So this is another argument for bumping the version I see numpy supports 2.6/7 and 3.x (http://www.scipy.org/scipylib/faq.html). So I suspect those using ParaView/VTK/Numpy are already using Python 2.6/2.7. It might be an idea to put it out to the community to see who is actually using Python 2.5 or earlier with VTK 6.0 and if so would they see any problems upgrading to Python 2.7. We really should be supporting Python 3.x because that is where all the Python development is going on now and I suspect that Numpy and SciPy will be focussing their efforts there too. Regards Andrew On Thu, Jul 17, 2014 at 11:39 PM, Ben Boeckel wrote: > Hi, > > On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: > > What are these options and what do they do? They have appeared in the > recent > > master. > > These are meant for ParaView, in two different use cases, explained > below. > > > To amplify: > > 1) I am wondering why KITS are being brought back and how linking will > work. In > > the case of the usual modular VTK you can, in your CMakeLists.txt file, > specify > > a minimal set of libraries. Will this change if KITS are used? If it > does, I > > see more problems in supporting the two different versions of VTK i.e > VTK and > > VTK with kits, in the CMakeLists.txt files. > > This is meant to help reduce the number of shared libraries built with > ParaView. The problem is that on OS X 10.9 has too large of a library > loader path (it used to be a dynamic buffer in the loader, but is now of > a static size). This is triggered by either linking too many libraries > or the paths to the libraries being too long. Due to the variables > available with modular VTK, there should be no difference between the > two (either linking directly to the target or using > ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE > libraries so that target linking works transparently. > > It is meant to be a purely internal thing and isn't necessary in the > normal course of using VTK. > > > 2) Why is there a need to specify that vtkpython and pvtkpython be > built? I > > would have thought that once Python is selected that these are built as a > > matter of course. > > This is because, in ParaView, we are looking to build a purely static > build with Python and NumPy support. This brings in extra requirements > when linking of Python which (p)vtkpython would need to link (e.g., ssl, > crypto, util, and some others). The solution was to either turn off > vtkpython in this case or to add a magic variable which ParaView sets > for extra libraries (p)vtkpython needs to link to work properly. It was > decided that for ParaView, turning off vtkpython makes the most sense > since pvpython and pvbatch exist. > > > Also I see some work is being done to support Python 3. Will there be an > option > > to select which version of Python to use? > > I hope so (I'm just watching the branch for now). > > > As for the tests, I think most of the tests should run in Python 3 the > only > > tests I can think that wont are those with a print statement and this is > easily > > fixed for both Python 2.6+/3. > > Anything that catches exceptions will likely need updated as well (and > the minimum version bumped as there isn't a nice way to catch an > exception that isn't a syntax error in either 2.4 or 3.0 without just > catching a type and asking sys.exc_info() for the actual object). Other > than that, I think we just need to watch for integer division now being > floating point in Python 3. > > --Ben > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From ben.boeckel at kitware.com Thu Jul 17 21:40:42 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 17 Jul 2014 21:40:42 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: <20140718014042.GA4897@bronto-burt.dev.benboeckel.net> On Fri, Jul 18, 2014 at 09:16:17 +1000, Andrew Maclean wrote: > Let me know what I can do in the way of reconfiguring the python tests so > that they run on both Python 3.x and Python 2.6+. I'm happy to spend time > doing this. A dashboard machine would be nice :) . Preferably continuous and/or gerrit, but nightly would be a start. > I think you are going to have to ultimately bump up the Python version > especially if we want to support Python 3. Currently I think it is 2.5 so > going to 2.6 would be Ok or even 2.7!!! It is *possible* to support 2.4 through 3.3 with the same code, but here's a (almost certainly incomplete) list of things which you have to do in non-Pythonic ways: - Exception catching must be done as: catch MyException: # 'as' isn't allowed in 2.4; ',' isn't in 3.0 exc = sys.exc_info()[1] # 0 is the type, 2 the backtrace - print can't be used if you use any keyword arguments or redirections: print('%d' % bar) # use parens and format strings ostr.write('%d\n' % bar) # use the write method for redirection sys.stdout.write('4') # write to stdout directly to not get a newline - Metaclasses can't be done (the only way in 2 and 3 is a syntax error in the other). Not used much (at all?) in VTK. - No 'with' statement (2.5 has it though). > I remember trying to make Python code run on earlier versions by testing > for the Python version, unfortunately the python interpreter seems to > precompile all branches so this approach failed. I never found a solution. > So this is another argument for bumping the version Yep, a lot of issues arise from the fact that some changes are syntax errors in the other version. PyPy has a plan to support Python2 and Python3 running at the same time, but it might be a moot question by the time that ever happens. > It might be an idea to put it out to the community to see who is actually > using Python 2.5 or earlier with VTK 6.0 and if so would they see any > problems upgrading to Python 2.7. RHEL5 ships with 2.4 and is probably still floating around in some places. 2.6 is available, but not from Red Hat (it's in EPEL). Other than that, 2.6 is probably a safe bet. 2.7 is becoming more common as well. > We really should be supporting Python 3.x because that is where all the > Python development is going on now and I suspect that Numpy and SciPy will > be focussing their efforts there too. I've had performance issues in Python3 (as in significantly worse than Python2) in other, non-VTK projects (mainly regex-related), but I don't know how many of VTK's use cases are affected. It's something to keep an eye out for though. --Ben From dave.demarle at kitware.com Thu Jul 17 21:40:58 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 17 Jul 2014 21:40:58 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: FYI http://markmail.org/thread/6fybkjbz5xpr3qt7 Is the email thread from the last time we talked about the VTK's minimum python version. David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 On Thu, Jul 17, 2014 at 7:16 PM, Andrew Maclean wrote: > Thanks for the update Ben. > > I didn't realise that this was triggered by OSX10.9 > > Let me know what I can do in the way of reconfiguring the python tests so > that they run on both Python 3.x and Python 2.6+. I'm happy to spend time > doing this. > > I think you are going to have to ultimately bump up the Python version > especially if we want to support Python 3. Currently I think it is 2.5 so > going to 2.6 would be Ok or even 2.7!!! > > I remember trying to make Python code run on earlier versions by testing > for the Python version, unfortunately the python interpreter seems to > precompile all branches so this approach failed. I never found a solution. > So this is another argument for bumping the version > > I see numpy supports 2.6/7 and 3.x (http://www.scipy.org/scipylib/faq.html). > So I suspect those using ParaView/VTK/Numpy are already using Python > 2.6/2.7. > > It might be an idea to put it out to the community to see who is actually > using Python 2.5 or earlier with VTK 6.0 and if so would they see any > problems upgrading to Python 2.7. > > We really should be supporting Python 3.x because that is where all the > Python development is going on now and I suspect that Numpy and SciPy will > be focussing their efforts there too. > > Regards > Andrew > > > On Thu, Jul 17, 2014 at 11:39 PM, Ben Boeckel > wrote: > >> Hi, >> >> On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: >> > What are these options and what do they do? They have appeared in the >> recent >> > master. >> >> These are meant for ParaView, in two different use cases, explained >> below. >> >> > To amplify: >> > 1) I am wondering why KITS are being brought back and how linking will >> work. In >> > the case of the usual modular VTK you can, in your CMakeLists.txt file, >> specify >> > a minimal set of libraries. Will this change if KITS are used? If it >> does, I >> > see more problems in supporting the two different versions of VTK i.e >> VTK and >> > VTK with kits, in the CMakeLists.txt files. >> >> This is meant to help reduce the number of shared libraries built with >> ParaView. The problem is that on OS X 10.9 has too large of a library >> loader path (it used to be a dynamic buffer in the loader, but is now of >> a static size). This is triggered by either linking too many libraries >> or the paths to the libraries being too long. Due to the variables >> available with modular VTK, there should be no difference between the >> two (either linking directly to the target or using >> ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE >> libraries so that target linking works transparently. >> >> It is meant to be a purely internal thing and isn't necessary in the >> normal course of using VTK. >> >> > 2) Why is there a need to specify that vtkpython and pvtkpython be >> built? I >> > would have thought that once Python is selected that these are built as >> a >> > matter of course. >> >> This is because, in ParaView, we are looking to build a purely static >> build with Python and NumPy support. This brings in extra requirements >> when linking of Python which (p)vtkpython would need to link (e.g., ssl, >> crypto, util, and some others). The solution was to either turn off >> vtkpython in this case or to add a magic variable which ParaView sets >> for extra libraries (p)vtkpython needs to link to work properly. It was >> decided that for ParaView, turning off vtkpython makes the most sense >> since pvpython and pvbatch exist. >> >> > Also I see some work is being done to support Python 3. Will there be >> an option >> > to select which version of Python to use? >> >> I hope so (I'm just watching the branch for now). >> >> > As for the tests, I think most of the tests should run in Python 3 the >> only >> > tests I can think that wont are those with a print statement and this >> is easily >> > fixed for both Python 2.6+/3. >> >> Anything that catches exceptions will likely need updated as well (and >> the minimum version bumped as there isn't a nice way to catch an >> exception that isn't a syntax error in either 2.4 or 3.0 without just >> catching a type and asking sys.exc_info() for the actual object). Other >> than that, I think we just need to watch for integer division now being >> floating point in Python 3. >> >> --Ben >> > > > > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Fri Jul 18 05:03:05 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Fri, 18 Jul 2014 02:03:05 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: <1405669583385-5727903.post@n5.nabble.com> References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Hello Xiaoming, I created a new vtkOpenGLProperty and set it to the actor, anyways i tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), because vtkProperty is an abstract class. I tried so many things to make it work but i didn't manage to do it. Also i tried to use vtkOpenGLActors instead of vtkActors but it also didn't work. Carlos. 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] < ml-node+s1045678n5727903h33 at n5.nabble.com>: > i'm sorry but i see that vtkActor::GetProperty() returns a pointer to the > vtkProperty not vtkOpenGLProperty,which has a member of SetPropProgram,i 'm > just confused with the 7th step,would you bother to tell me sth about that > ,thanks in advance. > Quote: > < 7- Put ShadingOn to the property and SetPropProgram with the > vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the > 2 shaders I put in).> > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727905.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From akshaya.r15 at gmail.com Sat Jul 19 06:11:04 2014 From: akshaya.r15 at gmail.com (Akshaya Ramaswamy) Date: Sat, 19 Jul 2014 15:41:04 +0530 Subject: [vtk-developers] Plotting a graph to scale Message-ID: Hi all, I have a 2d graph where the x and y coordinates are in millimeters. Is it possible to plot this graph to scale using vtk? Thanks and regards, Akshaya -------------- next part -------------- An HTML attachment was scrubbed... URL: From akshaya.r15 at gmail.com Sat Jul 19 06:11:56 2014 From: akshaya.r15 at gmail.com (Akshaya Ramaswamy) Date: Sat, 19 Jul 2014 15:41:56 +0530 Subject: [vtk-developers] Rendering a 3d plot at a certain view Message-ID: Hi all, I am facing problem in adjusting the view of a 3d plot. I am able to render a 3d plot using VTK, but i am not able to set the correct view for the plot. Basically, I need to adjust the azimuth and elevation angles, but somehow adjusting these parameters of vtkcamera class does not give the desired results. I am unable to understand how the view changes based on the angle change. Could somebody explain how this works? Thanks and regards, Akshaya -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Sun Jul 20 03:21:03 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Sun, 20 Jul 2014 17:21:03 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. Message-ID: I wanted to generate a lookup table from vtkCOlor series using BuildLookupTable(). However the only way I can do it is to create a second lookup table and copy from the first to the second one. I thought I could do this: colorSeries = vtk.vtkColorSeries() colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 colorSeries.SetColorScheme(colorSeriesEnum) lut = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut) But I have to do this: colorSeries = vtk.vtkColorSeries() colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 colorSeries.SetColorScheme(colorSeriesEnum) lut1 = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut1) lut = vtk.vtkLookupTable() lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) for i in range(0,lut1.GetNumberOfTableValues()): lut.SetTableValue(i,lut1.GetTableValue(i)) In looking at the code in vtkColorSeries.cxx, namely: //----------------------------------------------------------------------------- void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) { if (lkup) { lkup->SetNumberOfTableValues(this->GetNumberOfColors()); lkup->IndexedLookupOn(); for (int i = 0; i < this->GetNumberOfColors(); ++i) { vtkColor3ub colr = this->GetColor(i); lkup->SetTableValue( i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., 1.); } } } It seems lkup is built correctly. I can't see any reason for building and then copying to a new table. I would appreciate it if anyone could point out what I am missing. I have also attached a Python script that illustrates this. Regards Andrew -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: ColorSeries.zip Type: application/zip Size: 1344 bytes Desc: not available URL: From andrew.amaclean at gmail.com Sun Jul 20 20:23:52 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Mon, 21 Jul 2014 10:23:52 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: Just to add to this, I get the same result in C++. On Sun, Jul 20, 2014 at 5:21 PM, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using > BuildLookupTable(). > However the only way I can do it is to create a second lookup table and > copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., > 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Mon Jul 21 01:08:49 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Mon, 21 Jul 2014 15:08:49 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: I have found the problem. It lies in line 576 of vtkColorSeries.cxx: lkup->IndexedLookupOn(); in vtkColorSeries.cxx. This means that any lookup table has this set when returned from BuildLookupTable() or CreateLookupTable() The default value is off so this behaviour is unexpected. I am wondering whether this line should be removed and the tests should explicitly set this when needed. If this is too much then an alternative would be to add a comment. Any comments? I'll do any changes and test them. On Sun, Jul 20, 2014 at 5:21 PM, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using > BuildLookupTable(). > However the only way I can do it is to create a second lookup table and > copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., > 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.thompson at kitware.com Mon Jul 21 08:03:47 2014 From: david.thompson at kitware.com (David Thompson) Date: Mon, 21 Jul 2014 06:03:47 -0600 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: <56B57A36-07FA-4BC0-910E-D678BC0C583E@kitware.com> Hi Andrew, Have you tried IndexedLookupOff, i.e. lut = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut) lut.IndexedLookupOff() on the first lookup table? David On Jul 20, 2014, at 1:21, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using BuildLookupTable(). > However the only way I can do it is to create a second lookup table and copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > From dlrdave at aol.com Thu Jul 24 12:59:45 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 12:59:45 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test Message-ID: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> This code from the VTK Wiki examples ( http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails everywhere: http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 with: "Required arguments: Filename" What should the strategy be for an example that requires a filename, but does not have a default value built into its code...? Add a default file somehow? Avoid running it as a test on the dashboard? Something else? Thanks, David C. From bill.lorensen at gmail.com Thu Jul 24 13:25:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Thu, 24 Jul 2014 13:25:03 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: This is a strange example. I cannot find a VRML file that works with this example. I'll see if it can be repaired... On Thu, Jul 24, 2014 at 12:59 PM, David Cole via vtk-developers wrote: > This code from the VTK Wiki examples ( > http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails > everywhere: > http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 > > with: > "Required arguments: Filename" > > What should the strategy be for an example that requires a filename, but > does not have a default value built into its code...? > > Add a default file somehow? > Avoid running it as a test on the dashboard? > Something else? > > Thanks, > David C. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From christopher.mullins at kitware.com Thu Jul 24 13:28:12 2014 From: christopher.mullins at kitware.com (Christopher Mullins) Date: Thu, 24 Jul 2014 13:28:12 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: I spent some time cleaning these up and couldn't find a file for it either. bridge.wrl gives me a segfault. I'll try to find some time to put my fixes in the wiki soon, there are a number of examples that could use links to example files if I recall. On Thu, Jul 24, 2014 at 1:25 PM, Bill Lorensen wrote: > This is a strange example. I cannot find a VRML file that works with > this example. I'll see if it can be repaired... > > On Thu, Jul 24, 2014 at 12:59 PM, David Cole via vtk-developers > wrote: > > This code from the VTK Wiki examples ( > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails > > everywhere: > > > http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 > > > > with: > > "Required arguments: Filename" > > > > What should the strategy be for an example that requires a filename, but > > does not have a default value built into its code...? > > > > Add a default file somehow? > > Avoid running it as a test on the dashboard? > > Something else? > > > > Thanks, > > David C. > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -- Christopher Mullins R&D Engineer Kitware Inc., 919.869.8871 -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlrdave at aol.com Thu Jul 24 13:50:41 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 13:50:41 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: <8D1757EEB759265-948-264D0@webmail-vm059.sysops.aol.com> Cool -- thanks guys. FYI -- this one fails everywhere too: http://open.cdash.org/testSummary.php?project=32&name=Visualization-CorrectlyRenderTranslucentGeometry&date=2014-07-24 From ben.boeckel at kitware.com Thu Jul 24 15:10:16 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 24 Jul 2014 15:10:16 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: <20140724191016.GA14211@megas.kitwarein.com> On Thu, Jul 24, 2014 at 12:59:45 -0400, David Cole via vtk-developers wrote: > What should the strategy be for an example that requires a filename, > but does not have a default value built into its code...? If you're using vtk_add_test_*, setting ${name}_ARGS before calling it should be sufficient. --Ben From dlrdave at aol.com Thu Jul 24 16:25:24 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 16:25:24 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <20140724191016.GA14211@megas.kitwarein.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> Message-ID: <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> >> What should the strategy be for an example that requires a filename, >> but does not have a default value built into its code...? > If you're using vtk_add_test_*, setting ${name}_ARGS before calling it > should be sufficient. The wiki examples have their own dashboard, that run from this git repo: https://gitorious.org/vtkwikiexamples They build against VTK using find_package for VTK, so as far as I know, they can't call vtk_add_test_* -- they should build against a build tree or an install tree of VTK, and they work with VTK 5 and VTK 6. The (still separate) dashboard for them is here: http://open.cdash.org/index.php?project=VTKWikiExamples D From bill.lorensen at gmail.com Thu Jul 24 16:52:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Thu, 24 Jul 2014 16:52:03 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: The examples have their own way of specifying test args in the cmake lists that exist in a full checkout of the examples. Each example directory has a cmake lists file that controls the testing. This is somewhat explained here: http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers wrote: >>> What should the strategy be for an example that requires a filename, >>> but does not have a default value built into its code...? > > >> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it >> should be sufficient. > > > The wiki examples have their own dashboard, that run from this git repo: > https://gitorious.org/vtkwikiexamples > > They build against VTK using find_package for VTK, so as far as I know, they > can't call vtk_add_test_* -- they should build against a build tree or an > install tree of VTK, and they work with VTK 5 and VTK 6. > > The (still separate) dashboard for them is here: > http://open.cdash.org/index.php?project=VTKWikiExamples > > > D > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Jul 25 09:16:16 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 09:16:16 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: I have a working vrml file. I'll update the example and file later today. On Thu, Jul 24, 2014 at 4:52 PM, Bill Lorensen wrote: > The examples have their own way of specifying test args in the cmake > lists that exist in a full checkout of the examples. > Each example directory has a cmake lists file that controls the testing. > > This is somewhat explained here: > http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators > > > On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers > wrote: >>>> What should the strategy be for an example that requires a filename, >>>> but does not have a default value built into its code...? >> >> >>> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it >>> should be sufficient. >> >> >> The wiki examples have their own dashboard, that run from this git repo: >> https://gitorious.org/vtkwikiexamples >> >> They build against VTK using find_package for VTK, so as far as I know, they >> can't call vtk_add_test_* -- they should build against a build tree or an >> install tree of VTK, and they work with VTK 5 and VTK 6. >> >> The (still separate) dashboard for them is here: >> http://open.cdash.org/index.php?project=VTKWikiExamples >> >> >> D >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> > > > > -- > Unpaid intern in BillsBasement at noware dot com -- Unpaid intern in BillsBasement at noware dot com From christopher.mullins at kitware.com Fri Jul 25 09:18:34 2014 From: christopher.mullins at kitware.com (Christopher Mullins) Date: Fri, 25 Jul 2014 09:18:34 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: Thanks Bill! On Jul 25, 2014 9:16 AM, "Bill Lorensen" wrote: > I have a working vrml file. I'll update the example and file later today. > > > On Thu, Jul 24, 2014 at 4:52 PM, Bill Lorensen > wrote: > > The examples have their own way of specifying test args in the cmake > > lists that exist in a full checkout of the examples. > > Each example directory has a cmake lists file that controls the testing. > > > > This is somewhat explained here: > > http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators > > > > > > On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers > > wrote: > >>>> What should the strategy be for an example that requires a filename, > >>>> but does not have a default value built into its code...? > >> > >> > >>> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it > >>> should be sufficient. > >> > >> > >> The wiki examples have their own dashboard, that run from this git repo: > >> https://gitorious.org/vtkwikiexamples > >> > >> They build against VTK using find_package for VTK, so as far as I know, > they > >> can't call vtk_add_test_* -- they should build against a build tree or > an > >> install tree of VTK, and they work with VTK 5 and VTK 6. > >> > >> The (still separate) dashboard for them is here: > >> http://open.cdash.org/index.php?project=VTKWikiExamples > >> > >> > >> D > >> > >> _______________________________________________ > >> Powered by www.kitware.com > >> > >> Visit other Kitware open-source projects at > >> http://www.kitware.com/opensource/opensource.html > >> > >> Follow this link to subscribe/unsubscribe: > >> http://public.kitware.com/mailman/listinfo/vtk-developers > >> > > > > > > > > -- > > Unpaid intern in BillsBasement at noware dot com > > > > -- > Unpaid intern in BillsBasement at noware dot com > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlrdave at aol.com Fri Jul 25 15:36:06 2014 From: dlrdave at aol.com (David Cole) Date: Fri, 25 Jul 2014 15:36:06 -0400 (EDT) Subject: [vtk-developers] vtkDelimitedTextWriter needs some testing love Message-ID: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> I "fixed" the Windows dashboard crash for this wiki example (I think... -- we'll find out for sure tomorrow): http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/DelimitedTextWriter In doing so, I've noticed there are literally no tests for vtkDelimitedTextWriter in the VTK source tree. Does anybody have some bandwidth to submit a Gerrit patch that adds a test for vtkDelimitedTextWriter? Thanks, David C. From dlrdave at aol.com Fri Jul 25 15:48:40 2014 From: dlrdave at aol.com (David Cole) Date: Fri, 25 Jul 2014 15:48:40 -0400 (EDT) Subject: [vtk-developers] VTK wiki example FullScreen Message-ID: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Hey Bill L., This one: http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen produces output like this on my machine (which has a different full screen size than yours...): Image differencing failed to produce an image because images are different size: Valid image: 1279, 1023, 0 Test image: 1431, 828, 0 Seems like this one should not be a test that "fails" due to different image size. How should we fix it? Thanks, D From bill.lorensen at gmail.com Fri Jul 25 15:52:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 15:52:03 -0400 Subject: [vtk-developers] vtkDelimitedTextWriter needs some testing love In-Reply-To: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> References: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> Message-ID: David (elbow man), You are correct. Only smoke test coverage: http://lorensen.github.io/VTKCodeCoverage/VTK/IO/Core/vtkDelimitedTextWriter.cxx.gcov.html Bill On Fri, Jul 25, 2014 at 3:36 PM, David Cole via vtk-developers wrote: > I "fixed" the Windows dashboard crash for this wiki example (I think... -- > we'll find out for sure tomorrow): > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/DelimitedTextWriter > > In doing so, I've noticed there are literally no tests for > vtkDelimitedTextWriter in the VTK source tree. > > Does anybody have some bandwidth to submit a Gerrit patch that adds a test > for vtkDelimitedTextWriter? > > > Thanks, > David C. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Jul 25 15:53:08 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 15:53:08 -0400 Subject: [vtk-developers] VTK wiki example FullScreen In-Reply-To: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> References: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Message-ID: Agree. Need to ponder. On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > Hey Bill L., > > This one: > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > produces output like this on my machine (which has a different full screen > size than yours...): > > Image differencing failed to produce an image because images are different > size: > Valid image: 1279, 1023, 0 > Test image: 1431, 828, 0 > > Seems like this one should not be a test that "fails" due to different image > size. > > How should we fix it? > > > Thanks, > D > -- Unpaid intern in BillsBasement at noware dot com From dlrdave at aol.com Mon Jul 28 08:26:23 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 28 Jul 2014 08:26:23 -0400 (EDT) Subject: [vtk-developers] VTK Wiki example using vtkFrustumSource Message-ID: <8D1787646D90445-B88-B81@webmail-m270.sysops.aol.com> This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/Frustum uses vtkFrustumSource to visualize the view frustum from a vtkCamera object. The example's test was failing on my Windows Debug dashboard because the vtkFrustumSource defaults to "ShowLines" ON, and when ShowLines is on, there are extra points added to the polydata output.... but the coordinate values of those points are never set, and so the geometric data is undefined, resulting in ridiculous bounds values in the Debug build. (Thanks to the Microsoft compiler's forced-crazy-value-initialization of uninitialized stuff...) The code in question is here: http://vtk.org/gitweb?p=VTK.git;a=blob;f=Filters/Sources/vtkFrustumSource.cxx;h=7803ece7810d3cce76efd5f2d83e8099f1973a87;hb=refs/heads/master#l146 (5 extra points are added, but point ID values 8, 9, 10, 11, and 12 are never set, even though they *are* referenced later on...) So: does anybody here know what the extra points are supposed to be set to? If so, could you submit a gerrit patch? If not, could we remove the extra points from the output since they're not well defined...? I "fixed" the example for now by setting ShowLines to OFF. Thanks, David C. From joachim.pouderoux at kitware.com Tue Jul 29 08:55:46 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 29 Jul 2014 14:55:46 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I might have fixed. I will make a patch soon. In the meanwhile try to change those lines: needDefaultMainVS = !progHasVertex && propProg->HasVertexShaders(); needDefaultMainFS = !progHasFragment && propProg->HasFragmentShaders(); by needDefaultMainVS = !progHasVertex && !propProg->HasVertexShaders(); needDefaultMainFS = !progHasFragment && !propProg->HasFragmentShaders(); With that fixed, the steps you defined should now work as no second main() will be added to both shader code. Joachim *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2014-07-18 11:03 GMT+02:00 carlinhos : > Hello Xiaoming, > > I created a new vtkOpenGLProperty and set it to the actor, anyways i tried > to cast the vtkProperty obtained by the a vtkActor::GetProperty(), > because vtkProperty is an abstract class. I tried so many things to make it > work but i didn't manage to do it. Also i tried to use vtkOpenGLActors > instead of vtkActors but it also didn't work. > > Carlos. > > > 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] > >: > >> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to the >> vtkProperty not vtkOpenGLProperty,which has a member of SetPropProgram,i 'm >> just confused with the 7th step,would you bother to tell me sth about that >> ,thanks in advance. >> Quote: >> < 7- Put ShadingOn to the property and SetPropProgram with the >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >> the >> 2 shaders I put in).> >> >> >> >> ------------------------------ >> If you reply to this email, your message will be added to the >> discussion below: >> >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >> here. >> NAML >> >> > > > ------------------------------ > View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 and > Qt 5.2.1) > > Sent from the VTK - Dev mailing list archive > at Nabble.com. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Tue Jul 29 09:13:39 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 29 Jul 2014 15:13:39 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Carlos Ok actually I was wrong. My patch works but it is not how this is supposed to happen. Basically, VTK will merge 2 different shader source code to define each type of shader (vertex, fragment etc.). A first source will come from the shader code that can be attached to the renderer shaders. If it not exist, the default is a main function that will call propFuncVS()/propFuncFS() etc - depending the shader type. The second source will come from the shader code that can be attached to the actor's property. If it not exist, the default behaviour is to define that propFuncVS/FS functions. Both source codes will be appended before being compiled by the openGlProperty. So basically if you do not define a renderer shader program, you simply have to provide a shader codes to your property that defines propFuncVS/FS functions instead of usual main() functions. Also do not build your shader program (program->Build()) in your code as it will fail because the main() functions are not provided. Remember they will be added later automatically before compilation by OpenGLProperty. Hope it is clear and it helps! Best, *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux : > Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I > might have fixed. I will make a patch soon. > In the meanwhile try to change those lines: > > > needDefaultMainVS = !progHasVertex > && propProg->HasVertexShaders(); > needDefaultMainFS = !progHasFragment > && propProg->HasFragmentShaders(); > > by > > needDefaultMainVS = !progHasVertex > && !propProg->HasVertexShaders(); > needDefaultMainFS = !progHasFragment > && !propProg->HasFragmentShaders(); > > With that fixed, the steps you defined should now work as no second main() > will be added to both shader code. > > Joachim > > *Joachim Pouderoux* > > *PhD, Technical Expert* > *Kitware SAS * > > > > 2014-07-18 11:03 GMT+02:00 carlinhos : > >> Hello Xiaoming, >> >> I created a new vtkOpenGLProperty and set it to the actor, anyways i >> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >> because vtkProperty is an abstract class. I tried so many things to make it >> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >> instead of vtkActors but it also didn't work. >> >> Carlos. >> >> >> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >> >: >> >>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>> the vtkProperty not vtkOpenGLProperty,which has a member of >>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>> tell me sth about that ,thanks in advance. >>> Quote: >>> < 7- Put ShadingOn to the property and SetPropProgram with the >>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>> the >>> 2 shaders I put in).> >>> >>> >>> >>> ------------------------------ >>> If you reply to this email, your message will be added to the >>> discussion below: >>> >>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>> here. >>> NAML >>> >>> >> >> >> ------------------------------ >> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 and >> Qt 5.2.1) >> >> Sent from the VTK - Dev mailing list archive >> at Nabble.com. >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Tue Jul 29 15:48:54 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Tue, 29 Jul 2014 12:48:54 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Joachim, Thank you so much for the explanation, I tried something similar but building the shaders instead of not doing it (if I remember well). Tomorrow i will try it and I will tell you the results!! Carlos. 2014-07-29 15:14 GMT+02:00 Joachim Pouderoux [via VTK] < ml-node+s1045678n5728004h64 at n5.nabble.com>: > Carlos > > Ok actually I was wrong. My patch works but it is not how this is supposed > to happen. > Basically, VTK will merge 2 different shader source code to define each > type of shader (vertex, fragment etc.). > A first source will come from the shader code that can be attached to the > renderer shaders. > If it not exist, the default is a main function that will call > propFuncVS()/propFuncFS() etc - depending the shader type. > The second source will come from the shader code that can be attached to > the actor's property. > If it not exist, the default behaviour is to define that propFuncVS/FS > functions. > Both source codes will be appended before being compiled by the > openGlProperty. > > So basically if you do not define a renderer shader program, you simply > have to provide a shader codes to your property that defines propFuncVS/FS > functions instead of usual main() functions. > Also do not build your shader program (program->Build()) in your code as > it will fail because the main() functions are not provided. Remember they > will be added later automatically before compilation by OpenGLProperty. > > Hope it is clear and it helps! > > Best, > > > > *Joachim Pouderoux* > > *PhD, Technical Expert* > *Kitware SAS * > > > > 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux <[hidden email] > >: > >> Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I >> might have fixed. I will make a patch soon. >> In the meanwhile try to change those lines: >> >> >> needDefaultMainVS = !progHasVertex >> && propProg->HasVertexShaders(); >> needDefaultMainFS = !progHasFragment >> && propProg->HasFragmentShaders(); >> >> by >> >> needDefaultMainVS = !progHasVertex >> && !propProg->HasVertexShaders(); >> needDefaultMainFS = !progHasFragment >> && !propProg->HasFragmentShaders(); >> >> With that fixed, the steps you defined should now work as no second >> main() will be added to both shader code. >> >> Joachim >> >> *Joachim Pouderoux* >> >> *PhD, Technical Expert* >> *Kitware SAS * >> >> >> >> 2014-07-18 11:03 GMT+02:00 carlinhos <[hidden email] >> >: >> >> Hello Xiaoming, >>> >>> I created a new vtkOpenGLProperty and set it to the actor, anyways i >>> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >>> because vtkProperty is an abstract class. I tried so many things to make it >>> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >>> instead of vtkActors but it also didn't work. >>> >>> Carlos. >>> >>> >>> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >>> >: >>> >>>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>>> the vtkProperty not vtkOpenGLProperty,which has a member of >>>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>>> tell me sth about that ,thanks in advance. >>>> Quote: >>>> < 7- Put ShadingOn to the property and SetPropProgram with the >>>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>>> the >>>> 2 shaders I put in).> >>>> >>>> >>>> >>>> ------------------------------ >>>> If you reply to this email, your message will be added to the >>>> discussion below: >>>> >>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>>> here. >>>> NAML >>>> >>>> >>> >>> >>> ------------------------------ >>> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 >>> and Qt 5.2.1) >>> >>> Sent from the VTK - Dev mailing list archive >>> at Nabble.com. >>> >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/vtk-developers >>> >>> >>> >> > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728004.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728009.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Tue Jul 29 18:49:55 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Wed, 30 Jul 2014 08:49:55 +1000 Subject: [vtk-developers] vtk-developers Digest, Vol 123, Issue 11 In-Reply-To: References: Message-ID: Bill. David, I have has the same issue, the test image should be 800X800 however Bill's machine generates a 800?771 image so the test always fails. Bill and I had some discussion on it but as to why it happens we don't know. See: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/ParametricObjectsDemo Regards Andrew > > ---------- Forwarded message ---------- > From: Bill Lorensen > To: David Cole > Cc: VTK Developers > Date: Fri, 25 Jul 2014 15:53:08 -0400 > Subject: Re: [vtk-developers] VTK wiki example FullScreen > Agree. Need to ponder. > > > On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > > Hey Bill L., > > > > This one: > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > > > produces output like this on my machine (which has a different full > screen > > size than yours...): > > > > Image differencing failed to produce an image because images are > different > > size: > > Valid image: 1279, 1023, 0 > > Test image: 1431, 828, 0 > > > > Seems like this one should not be a test that "fails" due to different > image > > size. > > > > How should we fix it? > > > > > > Thanks, > > D > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > > > >> -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Tue Jul 29 19:39:26 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Wed, 30 Jul 2014 09:39:26 +1000 Subject: [vtk-developers] VTK wiki example FullScreen Message-ID: Bill. David, I have has the same issue, for ParametricObjectsDemo, the test image should be 800X800 however Bill's machine generates an 800?771 image so the test always fails. Bill and I had some discussion on it but as to why it happens we don't know. See: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/ParametricObjectsDemo Regards Andrew > > ---------- Forwarded message ---------- > From: Bill Lorensen > To: David Cole > Cc: VTK Developers > Date: Fri, 25 Jul 2014 15:53:08 -0400 > Subject: Re: [vtk-developers] VTK wiki example FullScreen > Agree. Need to ponder. > > > On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > > Hey Bill L., > > > > This one: > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > > > produces output like this on my machine (which has a different full > screen > > size than yours...): > > > > Image differencing failed to produce an image because images are > different > > size: > > Valid image: 1279, 1023, 0 > > Test image: 1431, 828, 0 > > > > Seems like this one should not be a test that "fails" due to different > image > > size. > > > > How should we fix it? > > > > > > Thanks, > > D > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > > > >> -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Wed Jul 30 09:40:52 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 30 Jul 2014 06:40:52 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Hello Joachim! I did it, it was the right way to do it :). Thank you so much for your explanation. I resume the steps for everyone: 0- Create a shader file with the function *propFuncFS**(Fragment shader)* * or **propFuncVS(Vertex shader).* 1- Load the shader from disk. 2- Create a vtkShader2 and set the source code. 3- Create a vtkShaderProgram2 and initialize it (DO NOT BUILD THE PROGRAM). 4- Add the shader to the program. 5- Obtain the actor vtkOpenGLProperty and set the program 6- Set the shading on. Code: > *QFile fragmentFile(QStringLiteral("C:/myfragmentshader"));* > * fragmentFile.open(QIODevice::ReadOnly);* > * auto fragmentBytes = fragmentFile.readAll();* > * fragmentFile.close();** QString fragmentShaderSource(fragmentBytes);* > > * //The GLSL binded program* > * vtkSmartPointer program = > vtkSmartPointer::New();* > * // Prepare the fragment shader* > * vtkSmartPointer shader = vtkSmartPointer::New();* > * shader->SetType(VTK_SHADER_TYPE_FRAGMENT);** > shader->SetSourceCode(fragmentShaderSource.toStdString().c_str());* > * program->GetShaders()->AddItem(shader);* > > * vtkSmartPointer openGLproperty = > static_cast(gemActor->GetProperty());* > * openGLproperty->SetPropProgram(program);** openGLproperty->ShadingOn();* Shader (simple shader to paint all fragments red): * #version 110* > > * void propFuncFS(void)* > * {* > * gl_FragColor = (255,0,0,1);** }* Thanks again and have a nice day! =) 2014-07-29 21:48 GMT+02:00 Carlos Martinez : > Joachim, > > Thank you so much for the explanation, I tried something similar but > building the shaders instead of not doing it (if I remember well). > Tomorrow i will try it and I will tell you the results!! > > Carlos. > > > > > 2014-07-29 15:14 GMT+02:00 Joachim Pouderoux [via VTK] < > ml-node+s1045678n5728004h64 at n5.nabble.com>: > >> Carlos >> >> Ok actually I was wrong. My patch works but it is not how this is >> supposed to happen. >> Basically, VTK will merge 2 different shader source code to define each >> type of shader (vertex, fragment etc.). >> A first source will come from the shader code that can be attached to the >> renderer shaders. >> If it not exist, the default is a main function that will call >> propFuncVS()/propFuncFS() etc - depending the shader type. >> The second source will come from the shader code that can be attached to >> the actor's property. >> If it not exist, the default behaviour is to define that propFuncVS/FS >> functions. >> Both source codes will be appended before being compiled by the >> openGlProperty. >> >> So basically if you do not define a renderer shader program, you simply >> have to provide a shader codes to your property that defines propFuncVS/FS >> functions instead of usual main() functions. >> Also do not build your shader program (program->Build()) in your code as >> it will fail because the main() functions are not provided. Remember they >> will be added later automatically before compilation by OpenGLProperty. >> >> Hope it is clear and it helps! >> >> Best, >> >> >> >> *Joachim Pouderoux* >> >> *PhD, Technical Expert* >> *Kitware SAS * >> >> >> >> 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux <[hidden email] >> >: >> >>> Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I >>> might have fixed. I will make a patch soon. >>> In the meanwhile try to change those lines: >>> >>> >>> needDefaultMainVS = !progHasVertex >>> && propProg->HasVertexShaders(); >>> needDefaultMainFS = !progHasFragment >>> && propProg->HasFragmentShaders(); >>> >>> by >>> >>> needDefaultMainVS = !progHasVertex >>> && !propProg->HasVertexShaders(); >>> needDefaultMainFS = !progHasFragment >>> && !propProg->HasFragmentShaders(); >>> >>> With that fixed, the steps you defined should now work as no second >>> main() will be added to both shader code. >>> >>> Joachim >>> >>> *Joachim Pouderoux* >>> >>> *PhD, Technical Expert* >>> *Kitware SAS * >>> >>> >>> >>> 2014-07-18 11:03 GMT+02:00 carlinhos <[hidden email] >>> >: >>> >>> Hello Xiaoming, >>>> >>>> I created a new vtkOpenGLProperty and set it to the actor, anyways i >>>> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >>>> because vtkProperty is an abstract class. I tried so many things to make it >>>> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >>>> instead of vtkActors but it also didn't work. >>>> >>>> Carlos. >>>> >>>> >>>> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >>>> >: >>>> >>>>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>>>> the vtkProperty not vtkOpenGLProperty,which has a member of >>>>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>>>> tell me sth about that ,thanks in advance. >>>>> Quote: >>>>> < 7- Put ShadingOn to the property and SetPropProgram with the >>>>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>>>> the >>>>> 2 shaders I put in).> >>>>> >>>>> >>>>> >>>>> ------------------------------ >>>>> If you reply to this email, your message will be added to the >>>>> discussion below: >>>>> >>>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>>>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>>>> here. >>>>> NAML >>>>> >>>>> >>>> >>>> >>>> ------------------------------ >>>> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 >>>> and Qt 5.2.1) >>>> >>>> Sent from the VTK - Dev mailing list archive >>>> at Nabble.com. >>>> >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/vtk-developers >>>> >>>> >>>> >>> >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> >> >> ------------------------------ >> If you reply to this email, your message will be added to the >> discussion below: >> >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728004.html >> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >> here >> >> . >> NAML >> >> > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728023.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.thompson at kitware.com Thu Jul 31 12:51:36 2014 From: david.thompson at kitware.com (David Thompson) Date: Thu, 31 Jul 2014 12:51:36 -0400 Subject: [vtk-developers] OpenGL2 tests Message-ID: Hi all, I've noticed that some tests I recently added are failing on the OpenGL2 dashboard build: http://open.cdash.org/viewTest.php?buildid=3430147 apparently because antialiasing is enabled and some face normals are handled differently. (My particular test is vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change in the test to disable antialiasing for OpenGL2+ or will that be done as part of the testing framework as the rendering changes continue? Thanks, David From marcus.hanwell at kitware.com Thu Jul 31 13:04:39 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 13:04:39 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: On Thu, Jul 31, 2014 at 12:51 PM, David Thompson wrote: > Hi all, > > I've noticed that some tests I recently added are failing on the OpenGL2 dashboard build: > > http://open.cdash.org/viewTest.php?buildid=3430147 > > apparently because antialiasing is enabled and some face normals are handled differently. (My particular test is vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change in the test to disable antialiasing for OpenGL2+ or will that be done as part of the testing framework as the rendering changes continue? > I will look into it, you shouldn't worry too much as we need to figure out how to minimize some of this. Some of the lighting will be slightly different, but we should still be able to disable multisampling. Thanks for pointing it out. Marcus From dave.demarle at kitware.com Thu Jul 31 13:31:36 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 31 Jul 2014 13:31:36 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: Surface selection and depth composting also disabling anti aliasing too. On Jul 31, 2014 1:05 PM, "Marcus D. Hanwell" wrote: > On Thu, Jul 31, 2014 at 12:51 PM, David Thompson > wrote: > > Hi all, > > > > I've noticed that some tests I recently added are failing on the OpenGL2 > dashboard build: > > > > http://open.cdash.org/viewTest.php?buildid=3430147 > > > > apparently because antialiasing is enabled and some face normals are > handled differently. (My particular test is > vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change > in the test to disable antialiasing for OpenGL2+ or will that be done as > part of the testing framework as the rendering changes continue? > > > I will look into it, you shouldn't worry too much as we need to figure > out how to minimize some of this. Some of the lighting will be > slightly different, but we should still be able to disable > multisampling. Thanks for pointing it out. > > Marcus > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From marcus.hanwell at kitware.com Thu Jul 31 13:53:29 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 13:53:29 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: On Thu, Jul 31, 2014 at 1:31 PM, David E DeMarle wrote: > Surface selection and depth composting also disabling anti aliasing too. Selection code is totally different in the GL2 backend, guessing you mean depth compositing and we haven't gotten to that yet. Like I said - I will look into why multisampling is being enabled in error for some tests. Marcus From dlrdave at aol.com Thu Jul 31 14:11:09 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 14:11:09 -0400 (EDT) Subject: [vtk-developers] More VTK Wiki Examples questions Message-ID: <8D17B01F0735AB3-1A1C-16D7A@webmail-vm031.sysops.aol.com> This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/XGMLReader gets an "fsm.gml" data file from "somewhere" (but *NOT* VTKData) and uses it when running the VTK Wiki Examples dashboard on my machine. This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/TreeMapView apparently depends on VTKData, which I do not have, so the test fails on my machine. On the wiki page itself, there's a note saying we should generate an example tree map instead of loading from a data file: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/TreeMapView So... we can fix the failing test by making the TreeMapView's data files available (as fsm.gml is already available) to my dashboard build.... or by modifying the TreeMapView example to use some generated data. Which is easier? I'm not sure how to do either myself -- I'm hoping Bill L. can easily add some data for this example, or Jeff Baumes can point me to how to generate an example TreeMap easily... Thanks, David C. From dlrdave at aol.com Thu Jul 31 14:20:57 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 14:20:57 -0400 (EDT) Subject: [vtk-developers] InfoVis graph visualization question: vtkGraphLayoutView with a "Simple 2D" layout strategy Message-ID: <8D17B034EF2C9AD-1A1C-16EE0@webmail-vm031.sysops.aol.com> This VTK wiki example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/XGMLReader Yields this different rendering test failure on my dashboard machine: http://open.cdash.org/testDetails.php?test=271695203&build=3430870 The graph structure looks the same, and the visual is roughly equivalent, but the expected image clearly shows a perfectly square glyph at each graph node. In my test image, the graph nodes look like they vary from circle to square to polygons in between... What determines the shape of the node glyph in a vtkGraphLayoutView with a "Simple 2D" layout strategy? And would the shape difference account entirely for the slight offset and angle between expected image and test image...? Thanks, David C. From dlrdave at aol.com Thu Jul 31 15:59:55 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 15:59:55 -0400 (EDT) Subject: [vtk-developers] VTK wiki example FullScreen In-Reply-To: References: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Message-ID: <8D17B11223B2197-1BBC-1A024@webmail-vd018.sysops.aol.com> > Agree. Need to ponder. Have you pondered any fresh ideas since last Friday? :-) From jchris.fillionr at kitware.com Thu Jul 31 19:44:35 2014 From: jchris.fillionr at kitware.com (Jean-Christophe Fillion-Robin) Date: Thu, 31 Jul 2014 19:44:35 -0400 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' Message-ID: Hi Folks, After doing some experiment with Slicer, building against: VTK 6.2-dev - f19689d Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 It causes the volume rendering test [0] to fail [1] with the following error: Generic Warning: In /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, line 27 Error: no override found for 'vtkContextDevice2D'. This has already been discussed few days ago in [2] but we didn't came to a solution. I suspect it is related to the recent work done regarding the support of different rendering backend. Any idea what could be done to fix this ? You will also find below a complete backtrace. See [3] Thanks Jc [0] https://github.com/Slicer/Slicer/blob/22f1c99f28d52f58070e31849d33a3a50e4501a6/Modules/Loadable/VolumeRendering/Testing/Cxx/qMRMLVolumePropertyNodeWidgetTest1.cxx [1] http://slicer.cdash.org/testDetails.php?test=5592103&build=253161 [2] http://vtk.1045678.n5.nabble.com/Problem-with-QVtkWidget-not-rendering-vktChartXY-in-visual-studio-2013-td5727913.html#a5727919 [3] Backtrace: (gdb) bt #0 0x00007fffdb63ecc6 in vtkContextActor::RenderOverlay (this=0xc34be0, viewport=0xbbe720) at /path/to/VTKv6/Rendering/Context2D/vtkContextActor.cxx:212 #1 0x00007fffd77f1483 in vtkRenderer::UpdateGeometry (this=0xbbe720) at /path/to/VTKv6/Rendering/Core/vtkRenderer.cxx:585 #2 0x00007fffdd3f5631 in vtkOpenGLRenderer::DeviceRender (this=0xbbe720) at /path/to/VTKv6/Rendering/OpenGL/vtkOpenGLRenderer.cxx:270 #3 0x00007fffd77f0691 in vtkRenderer::Render (this=0xbbe720) at /path/to/VTKv6/Rendering/Core/vtkRenderer.cxx:292 #4 0x00007fffd77eed45 in vtkRendererCollection::Render (this=0xbbe580) at /path/to/VTKv6/Rendering/Core/vtkRendererCollection.cxx:51 #5 0x00007fffd7804bd8 in vtkRenderWindow::DoStereoRender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:762 #6 0x00007fffd7804ade in vtkRenderWindow::DoFDRender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:731 #7 0x00007fffd780447e in vtkRenderWindow::DoAARender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:610 #8 0x00007fffd7803a4c in vtkRenderWindow::Render (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:426 #9 0x00007fffdd492ced in vtkXOpenGLRenderWindow::Render (this=0xbbe2c0) at /path/to/VTKv6/Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx:1830 #10 0x00007fffd78103df in vtkRenderWindowInteractor::Render (this=0xc1bb60) at /path/to/VTKv6/Rendering/Core/vtkRenderWindowInteractor.cxx:171 #11 0x00007fffddc117a4 in QVTKWidget::paintEvent (this=0xba6ad0) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:479 #12 0x00007fffcec51146 in QWidget::event(QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #13 0x00007fffddc11566 in QVTKWidget::event (this=0xba6ad0, e=0x7fffffffd020) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:414 #14 0x00007fffcec0781c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #15 0x00007fffcec0a189 in QApplication::notify(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #16 0x00007fffce6ae7ce in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #17 0x00007fffcec55de4 in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #18 0x00007fffcee2574c in QWidgetPrivate::repaint_sys(QRegion const&) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #19 0x00007fffcec44fa4 in QWidgetPrivate::syncBackingStore() () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #20 0x00007fffcec513a3 in QWidget::event(QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #21 0x00007fffddc11566 in QVTKWidget::event (this=0xba6ad0, e=0xd3fef0) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:414 #22 0x00007fffcec0781c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #23 0x00007fffcec0a189 in QApplication::notify(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #24 0x00007fffce6ae7ce in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #25 0x00007fffce6b2221 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #26 0x00007fffceca17cc in ?? () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #27 0x00007fffce6ad55f in QEventLoop::processEvents(QFlags) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #28 0x00007fffce6ad7e8 in QEventLoop::exec(QFlags) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #29 0x00007fffce6b28b8 in QCoreApplication::exec() () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #30 0x0000000000410f9c in qMRMLVolumePropertyNodeWidgetTest1 (argc=1, argv=0x7fffffffdd60) at /home/jchris/Projects/Slicer-2/Modules/Loadable/VolumeRendering/Testing/Cxx/qMRMLVolumePropertyNodeWidgetTest1.cxx:52 #31 0x0000000000410d29 in main (ac=1, av=0x7fffffffdd60) at /path/to/Slicer-build/Modules/Loadable/VolumeRendering/Testing/Cxx/qSlicerVolumeRenderingModuleCxxTests.cxx:197 -- +1 919 869 8849 -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.gobbi at gmail.com Thu Jul 31 20:03:50 2014 From: david.gobbi at gmail.com (David Gobbi) Date: Thu, 31 Jul 2014 18:03:50 -0600 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' In-Reply-To: References: Message-ID: It's due to the addition of the VTK Rendering/ContextOpenGL directory that occurred a couple weeks ago in the following commit: http://vtk.org/gitweb?p=VTK.git;a=commit;h=c5121871 Basically, now that the OpenGL override for vtkContextDevice2D has been moved int Rendering/ContextOpenGL, you have to make sure that you link to vtkRenderingContextOpenGL. See the following wiki page for more info: http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Factories_now_require_defines - David On Thu, Jul 31, 2014 at 5:44 PM, Jean-Christophe Fillion-Robin wrote: > Hi Folks, > > After doing some experiment with Slicer, building against: > > VTK 6.2-dev - f19689d > > Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 > > It causes the volume rendering test [0] to fail [1] with the following > error: > > > Generic Warning: In > /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, > line 27 > Error: no override found for 'vtkContextDevice2D'. > > This has already been discussed few days ago in [2] but we didn't came to a > solution. > > I suspect it is related to the recent work done regarding the support of > different rendering backend. > > Any idea what could be done to fix this ? > > You will also find below a complete backtrace. See [3] > > Thanks > Jc From marcus.hanwell at kitware.com Thu Jul 31 20:50:43 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 20:50:43 -0400 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' In-Reply-To: References: Message-ID: As David pointed, I split the OpenGL backend out. If you add the link to the vtkRenderingContextOpenGL backend then it should work fine. Let me know if you continue to have problems. On Thu, Jul 31, 2014 at 8:03 PM, David Gobbi wrote: > It's due to the addition of the VTK Rendering/ContextOpenGL directory > that occurred a couple weeks ago in the following commit: > > http://vtk.org/gitweb?p=VTK.git;a=commit;h=c5121871 > > Basically, now that the OpenGL override for vtkContextDevice2D has been > moved int Rendering/ContextOpenGL, you have to make sure that you link > to vtkRenderingContextOpenGL. See the following wiki page for more info: > > http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Factories_now_require_defines > > - David > > > On Thu, Jul 31, 2014 at 5:44 PM, Jean-Christophe Fillion-Robin > wrote: >> Hi Folks, >> >> After doing some experiment with Slicer, building against: >> >> VTK 6.2-dev - f19689d >> >> Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 >> >> It causes the volume rendering test [0] to fail [1] with the following >> error: >> >> >> Generic Warning: In >> /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, >> line 27 >> Error: no override found for 'vtkContextDevice2D'. >> >> This has already been discussed few days ago in [2] but we didn't came to a >> solution. >> >> I suspect it is related to the recent work done regarding the support of >> different rendering backend. >> >> Any idea what could be done to fix this ? >> >> You will also find below a complete backtrace. See [3] >> >> Thanks >> Jc > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > From nicole at bwh.harvard.edu Tue Jul 1 16:57:22 2014 From: nicole at bwh.harvard.edu (Nicole Aucoin) Date: Tue, 01 Jul 2014 16:57:22 -0400 Subject: [vtk-developers] an abstract class to manage groups of widgets? Message-ID: <53B320B2.8050805@bwh.harvard.edu> Hello, In 3D Slicer we're currently using a vtkSeedWidget to represent a list of points, and I'd like to extend my module[1] to work with lists of rulers, angles, bidimensional widgets etc. I want to eventually have many types of lists that contain elements with >1 points and have VTK widgets to interact with them. In the code that manages the mapping between the widgets and the stored point values, having one vtkSeedWidget per list of points is working well, but I'm finding that I have many special cases when trying to use many vtkDistanceWidgets to represent a list of pairs of points. I need a generalisation of a vtkSeedWidget that will manage a set of general widgets rather than being restricted to a set of handle widgets. I noticed that in VTK 6 there's a new class called vtkWidgetSet, but the documentation[2] states that it synchronises a set of widgets across render windows, which is not quite what I need (I have separate widgets in each render window, synchronised via the point(s) list). I was going to start working on the abstract widget group (list?) class and representation[3] that I need and at first integrate it into Slicer's fork of VTK then contribute it back into VTK. Before I start, I wanted to ask if there was any effort in this direction already, or if there's a grouping method in VTK6 that might work out of the box. thanks, Nicole [1] http://www.slicer.org/slicerWiki/index.php/Documentation/4.3/Modules/Markups [2] http://www.vtk.org/doc/nightly/html/classvtkWidgetSet.html#details [3] Working from the example of the seed representation as the base and extending to support Nth point set/get, which will probably require some superclass additions to generalise the representations. DistanceRepresentation uses [Get|Set]Point[1|2][World|Display]Position which could be updated to call a new virtual method [Get|Set]NthPoint[World|Display]Position(unsigned int n, ...). The vtkContourRepresentation has some generalisation already in [Get|Set]NthNode[World|Display]Position(int n, ...), while the vtkSeedRepresentation uses [Get|Set]Seed[World|Display]Position(unsigned int n, ...), so an effort to make it uniform could be worthwhile, but would likely be phase 2 of my project. The information in this e-mail is intended only for the person to whom it is addressed. If you believe this e-mail was sent to you in error and the e-mail contains patient information, please contact the Partners Compliance HelpLine at http://www.partners.org/complianceline . If the e-mail was sent to you in error but does not contain patient information, please contact the sender and properly dispose of the e-mail. From jatinparekh93 at gmail.com Thu Jul 3 02:53:24 2014 From: jatinparekh93 at gmail.com (Jatin Parekh) Date: Thu, 3 Jul 2014 12:23:24 +0530 Subject: [vtk-developers] Adding External Data for Testing to a Fork Message-ID: Hi! I have written a test for a GeoJSON format reader for vtk. My test has a baseline image (lets say test.png) and another input data (lets say input.json in Testing/Data folder) for my implemented vtkGeoJSONReader. After I run cmake and make, My input data gets converted into corresponding md5 hashes and the referenced data is stored in my .ExternalData folder of the source. Now, when I git push my local copy to my own vtk fork with this test.png.md5 and input.txt.md5, How is the referenced data uploaded on git? Should I push only the original data (baseline image and input.json) or the md5 files and the actual data both? What is the ideal approach in this case where I wish to add testing data and external data to my own fork? Since the data is to be added only to my fork and not the original VTK, I don't think gerrit would be useful. Would it? Here is the GeoJSON reader & VTK fork that I am working on https://github.com/OpenGeoscience/VTK/tree/master/IO/GeoJSON If anymore information is required, I'll be glad to provide them. Thanks! Jatin Parekh -------------- next part -------------- An HTML attachment was scrubbed... URL: From brad.king at kitware.com Thu Jul 3 10:13:52 2014 From: brad.king at kitware.com (Brad King) Date: Thu, 03 Jul 2014 10:13:52 -0400 Subject: [vtk-developers] Adding External Data for Testing to a Fork In-Reply-To: References: Message-ID: <53B56520.4070709@kitware.com> On 07/03/2014 02:53 AM, Jatin Parekh wrote: > What is the ideal approach in this case where I wish to add > testing data and external data to my own fork? I've just extended the VTK developer documentation on external data with a section for this case: http://www.vtk.org/Wiki/VTK/Git/Develop/Data#Publishing_Data_for_an_External_Branch -Brad From dave.demarle at kitware.com Thu Jul 3 14:13:47 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 3 Jul 2014 14:13:47 -0400 Subject: [vtk-developers] announce: Kitware is hiring - now with more web! Message-ID: Howdy, If you are talented researcher and developer with strong C++ and/or web services development skills, please consider applying to Kitware. We are particularly interested now in developers who have significant web service development talent to help us expand the frontiers of visualization and analytics delivered over the web. At Kitware you will join a fun and talented team and work on many interesting and challenging technical problems - always aiming to deliver robust and widely used software solutions. Specifically, the scientific visualization and medical groups at Kitware is looking for these people: * Scientific Visualization Web Developer (see below) * GUI and Application Software Developer * Informatics Researcher * Informatics Software Developer * HPC Visualization and Data Analysis Software Developer * Scientific Visualization Developer * Research and Development Involving Machine Learning and Medical Image Analysis * Technical Lead in Biomedical Image Analysis and Visualization * Biomechanical Modeling and Surgical Simulation Software Developer Go to http://jobs.kitware.com/opportunities.html for more details and to apply. SCIENTIFIC VISUALIZATION WEB DEVELOPER Job Description: By joining our team you will participate in a dynamic work environment with exceptionally talented coworkers who are committed to high-quality development practices. You will collaborate with esteemed researchers from around the world to create next-generation, open-source software for web applications for data management, analysis, and visualization; design and produce full-featured, modern web interfaces for cutting-edge applications; and will deploy software applications and infrastructure that are used by people, every day, around the world, to improve the world. Work will be performed in the context of an open-source and highly collaborative development model. Qualifications: An ideal candidate should have at least four years of experience in HTML, CSS, and JavaScript, with an undergraduate or higher degree in Computer Science or a related field. Strong software development skills are a must, and familiarity with website UI/UX aesthetics and design as well as JavaScript libraries such as JQuery, Underscore, Backbone, and/or Angular is highly desirable. Candidates should be familiar with tools for good software practice such as git and web testing frameworks. Also desirable is experience with server scripting languages like Python, and server components such as Apache, Node.js, Django, and CherryPy. Strong candidates will also have experience with web visualization libraries such as D3, WebGL, and HTML5 Canvas. C++ experience is a plus. thanks and good luck! David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 -------------- next part -------------- An HTML attachment was scrubbed... URL: From sean at rogue-research.com Thu Jul 3 14:51:24 2014 From: sean at rogue-research.com (Sean McBride) Date: Thu, 3 Jul 2014 14:51:24 -0400 Subject: [vtk-developers] Gerrit and OpenID Message-ID: <20140703185124.574802027@mail.rogue-research.com> Hi all, Guess it's been a while since I used gerrit because I discovered MyOpenID (that I used for my OpenID) has closed down. In fact, seems like OpenID itself is going the way of the dodo... Anyone know an OpenID provider? Or how else can I log back into gerrit? Thanks, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From jmerkow at gmail.com Thu Jul 3 18:30:10 2014 From: jmerkow at gmail.com (jmerkow) Date: Thu, 3 Jul 2014 15:30:10 -0700 (PDT) Subject: [vtk-developers] Problems with git, and setup scripts Message-ID: <1404426610508-5727747.post@n5.nabble.com> Hello, I am working on pushing some changes to gerrit, but the Setup scripts seem to be breaking on my system... I've made the changes, and I can add them but git commit is broken. use of git commit (i.e. git commit, git commit -m 'message', git commit -a), do nothing except print the following message ": No such file or directory" I haven't been able to track down what changes the setup scripts are making to cause this to happen. -Jameson -- View this message in context: http://vtk.1045678.n5.nabble.com/Problems-with-git-and-setup-scripts-tp5727747.html Sent from the VTK - Dev mailing list archive at Nabble.com. From ben.boeckel at kitware.com Thu Jul 3 20:35:57 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 3 Jul 2014 20:35:57 -0400 Subject: [vtk-developers] Gerrit and OpenID In-Reply-To: <20140703185124.574802027@mail.rogue-research.com> References: <20140703185124.574802027@mail.rogue-research.com> Message-ID: <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> On Thu, Jul 03, 2014 at 14:51:24 -0400, Sean McBride wrote: > Guess it's been a while since I used gerrit because I discovered > MyOpenID (that I used for my OpenID) has closed down. In fact, seems > like OpenID itself is going the way of the dodo... Google has been rumored to be ending support as a provider Soon. Seems they really want to be another Apple-like silo :( (albeit one that actually acknowledges that something other than their precious silo might exist). > Anyone know an OpenID provider? Or how else can I log back into > gerrit? Many of the "social networks" provide OpenID (e.g., Google, Facebook, Yahoo!, and more; StackOverflow has an example list[1] on their signup page). The OpenID site has a list[2] as well. If you can host something, there are also multiple ways; at least Janrain[3] and Fedora's provider is FOSS[4] as well (though I've deployed neither, so I have no information on which would be easier to setup). --Ben [1]https://stackoverflow.com/users/signup [2]http://openid.net/get-an-openid/ [3]http://developers.janrain.com/how-to/identity-services/integrate-identity-services/#appendix [4]https://fedoraproject.org/wiki/OpenID From sean at rogue-research.com Fri Jul 4 18:03:54 2014 From: sean at rogue-research.com (Sean McBride) Date: Fri, 4 Jul 2014 18:03:54 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <20140704220354.1112198926@mail.rogue-research.com> Hi all, The vtkGPUInfo class: uses vtkIdType, which is sometimes 32 bit and sometimes 64, to count the number of bytes of memory. This is a problem since these days you can have more than 2^32 bytes of memory. :) It seems something like size_t should be used instead of vtkIdType. Would such a change count as API breakage, or is it minor enough? Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From dlrdave at aol.com Sat Jul 5 15:06:57 2014 From: dlrdave at aol.com (David Cole) Date: Sat, 5 Jul 2014 15:06:57 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <20140704220354.1112198926@mail.rogue-research.com> References: <20140704220354.1112198926@mail.rogue-research.com> Message-ID: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> If you need more than 2^32 bytes of memory, you likely need to build VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit wide type, too... So is a change really necessary? Or..... you *can* build a 32-bit build of VTK, but explicitly set its id type to be 64-bits anyway, even in the 32-bit build. I'm not sure I see the advantage of using size_t over vtkIdType, as they both vary in size based on CMake/compiler settings. Can you elaborate on why you think it would be better to use size_t instead of vtkIdType? David C. From david.thompson at kitware.com Sat Jul 5 21:50:08 2014 From: david.thompson at kitware.com (David Thompson) Date: Sat, 5 Jul 2014 21:50:08 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> References: <20140704220354.1112198926@mail.rogue-research.com> <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> Message-ID: <6914A3D3-C4D3-4132-BCD1-0DEA6CDC3EFA@kitware.com> > If you need more than 2^32 bytes of memory, you likely need to build VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit wide type, too... So is a change really necessary? > > Or..... you *can* build a 32-bit build of VTK, but explicitly set its id type to be 64-bits anyway, even in the 32-bit build. > > I'm not sure I see the advantage of using size_t over vtkIdType, as they both vary in size based on CMake/compiler settings. > > Can you elaborate on why you think it would be better to use size_t instead of vtkIdType? Well, to be a contrarian, I think both those options are guilty of mixing metaphors: - vtkIdType is meant to hold IDs, not pointers or pointer offsets. For people using unstructured grids as opposed to image data, a 32-bit cell ID may be fine and the name of the type does not imply that it will be used as a pointer offset, so they may not be in the right frame of mind to realize what the problem is when their GPU memory is misreported. Those people might still want to know how much memory is on the GPU if they want to render to large textures, for instance. - If the class weren't named vtkGPUInfo, size_t would be appropriate since it is meant to serve as a pointer offset. But the GPU drivers could potentially be built to expose more memory than the host system libraries are configured to address, so it is also (just barely) misusing a typedef. - Why not use vtkTypeInt64? That is what it's there for. Then there is no chance that the memory will be misreported until vtkTypeInt128 is required. I doubt anyone is going to use vtkGPUInfo in a tight loop, so the overhead is negligible. Developers who don't have to hunt down why GPU memory is being misreported on some weird system their uncle's friend uses for his collection of cat X-rays will be happy you chose vtkTypeInt64. - Another alternative is to report GPU memory in saner units, like kiB or MiB. - That's the Good and the Bad. The Ugly would be to report memory as a double, which has a 53-bit mantissa. But then someone would surely ask how to access the fractional bits. :-) David From nex.public at gmail.com Sun Jul 6 06:07:29 2014 From: nex.public at gmail.com (Public Acc) Date: Sun, 6 Jul 2014 12:07:29 +0200 Subject: [vtk-developers] Problem with SetAnaglyphColorMask Message-ID: Dear everyone, Function SetAnaglyphColorMask (vtkRenderWindow Class) seems to be not working for me. Regardless of input values for SetAnaglyphColorMask, when using GetAnaglyphColorMask to check current mask I always receive the same values - 5 and 3 respectively. I am using VTK 5.8. Regards, -------------- next part -------------- An HTML attachment was scrubbed... URL: From sean at rogue-research.com Sun Jul 6 22:26:53 2014 From: sean at rogue-research.com (Sean McBride) Date: Sun, 6 Jul 2014 22:26:53 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> References: <20140704220354.1112198926@mail.rogue-research.com> <8D1669B6D62DBBA-340-51F5@webmail-d287.sysops.aol.com> Message-ID: <20140707022653.205313894@mail.rogue-research.com> On Sat, 5 Jul 2014 15:06:57 -0400, David Cole said: >If you need more than 2^32 bytes of memory, you likely need to build >VTK as 64-bit anyhow, in which case, vtkIdType defaults to a 64-bit >wide type, too... So is a change really necessary? > >Or..... you *can* build a 32-bit build of VTK, but explicitly set its >id type to be 64-bits anyway, even in the 32-bit build. > >I'm not sure I see the advantage of using size_t over vtkIdType, as >they both vary in size based on CMake/compiler settings. > >Can you elaborate on why you think it would be better to use size_t >instead of vtkIdType? "The other David"? said much of what I was thinking. To answer more directly, I brought this up because I made this change the other day: and noticed the possibility of overflow. It's doesn't actually affect me, so I don't really care. :) Just thought to fix it while nearby. What rubs me wrong, as David said, is that vtkIdType doesn't seem at all appropriate semantically, as there are no "id"s involved, just a size count, for which size_t seems the best type (as it's what sizeof() returns). Changing the return value to mebibytes is a good idea too, but a worse API/ABI breakage than changing from one kind of integer to another, I think. Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From brad.king at kitware.com Mon Jul 7 09:11:57 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 09:11:57 -0400 Subject: [vtk-developers] Gerrit and OpenID In-Reply-To: <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> References: <20140703185124.574802027@mail.rogue-research.com> <20140704003557.GA13400@bronto-burt.dev.benboeckel.net> Message-ID: <53BA9C9D.5040002@kitware.com> On 07/03/2014 08:35 PM, Ben Boeckel wrote: > The OpenID site has a list[2] as well. > > [2]http://openid.net/get-an-openid/ Once you get a new OpenID then I can work with our admins to associate it with your account. Contact me off-list. -Brad From brad.king at kitware.com Mon Jul 7 09:16:52 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 09:16:52 -0400 Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <1404426610508-5727747.post@n5.nabble.com> References: <1404426610508-5727747.post@n5.nabble.com> Message-ID: <53BA9DC4.4060901@kitware.com> On Thu, Jul 3, 2014 at 6:30 PM, jmerkow wrote: > I've made the changes, and I can add them but git commit is broken. use of > git commit (i.e. git commit, git commit -m 'message', git commit -a), do > nothing except print the following message ": No such file or directory" To get verbose information about the execution of the pre-commit hook, try running this from the top of the source tree: bash -x .git/hooks/pre-commit That might show the command that fails in more detail. -Brad From dlrdave at aol.com Mon Jul 7 09:34:22 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 7 Jul 2014 09:34:22 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> > "The other David"? :-) > To answer more directly, I > brought this up because I made this change the other day: > > > > and noticed the possibility of overflow. > > ... > ... just a size count, for which size_t seems the best type (as it's > what sizeof() returns). Right, but using size_t will still give you a potential overflow problem in a 32-bit pointer build... Shouldn't the type *always* be large enough to represent expected actual memory sizes encountered in the wild? And therefore, shouldn't it be something that's always at least 64-bits wide as "the other David" suggested...? Don't even get me started on what vtkIdType *is* correct for semantically... "id" to me implies something that can identify an object across a wide swath of operations. Since it's almost always just an index into some array, a vtkIdType value does not really "id" anything, *except* in a given container filled once with data and no inserts or removes allowed. Fortunately for VTK, that's the main use case when visualizing a large data set. David C. From sean at rogue-research.com Mon Jul 7 13:06:50 2014 From: sean at rogue-research.com (Sean McBride) Date: Mon, 7 Jul 2014 13:06:50 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: <20140707170650.1063395070@mail.rogue-research.com> On Mon, 7 Jul 2014 09:34:22 -0400, David Cole said: >Right, but using size_t will still give you a potential overflow >problem in a 32-bit pointer build... Shouldn't the type *always* be >large enough to represent expected actual memory sizes encountered in >the wild? And therefore, shouldn't it be something that's always at >least 64-bits wide as "the other David" suggested...? That's fine with me too. So back to the original question: is such a change minor enough to not count as breaking API/ABI? Or is it all just not worth it? :) Cheers, -- ____________________________________________________________ Sean McBride, B. Eng sean at rogue-research.com Rogue Research www.rogue-research.com Mac Software Developer Montr?al, Qu?bec, Canada From dlrdave at aol.com Mon Jul 7 13:29:52 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 7 Jul 2014 13:29:52 -0400 (EDT) Subject: [vtk-developers] vtkGPUInfo and large amounts of memory Message-ID: <8D1682031B18678-978-D6D2@webmail-m167.sysops.aol.com> >>the wild? And therefore, shouldn't it be something that's always at >>least 64-bits wide as "the other David" suggested...? > So back to the original question: is such a change minor enough to > not count as breaking API/ABI? Or is it all just not worth it? :) Well if you change the signature of the existing method, then it's definitely a breaking change. As for whether it's "minor enough" or not, I'll leave that to the VTK legacy police. I'm sure one of them will chime in eventually. And even if it's not "minor enough"... maybe just document its limitations, mark it as a legacy method, and invent a new method with a new signature that's wide enough for the foreseeable future. HTH, David C. From jmerkow at gmail.com Mon Jul 7 15:06:33 2014 From: jmerkow at gmail.com (jmerkow) Date: Mon, 7 Jul 2014 12:06:33 -0700 (PDT) Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <53BA9DC4.4060901@kitware.com> References: <1404426610508-5727747.post@n5.nabble.com> <53BA9DC4.4060901@kitware.com> Message-ID: <1404759993399-5727782.post@n5.nabble.com> Brad, Thanks for the reply. At some point in figuring out what went wrong, I saw an error with command not found $/r, which suggested that it was a crlf problem. I ran dos2unix on all the scripts and hooks etc and re-setup wit the developer script, and it worked fine. For some reason my crlf settings were setup wrong on this machine, so git added /r to some of the line endings. Anyway, fixed now. Thanks for the help! Jameson -- View this message in context: http://vtk.1045678.n5.nabble.com/Problems-with-git-and-setup-scripts-tp5727747p5727782.html Sent from the VTK - Dev mailing list archive at Nabble.com. From brad.king at kitware.com Mon Jul 7 15:27:59 2014 From: brad.king at kitware.com (Brad King) Date: Mon, 07 Jul 2014 15:27:59 -0400 Subject: [vtk-developers] Problems with git, and setup scripts In-Reply-To: <1404759993399-5727782.post@n5.nabble.com> References: <1404426610508-5727747.post@n5.nabble.com> <53BA9DC4.4060901@kitware.com> <1404759993399-5727782.post@n5.nabble.com> Message-ID: <53BAF4BF.7070405@kitware.com> On 07/07/2014 03:06 PM, jmerkow wrote: > For some reason my crlf settings were setup wrong on this machine, > so git added /r to some of the line endings. I'm glad you have it working locally. I fixed the hooks branch to use LF newlines regardless of local configuration: http://vtk.org/gitweb?p=VTK.git;a=commitdiff;h=b9b95219 Thanks, -Brad From berk.geveci at kitware.com Mon Jul 7 15:53:33 2014 From: berk.geveci at kitware.com (Berk Geveci) Date: Mon, 7 Jul 2014 15:53:33 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <20140707170650.1063395070@mail.rogue-research.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> <20140707170650.1063395070@mail.rogue-research.com> Message-ID: Bugs in the API are fair game to fix even if they break compatibility. I'd say fix it. I would go with a 64 bit type like Dave T. suggested. -berk On Mon, Jul 7, 2014 at 1:06 PM, Sean McBride wrote: > On Mon, 7 Jul 2014 09:34:22 -0400, David Cole said: > > >Right, but using size_t will still give you a potential overflow > >problem in a 32-bit pointer build... Shouldn't the type *always* be > >large enough to represent expected actual memory sizes encountered in > >the wild? And therefore, shouldn't it be something that's always at > >least 64-bits wide as "the other David" suggested...? > > That's fine with me too. > > So back to the original question: is such a change minor enough to not > count as breaking API/ABI? Or is it all just not worth it? :) > > Cheers, > > -- > ____________________________________________________________ > Sean McBride, B. Eng sean at rogue-research.com > Rogue Research www.rogue-research.com > Mac Software Developer Montr?al, Qu?bec, Canada > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From berk.geveci at kitware.com Mon Jul 7 16:01:42 2014 From: berk.geveci at kitware.com (Berk Geveci) Date: Mon, 7 Jul 2014 16:01:42 -0400 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: > Don't even get me started on what vtkIdType *is* correct for > semantically... "id" to me implies something that can identify an > object across a wide swath of operations. Since it's almost always just > an index into some array, a vtkIdType value does not really "id" > anything, *except* in a given container filled once with data and no > inserts or removes allowed. Fortunately for VTK, that's the main use > case when visualizing a large data set. I disagree. vtkIdType is supposed to be the type of the id that identifies things like points and cells. The fact that the most common data structures in VTK store these in contiguous arrays is irrelevant to the validity of the term. VTK can easily support a vtkDataSet subclass that stores a map of (ids -> cell objects) for connectivity. The API abstracts away the underlying storage details (for the most part). My main issue with the current vtkIdType usage is that it is also used to define the size of the integer used in cell arrays to refer to points. So even if you have less than 2^31 point, you end up using 64 bits in the cell array to store the ids. Which doubles the storage. In my opinion, this should be run-time configurable. Furthermore, we should use size_t when defining offsets into these arrays, not vtkIdType. (See the Locations data member of vtkUnstructuredGrid for example). Best, -berk On Mon, Jul 7, 2014 at 9:34 AM, David Cole via vtk-developers < vtk-developers at vtk.org> wrote: > > "The other David"? > > :-) > > > > To answer more directly, I > > brought this up because I made this change the other day: > > > > > > > > and noticed the possibility of overflow. > > > > ... > > ... just a size count, for which size_t seems the best type (as it's > > what sizeof() returns). > > Right, but using size_t will still give you a potential overflow > problem in a 32-bit pointer build... Shouldn't the type *always* be > large enough to represent expected actual memory sizes encountered in > the wild? And therefore, shouldn't it be something that's always at > least 64-bits wide as "the other David" suggested...? > > Don't even get me started on what vtkIdType *is* correct for > semantically... "id" to me implies something that can identify an > object across a wide swath of operations. Since it's almost always just > an index into some array, a vtkIdType value does not really "id" > anything, *except* in a given container filled once with data and no > inserts or removes allowed. Fortunately for VTK, that's the main use > case when visualizing a large data set. > > > David C. > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.gobbi at gmail.com Mon Jul 7 16:29:39 2014 From: david.gobbi at gmail.com (David Gobbi) Date: Mon, 7 Jul 2014 14:29:39 -0600 Subject: [vtk-developers] vtkGPUInfo and large amounts of memory In-Reply-To: References: <8D167FF4BD6E449-B3C-BF1A@webmail-vm014.sysops.aol.com> Message-ID: On Mon, Jul 7, 2014 at 2:01 PM, Berk Geveci wrote: > My main issue with the current vtkIdType usage is that it is also used > to define the size of the integer used in cell arrays to refer to points. So > even if you have less than 2^31 point, you end up using 64 bits in the cell > array to store the ids. Which doubles the storage. In my opinion, this should > be run-time configurable. Furthermore, we should use size_t when defining > offsets into these arrays, not vtkIdType. (See the Locations data member > of vtkUnstructuredGrid for example). If it is made to be configurable, I would vote to switch many of the core VTK filters to templated execute methods (templated over float vs. double and 64-bit IDs vs. 32-bit IDs). This would avoid the performance hit of accessing all points and point IDs through virtual methods. - Yet another David (sorry 'bout that...) From carlinhosmp87 at gmail.com Tue Jul 8 03:15:27 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Tue, 8 Jul 2014 00:15:27 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) Message-ID: <1404803727578-5727788.post@n5.nabble.com> Hi all, I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. I have an assembly with different actors into a vtkRenderWindow. I load a shader with the class vtkShader2, and create the program with vtkShaderProgram2, all ok with this. After that, i wanted to attach the shader to the actors (i'm going to use different shaders, depending on the actors). The problem is i didn't find examples or documentation to do this and i'm not capable to use the classes for the shaders correctly. I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 with the method "SetPropProgram" and i set the property of the actors with that one, but vtk shows me a warning window with a conflict between the default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). Can someone help me? Thanks in advance!! -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html Sent from the VTK - Dev mailing list archive at Nabble.com. From simon.esneault at gmail.com Tue Jul 8 05:41:01 2014 From: simon.esneault at gmail.com (Simon ESNEAULT) Date: Tue, 8 Jul 2014 11:41:01 +0200 Subject: [vtk-developers] [vtkusers] About vtkImageReslice interpolation Message-ID: Hi All, We use vtkImageResample/vtkImageReslice (from vtk 5.8.1) quite a lot here, and I've noticed a strange behavior. If we down sample a volume by a factor of 2 in all 3 directions, the output image will be the exact same if we use a nearest neighborhood, linear or cubic interpolation. There seems to be no interpolation at all if the reduction factor is a power of two. If the reduction factor is set to 2.00001, the interpolation is performed correctly when asked for linear or cubic. Is this an intended behavior ? After some debugging : In the file vtkImageReslice.cxx, method vtkTricubicInterpCoeffs (line 1503) with a power of 2 factor we always fall back to the part with the comment // no interpolation (line 1510), but I don't understand why. And last question : there is a new vtkImageResize that was introduced in vtk 5.10, will the behavior be the same ? Thanks for your help -Simon -- ------------------------------------------------------------------ Simon Esneault 13 rue Vasselot 35000 Rennes, France Tel : 06 64 61 30 94 Mail : simon.esneault at gmail.com ------------------------------------------------------------------ -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Tue Jul 8 12:25:17 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Tue, 8 Jul 2014 12:25:17 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: <1404803727578-5727788.post@n5.nabble.com> References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. - Aashish On Tue, Jul 8, 2014 at 3:15 AM, carlinhos wrote: > Hi all, > > I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. > > I have an assembly with different actors into a vtkRenderWindow. > > I load a shader with the class vtkShader2, and create the program with > vtkShaderProgram2, all ok with this. After that, i wanted to attach the > shader to the actors (i'm going to use different shaders, depending on the > actors). The problem is i didn't find examples or documentation to do this > and i'm not capable to use the classes for the shaders correctly. > > I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 > with the method "SetPropProgram" and i set the property of the actors with > that one, but vtk shows me a warning window with a conflict between the > default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). > > Can someone help me? Thanks in advance!! > > > > -- > View this message in context: > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html > Sent from the VTK - Dev mailing list archive at Nabble.com. > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Tue Jul 8 14:14:23 2014 From: carlinhosmp87 at gmail.com (Carlos Martinez) Date: Tue, 8 Jul 2014 20:14:23 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: Thanks for your answer, i thought it wasn't the right way! What do you mean when you say i have to load the shaders manually? The steps i'm doing are: 1- Create a vtkShaderProgram2 2- Create the vtkShader2 (VertexShader) and load it from the file with SetSourceCode. 3- Add my VertexShader to the vtkShaderProgram2 with "GetShaders()->AddItem()". 4- Repeat 2 and 3 with the FragmentShader. 5- Build the vtkShaderProgram and check the Build Status (to check if everything is ok). 6- Create a vtkActor and obtain his property(with GetProperty()). 7- Put ShadingOn to the property and SetPropProgram with the vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the 2 shaders I put in). When the actors are going to display into the screen, the warning window shows up and tells me that the main is defined twice (and shows me the Default shaders and mine). Thanks again!! 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary : > vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. > > - Aashish > > > > On Tue, Jul 8, 2014 at 3:15 AM, carlinhos wrote: > >> Hi all, >> >> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >> >> I have an assembly with different actors into a vtkRenderWindow. >> >> I load a shader with the class vtkShader2, and create the program with >> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >> shader to the actors (i'm going to use different shaders, depending on the >> actors). The problem is i didn't find examples or documentation to do this >> and i'm not capable to use the classes for the shaders correctly. >> >> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >> with the method "SetPropProgram" and i set the property of the actors with >> that one, but vtk shows me a warning window with a conflict between the >> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >> >> Can someone help me? Thanks in advance!! >> >> >> >> -- >> View this message in context: >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >> Sent from the VTK - Dev mailing list archive at Nabble.com. >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> > > > -- > > > > *| Aashish Chaudhary | Technical Leader | Kitware Inc. * > *| http://www.kitware.com/company/team/chaudhary.html > * > -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Tue Jul 8 15:07:39 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Tue, 8 Jul 2014 15:07:39 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: I can reply in detail layer bu*t on this note, you may want to use the new VTK rendering code for it. Marcus or Ken hopefully reply to you on that.* - Aashish On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez wrote: > Thanks for your answer, i thought it wasn't the right way! > > What do you mean when you say i have to load the shaders manually? The > steps i'm doing are: > > 1- Create a vtkShaderProgram2 > 2- Create the vtkShader2 (VertexShader) and load it from the file with > SetSourceCode. > 3- Add my VertexShader to the vtkShaderProgram2 with > "GetShaders()->AddItem()". > 4- Repeat 2 and 3 with the FragmentShader. > 5- Build the vtkShaderProgram and check the Build Status (to check if > everything is ok). > 6- Create a vtkActor and obtain his property(with GetProperty()). > 7- Put ShadingOn to the property and SetPropProgram with the > vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the > 2 shaders I put in). > > When the actors are going to display into the screen, the warning window > shows up and tells me that the main is defined twice (and shows me the > Default shaders and mine). > > Thanks again!! > > > 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary < > aashish.chaudhary at kitware.com>: > > vtkOpenGLProperty::SetPropProgram is the right function but you have load your shaders manually now. I believe the error you are getting is because it is still trying to use the last shader code. >> >> - Aashish >> >> >> >> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos >> wrote: >> >>> Hi all, >>> >>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >>> >>> I have an assembly with different actors into a vtkRenderWindow. >>> >>> I load a shader with the class vtkShader2, and create the program with >>> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >>> shader to the actors (i'm going to use different shaders, depending on >>> the >>> actors). The problem is i didn't find examples or documentation to do >>> this >>> and i'm not capable to use the classes for the shaders correctly. >>> >>> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >>> with the method "SetPropProgram" and i set the property of the actors >>> with >>> that one, but vtk shows me a warning window with a conflict between the >>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >>> >>> Can someone help me? Thanks in advance!! >>> >>> >>> >>> -- >>> View this message in context: >>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >>> Sent from the VTK - Dev mailing list archive at Nabble.com. >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/vtk-developers >>> >>> >> >> >> -- >> >> >> >> *| Aashish Chaudhary | Technical Leader | Kitware Inc. >> * >> *| http://www.kitware.com/company/team/chaudhary.html >> * >> > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From marcus.hanwell at kitware.com Tue Jul 8 15:40:30 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Tue, 8 Jul 2014 15:40:30 -0400 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: I don't think that would be useful at this time - whilst the new rendering code is shader based we have not yet started to add functionality to add your own or modify our shader code. On Tue, Jul 8, 2014 at 3:07 PM, Aashish Chaudhary wrote: > I can reply in detail layer but on this note, you may want to use the new > VTK rendering code for it. Marcus or Ken hopefully reply to you on that. > > - Aashish > > > On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez > wrote: >> >> Thanks for your answer, i thought it wasn't the right way! >> >> What do you mean when you say i have to load the shaders manually? The >> steps i'm doing are: >> >> 1- Create a vtkShaderProgram2 >> 2- Create the vtkShader2 (VertexShader) and load it from the file with >> SetSourceCode. >> 3- Add my VertexShader to the vtkShaderProgram2 with >> "GetShaders()->AddItem()". >> 4- Repeat 2 and 3 with the FragmentShader. >> 5- Build the vtkShaderProgram and check the Build Status (to check if >> everything is ok). >> 6- Create a vtkActor and obtain his property(with GetProperty()). >> 7- Put ShadingOn to the property and SetPropProgram with the >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the 2 >> shaders I put in). >> >> When the actors are going to display into the screen, the warning window >> shows up and tells me that the main is defined twice (and shows me the >> Default shaders and mine). >> >> Thanks again!! >> >> >> 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary >> : >> >>> vtkOpenGLProperty::SetPropProgram is the right function but you have load >>> your shaders manually now. I believe the error you are getting is because it >>> is still trying to use the last shader code. >>> >>> - Aashish >>> >>> >>> >>> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos >>> wrote: >>>> >>>> Hi all, >>>> >>>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. >>>> >>>> I have an assembly with different actors into a vtkRenderWindow. >>>> >>>> I load a shader with the class vtkShader2, and create the program with >>>> vtkShaderProgram2, all ok with this. After that, i wanted to attach the >>>> shader to the actors (i'm going to use different shaders, depending on >>>> the >>>> actors). The problem is i didn't find examples or documentation to do >>>> this >>>> and i'm not capable to use the classes for the shaders correctly. >>>> >>>> I searched into the class vtkOpenGLProperty to set the vtkShaderProgram2 >>>> with the method "SetPropProgram" and i set the property of the actors >>>> with >>>> that one, but vtk shows me a warning window with a conflict between the >>>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). >>>> >>>> Can someone help me? Thanks in advance!! >>>> >>>> >>>> >>>> -- >>>> View this message in context: >>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html >>>> Sent from the VTK - Dev mailing list archive at Nabble.com. >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/vtk-developers >>>> >>> >>> >>> >>> -- >>> | Aashish Chaudhary >>> | Technical Leader >>> | Kitware Inc. >>> | http://www.kitware.com/company/team/chaudhary.html >> >> > > > > -- > | Aashish Chaudhary > | Technical Leader > | Kitware Inc. > | http://www.kitware.com/company/team/chaudhary.html > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > From carlinhosmp87 at gmail.com Wed Jul 9 04:06:18 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 9 Jul 2014 01:06:18 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> Message-ID: Thanks for your answer, i thought to use them to give my actors metallic visualization. Maybe i could use textures to show actors with that kind of visualization. Carlos. 2014-07-08 21:41 GMT+02:00 Marcus D. Hanwell-2 [via VTK] < ml-node+s1045678n5727800h40 at n5.nabble.com>: > I don't think that would be useful at this time - whilst the new > rendering code is shader based we have not yet started to add > functionality to add your own or modify our shader code. > > On Tue, Jul 8, 2014 at 3:07 PM, Aashish Chaudhary > <[hidden email] > > wrote: > > > I can reply in detail layer but on this note, you may want to use the > new > > VTK rendering code for it. Marcus or Ken hopefully reply to you on that. > > > > - Aashish > > > > > > On Tue, Jul 8, 2014 at 2:14 PM, Carlos Martinez <[hidden email] > > > > wrote: > >> > >> Thanks for your answer, i thought it wasn't the right way! > >> > >> What do you mean when you say i have to load the shaders manually? The > >> steps i'm doing are: > >> > >> 1- Create a vtkShaderProgram2 > >> 2- Create the vtkShader2 (VertexShader) and load it from the file with > >> SetSourceCode. > >> 3- Add my VertexShader to the vtkShaderProgram2 with > >> "GetShaders()->AddItem()". > >> 4- Repeat 2 and 3 with the FragmentShader. > >> 5- Build the vtkShaderProgram and check the Build Status (to check if > >> everything is ok). > >> 6- Create a vtkActor and obtain his property(with GetProperty()). > >> 7- Put ShadingOn to the property and SetPropProgram with the > >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only > the 2 > >> shaders I put in). > >> > >> When the actors are going to display into the screen, the warning > window > >> shows up and tells me that the main is defined twice (and shows me the > >> Default shaders and mine). > >> > >> Thanks again!! > >> > >> > >> 2014-07-08 18:25 GMT+02:00 Aashish Chaudhary > >> <[hidden email] >: > > >> > >>> vtkOpenGLProperty::SetPropProgram is the right function but you have > load > >>> your shaders manually now. I believe the error you are getting is > because it > >>> is still trying to use the last shader code. > >>> > >>> - Aashish > >>> > >>> > >>> > >>> On Tue, Jul 8, 2014 at 3:15 AM, carlinhos <[hidden email] > > > >>> wrote: > >>>> > >>>> Hi all, > >>>> > >>>> I'm using Vtk 6.1.0 and Qt 5.2.1 (C++) to develop my app. > >>>> > >>>> I have an assembly with different actors into a vtkRenderWindow. > >>>> > >>>> I load a shader with the class vtkShader2, and create the program > with > >>>> vtkShaderProgram2, all ok with this. After that, i wanted to attach > the > >>>> shader to the actors (i'm going to use different shaders, depending > on > >>>> the > >>>> actors). The problem is i didn't find examples or documentation to do > >>>> this > >>>> and i'm not capable to use the classes for the shaders correctly. > >>>> > >>>> I searched into the class vtkOpenGLProperty to set the > vtkShaderProgram2 > >>>> with the method "SetPropProgram" and i set the property of the actors > >>>> with > >>>> that one, but vtk shows me a warning window with a conflict between > the > >>>> default shaders and mine (total 4 shaders, 2 vertex and 2 fragment). > >>>> > >>>> Can someone help me? Thanks in advance!! > >>>> > >>>> > >>>> > >>>> -- > >>>> View this message in context: > >>>> > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788.html > >>>> Sent from the VTK - Dev mailing list archive at Nabble.com. > >>>> _______________________________________________ > >>>> Powered by www.kitware.com > >>>> > >>>> Visit other Kitware open-source projects at > >>>> http://www.kitware.com/opensource/opensource.html > >>>> > >>>> Follow this link to subscribe/unsubscribe: > >>>> http://public.kitware.com/mailman/listinfo/vtk-developers > >>>> > >>> > >>> > >>> > >>> -- > >>> | Aashish Chaudhary > >>> | Technical Leader > >>> | Kitware Inc. > >>> | http://www.kitware.com/company/team/chaudhary.html > >> > >> > > > > > > > > -- > > | Aashish Chaudhary > > | Technical Leader > > | Kitware Inc. > > | http://www.kitware.com/company/team/chaudhary.html > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727800.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727802.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Thu Jul 10 04:00:15 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Thu, 10 Jul 2014 10:00:15 +0200 Subject: [vtk-developers] ANN: VTK/ParaView Training Course in Lyon, France, September 30th & October 1st, 2014 Message-ID: Kitware will be holding a 2-day VTK and ParaView course on September 30th and October 1st, 2014 in Lyon, France. Please visit our web site for more information and registration details at either: http://training.kitware.fr/browse/24 (in English) or http://formations.kitware.fr/browse/24 (in French) Note that the course will be taught in English. If you have any question, please contact us at formations at http://www.kitware.fr Thank you, *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * -------------- next part -------------- An HTML attachment was scrubbed... URL: From iven87 at gmx.de Thu Jul 10 16:40:09 2014 From: iven87 at gmx.de (iven87 at gmx.de) Date: Thu, 10 Jul 2014 22:40:09 +0200 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL Message-ID: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Hi vtk developers, I?m trying to implement stereo rendering via quad-buffer-stereo. Unfortunately, I can?t just use the crystal eye setting in the vtkRenderWindow, because I use headtracking and thus have special model+view and projection matrices. So i need a place to implement the following logic: -set the modelview and projection matrix for the left eye -render the scene in GL_BACK_LEFT Buffer -set the modelview and projection matrix for the right eye -render the scene in GL_BACK_RIGHT Buffer I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I should override. Should I even use existing vtk stereo functionality or would it be wiser to ?just? extend monoscopic render behavior? Any tips would be greatly appreciated. Best regards, Iven -------------- next part -------------- An HTML attachment was scrubbed... URL: From aashish.chaudhary at kitware.com Thu Jul 10 16:54:20 2014 From: aashish.chaudhary at kitware.com (Aashish Chaudhary) Date: Thu, 10 Jul 2014 16:54:20 -0400 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL In-Reply-To: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> References: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Message-ID: Hi Iven, We already have a code for it in ParaView. Actually most of the classes are VTK classes so in theory we can move them to VTK. If this sounds interesting to you let me know and I can help you with the code. - Aashish On Thu, Jul 10, 2014 at 4:40 PM, wrote: > Hi vtk developers, > > I?m trying to implement stereo rendering via quad-buffer-stereo. > Unfortunately, I can?t just use the crystal eye setting in the > vtkRenderWindow, because I use headtracking and thus have special > model+view and projection matrices. > > So i need a place to implement the following logic: > -set the modelview and projection matrix for the left eye > -render the scene in GL_BACK_LEFT Buffer > -set the modelview and projection matrix for the right eye > -render the scene in GL_BACK_RIGHT Buffer > > I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, > vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I > should override. Should I even use existing vtk stereo functionality or > would it be wiser to ?just? extend monoscopic render behavior? > > Any tips would be greatly appreciated. > > Best regards, > Iven > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -- *| Aashish Chaudhary | Technical Leader | Kitware Inc. * *| http://www.kitware.com/company/team/chaudhary.html * -------------- next part -------------- An HTML attachment was scrubbed... URL: From iven87 at gmx.de Thu Jul 10 17:19:14 2014 From: iven87 at gmx.de (iven87 at gmx.de) Date: Thu, 10 Jul 2014 23:19:14 +0200 Subject: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL In-Reply-To: References: <991CD485A59E41AE8FE0CD0E2FB4982E@Subnotebook> Message-ID: Hi Aashish, that sounds good! If you can point me to relevant classes that would be great. Thanks and best regards, Iven From: Aashish Chaudhary Sent: Thursday, July 10, 2014 10:54 PM To: iven87 at gmx.de Cc: VTK Developers Subject: Re: [vtk-developers] Quad Buffer Stereo with Headtracking and OpenGL Hi Iven, We already have a code for it in ParaView. Actually most of the classes are VTK classes so in theory we can move them to VTK. If this sounds interesting to you let me know and I can help you with the code. - Aashish On Thu, Jul 10, 2014 at 4:40 PM, wrote: Hi vtk developers, I?m trying to implement stereo rendering via quad-buffer-stereo. Unfortunately, I can?t just use the crystal eye setting in the vtkRenderWindow, because I use headtracking and thus have special model+view and projection matrices. So i need a place to implement the following logic: -set the modelview and projection matrix for the left eye -render the scene in GL_BACK_LEFT Buffer -set the modelview and projection matrix for the right eye -render the scene in GL_BACK_RIGHT Buffer I?ve investigated the vtkRenderer, vtkOpenGLRenderer, vtkRenderWindow, vtkOpenGLRenderWindow, and vtkCamera. I am not sure which class/functions I should override. Should I even use existing vtk stereo functionality or would it be wiser to ?just? extend monoscopic render behavior? Any tips would be greatly appreciated. Best regards, Iven _______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Follow this link to subscribe/unsubscribe: http://public.kitware.com/mailman/listinfo/vtk-developers -- | Aashish Chaudhary | Technical Leader | Kitware Inc. | http://www.kitware.com/company/team/chaudhary.html -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Wed Jul 16 11:14:32 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 16 Jul 2014 08:14:32 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance Message-ID: <1405523672762-5727880.post@n5.nabble.com> Hello, I'm developing an app to measure the euclidean distance from a 3D point on the surface of an object to another and show the distance with a line. To accomplish that, i use *vtkLineWidget2 *with the representation associated. First time i place it , it shows correctly fit on the surface of the sphere (or any other object i place into the render window). But when i'm moving the widget from one of the handler points of the *vtkLineRepresentation *, it doesn't put the point on the surface of the sphere. The method i use sometimes work, sometimes not. I'm getting the pick every time the *vtkLineWidget2 *throws an Interaction event, and getting the 3d point of the picked position to set it to the selected handler of the *vtkLineRepresentation *. Sometimes it works, but other times, it shows the border of the *vtkLineRepresentation *in a wrong place (its correctly situated where i picked, but not on the surface of the object). It seems random to me when it works or not. I paste the code i call when the Interaction Event of the Widget is thrown. *///If the selected point is the 1st if ( state == vtkLineRepresentation::OnP1 ) { this->m_rwi->GetPicker()->Pick(m_rwi->GetLastEventPosition()[0], m_rwi->GetLastEventPosition()[1], 0, // always zero. this->m_rwi->GetRenderWindow()->GetRenderers()->GetFirstRenderer()); double picked[3]; this->m_rwi->GetPicker()->GetPickPosition(picked); lineRepresentation->SetPoint1WorldPosition(picked); } //If the selected point is the 2nd else if (state == vtkLineRepresentation::OnP2) { this->m_rwi->GetPicker()->Pick(m_rwi->GetLastEventPosition()[0], m_rwi->GetLastEventPosition()[1], 0, this->m_rwi->GetRenderWindow()->GetRenderers()->GetFirstRenderer()); double picked[3]; this->m_rwi->GetPicker()->GetPickPosition(picked); lineRepresentation->SetPoint2WorldPosition(picked); }/* Does anyone know why is not working in all the cases? Thanks in advance. -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880.html Sent from the VTK - Dev mailing list archive at Nabble.com. From dlrdave at aol.com Wed Jul 16 11:57:56 2014 From: dlrdave at aol.com (David Cole) Date: Wed, 16 Jul 2014 11:57:56 -0400 (EDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <1405523672762-5727880.post@n5.nabble.com> References: <1405523672762-5727880.post@n5.nabble.com> Message-ID: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> The documentation for "Pick" says "Return non-zero if something was successfully picked." But you are ignoring the return value of Pick. So how do you know if something was successfully picked or not? Calling GetPickPosition is only well-defined, and will only give you a good value if Pick returned non-zero..... HTH, David C From carlinhosmp87 at gmail.com Wed Jul 16 12:17:22 2014 From: carlinhosmp87 at gmail.com (Carlos Martinez) Date: Wed, 16 Jul 2014 18:17:22 +0200 Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: Hi David, Thanks for your answer but i think isn't the problem here.This is a dummy project and I'm moving the handlers only inside the area of the sphere and pick doesn't return 0 in any of the calls to the method. I checked it previously and now (just in case). I sent 3 captures: 1- First 2 clicks, the 2 white spheres are from the vtklinewidget2. 2- Wrong case (you can see the line because the points are not on the surface of the sphere). I checked it with the camera. 3- Correct case (you can't see the line between the points because they are on the surface of the sphere). I don't know what's happening here! Thanks in advance. 2014-07-16 17:57 GMT+02:00 David Cole : > The documentation for "Pick" says "Return non-zero if something was > successfully picked." > > But you are ignoring the return value of Pick. > > So how do you know if something was successfully picked or not? > > Calling GetPickPosition is only well-defined, and will only give you a > good value if Pick returned non-zero..... > > > HTH, > David C > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 1.png Type: image/png Size: 58636 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 2.png Type: image/png Size: 57843 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: 3.png Type: image/png Size: 54628 bytes Desc: not available URL: From carlinhosmp87 at gmail.com Wed Jul 16 12:22:48 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 16 Jul 2014 09:22:48 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: <1405527768358-5727883.post@n5.nabble.com> Hi David,Thanks for your answer but i think isn't the problem here.This is a dummy project and I'm moving the handlers only inside the area of the sphere and pick doesn't return 0 in any of the calls to the method. I checked it previously and now (just in case).I sent 3 captures:1- First 2 clicks, the 2 white spheres are from the vtklinewidget2. 2- Wrong case (you can see the line because the points are not on the surface of the sphere). I checked it with the camera. 3- Correct case (you can't see the line between the points because they are on the surface of the sphere). I don't know what's happening here!Thanks in advance. -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880p5727883.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Wed Jul 16 19:54:51 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Thu, 17 Jul 2014 09:54:51 +1000 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON Message-ID: What are these options and what do they do? They have appeared in the recent master. To amplify: 1) I am wondering why KITS are being brought back and how linking will work. In the case of the usual modular VTK you can, in your CMakeLists.txt file, specify a minimal set of libraries. Will this change if KITS are used? If it does, I see more problems in supporting the two different versions of VTK i.e VTK and VTK with kits, in the CMakeLists.txt files. 2) Why is there a need to specify that vtkpython and pvtkpython be built? I would have thought that once Python is selected that these are built as a matter of course. Also I see some work is being done to support Python 3. Will there be an option to select which version of Python to use? As for the tests, I think most of the tests should run in Python 3 the only tests I can think that wont are those with a print statement and this is easily fixed for both Python 2.6+/3. Regards Andrew -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Thu Jul 17 04:13:09 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Thu, 17 Jul 2014 01:13:09 -0700 (PDT) Subject: [vtk-developers] VtkLineWidget2 InteractionEvent distance In-Reply-To: References: <1405523672762-5727880.post@n5.nabble.com> <8D16F25D7D36FA1-1934-88F8@webmail-va062.sysops.aol.com> Message-ID: <1405584789439-5727886.post@n5.nabble.com> Hi all! Finally, i solved it using a vtkCellPicker explicit to get the world point where the mouse is, in case I use the picker returned by the interactor the coordinates seem wrong many times. This is the new code: *vtkSmartPointer picker = vtkSmartPointer::New(); int* clickPos = m_rwi->GetEventPosition(); if ( state == vtkLineRepresentation::OnP1 ) { if (picker->Pick(clickPos[0], clickPos[1], clickPos[2], m_renderer)) { double picked[3]; picker->GetPickPosition(picked); lineRepresentation->SetPoint1WorldPosition(picked); PrintPointsPosition(oldLineRepresentation); } }else if ( state == vtkLineRepresentation::OnP2 ) { if (picker->Pick(clickPos[0], clickPos[1], clickPos[2], m_renderer)) { double picked[3]; picker->GetPickPosition(picked); lineRepresentation->SetPoint2WorldPosition(picked); PrintPointsPosition(oldLineRepresentation); } }* Thanks to everyone!!! :) -- View this message in context: http://vtk.1045678.n5.nabble.com/VtkLineWidget2-InteractionEvent-distance-tp5727880p5727886.html Sent from the VTK - Dev mailing list archive at Nabble.com. From ben.boeckel at kitware.com Thu Jul 17 09:39:42 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 17 Jul 2014 09:39:42 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: Message-ID: <20140717133942.GA1787@megas.kitwarein.com> Hi, On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: > What are these options and what do they do? They have appeared in the recent > master. These are meant for ParaView, in two different use cases, explained below. > To amplify: > 1) I am wondering why KITS are being brought back and how linking will work. In > the case of the usual modular VTK you can, in your CMakeLists.txt file, specify > a minimal set of libraries. Will this change if KITS are used? If it does, I > see more problems in supporting the two different versions of VTK i.e VTK and > VTK with kits, in the CMakeLists.txt files. This is meant to help reduce the number of shared libraries built with ParaView. The problem is that on OS X 10.9 has too large of a library loader path (it used to be a dynamic buffer in the loader, but is now of a static size). This is triggered by either linking too many libraries or the paths to the libraries being too long. Due to the variables available with modular VTK, there should be no difference between the two (either linking directly to the target or using ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE libraries so that target linking works transparently. It is meant to be a purely internal thing and isn't necessary in the normal course of using VTK. > 2) Why is there a need to specify that vtkpython and pvtkpython be built? I > would have thought that once Python is selected that these are built as a > matter of course. This is because, in ParaView, we are looking to build a purely static build with Python and NumPy support. This brings in extra requirements when linking of Python which (p)vtkpython would need to link (e.g., ssl, crypto, util, and some others). The solution was to either turn off vtkpython in this case or to add a magic variable which ParaView sets for extra libraries (p)vtkpython needs to link to work properly. It was decided that for ParaView, turning off vtkpython makes the most sense since pvpython and pvbatch exist. > Also I see some work is being done to support Python 3. Will there be an option > to select which version of Python to use? I hope so (I'm just watching the branch for now). > As for the tests, I think most of the tests should run in Python 3 the only > tests I can think that wont are those with a print statement and this is easily > fixed for both Python 2.6+/3. Anything that catches exceptions will likely need updated as well (and the minimum version bumped as there isn't a nice way to catch an exception that isn't a syntax error in either 2.4 or 3.0 without just catching a type and asking sys.exc_info() for the actual object). Other than that, I think we just need to watch for integer division now being floating point in Python 3. --Ben From andrew.amaclean at gmail.com Thu Jul 17 19:16:17 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Fri, 18 Jul 2014 09:16:17 +1000 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: <20140717133942.GA1787@megas.kitwarein.com> References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: Thanks for the update Ben. I didn't realise that this was triggered by OSX10.9 Let me know what I can do in the way of reconfiguring the python tests so that they run on both Python 3.x and Python 2.6+. I'm happy to spend time doing this. I think you are going to have to ultimately bump up the Python version especially if we want to support Python 3. Currently I think it is 2.5 so going to 2.6 would be Ok or even 2.7!!! I remember trying to make Python code run on earlier versions by testing for the Python version, unfortunately the python interpreter seems to precompile all branches so this approach failed. I never found a solution. So this is another argument for bumping the version I see numpy supports 2.6/7 and 3.x (http://www.scipy.org/scipylib/faq.html). So I suspect those using ParaView/VTK/Numpy are already using Python 2.6/2.7. It might be an idea to put it out to the community to see who is actually using Python 2.5 or earlier with VTK 6.0 and if so would they see any problems upgrading to Python 2.7. We really should be supporting Python 3.x because that is where all the Python development is going on now and I suspect that Numpy and SciPy will be focussing their efforts there too. Regards Andrew On Thu, Jul 17, 2014 at 11:39 PM, Ben Boeckel wrote: > Hi, > > On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: > > What are these options and what do they do? They have appeared in the > recent > > master. > > These are meant for ParaView, in two different use cases, explained > below. > > > To amplify: > > 1) I am wondering why KITS are being brought back and how linking will > work. In > > the case of the usual modular VTK you can, in your CMakeLists.txt file, > specify > > a minimal set of libraries. Will this change if KITS are used? If it > does, I > > see more problems in supporting the two different versions of VTK i.e > VTK and > > VTK with kits, in the CMakeLists.txt files. > > This is meant to help reduce the number of shared libraries built with > ParaView. The problem is that on OS X 10.9 has too large of a library > loader path (it used to be a dynamic buffer in the loader, but is now of > a static size). This is triggered by either linking too many libraries > or the paths to the libraries being too long. Due to the variables > available with modular VTK, there should be no difference between the > two (either linking directly to the target or using > ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE > libraries so that target linking works transparently. > > It is meant to be a purely internal thing and isn't necessary in the > normal course of using VTK. > > > 2) Why is there a need to specify that vtkpython and pvtkpython be > built? I > > would have thought that once Python is selected that these are built as a > > matter of course. > > This is because, in ParaView, we are looking to build a purely static > build with Python and NumPy support. This brings in extra requirements > when linking of Python which (p)vtkpython would need to link (e.g., ssl, > crypto, util, and some others). The solution was to either turn off > vtkpython in this case or to add a magic variable which ParaView sets > for extra libraries (p)vtkpython needs to link to work properly. It was > decided that for ParaView, turning off vtkpython makes the most sense > since pvpython and pvbatch exist. > > > Also I see some work is being done to support Python 3. Will there be an > option > > to select which version of Python to use? > > I hope so (I'm just watching the branch for now). > > > As for the tests, I think most of the tests should run in Python 3 the > only > > tests I can think that wont are those with a print statement and this is > easily > > fixed for both Python 2.6+/3. > > Anything that catches exceptions will likely need updated as well (and > the minimum version bumped as there isn't a nice way to catch an > exception that isn't a syntax error in either 2.4 or 3.0 without just > catching a type and asking sys.exc_info() for the actual object). Other > than that, I think we just need to watch for integer division now being > floating point in Python 3. > > --Ben > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From ben.boeckel at kitware.com Thu Jul 17 21:40:42 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 17 Jul 2014 21:40:42 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: <20140718014042.GA4897@bronto-burt.dev.benboeckel.net> On Fri, Jul 18, 2014 at 09:16:17 +1000, Andrew Maclean wrote: > Let me know what I can do in the way of reconfiguring the python tests so > that they run on both Python 3.x and Python 2.6+. I'm happy to spend time > doing this. A dashboard machine would be nice :) . Preferably continuous and/or gerrit, but nightly would be a start. > I think you are going to have to ultimately bump up the Python version > especially if we want to support Python 3. Currently I think it is 2.5 so > going to 2.6 would be Ok or even 2.7!!! It is *possible* to support 2.4 through 3.3 with the same code, but here's a (almost certainly incomplete) list of things which you have to do in non-Pythonic ways: - Exception catching must be done as: catch MyException: # 'as' isn't allowed in 2.4; ',' isn't in 3.0 exc = sys.exc_info()[1] # 0 is the type, 2 the backtrace - print can't be used if you use any keyword arguments or redirections: print('%d' % bar) # use parens and format strings ostr.write('%d\n' % bar) # use the write method for redirection sys.stdout.write('4') # write to stdout directly to not get a newline - Metaclasses can't be done (the only way in 2 and 3 is a syntax error in the other). Not used much (at all?) in VTK. - No 'with' statement (2.5 has it though). > I remember trying to make Python code run on earlier versions by testing > for the Python version, unfortunately the python interpreter seems to > precompile all branches so this approach failed. I never found a solution. > So this is another argument for bumping the version Yep, a lot of issues arise from the fact that some changes are syntax errors in the other version. PyPy has a plan to support Python2 and Python3 running at the same time, but it might be a moot question by the time that ever happens. > It might be an idea to put it out to the community to see who is actually > using Python 2.5 or earlier with VTK 6.0 and if so would they see any > problems upgrading to Python 2.7. RHEL5 ships with 2.4 and is probably still floating around in some places. 2.6 is available, but not from Red Hat (it's in EPEL). Other than that, 2.6 is probably a safe bet. 2.7 is becoming more common as well. > We really should be supporting Python 3.x because that is where all the > Python development is going on now and I suspect that Numpy and SciPy will > be focussing their efforts there too. I've had performance issues in Python3 (as in significantly worse than Python2) in other, non-VTK projects (mainly regex-related), but I don't know how many of VTK's use cases are affected. It's something to keep an eye out for though. --Ben From dave.demarle at kitware.com Thu Jul 17 21:40:58 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 17 Jul 2014 21:40:58 -0400 Subject: [vtk-developers] VTK_ENABLE_KITS and VTK_ENABLE_VTKPYTHON In-Reply-To: References: <20140717133942.GA1787@megas.kitwarein.com> Message-ID: FYI http://markmail.org/thread/6fybkjbz5xpr3qt7 Is the email thread from the last time we talked about the VTK's minimum python version. David E DeMarle Kitware, Inc. R&D Engineer 21 Corporate Drive Clifton Park, NY 12065-8662 Phone: 518-881-4909 On Thu, Jul 17, 2014 at 7:16 PM, Andrew Maclean wrote: > Thanks for the update Ben. > > I didn't realise that this was triggered by OSX10.9 > > Let me know what I can do in the way of reconfiguring the python tests so > that they run on both Python 3.x and Python 2.6+. I'm happy to spend time > doing this. > > I think you are going to have to ultimately bump up the Python version > especially if we want to support Python 3. Currently I think it is 2.5 so > going to 2.6 would be Ok or even 2.7!!! > > I remember trying to make Python code run on earlier versions by testing > for the Python version, unfortunately the python interpreter seems to > precompile all branches so this approach failed. I never found a solution. > So this is another argument for bumping the version > > I see numpy supports 2.6/7 and 3.x (http://www.scipy.org/scipylib/faq.html). > So I suspect those using ParaView/VTK/Numpy are already using Python > 2.6/2.7. > > It might be an idea to put it out to the community to see who is actually > using Python 2.5 or earlier with VTK 6.0 and if so would they see any > problems upgrading to Python 2.7. > > We really should be supporting Python 3.x because that is where all the > Python development is going on now and I suspect that Numpy and SciPy will > be focussing their efforts there too. > > Regards > Andrew > > > On Thu, Jul 17, 2014 at 11:39 PM, Ben Boeckel > wrote: > >> Hi, >> >> On Thu, Jul 17, 2014 at 09:54:51 +1000, Andrew Maclean wrote: >> > What are these options and what do they do? They have appeared in the >> recent >> > master. >> >> These are meant for ParaView, in two different use cases, explained >> below. >> >> > To amplify: >> > 1) I am wondering why KITS are being brought back and how linking will >> work. In >> > the case of the usual modular VTK you can, in your CMakeLists.txt file, >> specify >> > a minimal set of libraries. Will this change if KITS are used? If it >> does, I >> > see more problems in supporting the two different versions of VTK i.e >> VTK and >> > VTK with kits, in the CMakeLists.txt files. >> >> This is meant to help reduce the number of shared libraries built with >> ParaView. The problem is that on OS X 10.9 has too large of a library >> loader path (it used to be a dynamic buffer in the loader, but is now of >> a static size). This is triggered by either linking too many libraries >> or the paths to the libraries being too long. Due to the variables >> available with modular VTK, there should be no difference between the >> two (either linking directly to the target or using >> ${vtk-module}_LIBRARIES). It also requires CMake 3.0 for INTERFACE >> libraries so that target linking works transparently. >> >> It is meant to be a purely internal thing and isn't necessary in the >> normal course of using VTK. >> >> > 2) Why is there a need to specify that vtkpython and pvtkpython be >> built? I >> > would have thought that once Python is selected that these are built as >> a >> > matter of course. >> >> This is because, in ParaView, we are looking to build a purely static >> build with Python and NumPy support. This brings in extra requirements >> when linking of Python which (p)vtkpython would need to link (e.g., ssl, >> crypto, util, and some others). The solution was to either turn off >> vtkpython in this case or to add a magic variable which ParaView sets >> for extra libraries (p)vtkpython needs to link to work properly. It was >> decided that for ParaView, turning off vtkpython makes the most sense >> since pvpython and pvbatch exist. >> >> > Also I see some work is being done to support Python 3. Will there be >> an option >> > to select which version of Python to use? >> >> I hope so (I'm just watching the branch for now). >> >> > As for the tests, I think most of the tests should run in Python 3 the >> only >> > tests I can think that wont are those with a print statement and this >> is easily >> > fixed for both Python 2.6+/3. >> >> Anything that catches exceptions will likely need updated as well (and >> the minimum version bumped as there isn't a nice way to catch an >> exception that isn't a syntax error in either 2.4 or 3.0 without just >> catching a type and asking sys.exc_info() for the actual object). Other >> than that, I think we just need to watch for integer division now being >> floating point in Python 3. >> >> --Ben >> > > > > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Fri Jul 18 05:03:05 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Fri, 18 Jul 2014 02:03:05 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: <1405669583385-5727903.post@n5.nabble.com> References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Hello Xiaoming, I created a new vtkOpenGLProperty and set it to the actor, anyways i tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), because vtkProperty is an abstract class. I tried so many things to make it work but i didn't manage to do it. Also i tried to use vtkOpenGLActors instead of vtkActors but it also didn't work. Carlos. 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] < ml-node+s1045678n5727903h33 at n5.nabble.com>: > i'm sorry but i see that vtkActor::GetProperty() returns a pointer to the > vtkProperty not vtkOpenGLProperty,which has a member of SetPropProgram,i 'm > just confused with the 7th step,would you bother to tell me sth about that > ,thanks in advance. > Quote: > < 7- Put ShadingOn to the property and SetPropProgram with the > vtkShaderProgram2 build before (The vtkShaderProgram on debug has only the > 2 shaders I put in).> > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727905.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From akshaya.r15 at gmail.com Sat Jul 19 06:11:04 2014 From: akshaya.r15 at gmail.com (Akshaya Ramaswamy) Date: Sat, 19 Jul 2014 15:41:04 +0530 Subject: [vtk-developers] Plotting a graph to scale Message-ID: Hi all, I have a 2d graph where the x and y coordinates are in millimeters. Is it possible to plot this graph to scale using vtk? Thanks and regards, Akshaya -------------- next part -------------- An HTML attachment was scrubbed... URL: From akshaya.r15 at gmail.com Sat Jul 19 06:11:56 2014 From: akshaya.r15 at gmail.com (Akshaya Ramaswamy) Date: Sat, 19 Jul 2014 15:41:56 +0530 Subject: [vtk-developers] Rendering a 3d plot at a certain view Message-ID: Hi all, I am facing problem in adjusting the view of a 3d plot. I am able to render a 3d plot using VTK, but i am not able to set the correct view for the plot. Basically, I need to adjust the azimuth and elevation angles, but somehow adjusting these parameters of vtkcamera class does not give the desired results. I am unable to understand how the view changes based on the angle change. Could somebody explain how this works? Thanks and regards, Akshaya -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Sun Jul 20 03:21:03 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Sun, 20 Jul 2014 17:21:03 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. Message-ID: I wanted to generate a lookup table from vtkCOlor series using BuildLookupTable(). However the only way I can do it is to create a second lookup table and copy from the first to the second one. I thought I could do this: colorSeries = vtk.vtkColorSeries() colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 colorSeries.SetColorScheme(colorSeriesEnum) lut = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut) But I have to do this: colorSeries = vtk.vtkColorSeries() colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 colorSeries.SetColorScheme(colorSeriesEnum) lut1 = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut1) lut = vtk.vtkLookupTable() lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) for i in range(0,lut1.GetNumberOfTableValues()): lut.SetTableValue(i,lut1.GetTableValue(i)) In looking at the code in vtkColorSeries.cxx, namely: //----------------------------------------------------------------------------- void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) { if (lkup) { lkup->SetNumberOfTableValues(this->GetNumberOfColors()); lkup->IndexedLookupOn(); for (int i = 0; i < this->GetNumberOfColors(); ++i) { vtkColor3ub colr = this->GetColor(i); lkup->SetTableValue( i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., 1.); } } } It seems lkup is built correctly. I can't see any reason for building and then copying to a new table. I would appreciate it if anyone could point out what I am missing. I have also attached a Python script that illustrates this. Regards Andrew -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: ColorSeries.zip Type: application/zip Size: 1344 bytes Desc: not available URL: From andrew.amaclean at gmail.com Sun Jul 20 20:23:52 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Mon, 21 Jul 2014 10:23:52 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: Just to add to this, I get the same result in C++. On Sun, Jul 20, 2014 at 5:21 PM, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using > BuildLookupTable(). > However the only way I can do it is to create a second lookup table and > copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., > 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Mon Jul 21 01:08:49 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Mon, 21 Jul 2014 15:08:49 +1000 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: I have found the problem. It lies in line 576 of vtkColorSeries.cxx: lkup->IndexedLookupOn(); in vtkColorSeries.cxx. This means that any lookup table has this set when returned from BuildLookupTable() or CreateLookupTable() The default value is off so this behaviour is unexpected. I am wondering whether this line should be removed and the tests should explicitly set this when needed. If this is too much then an alternative would be to add a comment. Any comments? I'll do any changes and test them. On Sun, Jul 20, 2014 at 5:21 PM, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using > BuildLookupTable(). > However the only way I can do it is to create a second lookup table and > copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., > 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.thompson at kitware.com Mon Jul 21 08:03:47 2014 From: david.thompson at kitware.com (David Thompson) Date: Mon, 21 Jul 2014 06:03:47 -0600 Subject: [vtk-developers] Interesting problem building a vtkLookupTable from vtkColorSeries. In-Reply-To: References: Message-ID: <56B57A36-07FA-4BC0-910E-D678BC0C583E@kitware.com> Hi Andrew, Have you tried IndexedLookupOff, i.e. lut = vtk.vtkLookupTable() colorSeries.BuildLookupTable(lut) lut.IndexedLookupOff() on the first lookup table? David On Jul 20, 2014, at 1:21, Andrew Maclean wrote: > I wanted to generate a lookup table from vtkCOlor series using BuildLookupTable(). > However the only way I can do it is to create a second lookup table and copy from the first to the second one. > I thought I could do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut) > > But I have to do this: > colorSeries = vtk.vtkColorSeries() > colorSeriesEnum = colorSeries.BREWER_DIVERGING_BROWN_BLUE_GREEN_10 > colorSeries.SetColorScheme(colorSeriesEnum) > lut1 = vtk.vtkLookupTable() > colorSeries.BuildLookupTable(lut1) > lut = vtk.vtkLookupTable() > lut.SetNumberOfTableValues(lut1.GetNumberOfTableValues()) > for i in range(0,lut1.GetNumberOfTableValues()): > lut.SetTableValue(i,lut1.GetTableValue(i)) > > In looking at the code in vtkColorSeries.cxx, namely: > //----------------------------------------------------------------------------- > void vtkColorSeries::BuildLookupTable(vtkLookupTable* lkup) > { > if (lkup) > { > lkup->SetNumberOfTableValues(this->GetNumberOfColors()); > lkup->IndexedLookupOn(); > for (int i = 0; i < this->GetNumberOfColors(); ++i) > { > vtkColor3ub colr = this->GetColor(i); > lkup->SetTableValue( > i, colr.GetRed()/255., colr.GetGreen()/255., colr.GetBlue()/255., 1.); > } > } > } > It seems lkup is built correctly. > > I can't see any reason for building and then copying to a new table. > > I would appreciate it if anyone could point out what I am missing. > > I have also attached a Python script that illustrates this. > > Regards > Andrew > -- > ___________________________________________ > Andrew J. P. Maclean > > ___________________________________________ > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > From dlrdave at aol.com Thu Jul 24 12:59:45 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 12:59:45 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test Message-ID: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> This code from the VTK Wiki examples ( http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails everywhere: http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 with: "Required arguments: Filename" What should the strategy be for an example that requires a filename, but does not have a default value built into its code...? Add a default file somehow? Avoid running it as a test on the dashboard? Something else? Thanks, David C. From bill.lorensen at gmail.com Thu Jul 24 13:25:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Thu, 24 Jul 2014 13:25:03 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: This is a strange example. I cannot find a VRML file that works with this example. I'll see if it can be repaired... On Thu, Jul 24, 2014 at 12:59 PM, David Cole via vtk-developers wrote: > This code from the VTK Wiki examples ( > http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails > everywhere: > http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 > > with: > "Required arguments: Filename" > > What should the strategy be for an example that requires a filename, but > does not have a default value built into its code...? > > Add a default file somehow? > Avoid running it as a test on the dashboard? > Something else? > > Thanks, > David C. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From christopher.mullins at kitware.com Thu Jul 24 13:28:12 2014 From: christopher.mullins at kitware.com (Christopher Mullins) Date: Thu, 24 Jul 2014 13:28:12 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: I spent some time cleaning these up and couldn't find a file for it either. bridge.wrl gives me a segfault. I'll try to find some time to put my fixes in the wiki soon, there are a number of examples that could use links to example files if I recall. On Thu, Jul 24, 2014 at 1:25 PM, Bill Lorensen wrote: > This is a strange example. I cannot find a VRML file that works with > this example. I'll see if it can be repaired... > > On Thu, Jul 24, 2014 at 12:59 PM, David Cole via vtk-developers > wrote: > > This code from the VTK Wiki examples ( > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/IO/IndividualVRML ) fails > > everywhere: > > > http://open.cdash.org/testSummary.php?project=32&name=IO-IndividualVRML&date=2014-07-24 > > > > with: > > "Required arguments: Filename" > > > > What should the strategy be for an example that requires a filename, but > > does not have a default value built into its code...? > > > > Add a default file somehow? > > Avoid running it as a test on the dashboard? > > Something else? > > > > Thanks, > > David C. > > > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > > http://www.kitware.com/opensource/opensource.html > > > > Follow this link to subscribe/unsubscribe: > > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -- Christopher Mullins R&D Engineer Kitware Inc., 919.869.8871 -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlrdave at aol.com Thu Jul 24 13:50:41 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 13:50:41 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: <8D1757EEB759265-948-264D0@webmail-vm059.sysops.aol.com> Cool -- thanks guys. FYI -- this one fails everywhere too: http://open.cdash.org/testSummary.php?project=32&name=Visualization-CorrectlyRenderTranslucentGeometry&date=2014-07-24 From ben.boeckel at kitware.com Thu Jul 24 15:10:16 2014 From: ben.boeckel at kitware.com (Ben Boeckel) Date: Thu, 24 Jul 2014 15:10:16 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> Message-ID: <20140724191016.GA14211@megas.kitwarein.com> On Thu, Jul 24, 2014 at 12:59:45 -0400, David Cole via vtk-developers wrote: > What should the strategy be for an example that requires a filename, > but does not have a default value built into its code...? If you're using vtk_add_test_*, setting ${name}_ARGS before calling it should be sufficient. --Ben From dlrdave at aol.com Thu Jul 24 16:25:24 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 24 Jul 2014 16:25:24 -0400 (EDT) Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <20140724191016.GA14211@megas.kitwarein.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> Message-ID: <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> >> What should the strategy be for an example that requires a filename, >> but does not have a default value built into its code...? > If you're using vtk_add_test_*, setting ${name}_ARGS before calling it > should be sufficient. The wiki examples have their own dashboard, that run from this git repo: https://gitorious.org/vtkwikiexamples They build against VTK using find_package for VTK, so as far as I know, they can't call vtk_add_test_* -- they should build against a build tree or an install tree of VTK, and they work with VTK 5 and VTK 6. The (still separate) dashboard for them is here: http://open.cdash.org/index.php?project=VTKWikiExamples D From bill.lorensen at gmail.com Thu Jul 24 16:52:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Thu, 24 Jul 2014 16:52:03 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: The examples have their own way of specifying test args in the cmake lists that exist in a full checkout of the examples. Each example directory has a cmake lists file that controls the testing. This is somewhat explained here: http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers wrote: >>> What should the strategy be for an example that requires a filename, >>> but does not have a default value built into its code...? > > >> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it >> should be sufficient. > > > The wiki examples have their own dashboard, that run from this git repo: > https://gitorious.org/vtkwikiexamples > > They build against VTK using find_package for VTK, so as far as I know, they > can't call vtk_add_test_* -- they should build against a build tree or an > install tree of VTK, and they work with VTK 5 and VTK 6. > > The (still separate) dashboard for them is here: > http://open.cdash.org/index.php?project=VTKWikiExamples > > > D > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Jul 25 09:16:16 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 09:16:16 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: I have a working vrml file. I'll update the example and file later today. On Thu, Jul 24, 2014 at 4:52 PM, Bill Lorensen wrote: > The examples have their own way of specifying test args in the cmake > lists that exist in a full checkout of the examples. > Each example directory has a cmake lists file that controls the testing. > > This is somewhat explained here: > http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators > > > On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers > wrote: >>>> What should the strategy be for an example that requires a filename, >>>> but does not have a default value built into its code...? >> >> >>> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it >>> should be sufficient. >> >> >> The wiki examples have their own dashboard, that run from this git repo: >> https://gitorious.org/vtkwikiexamples >> >> They build against VTK using find_package for VTK, so as far as I know, they >> can't call vtk_add_test_* -- they should build against a build tree or an >> install tree of VTK, and they work with VTK 5 and VTK 6. >> >> The (still separate) dashboard for them is here: >> http://open.cdash.org/index.php?project=VTKWikiExamples >> >> >> D >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> > > > > -- > Unpaid intern in BillsBasement at noware dot com -- Unpaid intern in BillsBasement at noware dot com From christopher.mullins at kitware.com Fri Jul 25 09:18:34 2014 From: christopher.mullins at kitware.com (Christopher Mullins) Date: Fri, 25 Jul 2014 09:18:34 -0400 Subject: [vtk-developers] Failing VTK Wiki example test In-Reply-To: References: <8D17577CE12BB7B-948-25D14@webmail-vm059.sysops.aol.com> <20140724191016.GA14211@megas.kitwarein.com> <8D17594887E1164-948-2783E@webmail-vm059.sysops.aol.com> Message-ID: Thanks Bill! On Jul 25, 2014 9:16 AM, "Bill Lorensen" wrote: > I have a working vrml file. I'll update the example and file later today. > > > On Thu, Jul 24, 2014 at 4:52 PM, Bill Lorensen > wrote: > > The examples have their own way of specifying test args in the cmake > > lists that exist in a full checkout of the examples. > > Each example directory has a cmake lists file that controls the testing. > > > > This is somewhat explained here: > > http://www.vtk.org/Wiki/VTK/Examples/Instructions/ForAdministrators > > > > > > On Thu, Jul 24, 2014 at 4:25 PM, David Cole via vtk-developers > > wrote: > >>>> What should the strategy be for an example that requires a filename, > >>>> but does not have a default value built into its code...? > >> > >> > >>> If you're using vtk_add_test_*, setting ${name}_ARGS before calling it > >>> should be sufficient. > >> > >> > >> The wiki examples have their own dashboard, that run from this git repo: > >> https://gitorious.org/vtkwikiexamples > >> > >> They build against VTK using find_package for VTK, so as far as I know, > they > >> can't call vtk_add_test_* -- they should build against a build tree or > an > >> install tree of VTK, and they work with VTK 5 and VTK 6. > >> > >> The (still separate) dashboard for them is here: > >> http://open.cdash.org/index.php?project=VTKWikiExamples > >> > >> > >> D > >> > >> _______________________________________________ > >> Powered by www.kitware.com > >> > >> Visit other Kitware open-source projects at > >> http://www.kitware.com/opensource/opensource.html > >> > >> Follow this link to subscribe/unsubscribe: > >> http://public.kitware.com/mailman/listinfo/vtk-developers > >> > > > > > > > > -- > > Unpaid intern in BillsBasement at noware dot com > > > > -- > Unpaid intern in BillsBasement at noware dot com > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From dlrdave at aol.com Fri Jul 25 15:36:06 2014 From: dlrdave at aol.com (David Cole) Date: Fri, 25 Jul 2014 15:36:06 -0400 (EDT) Subject: [vtk-developers] vtkDelimitedTextWriter needs some testing love Message-ID: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> I "fixed" the Windows dashboard crash for this wiki example (I think... -- we'll find out for sure tomorrow): http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/DelimitedTextWriter In doing so, I've noticed there are literally no tests for vtkDelimitedTextWriter in the VTK source tree. Does anybody have some bandwidth to submit a Gerrit patch that adds a test for vtkDelimitedTextWriter? Thanks, David C. From dlrdave at aol.com Fri Jul 25 15:48:40 2014 From: dlrdave at aol.com (David Cole) Date: Fri, 25 Jul 2014 15:48:40 -0400 (EDT) Subject: [vtk-developers] VTK wiki example FullScreen Message-ID: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Hey Bill L., This one: http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen produces output like this on my machine (which has a different full screen size than yours...): Image differencing failed to produce an image because images are different size: Valid image: 1279, 1023, 0 Test image: 1431, 828, 0 Seems like this one should not be a test that "fails" due to different image size. How should we fix it? Thanks, D From bill.lorensen at gmail.com Fri Jul 25 15:52:03 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 15:52:03 -0400 Subject: [vtk-developers] vtkDelimitedTextWriter needs some testing love In-Reply-To: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> References: <8D17656D00190B2-81C-2C431@webmail-d223.sysops.aol.com> Message-ID: David (elbow man), You are correct. Only smoke test coverage: http://lorensen.github.io/VTKCodeCoverage/VTK/IO/Core/vtkDelimitedTextWriter.cxx.gcov.html Bill On Fri, Jul 25, 2014 at 3:36 PM, David Cole via vtk-developers wrote: > I "fixed" the Windows dashboard crash for this wiki example (I think... -- > we'll find out for sure tomorrow): > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/DelimitedTextWriter > > In doing so, I've noticed there are literally no tests for > vtkDelimitedTextWriter in the VTK source tree. > > Does anybody have some bandwidth to submit a Gerrit patch that adds a test > for vtkDelimitedTextWriter? > > > Thanks, > David C. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > -- Unpaid intern in BillsBasement at noware dot com From bill.lorensen at gmail.com Fri Jul 25 15:53:08 2014 From: bill.lorensen at gmail.com (Bill Lorensen) Date: Fri, 25 Jul 2014 15:53:08 -0400 Subject: [vtk-developers] VTK wiki example FullScreen In-Reply-To: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> References: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Message-ID: Agree. Need to ponder. On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > Hey Bill L., > > This one: > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > produces output like this on my machine (which has a different full screen > size than yours...): > > Image differencing failed to produce an image because images are different > size: > Valid image: 1279, 1023, 0 > Test image: 1431, 828, 0 > > Seems like this one should not be a test that "fails" due to different image > size. > > How should we fix it? > > > Thanks, > D > -- Unpaid intern in BillsBasement at noware dot com From dlrdave at aol.com Mon Jul 28 08:26:23 2014 From: dlrdave at aol.com (David Cole) Date: Mon, 28 Jul 2014 08:26:23 -0400 (EDT) Subject: [vtk-developers] VTK Wiki example using vtkFrustumSource Message-ID: <8D1787646D90445-B88-B81@webmail-m270.sysops.aol.com> This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/Frustum uses vtkFrustumSource to visualize the view frustum from a vtkCamera object. The example's test was failing on my Windows Debug dashboard because the vtkFrustumSource defaults to "ShowLines" ON, and when ShowLines is on, there are extra points added to the polydata output.... but the coordinate values of those points are never set, and so the geometric data is undefined, resulting in ridiculous bounds values in the Debug build. (Thanks to the Microsoft compiler's forced-crazy-value-initialization of uninitialized stuff...) The code in question is here: http://vtk.org/gitweb?p=VTK.git;a=blob;f=Filters/Sources/vtkFrustumSource.cxx;h=7803ece7810d3cce76efd5f2d83e8099f1973a87;hb=refs/heads/master#l146 (5 extra points are added, but point ID values 8, 9, 10, 11, and 12 are never set, even though they *are* referenced later on...) So: does anybody here know what the extra points are supposed to be set to? If so, could you submit a gerrit patch? If not, could we remove the extra points from the output since they're not well defined...? I "fixed" the example for now by setting ShowLines to OFF. Thanks, David C. From joachim.pouderoux at kitware.com Tue Jul 29 08:55:46 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 29 Jul 2014 14:55:46 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I might have fixed. I will make a patch soon. In the meanwhile try to change those lines: needDefaultMainVS = !progHasVertex && propProg->HasVertexShaders(); needDefaultMainFS = !progHasFragment && propProg->HasFragmentShaders(); by needDefaultMainVS = !progHasVertex && !propProg->HasVertexShaders(); needDefaultMainFS = !progHasFragment && !propProg->HasFragmentShaders(); With that fixed, the steps you defined should now work as no second main() will be added to both shader code. Joachim *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2014-07-18 11:03 GMT+02:00 carlinhos : > Hello Xiaoming, > > I created a new vtkOpenGLProperty and set it to the actor, anyways i tried > to cast the vtkProperty obtained by the a vtkActor::GetProperty(), > because vtkProperty is an abstract class. I tried so many things to make it > work but i didn't manage to do it. Also i tried to use vtkOpenGLActors > instead of vtkActors but it also didn't work. > > Carlos. > > > 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] > >: > >> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to the >> vtkProperty not vtkOpenGLProperty,which has a member of SetPropProgram,i 'm >> just confused with the 7th step,would you bother to tell me sth about that >> ,thanks in advance. >> Quote: >> < 7- Put ShadingOn to the property and SetPropProgram with the >> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >> the >> 2 shaders I put in).> >> >> >> >> ------------------------------ >> If you reply to this email, your message will be added to the >> discussion below: >> >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >> here. >> NAML >> >> > > > ------------------------------ > View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 and > Qt 5.2.1) > > Sent from the VTK - Dev mailing list archive > at Nabble.com. > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From joachim.pouderoux at kitware.com Tue Jul 29 09:13:39 2014 From: joachim.pouderoux at kitware.com (Joachim Pouderoux) Date: Tue, 29 Jul 2014 15:13:39 +0200 Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Carlos Ok actually I was wrong. My patch works but it is not how this is supposed to happen. Basically, VTK will merge 2 different shader source code to define each type of shader (vertex, fragment etc.). A first source will come from the shader code that can be attached to the renderer shaders. If it not exist, the default is a main function that will call propFuncVS()/propFuncFS() etc - depending the shader type. The second source will come from the shader code that can be attached to the actor's property. If it not exist, the default behaviour is to define that propFuncVS/FS functions. Both source codes will be appended before being compiled by the openGlProperty. So basically if you do not define a renderer shader program, you simply have to provide a shader codes to your property that defines propFuncVS/FS functions instead of usual main() functions. Also do not build your shader program (program->Build()) in your code as it will fail because the main() functions are not provided. Remember they will be added later automatically before compilation by OpenGLProperty. Hope it is clear and it helps! Best, *Joachim Pouderoux* *PhD, Technical Expert* *Kitware SAS * 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux : > Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I > might have fixed. I will make a patch soon. > In the meanwhile try to change those lines: > > > needDefaultMainVS = !progHasVertex > && propProg->HasVertexShaders(); > needDefaultMainFS = !progHasFragment > && propProg->HasFragmentShaders(); > > by > > needDefaultMainVS = !progHasVertex > && !propProg->HasVertexShaders(); > needDefaultMainFS = !progHasFragment > && !propProg->HasFragmentShaders(); > > With that fixed, the steps you defined should now work as no second main() > will be added to both shader code. > > Joachim > > *Joachim Pouderoux* > > *PhD, Technical Expert* > *Kitware SAS * > > > > 2014-07-18 11:03 GMT+02:00 carlinhos : > >> Hello Xiaoming, >> >> I created a new vtkOpenGLProperty and set it to the actor, anyways i >> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >> because vtkProperty is an abstract class. I tried so many things to make it >> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >> instead of vtkActors but it also didn't work. >> >> Carlos. >> >> >> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >> >: >> >>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>> the vtkProperty not vtkOpenGLProperty,which has a member of >>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>> tell me sth about that ,thanks in advance. >>> Quote: >>> < 7- Put ShadingOn to the property and SetPropProgram with the >>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>> the >>> 2 shaders I put in).> >>> >>> >>> >>> ------------------------------ >>> If you reply to this email, your message will be added to the >>> discussion below: >>> >>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>> here. >>> NAML >>> >>> >> >> >> ------------------------------ >> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 and >> Qt 5.2.1) >> >> Sent from the VTK - Dev mailing list archive >> at Nabble.com. >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Tue Jul 29 15:48:54 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Tue, 29 Jul 2014 12:48:54 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Joachim, Thank you so much for the explanation, I tried something similar but building the shaders instead of not doing it (if I remember well). Tomorrow i will try it and I will tell you the results!! Carlos. 2014-07-29 15:14 GMT+02:00 Joachim Pouderoux [via VTK] < ml-node+s1045678n5728004h64 at n5.nabble.com>: > Carlos > > Ok actually I was wrong. My patch works but it is not how this is supposed > to happen. > Basically, VTK will merge 2 different shader source code to define each > type of shader (vertex, fragment etc.). > A first source will come from the shader code that can be attached to the > renderer shaders. > If it not exist, the default is a main function that will call > propFuncVS()/propFuncFS() etc - depending the shader type. > The second source will come from the shader code that can be attached to > the actor's property. > If it not exist, the default behaviour is to define that propFuncVS/FS > functions. > Both source codes will be appended before being compiled by the > openGlProperty. > > So basically if you do not define a renderer shader program, you simply > have to provide a shader codes to your property that defines propFuncVS/FS > functions instead of usual main() functions. > Also do not build your shader program (program->Build()) in your code as > it will fail because the main() functions are not provided. Remember they > will be added later automatically before compilation by OpenGLProperty. > > Hope it is clear and it helps! > > Best, > > > > *Joachim Pouderoux* > > *PhD, Technical Expert* > *Kitware SAS * > > > > 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux <[hidden email] > >: > >> Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I >> might have fixed. I will make a patch soon. >> In the meanwhile try to change those lines: >> >> >> needDefaultMainVS = !progHasVertex >> && propProg->HasVertexShaders(); >> needDefaultMainFS = !progHasFragment >> && propProg->HasFragmentShaders(); >> >> by >> >> needDefaultMainVS = !progHasVertex >> && !propProg->HasVertexShaders(); >> needDefaultMainFS = !progHasFragment >> && !propProg->HasFragmentShaders(); >> >> With that fixed, the steps you defined should now work as no second >> main() will be added to both shader code. >> >> Joachim >> >> *Joachim Pouderoux* >> >> *PhD, Technical Expert* >> *Kitware SAS * >> >> >> >> 2014-07-18 11:03 GMT+02:00 carlinhos <[hidden email] >> >: >> >> Hello Xiaoming, >>> >>> I created a new vtkOpenGLProperty and set it to the actor, anyways i >>> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >>> because vtkProperty is an abstract class. I tried so many things to make it >>> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >>> instead of vtkActors but it also didn't work. >>> >>> Carlos. >>> >>> >>> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >>> >: >>> >>>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>>> the vtkProperty not vtkOpenGLProperty,which has a member of >>>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>>> tell me sth about that ,thanks in advance. >>>> Quote: >>>> < 7- Put ShadingOn to the property and SetPropProgram with the >>>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>>> the >>>> 2 shaders I put in).> >>>> >>>> >>>> >>>> ------------------------------ >>>> If you reply to this email, your message will be added to the >>>> discussion below: >>>> >>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>>> here. >>>> NAML >>>> >>>> >>> >>> >>> ------------------------------ >>> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 >>> and Qt 5.2.1) >>> >>> Sent from the VTK - Dev mailing list archive >>> at Nabble.com. >>> >>> _______________________________________________ >>> Powered by www.kitware.com >>> >>> Visit other Kitware open-source projects at >>> http://www.kitware.com/opensource/opensource.html >>> >>> Follow this link to subscribe/unsubscribe: >>> http://public.kitware.com/mailman/listinfo/vtk-developers >>> >>> >>> >> > > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728004.html > To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click > here > > . > NAML > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728009.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Tue Jul 29 18:49:55 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Wed, 30 Jul 2014 08:49:55 +1000 Subject: [vtk-developers] vtk-developers Digest, Vol 123, Issue 11 In-Reply-To: References: Message-ID: Bill. David, I have has the same issue, the test image should be 800X800 however Bill's machine generates a 800?771 image so the test always fails. Bill and I had some discussion on it but as to why it happens we don't know. See: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/ParametricObjectsDemo Regards Andrew > > ---------- Forwarded message ---------- > From: Bill Lorensen > To: David Cole > Cc: VTK Developers > Date: Fri, 25 Jul 2014 15:53:08 -0400 > Subject: Re: [vtk-developers] VTK wiki example FullScreen > Agree. Need to ponder. > > > On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > > Hey Bill L., > > > > This one: > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > > > produces output like this on my machine (which has a different full > screen > > size than yours...): > > > > Image differencing failed to produce an image because images are > different > > size: > > Valid image: 1279, 1023, 0 > > Test image: 1431, 828, 0 > > > > Seems like this one should not be a test that "fails" due to different > image > > size. > > > > How should we fix it? > > > > > > Thanks, > > D > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > > > >> -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.amaclean at gmail.com Tue Jul 29 19:39:26 2014 From: andrew.amaclean at gmail.com (Andrew Maclean) Date: Wed, 30 Jul 2014 09:39:26 +1000 Subject: [vtk-developers] VTK wiki example FullScreen Message-ID: Bill. David, I have has the same issue, for ParametricObjectsDemo, the test image should be 800X800 however Bill's machine generates an 800?771 image so the test always fails. Bill and I had some discussion on it but as to why it happens we don't know. See: http://www.vtk.org/Wiki/VTK/Examples/Cxx/GeometricObjects/ParametricObjectsDemo Regards Andrew > > ---------- Forwarded message ---------- > From: Bill Lorensen > To: David Cole > Cc: VTK Developers > Date: Fri, 25 Jul 2014 15:53:08 -0400 > Subject: Re: [vtk-developers] VTK wiki example FullScreen > Agree. Need to ponder. > > > On Fri, Jul 25, 2014 at 3:48 PM, David Cole wrote: > > Hey Bill L., > > > > This one: > > http://www.vtk.org/Wiki/VTK/Examples/Cxx/Utilities/FullScreen > > > > produces output like this on my machine (which has a different full > screen > > size than yours...): > > > > Image differencing failed to produce an image because images are > different > > size: > > Valid image: 1279, 1023, 0 > > Test image: 1431, 828, 0 > > > > Seems like this one should not be a test that "fails" due to different > image > > size. > > > > How should we fix it? > > > > > > Thanks, > > D > > > > > > -- > Unpaid intern in BillsBasement at noware dot com > > > >> -- ___________________________________________ Andrew J. P. Maclean ___________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: From carlinhosmp87 at gmail.com Wed Jul 30 09:40:52 2014 From: carlinhosmp87 at gmail.com (carlinhos) Date: Wed, 30 Jul 2014 06:40:52 -0700 (PDT) Subject: [vtk-developers] GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1) In-Reply-To: References: <1404803727578-5727788.post@n5.nabble.com> <1405669583385-5727903.post@n5.nabble.com> Message-ID: Hello Joachim! I did it, it was the right way to do it :). Thank you so much for your explanation. I resume the steps for everyone: 0- Create a shader file with the function *propFuncFS**(Fragment shader)* * or **propFuncVS(Vertex shader).* 1- Load the shader from disk. 2- Create a vtkShader2 and set the source code. 3- Create a vtkShaderProgram2 and initialize it (DO NOT BUILD THE PROGRAM). 4- Add the shader to the program. 5- Obtain the actor vtkOpenGLProperty and set the program 6- Set the shading on. Code: > *QFile fragmentFile(QStringLiteral("C:/myfragmentshader"));* > * fragmentFile.open(QIODevice::ReadOnly);* > * auto fragmentBytes = fragmentFile.readAll();* > * fragmentFile.close();** QString fragmentShaderSource(fragmentBytes);* > > * //The GLSL binded program* > * vtkSmartPointer program = > vtkSmartPointer::New();* > * // Prepare the fragment shader* > * vtkSmartPointer shader = vtkSmartPointer::New();* > * shader->SetType(VTK_SHADER_TYPE_FRAGMENT);** > shader->SetSourceCode(fragmentShaderSource.toStdString().c_str());* > * program->GetShaders()->AddItem(shader);* > > * vtkSmartPointer openGLproperty = > static_cast(gemActor->GetProperty());* > * openGLproperty->SetPropProgram(program);** openGLproperty->ShadingOn();* Shader (simple shader to paint all fragments red): * #version 110* > > * void propFuncFS(void)* > * {* > * gl_FragColor = (255,0,0,1);** }* Thanks again and have a nice day! =) 2014-07-29 21:48 GMT+02:00 Carlos Martinez : > Joachim, > > Thank you so much for the explanation, I tried something similar but > building the shaders instead of not doing it (if I remember well). > Tomorrow i will try it and I will tell you the results!! > > Carlos. > > > > > 2014-07-29 15:14 GMT+02:00 Joachim Pouderoux [via VTK] < > ml-node+s1045678n5728004h64 at n5.nabble.com>: > >> Carlos >> >> Ok actually I was wrong. My patch works but it is not how this is >> supposed to happen. >> Basically, VTK will merge 2 different shader source code to define each >> type of shader (vertex, fragment etc.). >> A first source will come from the shader code that can be attached to the >> renderer shaders. >> If it not exist, the default is a main function that will call >> propFuncVS()/propFuncFS() etc - depending the shader type. >> The second source will come from the shader code that can be attached to >> the actor's property. >> If it not exist, the default behaviour is to define that propFuncVS/FS >> functions. >> Both source codes will be appended before being compiled by the >> openGlProperty. >> >> So basically if you do not define a renderer shader program, you simply >> have to provide a shader codes to your property that defines propFuncVS/FS >> functions instead of usual main() functions. >> Also do not build your shader program (program->Build()) in your code as >> it will fail because the main() functions are not provided. Remember they >> will be added later automatically before compilation by OpenGLProperty. >> >> Hope it is clear and it helps! >> >> Best, >> >> >> >> *Joachim Pouderoux* >> >> *PhD, Technical Expert* >> *Kitware SAS * >> >> >> >> 2014-07-29 14:55 GMT+02:00 Joachim Pouderoux <[hidden email] >> >: >> >>> Actually it seems like there is a bug in vtkOpenGLProperty.cxx that I >>> might have fixed. I will make a patch soon. >>> In the meanwhile try to change those lines: >>> >>> >>> needDefaultMainVS = !progHasVertex >>> && propProg->HasVertexShaders(); >>> needDefaultMainFS = !progHasFragment >>> && propProg->HasFragmentShaders(); >>> >>> by >>> >>> needDefaultMainVS = !progHasVertex >>> && !propProg->HasVertexShaders(); >>> needDefaultMainFS = !progHasFragment >>> && !propProg->HasFragmentShaders(); >>> >>> With that fixed, the steps you defined should now work as no second >>> main() will be added to both shader code. >>> >>> Joachim >>> >>> *Joachim Pouderoux* >>> >>> *PhD, Technical Expert* >>> *Kitware SAS * >>> >>> >>> >>> 2014-07-18 11:03 GMT+02:00 carlinhos <[hidden email] >>> >: >>> >>> Hello Xiaoming, >>>> >>>> I created a new vtkOpenGLProperty and set it to the actor, anyways i >>>> tried to cast the vtkProperty obtained by the a vtkActor::GetProperty(), >>>> because vtkProperty is an abstract class. I tried so many things to make it >>>> work but i didn't manage to do it. Also i tried to use vtkOpenGLActors >>>> instead of vtkActors but it also didn't work. >>>> >>>> Carlos. >>>> >>>> >>>> 2014-07-18 9:46 GMT+02:00 xiaoming [via VTK] <[hidden email] >>>> >: >>>> >>>>> i'm sorry but i see that vtkActor::GetProperty() returns a pointer to >>>>> the vtkProperty not vtkOpenGLProperty,which has a member of >>>>> SetPropProgram,i 'm just confused with the 7th step,would you bother to >>>>> tell me sth about that ,thanks in advance. >>>>> Quote: >>>>> < 7- Put ShadingOn to the property and SetPropProgram with the >>>>> vtkShaderProgram2 build before (The vtkShaderProgram on debug has only >>>>> the >>>>> 2 shaders I put in).> >>>>> >>>>> >>>>> >>>>> ------------------------------ >>>>> If you reply to this email, your message will be added to the >>>>> discussion below: >>>>> >>>>> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5727903.html >>>>> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >>>>> here. >>>>> NAML >>>>> >>>>> >>>> >>>> >>>> ------------------------------ >>>> View this message in context: Re: GLSL Shader on a vtkActor (VTK 6.1 >>>> and Qt 5.2.1) >>>> >>>> Sent from the VTK - Dev mailing list archive >>>> at Nabble.com. >>>> >>>> _______________________________________________ >>>> Powered by www.kitware.com >>>> >>>> Visit other Kitware open-source projects at >>>> http://www.kitware.com/opensource/opensource.html >>>> >>>> Follow this link to subscribe/unsubscribe: >>>> http://public.kitware.com/mailman/listinfo/vtk-developers >>>> >>>> >>>> >>> >> >> _______________________________________________ >> Powered by www.kitware.com >> >> Visit other Kitware open-source projects at >> http://www.kitware.com/opensource/opensource.html >> >> Follow this link to subscribe/unsubscribe: >> http://public.kitware.com/mailman/listinfo/vtk-developers >> >> >> >> ------------------------------ >> If you reply to this email, your message will be added to the >> discussion below: >> >> http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728004.html >> To unsubscribe from GLSL Shader on a vtkActor (VTK 6.1 and Qt 5.2.1), click >> here >> >> . >> NAML >> >> > > -- View this message in context: http://vtk.1045678.n5.nabble.com/GLSL-Shader-on-a-vtkActor-VTK-6-1-and-Qt-5-2-1-tp5727788p5728023.html Sent from the VTK - Dev mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.thompson at kitware.com Thu Jul 31 12:51:36 2014 From: david.thompson at kitware.com (David Thompson) Date: Thu, 31 Jul 2014 12:51:36 -0400 Subject: [vtk-developers] OpenGL2 tests Message-ID: Hi all, I've noticed that some tests I recently added are failing on the OpenGL2 dashboard build: http://open.cdash.org/viewTest.php?buildid=3430147 apparently because antialiasing is enabled and some face normals are handled differently. (My particular test is vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change in the test to disable antialiasing for OpenGL2+ or will that be done as part of the testing framework as the rendering changes continue? Thanks, David From marcus.hanwell at kitware.com Thu Jul 31 13:04:39 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 13:04:39 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: On Thu, Jul 31, 2014 at 12:51 PM, David Thompson wrote: > Hi all, > > I've noticed that some tests I recently added are failing on the OpenGL2 dashboard build: > > http://open.cdash.org/viewTest.php?buildid=3430147 > > apparently because antialiasing is enabled and some face normals are handled differently. (My particular test is vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change in the test to disable antialiasing for OpenGL2+ or will that be done as part of the testing framework as the rendering changes continue? > I will look into it, you shouldn't worry too much as we need to figure out how to minimize some of this. Some of the lighting will be slightly different, but we should still be able to disable multisampling. Thanks for pointing it out. Marcus From dave.demarle at kitware.com Thu Jul 31 13:31:36 2014 From: dave.demarle at kitware.com (David E DeMarle) Date: Thu, 31 Jul 2014 13:31:36 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: Surface selection and depth composting also disabling anti aliasing too. On Jul 31, 2014 1:05 PM, "Marcus D. Hanwell" wrote: > On Thu, Jul 31, 2014 at 12:51 PM, David Thompson > wrote: > > Hi all, > > > > I've noticed that some tests I recently added are failing on the OpenGL2 > dashboard build: > > > > http://open.cdash.org/viewTest.php?buildid=3430147 > > > > apparently because antialiasing is enabled and some face normals are > handled differently. (My particular test is > vtkIOExodusPython-TestExodusPolyhedra.) Is there anything I need to change > in the test to disable antialiasing for OpenGL2+ or will that be done as > part of the testing framework as the rendering changes continue? > > > I will look into it, you shouldn't worry too much as we need to figure > out how to minimize some of this. Some of the lighting will be > slightly different, but we should still be able to disable > multisampling. Thanks for pointing it out. > > Marcus > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From marcus.hanwell at kitware.com Thu Jul 31 13:53:29 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 13:53:29 -0400 Subject: [vtk-developers] OpenGL2 tests In-Reply-To: References: Message-ID: On Thu, Jul 31, 2014 at 1:31 PM, David E DeMarle wrote: > Surface selection and depth composting also disabling anti aliasing too. Selection code is totally different in the GL2 backend, guessing you mean depth compositing and we haven't gotten to that yet. Like I said - I will look into why multisampling is being enabled in error for some tests. Marcus From dlrdave at aol.com Thu Jul 31 14:11:09 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 14:11:09 -0400 (EDT) Subject: [vtk-developers] More VTK Wiki Examples questions Message-ID: <8D17B01F0735AB3-1A1C-16D7A@webmail-vm031.sysops.aol.com> This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/XGMLReader gets an "fsm.gml" data file from "somewhere" (but *NOT* VTKData) and uses it when running the VTK Wiki Examples dashboard on my machine. This example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/TreeMapView apparently depends on VTKData, which I do not have, so the test fails on my machine. On the wiki page itself, there's a note saying we should generate an example tree map instead of loading from a data file: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/TreeMapView So... we can fix the failing test by making the TreeMapView's data files available (as fsm.gml is already available) to my dashboard build.... or by modifying the TreeMapView example to use some generated data. Which is easier? I'm not sure how to do either myself -- I'm hoping Bill L. can easily add some data for this example, or Jeff Baumes can point me to how to generate an example TreeMap easily... Thanks, David C. From dlrdave at aol.com Thu Jul 31 14:20:57 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 14:20:57 -0400 (EDT) Subject: [vtk-developers] InfoVis graph visualization question: vtkGraphLayoutView with a "Simple 2D" layout strategy Message-ID: <8D17B034EF2C9AD-1A1C-16EE0@webmail-vm031.sysops.aol.com> This VTK wiki example: http://www.vtk.org/Wiki/VTK/Examples/Cxx/InfoVis/XGMLReader Yields this different rendering test failure on my dashboard machine: http://open.cdash.org/testDetails.php?test=271695203&build=3430870 The graph structure looks the same, and the visual is roughly equivalent, but the expected image clearly shows a perfectly square glyph at each graph node. In my test image, the graph nodes look like they vary from circle to square to polygons in between... What determines the shape of the node glyph in a vtkGraphLayoutView with a "Simple 2D" layout strategy? And would the shape difference account entirely for the slight offset and angle between expected image and test image...? Thanks, David C. From dlrdave at aol.com Thu Jul 31 15:59:55 2014 From: dlrdave at aol.com (David Cole) Date: Thu, 31 Jul 2014 15:59:55 -0400 (EDT) Subject: [vtk-developers] VTK wiki example FullScreen In-Reply-To: References: <8D176589186F68A-81C-2C551@webmail-d223.sysops.aol.com> Message-ID: <8D17B11223B2197-1BBC-1A024@webmail-vd018.sysops.aol.com> > Agree. Need to ponder. Have you pondered any fresh ideas since last Friday? :-) From jchris.fillionr at kitware.com Thu Jul 31 19:44:35 2014 From: jchris.fillionr at kitware.com (Jean-Christophe Fillion-Robin) Date: Thu, 31 Jul 2014 19:44:35 -0400 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' Message-ID: Hi Folks, After doing some experiment with Slicer, building against: VTK 6.2-dev - f19689d Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 It causes the volume rendering test [0] to fail [1] with the following error: Generic Warning: In /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, line 27 Error: no override found for 'vtkContextDevice2D'. This has already been discussed few days ago in [2] but we didn't came to a solution. I suspect it is related to the recent work done regarding the support of different rendering backend. Any idea what could be done to fix this ? You will also find below a complete backtrace. See [3] Thanks Jc [0] https://github.com/Slicer/Slicer/blob/22f1c99f28d52f58070e31849d33a3a50e4501a6/Modules/Loadable/VolumeRendering/Testing/Cxx/qMRMLVolumePropertyNodeWidgetTest1.cxx [1] http://slicer.cdash.org/testDetails.php?test=5592103&build=253161 [2] http://vtk.1045678.n5.nabble.com/Problem-with-QVtkWidget-not-rendering-vktChartXY-in-visual-studio-2013-td5727913.html#a5727919 [3] Backtrace: (gdb) bt #0 0x00007fffdb63ecc6 in vtkContextActor::RenderOverlay (this=0xc34be0, viewport=0xbbe720) at /path/to/VTKv6/Rendering/Context2D/vtkContextActor.cxx:212 #1 0x00007fffd77f1483 in vtkRenderer::UpdateGeometry (this=0xbbe720) at /path/to/VTKv6/Rendering/Core/vtkRenderer.cxx:585 #2 0x00007fffdd3f5631 in vtkOpenGLRenderer::DeviceRender (this=0xbbe720) at /path/to/VTKv6/Rendering/OpenGL/vtkOpenGLRenderer.cxx:270 #3 0x00007fffd77f0691 in vtkRenderer::Render (this=0xbbe720) at /path/to/VTKv6/Rendering/Core/vtkRenderer.cxx:292 #4 0x00007fffd77eed45 in vtkRendererCollection::Render (this=0xbbe580) at /path/to/VTKv6/Rendering/Core/vtkRendererCollection.cxx:51 #5 0x00007fffd7804bd8 in vtkRenderWindow::DoStereoRender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:762 #6 0x00007fffd7804ade in vtkRenderWindow::DoFDRender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:731 #7 0x00007fffd780447e in vtkRenderWindow::DoAARender (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:610 #8 0x00007fffd7803a4c in vtkRenderWindow::Render (this=0xbbe2c0) at /path/to/VTKv6/Rendering/Core/vtkRenderWindow.cxx:426 #9 0x00007fffdd492ced in vtkXOpenGLRenderWindow::Render (this=0xbbe2c0) at /path/to/VTKv6/Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx:1830 #10 0x00007fffd78103df in vtkRenderWindowInteractor::Render (this=0xc1bb60) at /path/to/VTKv6/Rendering/Core/vtkRenderWindowInteractor.cxx:171 #11 0x00007fffddc117a4 in QVTKWidget::paintEvent (this=0xba6ad0) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:479 #12 0x00007fffcec51146 in QWidget::event(QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #13 0x00007fffddc11566 in QVTKWidget::event (this=0xba6ad0, e=0x7fffffffd020) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:414 #14 0x00007fffcec0781c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #15 0x00007fffcec0a189 in QApplication::notify(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #16 0x00007fffce6ae7ce in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #17 0x00007fffcec55de4 in QWidgetPrivate::drawWidget(QPaintDevice*, QRegion const&, QPoint const&, int, QPainter*, QWidgetBackingStore*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #18 0x00007fffcee2574c in QWidgetPrivate::repaint_sys(QRegion const&) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #19 0x00007fffcec44fa4 in QWidgetPrivate::syncBackingStore() () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #20 0x00007fffcec513a3 in QWidget::event(QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #21 0x00007fffddc11566 in QVTKWidget::event (this=0xba6ad0, e=0xd3fef0) at /path/to/VTKv6/GUISupport/Qt/QVTKWidget.cxx:414 #22 0x00007fffcec0781c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #23 0x00007fffcec0a189 in QApplication::notify(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #24 0x00007fffce6ae7ce in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #25 0x00007fffce6b2221 in QCoreApplicationPrivate::sendPostedEvents(QObject*, int, QThreadData*) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #26 0x00007fffceca17cc in ?? () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtGui.so.4 #27 0x00007fffce6ad55f in QEventLoop::processEvents(QFlags) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #28 0x00007fffce6ad7e8 in QEventLoop::exec(QFlags) () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #29 0x00007fffce6b28b8 in QCoreApplication::exec() () from /path/to/qt-everywhere-opensource-release-build-4.8.5/lib/libQtCore.so.4 #30 0x0000000000410f9c in qMRMLVolumePropertyNodeWidgetTest1 (argc=1, argv=0x7fffffffdd60) at /home/jchris/Projects/Slicer-2/Modules/Loadable/VolumeRendering/Testing/Cxx/qMRMLVolumePropertyNodeWidgetTest1.cxx:52 #31 0x0000000000410d29 in main (ac=1, av=0x7fffffffdd60) at /path/to/Slicer-build/Modules/Loadable/VolumeRendering/Testing/Cxx/qSlicerVolumeRenderingModuleCxxTests.cxx:197 -- +1 919 869 8849 -------------- next part -------------- An HTML attachment was scrubbed... URL: From david.gobbi at gmail.com Thu Jul 31 20:03:50 2014 From: david.gobbi at gmail.com (David Gobbi) Date: Thu, 31 Jul 2014 18:03:50 -0600 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' In-Reply-To: References: Message-ID: It's due to the addition of the VTK Rendering/ContextOpenGL directory that occurred a couple weeks ago in the following commit: http://vtk.org/gitweb?p=VTK.git;a=commit;h=c5121871 Basically, now that the OpenGL override for vtkContextDevice2D has been moved int Rendering/ContextOpenGL, you have to make sure that you link to vtkRenderingContextOpenGL. See the following wiki page for more info: http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Factories_now_require_defines - David On Thu, Jul 31, 2014 at 5:44 PM, Jean-Christophe Fillion-Robin wrote: > Hi Folks, > > After doing some experiment with Slicer, building against: > > VTK 6.2-dev - f19689d > > Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 > > It causes the volume rendering test [0] to fail [1] with the following > error: > > > Generic Warning: In > /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, > line 27 > Error: no override found for 'vtkContextDevice2D'. > > This has already been discussed few days ago in [2] but we didn't came to a > solution. > > I suspect it is related to the recent work done regarding the support of > different rendering backend. > > Any idea what could be done to fix this ? > > You will also find below a complete backtrace. See [3] > > Thanks > Jc From marcus.hanwell at kitware.com Thu Jul 31 20:50:43 2014 From: marcus.hanwell at kitware.com (Marcus D. Hanwell) Date: Thu, 31 Jul 2014 20:50:43 -0400 Subject: [vtk-developers] QVTKWidget - Error: no override found for 'vtkContextDevice2D' In-Reply-To: References: Message-ID: As David pointed, I split the OpenGL backend out. If you add the link to the vtkRenderingContextOpenGL backend then it should work fine. Let me know if you continue to have problems. On Thu, Jul 31, 2014 at 8:03 PM, David Gobbi wrote: > It's due to the addition of the VTK Rendering/ContextOpenGL directory > that occurred a couple weeks ago in the following commit: > > http://vtk.org/gitweb?p=VTK.git;a=commit;h=c5121871 > > Basically, now that the OpenGL override for vtkContextDevice2D has been > moved int Rendering/ContextOpenGL, you have to make sure that you link > to vtkRenderingContextOpenGL. See the following wiki page for more info: > > http://www.vtk.org/Wiki/VTK/VTK_6_Migration/Factories_now_require_defines > > - David > > > On Thu, Jul 31, 2014 at 5:44 PM, Jean-Christophe Fillion-Robin > wrote: >> Hi Folks, >> >> After doing some experiment with Slicer, building against: >> >> VTK 6.2-dev - f19689d >> >> Ubuntu 10.04 - g++ (Ubuntu 4.4.3-4ubuntu5.1) 4.4.3 >> >> It causes the volume rendering test [0] to fail [1] with the following >> error: >> >> >> Generic Warning: In >> /home/kitware/Dashboards/Nightly/Slicer-0-build/VTKv6/Rendering/Context2D/vtkContextDevice2D.cxx, >> line 27 >> Error: no override found for 'vtkContextDevice2D'. >> >> This has already been discussed few days ago in [2] but we didn't came to a >> solution. >> >> I suspect it is related to the recent work done regarding the support of >> different rendering backend. >> >> Any idea what could be done to fix this ? >> >> You will also find below a complete backtrace. See [3] >> >> Thanks >> Jc > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html > > Follow this link to subscribe/unsubscribe: > http://public.kitware.com/mailman/listinfo/vtk-developers >