Tue 27 Jan 11:47:53 CET 2026
This commit is contained in:
parent
497cd48715
commit
a65e6b3b55
|
|
@ -21,7 +21,7 @@ class Scenario:
|
||||||
self.Height = Height
|
self.Height = Height
|
||||||
self.Pixel_mm = Pixel_mm
|
self.Pixel_mm = Pixel_mm
|
||||||
self.Label = Label
|
self.Label = Label
|
||||||
|
self.Objects = []
|
||||||
self.M = int(self.Height * self.Pixel_mm)
|
self.M = int(self.Height * self.Pixel_mm)
|
||||||
self.N = int(self.Width * self.Pixel_mm)
|
self.N = int(self.Width * self.Pixel_mm)
|
||||||
self.I = np.ones((self.M,self.N), dtype=np.uint8)*Label # create a matrix of MxN with each pixel having value as material Label
|
self.I = np.ones((self.M,self.N), dtype=np.uint8)*Label # create a matrix of MxN with each pixel having value as material Label
|
||||||
|
|
@ -134,7 +134,7 @@ class Scenario:
|
||||||
|
|
||||||
|
|
||||||
def addObject(self, obj):
|
def addObject(self, obj):
|
||||||
|
self.Objects.append(obj)
|
||||||
if obj.Name == "ellipse":
|
if obj.Name == "ellipse":
|
||||||
print("Adding ellipse to Scenario.")
|
print("Adding ellipse to Scenario.")
|
||||||
print(obj)
|
print(obj)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user