<commit_before>THREE = require( 'three' )
ThreeCSG =  require( '../../vendor/ThreeCSG' )
  
#TODO: where to do canonicalization and normalization?
#TODO: review inheritance : basic geometry (cube, sphere) should not have children etc (like "mesh") but should have position, rotation etc
#TODO: add connectors

class ObjectBase extends THREE.Mesh
  #base class regrouping features of THREE.Mesh and THREE.CSG
  
  constructor:( geometry, material )->
    if not material?
      material = new THREE.MeshBasicMaterial( { color: 0xffffff, wireframe: false } )
      shine= 1500
      spec= 1000
      opacity = 1
      material = new THREE.MeshPhongMaterial({color:  0xFFFFFF , shading: THREE.SmoothShading,  shininess: shine, specular: spec, metal: false}) 
    #super(geometry, material)
    THREE.Mesh.call( @, geometry, material )
    
    
    #VERY important : transforms stack : all operations done on this shape is stored here
    #TODO: should we be explicit , ie in basic shape class, or do it in processor/preprocessor
    @transforms = []
    
    
    #FIXME: see THREE.jS constructors thingamajig
    #console.log @prototype
    #Object.create(@prototype)
    @bsp = null
    
    @connectors = []
  
  #------base transforms--------#
  translate:( amount )->
    tVector = toVector3( amount )
    <commit_msg>- continuing refactoring of preprocessor and related elements<commit_after>THREE = require( 'three' )
ThreeCSG =  require( '../../vendor/ThreeCSG' )
  
#TODO: where to do canonicalization and normalization?
#TODO: review inheritance : basic geometry (cube, sphere) should not have children etc (like "mesh") but should have position, rotation etc
#TODO: add connectors
#TODO: since we want objects / parts to be exportable individually, perhaps adding "export" methods to them
# would be a good idea ...

class ObjectBase extends THREE.Mesh
  #base class regrouping features of THREE.Mesh and THREE.CSG
  
  constructor:( geometry, material )->
    if not material?
      material = new THREE.MeshBasicMaterial( { color: 0xffffff, wireframe: false } )
      shine= 1500
      spec= 1000
      opacity = 1
      material = new THREE.MeshPhongMaterial({color:  0xFFFFFF , shading: THREE.SmoothShading,  shininess: shine, specular: spec, metal: false}) 
    #super(geometry, material)
    THREE.Mesh.call( @, geometry, material )
    
    
    #VERY important : transforms stack : all operations done on this shape is stored here
    #TODO: should we be explicit , ie in basic shape class, or do it in processor/preprocessor
    @transforms = []
    
    
    #FIXME: see THREE.jS constructors thingamajig
    #console.log @prototype
    #Object.create(@prototype)
    @bsp = null
    
    @connectors = []
  
  #------base transforms--------#
  translate:( amount )->
    tVector = toVector3( amount )
    
{'fraction_non_alphanumeric': 0.10230088495575221, 'fraction_numerical': 0.008495575221238939, 'mean_word_length': 3.1620029455081, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6758523', 'n_tokens_mistral': 852, 'n_tokens_neox': 804, 'n_words': 290}