Skip to content
Snippets Groups Projects
Commit f65d5013 authored by Johannes Mey's avatar Johannes Mey
Browse files

add virtual scene

parent 3e24e87e
Branches
Tags 0.1.10
No related merge requests found
{
"objects": [
{
"id": "table",
"pos": {
"z": 0.25
},
"size": {
"length": 1,
"width": 2,
"height": 0.5
},
"orientation": {
"w": 1
},
"color": {
"r": 0.3,
"g": 0.3,
"b": 0.3
}
},
{
"id": "binBlue",
"type": "BIN",
"pos": {
"x": -0.35,
"y": -0.6,
"z": 0.65
},
"size": {
"length": 0.2,
"width": 0.4,
"height": 0.3
},
"orientation": {
"w": 1
},
"color": {
"b": 1
}
},
{
"id": "binGreen",
"type": "BIN",
"pos": {
"x": -0.35,
"y": 0,
"z": 0.65
},
"size": {
"length": 0.2,
"width": 0.4,
"height": 0.3
},
"orientation": {
"w": 1
},
"color": {
"g": 1
}
},
{
"id": "binRed",
"type": "BIN",
"pos": {
"x": -0.35,
"y": 0.6,
"z": 0.65
},
"size": {
"length": 0.2,
"width": 0.4,
"height": 0.3
},
"orientation": {
"w": 1
},
"color": {
"r": 1
}
},
{
"id": "bigBlue",
"type": "BOX",
"pos": {
"x": 0.2,
"y": -0.3,
"z": 0.58
},
"size": {
"length": 0.1,
"width": 0.16,
"height": 0.16
},
"orientation": {
"w": 1
},
"color": {
"b": 0.8
}
},
{
"id": "bigGreen",
"type": "BOX",
"pos": {
"x": 0.2,
"y": -0.1,
"z": 0.58
},
"size": {
"length": 0.1,
"width": 0.16,
"height": 0.16
},
"orientation": {
"w": 1
},
"color": {
"g": 0.8
}
},
{
"id": "bigRed",
"type": "BOX",
"pos": {
"x": 0.2,
"y": 0.1,
"z": 0.58
},
"size": {
"length": 0.1,
"width": 0.16,
"height": 0.16
},
"orientation": {
"w": 1
},
"color": {
"r": 0.8
}
},
{
"id": "bigYellow",
"type": "BOX",
"pos": {
"x": 0.2,
"y": 0.3,
"z": 0.58
},
"size": {
"length": 0.1,
"width": 0.16,
"height": 0.16
},
"orientation": {
"w": 1
},
"color": {
"r": 0.8,
"g": 0.8
}
},
{
"id": "smallBlue",
"type": "BOX",
"pos": {
"x": 0.4,
"y": -0.2,
"z": 0.54
},
"size": {
"length": 0.1,
"width": 0.08,
"height": 0.08
},
"orientation": {
"w": 1
},
"color": {
"b": 0.8
}
},
{
"id": "smallGreen",
"type": "BOX",
"pos": {
"x": 0.4,
"y": 0,
"z": 0.54
},
"size": {
"length": 0.1,
"width": 0.08,
"height": 0.08
},
"orientation": {
"w": 1
},
"color": {
"g": 0.8
}
},
{
"id": "smallRed",
"type": "BOX",
"pos": {
"x": 0.4,
"y": 0.2,
"z": 0.54
},
"size": {
"length": 0.1,
"width": 0.08,
"height": 0.08
},
"orientation": {
"w": 1
},
"color": {
"r": 0.8
}
},
{
"id": "smallYellow",
"type": "BOX",
"pos": {
"x": 0.4,
"y": 0.4,
"z": 0.54
},
"size": {
"length": 0.1,
"width": 0.08,
"height": 0.08
},
"orientation": {
"w": 1
},
"color": {
"r": 0.8,
"g": 0.8
}
},
{
"id": "arm",
"type": "ARM",
"pos": {},
"size": {},
"orientation": {
"w": 1
},
"color": {}
}
]
}
# create json file using
# yq eval -o=json config_scene_virtual-table.yaml > config_scene_virtual-table.json
{ 'objects': [
# table
# height: 1m
# width: 2m
{ 'id': 'table', 'pos': { 'z': 0.25 },'size': { 'length': 1,'width': 2,'height': .5 },'orientation': { 'w': 1 },'color': { 'r': 0.3,'g': 0.3,'b': 0.3 } },
#
{ 'id': 'binBlue', 'type': 'BIN','pos': { 'x': -0.35,'y': -0.60,'z': 0.65 },'size': { 'length': 0.20,'width': 0.4,'height': 0.3 },'orientation': { 'w': 1 },'color': { 'b': 1 } },
{ 'id': 'binGreen', 'type': 'BIN','pos': { 'x': -0.35,'y': 0,'z': 0.65 },'size': { 'length': 0.20,'width': 0.4,'height': 0.3 },'orientation': { 'w': 1 },'color': { 'g': 1 } },
{ 'id': 'binRed','type': 'BIN','pos': { 'x': -0.35,'y': 0.60,'z': 0.65 },'size': { 'length': 0.20,'width': 0.4,'height': 0.3 },'orientation': { 'w': 1 },'color': { 'r': 1 } },
# for i in range(3,10): print("{ 'id': 'object4x2x%.1f','type': 'BOX','pos': { 'x': 0.3,'y': %f,'z': %f },'size': { 'length': .0318, 'width': .0636,'height': %f },'orientation': { 'w': 1 },'color': {} }," % (i/2, (i-6)*.1, (i*48+23+7160)/10000, (i*96+46)/10000));
{ 'id': 'bigBlue', 'type': 'BOX','pos': { 'x': 0.2,'y': -0.300000,'z': 0.58 },'size': { 'length': .1, 'width': .16,'height': 0.16 },'orientation': { 'w': 1 },'color': {b: 0.8} },
{ 'id': 'bigGreen', 'type': 'BOX','pos': { 'x': 0.2,'y': -0.100000,'z': 0.58 },'size': { 'length': .1, 'width': .16,'height': 0.16 },'orientation': { 'w': 1 },'color': {g: 0.8} },
{ 'id': 'bigRed', 'type': 'BOX','pos': { 'x': 0.2,'y': 0.100000,'z': 0.58 },'size': { 'length': .1, 'width': .16,'height': 0.16 },'orientation': { 'w': 1 },'color': {r: 0.8} },
{ 'id': 'bigYellow','type': 'BOX','pos': { 'x': 0.2,'y': 0.300000,'z': 0.58 },'size': { 'length': .1, 'width': .16,'height': 0.16 },'orientation': { 'w': 1 },'color': {r: 0.8, 'g':0.8} },
# for i in range(3,10): print("{ 'id': 'object2x2x%.1f','type': 'BOX','pos': { 'x': 0.5,'y': %f,'z': %f },'size': { 'length': .0318, 'width': .0318,'height': %f },'orientation': { 'w': 1 },'color': {} }," % (i/2, (i-6)*.1, (i*48+23+7020)/10000, (i*96+46)/10000));
{ 'id': 'smallBlue', 'type': 'BOX','pos': { 'x': 0.4,'y': -0.200000,'z': 0.54 },'size': { 'length': .1, 'width': .08,'height': 0.08 },'orientation': { 'w': 1 },'color': {b: 0.8} },
{ 'id': 'smallGreen', 'type': 'BOX','pos': { 'x': 0.4,'y': 0.000000,'z': 0.54 },'size': { 'length': .1, 'width': .08,'height': 0.08 },'orientation': { 'w': 1 },'color': {g: 0.8} },
{ 'id': 'smallRed', 'type': 'BOX','pos': { 'x': 0.4,'y': 0.200000,'z': 0.54 },'size': { 'length': .1, 'width': .08,'height': 0.08 },'orientation': { 'w': 1 },'color': {r: 0.8} },
{ 'id': 'smallYellow','type': 'BOX','pos': { 'x': 0.4,'y': 0.400000,'z': 0.54 },'size': { 'length': .1, 'width': .08,'height': 0.08 },'orientation': { 'w': 1 },'color': {r: 0.8, 'g':0.8} },
{ 'id': 'arm','type': 'ARM','pos': { },'size': { },'orientation': { 'w': 1 },'color': { } }
] }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment