Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Qt3D Cube, No surface texture but with edges, how to?

Qt3D Cube, No surface texture but with edges, how to?

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 926 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • jiapei100J Offline
    jiapei100J Offline
    jiapei100
    wrote on last edited by
    #1

    Hi, all:

    I'm trying to create a cube shape, without any texture on the surfaces, but it should still be able to show the edges. I tried:

    @QGLSceneNode *cube = builder.finalizedSceneNode();
    QGLMaterial *mat = new QGLMaterial;
    mat->setColor( Qt::transparent);
    cube->setMaterial(mat);@

    Nothing can be shown up.

    If I try
    @QGLSceneNode *cube = builder.finalizedSceneNode();
    QGLMaterial *mat = new QGLMaterial;
    mat->setColor(QColor(255, 0, 0));
    cube->setMaterial(mat);@

    This will show up a cube with texture on all surfaces.

    Is there a method to show just the edges (maybe I can specify the edge width, or even emphasize the vertexes), but not the surfaces?

    Cheers
    Pei

    Welcome to Longer Vision
    https://www.longervision.com

    1 Reply Last reply
    0

    • Login

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Get Qt Extensions
    • Unsolved