DesignCAD 3D Max 2027 box
Now available

DesignCAD 2027

Hatches that follow their boundaries, an on-screen dial to turn your model, and a way to find any command by name, in a clean Windows 11 look.

Solids changing colors without my permission

Started by roger_c130, April 18, 2008, 04:17:56 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

roger_c130

I'm back sooner than I thought.  Several of my forms refuse to stay in the color I initially set up.  They go from a light tan to a dark crystaline color.  Weird.  I've tried redrawing the forms from 2D to 3D solids, recolored them, put them back in my drawing, and within an instruction or two, they change.  Where should I begin to look for this problem?

kchoekstra

Roger, can you post a drawing with the problem.

    KC

roger_c130

Actually, I can.  What's the best way to do that?  DCD file or other?

edgar

If you click "Additional Options" you may enter any of a number of file types which will show up in your post.
-Ed

roger_c130

Sending as a dcd file.  This version seems to have reverted to original colors.

Rob S


The setting for "enable color material" in the shading dialog will affect whether the material color overrides the objects assigned color.

Also, lighting and direction of lighting significantly affects apparent colors, if you rotate your object, also depends of the reflectivity settings of your materials.

I have not experienced DCAD arbitrarily changing colors, but I have lots of instances where they don't come out looking as I would expect them to!!!

Colors, materials, shading, and lighting are definitely works of art, rather than science.
User since forever

Dr PR

roger,

First, you have a yellowish color assigned to layer 88 (R182, G182, B0). Light color is white (R255, G255, B255). The solids have "Multiple material" properties and an assigned color of orangish yellow(R255, G237, B77) and orange (R255, G135, B34). Lines are red (R213, G0, B0). One of the objects on layer 88 is not a solid, but just a hollow grid (these sometimes color differently from solids). Some of the "multiple color" solids appear to have been drawn in black and then have an assigned material of a different color (or colors). Some groups span multiple layers with different assigned layer colors. Frankly, I don't understand why the drawing ever displays with "normal" colors.

If you shade with "Quick (Flat)" and "Gouraud" with graphics acceleration enabled you get what appears to be the object color. Without graphics acceleration enabled you get different colors. And with Phong shading you get a third set of colors. If you select the "Enable color material" option you get a fourth set of colors.

For 3D drawings I recommend disabling layer colors (select the layer in the "Options/Layers" dialog box (L) and click the "Color reset" button.

You should select all solids and assign a material to them. With some materials (default) you can also assign a color - you should do this.

Be sure solids are not made up of parts on different layers. This can cause strange results. Note that the 3D boolean operations have a bug that occasionally causes solids to change layers - usually to layer 1.

If you are going to make a 3D drawing always work in 3D. Colors can look different in 2D, and switching to 3D (where lighting matters) will cause the colors to change.

You can continue to use this drawing but you should explode all groups and select each object individually. Use the Info Box to be sure you have selected a single object, on a single layer, and assign your desired material and color. Since you are working mostly with solids, look for lines and grids. These can cause odd colors effects in shading.

Don't use the "Enable color material" option in the "Shading Options" dialog until you fully understand what it does (I don't).

Select a shading option that suits you and always use that. Use wireframe for normal editing and shade to see what the work really looks like. If you plan to add textures and want more complex lighting effects you should use Phong shading (much slower).
DesignCAD user since 1987

roger_c130

Thanks again.  I'll try to restart the drawing with all suggestions.  Now if you can tell me how to turn off Wire Frame I'll be in business.  I have to turn it on when I'm turning a 2D into 3D with color or very strange things happen to my drawing like getting colored without any colors being set.  I'm now stuck with my drawing in wire frame (same drawing I sent out) and though the turn off may be simple, I haven't found the way yet.

Bob P

I made my own toolbox with 4 "view" macros.  You can also run them from the command line.

Standard shade:

'sh1.dcm
sys(2)=2  'Flatshade mode
>regenerate
{
}

-----------------

Smooth shade:

'sh2.dcm
sys(2)=3  'Smooth shade mode
>regenerate
{
}

---------------------

Hidden line:

'hidl.d3m
sys(2)=4  'Hidden line mode
>regenerate
{
}

---------------------------

Wireframe:

'wiref.d3m
sys(2)=0 'wireframe mode
>regenerate
{
}

prl

QuoteNow if you can tell me how to turn off Wire Frame I'll be in business.

You can't turn it off but you can select a different rendering mode. 

Like BobP, I've created something to help me model in 3d.  I wanted a very quick way to change the rendering view of my drawing.  99% of the time I model in wireframe but sometimes I get lost in all the lines and I want to quickly double check things by shading or hidden line. It helps me get my bearings.

The below code is my solution.  I have it hotkeyed so I just hit it a bunch of times and stop at the rendering setting I want.

' Program:  qs.d3m (quick shade - a round-robin viewing toggle)

gosub getversion
if dcver > 15 then
  shade = 3
else
  shade = 2
endif

if Sys(344) = 1 then
   Message "in 2d mode. . . press any key to continue"
   end
end if
      
' Sys2 is the mode, 0-4
'0 = wireframe
'1 = OpenGL Hidden
'2 = OpenGL Flat Shade
'3 = OpenGL Smooth Shade
'4 = OpenGl Hidden (no surface intersections)

if sys(2)=0 then
   sys(2)=shade
   goto here
end if

if sys(2)=4 then
   sys(2)=0
   goto here
end if

if sys(2)=shade then
   sys(2)=4
   goto here
end if

here:
end


getversion:
  s$ = sys$(105)
  fmt$ = "%d.%d.%d"
  parse s$, fmt$, dcver, dum1, dum2
return

roger_c130

Thanks to all.  I shall each suggestion as I forge on. I've been in 2D for years.  Getting into 3D is a whole new ball game for me.  Now, onward until the next stumper.

Dr PR

Roger,

Wireframe is the default mode for 2D, but in 3D you can work in wireframe, hidden line or shaded mode. There are three buttons on the tool bar at the top of the screen just below the menu line. These are "Wireframe," "Hidden Line Removal" and "Shading." Just click the appropriate button to switch between modes.

If you are in shaded mode in 3D and switch to 2D you automatically get wireframe mode. However, when you switch back to 3D you will return to the last mode (shaded) you used in 3D. If you don't want this to happen just deselect the "Enable graphics acceleration" box at the bottom of the "Shading options" dialog box before switching back to 2D.
DesignCAD user since 1987