예제 #1
0
 def __init__(self, uid):
     self.uid = uid  # unique id
     self.jid = ''  # object id
     self.aid = []
     self.type = ''  # Floor or Window or ...
     self.bounding_box = BoundingBox()  # bbox
     self.mesh = 0  # is Mesh object, juran-json 'mesh' info
     self.ref = 0  # reference count
예제 #2
0
 def __init__(self, uid, scene):
     self.scene = scene  # parent
     self.id = uid  # id
     self.type = ''  # Bedroom
     self.position = np.zeros(3)  # [0,0,0]
     self.rotation = np.array([0.0, 0.0, 0.0, 1.0])  # [0,0,0,1]
     self.scale = np.array([1.0, 1.0, 1.0])  # [1,1,1]
     self.children_for_mesh = []  # furniture
     self.children_for_furniture = []  # floor, window ...
     self.bounding_box = BoundingBox()  # box
예제 #3
0
 def __init__(self,
              refer_position=np.array([0, 0, 0]),
              direction_2d=np.array([1, 0]),
              bbox=BoundingBox(),
              position_str=['center', 'center', 'center']):
     self.position_str = position_str
     self.direction_3d = np.array([direction_2d[0], 0, direction_2d[1]])
     self.vt_3d = np.array([-direction_2d[1], 0, direction_2d[0]])
     self.z_axis = np.array([0, 1, 0])
     self.bbox = bbox
     self.camera_position = copy.deepcopy(refer_position)
예제 #4
0
    def __init__(self, instance):
        self.instance = instance  # instance object
        self.type = ''  # data type
        self.bounding_box = BoundingBox()  # box
        self.rotate = np.array([0.0, 0.0, 0.0, 1.0])  # [0,0,0,1]
        self.position = np.array([0.0, 0.0, 0.0])  # [0,0,0
        self.scale = np.array([1.0, 1.0, 1.0])  # [1,1,1]
        self.used = True  # is used
        self.clamp_wall = False  # clamp wall
        self.clamp_rotate_list = []  # clamp direction
        self.children = []  # child object
        self.parent = None  # parent object
        self.modify = False  # is transform
        self.instance_id = 'id'  # reflect instanceid
        self.instance_ref = ''  # reflect uid
        self.use_gmm = False  # is gmm
        self.special_children = []  # bed and bedstand
        # self.align_neighbours = []

        # 规则摆放
        self.mainObject = False
        self.valid = True

        self.is_sale = False  # 是否为在售商品
예제 #5
0
 def __init__(self):
     self.bounding_box = BoundingBox()  # box
     self.vertex_array = []  # vertex
     self.index_array = []  # index
     self.normal = 0  # normal
     self.uv = 0  # texcoord