Giter Site home page Giter Site logo

Texture swapping problem about neumesh HOT 4 CLOSED

zju3dv avatar zju3dv commented on May 23, 2024
Texture swapping problem

from neumesh.

Comments (4)

chobao avatar chobao commented on May 23, 2024 1

Hi, loveaca-sunlight! Following our paper, there are 3 steps to customize the region of the texture swapping.

  1. Annotate the region you want to swap on each mesh with blender. Our code recognizes the swapping region by the vertex color. All white nodes are selected as swapped candidates. The step can be done with the vertex paint mode in Blender. Please note that the vertices order of exported mesh should be the same as the original mesh. After that, the path of the main mesh(main_mask_mesh) and affiliated mesh should be written on the config.
    mask = np.sum(np.asarray(mask_mesh.vertex_colors), axis=-1) != 0
  2. Align the swapped region in Euclidean space. T_s_m denotes the similarity transformation from the main mesh(painted mesh) to the affiliated mesh(provide texture). corr denotes the still points when deforming mesh with as rigid as possible. The step can be easily done by enabling estimate_srt and our method will compute T_s_m, corr automatically with your intervention
    parser.add_argument("--estimate_srt", nargs="+", default=[], type=int)
  3. Run the code and enjoy it.

from neumesh.

loveaca-sunlight avatar loveaca-sunlight commented on May 23, 2024

Thanks a lot, I've made some progress with your tips.

I'd also like to double-check that your mention of "the vertices order should be the same" means that I shouldn't delete any vertices in Blender? If I paint one of them black and the other white in vertex drawing, shouldn't it affect the vertex order?

from neumesh.

chobao avatar chobao commented on May 23, 2024

Hi, the full code has been released! Please take a look at it for more details.

  • In our implementation, the vertices should not be deleted. However, I think some tricks can be employed to index the vertex correctly before and after deletion.
  • Painting the vertex will not affect the vertex order if you check the keep the vertex order when exporting mesh in Blender.

from neumesh.

chobao avatar chobao commented on May 23, 2024

Close the inactive issues. Feel free to reopen it if the problem still needs to be solved.

from neumesh.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.