Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I want to add a 2D surface of a static image to a 3DScatter graph as shown below.

enter image description here

I can achieve this using QCustom3DVolume. However my app uses OpenGL ES and QCustom3DVolume's documentation explicitly says that it does not support OpenGL ES environments.

I have also tried creating a simple cubic obj mesh file, load it using QCustom3DItem and set its textureFile property to my desired image. However there seems to be no way to scale the texture image to fit the item size as shown below.

enter image description here

original image:

enter image description here

mesh file:

# WaveFront *.obj file (generated by Autodesk ATF)

mtllib 5eb607c1-f53f-4cb4-b0b6-7d334249fcd3.mtl

g Body1

v 0.000000 0.000000 0.000000
v 0.000000 -1.000000 0.000000
v 0.000000 -1.000000 1.000000
v 0.000000 0.000000 1.000000
v 1.000000 0.000000 0.000000
v 1.000000 0.000000 1.000000
v 1.000000 -1.000000 0.000000
v 1.000000 -1.000000 1.000000
vt -0.000000 0.000000 0.000000
vt 0.100000 0.000000 0.000000
vt -0.000000 0.100000 0.000000
vt 0.100000 0.100000 0.000000
vt -0.000000 0.000000 0.000000
vt 0.100000 0.000000 0.000000
vt -0.000000 0.100000 0.000000
vt 0.100000 0.100000 0.000000
vt 0.000000 0.000000 0.000000
vt 0.100000 0.000000 0.000000
vt 0.000000 0.100000 0.000000
vt 0.100000 0.100000 0.000000
vt 0.000000 0.000000 0.000000
vt 0.100000 0.000000 0.000000
vt 0.000000 0.100000 0.000000
vt 0.100000 0.100000 0.000000
vt -0.050000 -0.050000 0.000000
vt 0.050000 -0.050000 0.000000
vt -0.050000 0.050000 0.000000
vt 0.050000 0.050000 0.000000
vt -0.050000 -0.050000 0.000000
vt 0.050000 -0.050000 0.000000
vt -0.050000 0.050000 0.000000
vt 0.050000 0.050000 0.000000
vn -0.100000 0.000000 0.000000
vn -0.100000 0.000000 0.000000
vn -0.100000 0.000000 0.000000
vn -0.100000 0.000000 0.000000
vn 0.000000 0.100000 0.000000
vn 0.000000 0.100000 0.000000
vn 0.000000 0.100000 0.000000
vn 0.000000 0.100000 0.000000
vn 0.100000 0.000000 0.000000
vn 0.100000 0.000000 0.000000
vn 0.100000 0.000000 0.000000
vn 0.100000 0.000000 0.000000
vn -0.000000 -0.100000 0.000000
vn -0.000000 -0.100000 0.000000
vn -0.000000 -0.100000 0.000000
vn -0.000000 -0.100000 0.000000
vn 0.000000 0.000000 0.100000
vn 0.000000 0.000000 0.100000
vn 0.000000 0.000000 0.100000
vn 0.000000 0.000000 0.100000
vn -0.000000 0.000000 -0.100000
vn -0.000000 0.000000 -0.100000
vn -0.000000 0.000000 -0.100000
vn -0.000000 0.000000 -0.100000
usemtl Steel_-_Satin
f 1/1/1 2/2/2 4/3/3
f 4/3/3 2/2/2 3/4/4
f 5/5/5 1/6/6 6/7/7
f 6/7/7 1/6/6 4/8/8
f 7/9/9 5/10/10 8/11/11
f 8/11/11 5/10/10 6/12/12
f 2/13/13 7/14/14 3/15/15
f 3/15/15 7/14/14 8/16/16
f 3/17/17 8/18/18 4/19/19
f 4/19/19 8/18/18 6/20/20
f 7/21/21 2/22/22 5/23/23
f 5/23/23 2/22/22 1/24/24

# 8 vertices
# 24 texture params
# 24 normals
# 12 facets

# 1 groups

Is there any other way to achieve this?

question from:https://stackoverflow.com/questions/65891996/how-to-add-2d-surface-to-a-qml-scatter3d

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
1.6k views
Welcome To Ask or Share your Answers For Others

1 Answer

Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...