thanks Paolo, that solved the immediate problem. I'm having trouble
compiling, though. the error i'm getting is:
release/moc_filter_texture.o:(.data.rel.ro._ZTV19FilterTexturePlugin[vtable
for FilterTexturePlugin]+0x4c): undefined reference to
`FilterTexturePlugin::applyFilter(QAction*, MeshModel&, FilterParameterSet&,
bool (*)(int, char const*))'
I changed the function definition from the above to applyFilter(QAction
*filter, MeshModel &m, FilterParameterSet &par, vcg::CallBackPos * cb) but
can't figure out where the old definition is still present, as the .h file
has the same definition.
any ideas?
thanks
imran
On Thu, May 8, 2008 at 12:35 AM, Paolo Cignoni <pao...@is...>
wrote:
> fit->cWT(0).N()
> the small c before WT means that you are asking for a constant access so
> you can read the values inside WT but you cannot change them.
> you should use something like fit->WT(0).N() obviously assuming that fit is
> not a constfaceiterator.
>
> We are building up some tutorial on the vcg foundations you can find a
> first draft at
>
> http://vcg.sourceforge.net/mediawiki/index.php/Tutorial
>
> p.
>
>
>
>
> skunkwerk wrote:
>
> thanks paolo,
> any hints on why i can't modify faces with the iterator i'm using? am i
> using the wrong kind? i saw 'constfaceiterator' in the code somewhere, so I
> figured 'faceiterator' wouldn't be const.
>
> imran
>
> On Wed, May 7, 2008 at 3:44 PM, Paolo Cignoni <pao...@is...>
> wrote:
>
>> Translated. sorry for the italian comments that are surviving in a lot of
>> places...
>>
>>
>> skunkwerk wrote:
>>
>> i'm using a CMesh0::FaceIterator but it seems like it's a const for some
>> reason - when I try to change values of the face, like fit->cWT(0).N() i get
>> compilation errors about 'assignment of read-only location.' what's the
>> proper way to modify these values?
>>
>> i was translating some of the italian comments in rect_packer.cpp but
>> couldn't find translations for the following:
>> posiziono - position?
>> pe plus'
>> could someone please translate these to english for me?
>>
>> thanks
>> imran
>>
>> On Tue, Apr 29, 2008 at 11:48 PM, skunkwerk <sku...@gm...> wrote:
>>
>>> thanks Paolo,
>>> i guess CMesh0 is how i'll get the faceiterator - i'm working on some
>>> collada importer optimizations right now but might get back to this in a few
>>> days. what options do we have for a numerical solver?
>>>
>>> imran
>>>
>>> On Tue, Apr 29, 2008 at 2:22 PM, Paolo Cignoni <
>>> pao...@is...> wrote:
>>>
>>>> I like your proposal, but I strongly suggest you to proceed gradually
>>>> and start and complete and test a functionality at a time.
>>>>
>>>> First of all start to just add a simple rectangular packer,
>>>>
>>>> - then try to use the rect_packer provided code
>>>>
>>>> - then try to look at the code in the trimesh/textcoord_optimization.h
>>>> file.
>>>>
>>>> Before facing LSCM we should solve the issue of what numerical solver
>>>> use for it and for other issues that we have around in the vcg.
>>>> I hope we could take some decision in the next weeks about the numeric
>>>> solver in the vcg.
>>>>
>>>> I noticed that some notes on the basic types were missing so i added it
>>>> in http://meshlab.sourceforge.net/wiki/index.php/Writing_a_Plugin
>>>> Feel also free to contribute to the wiki in the part about the writing
>>>> of the plugins when you see points needing some clarification or a deeper
>>>> discussion.
>>>>
>>>>
>>>> cheers
>>>> p.
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> skunkwerk wrote:
>>>>
>>>> thanks for the hints paolo,
>>>> i wanted to use this algorithm:
>>>> http://alice.loria.fr/php/article.php?pub=../publications/papers/2002/lscm
>>>> but it seemed like it needed information on the actual models, and was
>>>> taking in arbitrarily-shaped textures.
>>>>
>>>> the only other algorithm i've found for texture packing is a recursive
>>>> tree-based one:
>>>> http://www.blackpawn.com/texts/lightmaps/default.html
>>>>
>>>> i tried this line (along with everything else i could think of):
>>>> MeshModel::FaceIterator fit;
>>>> but it didn't like the 'MeshModel' part - is 'mm' not an object of type
>>>> MeshModel?
>>>>
>>>> if someone could suggest the correct syntax i can get started on testing
>>>> the texture atlas
>>>>
>>>> thanks,
>>>> imran
>>>>
>>>> On Tue, Apr 29, 2008 at 2:13 AM, Paolo Cignoni <
>>>> pao...@is...> wrote:
>>>>
>>>> skunkwerk wrote:
>>>> > i've attached a texture atlas function.
>>>> >
>>>> > it compiles except for a ConstFaceIterator error - I've tried using
>>>> > the template<typename MESHTYPE> but that didn't work either. the
>>>> > algorithm is VERY basic (textures are added one after another in a
>>>> > row), but should work. i couldn't find any algorithms for more
>>>> > closely-packed positioning, but i could look at the code in
>>>> > openscenegraph's texture atlas generator.
>>>> Nice Job!
>>>>
>>>> The right place for this stuff is the filter_texture plugin that i have
>>>> just added,
>>>> Now it is just a placeholder filter you should add your code there.
>>>>
>>>> Important:
>>>> In the plugin dir you can find a rect_packer that should make good job.
>>>> please use it to build a good packing of the texture size
>>>>
>>>> > questions:
>>>> > 1) if someone could tell me how to iterate through faces from a
>>>> > function outside vcg, that'd be great so i could test this out
>>>> We have started to improve the developer documentation: two new pages
>>>> in
>>>> the wiki should help you
>>>>
>>>> http://meshlab.sourceforge.net/wiki/index.php/Accessing_the_mesh
>>>> http://meshlab.sourceforge.net/wiki/index.php/Algorithms
>>>>
>>>> > 2) paolo, what's the best location of this function? i'm currently
>>>> > putting it in mainwindow_Runtime.cpp to test it out
>>>> The right location is inside the filter_texture plugin
>>>> possible parameter of the plugin:
>>>> - format of the saved texture (as a enum)
>>>> - max size of the texture
>>>>
>>>> > 3) how do I access the data from already-loaded textures? so i can
>>>> > prevent having to load all the textures again...
>>>> Do not worry about that. Feel free to use QT to load again the images
>>>> and process them, it should not create a significant overhead.
>>>>
>>>> Once your processing is ended (and you have saved the new texture) you
>>>> should update the texture names stored inside the mesh sending a signal
>>>> to the updateTexture() slot of the mainwindow (the parent of the
>>>> action)
>>>>
>>>> cheers
>>>> p.
>>>>
>>>> --
>>>> Paolo Cignoni -- Senior Researcher
>>>> Visual Computing Laboratory - ISTI - CNR
>>>> http://vcg.isti.cnr.it/~cignoni <http://vcg.isti.cnr.it/%7Ecignoni>
>>>>
>>>> ISTI - CNR
>>>> Via Moruzzi 1,
>>>> 56124 Pisa
>>>> ITALY
>>>>
>>>>
>>>>
>>>> -------------------------------------------------------------------------
>>>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>>>> Don't miss this year's exciting event. There's still time to save $100.
>>>> Use priority code J8TL2D2.
>>>>
>>>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>>>> _______________________________________________
>>>> Meshlab-devel mailing list
>>>> Mes...@li...
>>>> https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>>>>
>>>>
>>>> ------------------------------
>>>>
>>>> -------------------------------------------------------------------------
>>>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>>>> Don't miss this year's exciting event. There's still time to save $100.
>>>> Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>>>>
>>>> ------------------------------
>>>>
>>>> _______________________________________________
>>>> Meshlab-devel mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>>>>
>>>>
>>>>
>>>> --
>>>> Paolo Cignoni -- Senior Researcher
>>>> Visual Computing Laboratory - ISTI - CNR http://vcg.isti.cnr.it/~cignoni <http://vcg.isti.cnr.it/%7Ecignoni>
>>>>
>>>> ISTI - CNR
>>>> Via Moruzzi 1,
>>>> 56124 Pisa
>>>> ITALY
>>>>
>>>>
>>>>
>>>> -------------------------------------------------------------------------
>>>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>>>> Don't miss this year's exciting event. There's still time to save $100.
>>>> Use priority code J8TL2D2.
>>>>
>>>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>>>> _______________________________________________
>>>> Meshlab-devel mailing list
>>>> Mes...@li...
>>>> https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>>>>
>>>>
>>>
>> ------------------------------
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>> Don't miss this year's exciting event. There's still time to save $100.
>> Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>>
>> ------------------------------
>>
>> _______________________________________________
>> Meshlab-devel mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>>
>>
>>
>> --
>> Paolo Cignoni -- Senior Researcher
>> Visual Computing Laboratory - ISTI - CNR http://vcg.isti.cnr.it/~cignoni <http://vcg.isti.cnr.it/%7Ecignoni>
>>
>> ISTI - CNR
>> Via Moruzzi 1,
>> 56124 Pisa
>> ITALY
>>
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
>> Don't miss this year's exciting event. There's still time to save $100.
>> Use priority code J8TL2D2.
>>
>> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>> _______________________________________________
>> Meshlab-devel mailing list
>> Mes...@li...
>> https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>>
>>
> ------------------------------
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
> Don't miss this year's exciting event. There's still time to save $100.
> Use priority code J8TL2D2. http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
>
> ------------------------------
>
> _______________________________________________
> Meshlab-devel mailing lis...@li...https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>
>
>
> --
> Paolo Cignoni -- Senior Researcher
> Visual Computing Laboratory - ISTI - CNR http://vcg.isti.cnr.it/~cignoni <http://vcg.isti.cnr.it/%7Ecignoni>
>
> ISTI - CNR
> Via Moruzzi 1,
> 56124 Pisa
> ITALY
>
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by the 2008 JavaOne(SM) Conference
> Don't miss this year's exciting event. There's still time to save $100.
> Use priority code J8TL2D2.
>
> http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
> _______________________________________________
> Meshlab-devel mailing list
> Mes...@li...
> https://lists.sourceforge.net/lists/listinfo/meshlab-devel
>
>
|