Dave,

The global methodology is to:
- create mesh
- add hypothesis
- add algorithms
- compute mesh

The best way to start with is the samples scripts provided in the /SMESH
folder (for instance volumic_mesh.py)

The thing to know: the API is really ugly and not pythonic at all (one more
time). Studies, algorithms and hypothesis are identified with an integer.

For instance:
aMesh = aMeshGen.CreateMesh(0,True)
means that the created mesh is related to the study 0.

Then:
an1DHypothesis = StdMeshers_Arithmetic1D(0,0,aMeshGen)
means that it's the hypothesis 0 for the study 0

an1DAlgo = StdMeshers_Regular_1D(1,0,aMeshGen)
means that this algo has the id 1, and is applied to study 0

When all algo and hyp are created, they have to be added to the mesh:
aMesh.AddHypothesis(aShape,0) # = add the hypothesis id 0 to the mesh
aMesh.AddHypothesis(aShape,1)  # = add the hypothesis id 1 to the mesh
etc.

THe hypothesis and algo control the way the boundary is discretized and how
the elements are generated.

Thomas

2010/3/19 Cowdens <dave.cow...@gmail.com>

>  Thanks, Thomas.
>
> Is there any place I can get more 'conceptual' documentation? For example
> the function of the various 'hypotheses' and the general nature of how the
> api works?
>
>  ------------------------------
> *From:* pythonocc-users-boun...@gna.org [mailto:
> pythonocc-users-boun...@gna.org] *On Behalf Of *Thomas Paviot
> *Sent:* Friday, March 19, 2010 3:47 AM
> *To:* pythonOCC users mailing list.
> *Subject:* Re: [Pythonocc-users] Meshing Question
>
> Hi Dave,
>
> The meshing features for SMESH are available from the following python
> modules: SMESH, SMDS, SMDSAbs, SMEHSDS, StdMeshers, DriverDAT, DriverUNV.
> The api documentation can be browsed at:
> http://api.pythonocc.org/toc-OCC.SMESH-module.html
> http://api.pythonocc.org/toc-OCC.StdMeshers-module.html
> etc...
>
> 2010/3/19 Dave Cowden <dave.cow...@gmail.com>
>
>> Ok, nevermind this question, i found a starting point in the Level1\SMESH
>> samples.
>>
>> However, I cannnot seem to find any documentation to help me understand
>> these objects.  I looked at the website, apidoc.  Is the API published
>> somewhere?
>>
>>
>> On Thu, Mar 18, 2010 at 8:08 PM, Dave Cowden <dave.cow...@gmail.com>wrote:
>>
>>> Hi, everyone:
>>>
>>> I have  a qq about meshing.  I have been struggling for several weeks now
>>> with a filling algorithm.  I have an idea I might be able to use a mesh of a
>>> face  to make my algo easier.
>>>
>>> I investigated the built-in BRepMesh functionality, but realized quickly
>>> that those triangulate surfaces with only the number of triangles necessary:
>>> IE, a square face would have exactly two triangles.
>>>
>>> What i need is a mesher that will let me triangulate (or, better, use
>>> quadrilateral polygons ) to mesh a face , but with arbitrarily selected mesh
>>> size.
>>>
>>> I looked briefly at salome docs and i'm completely swamped. Could someone
>>> point me to a starting point for meshing with salome?
>>>
>>> thanks kindly!
>>>
>>
>>
>> _______________________________________________
>> Pythonocc-users mailing list
>> Pythonocc-users@gna.org
>> https://mail.gna.org/listinfo/pythonocc-users
>>
>>
>
> _______________________________________________
> Pythonocc-users mailing list
> Pythonocc-users@gna.org
> https://mail.gna.org/listinfo/pythonocc-users
>
>
_______________________________________________
Pythonocc-users mailing list
Pythonocc-users@gna.org
https://mail.gna.org/listinfo/pythonocc-users

Reply via email to