It is currently Fri Nov 24, 2017 10:21 pm


All times are UTC




Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Cubiquity functions
PostPosted: Tue Sep 12, 2017 11:51 pm 

Joined: Wed Nov 23, 2016 3:46 pm
Posts: 4
hi, if its not secret,could you tell me where can i find the code behind this function of old ue4 Cubiquity (cuSculptTerrainVolume) pls

i wonder if its something special or just a metaball

called in Cubiquity.hpp like this

Code:
   void sculpt(const Vector<float>& brushPosition, float brushInnerRadius, float brushOuterRadius, float opacity)
      {
         ::validate(cuSculptTerrainVolume(m_volumeHandle, brushPosition.x, brushPosition.y, brushPosition.z, brushInnerRadius, brushOuterRadius, opacity));
      }


thx in adv


Top
Offline Profile  
Reply with quote  
 Post subject: Re: Cubiquity functions
PostPosted: Wed Sep 13, 2017 10:01 pm 
Developer
User avatar

Joined: Sun May 04, 2008 6:35 pm
Posts: 1816
Hi, it is defined here:

https://bitbucket.org/volumesoffun/cubi ... yC.cpp-984

Which then leads to here:

https://bitbucket.org/volumesoffun/cubi ... tor.cpp-47

My memory is hazy, but as I recall the brush has a falloff so that it has a stronger effect near the center. When modifying the terrain, two obvious choices are either to multiply the current terrain value by the brush value of to add the brush value to the terrain value. These both had problems, and I ended up doing a convolution (or something similar?) between the brush and terrain. It worked pretty well for smooth editing but computing a convolution is very performance intensive.


Top
Offline Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Theme created StylerBB.net