My first CAD file it is too slow, and had to stop.

If you are having problems with QCAD, post here. Please report bugs through our Bug Tracker instead.

Always attach your original DXF or DWG file and mentions your QCAD version and the platform you are on.

Moderator: andrew

Forum rules

Always indicate your operating system and QCAD version.

Attach drawing files and screenshots.

Post one question per topic.

Post Reply
MarkMcC
Junior Member
Posts: 14
Joined: Thu Apr 08, 2021 9:33 am

My first CAD file it is too slow, and had to stop.

Post by MarkMcC » Thu Apr 08, 2021 10:10 am

I'm new to QCAD, and recently got paid version. This is my first post in forum.
Did a search of forum to see if I could see something previously related, and answered, and could not see.

I am recently working on my first CAD file, for a Horticultural landscape project, and noticed a 'dramatic' slow down,
after opened one extra tab, of cad Blocks elements, to copy into my main file, and after I added the first block.
Was hoping to add more blocks(by copy command), to create patterns, but it is too slow, and had to stop.

The CAD file itself is very small at 113kb. Please see attached.

Thanks.


QCAD version is most recent:

Version:
3.26.1.0 (3.26.1)
Internet:
QCAD.org
Build Date:
Mar 8 2021
Revision:
eec8166
Qt Version:
5.8.0
Architecture:
x86_64
Compiler:
gcc 4.8.1


I am using:

Operating System: Kubuntu 20.10
KDE Plasma Version: 5.19.5
KDE Frameworks Version: 5.74.0
Qt Version: 5.14.2
Kernel Version: 5.8.0-48-generic
OS Type: 64-bit
Processors: 2 × AMD A4-4000 APU with Radeon(tm) HD Graphics
Memory: 10.9 GiB of RAM
Graphics Processor: Radeon RX 580 Series
Attachments
din_a3_m_landscape_B-Front-beds-002_R.dxf
(332.84 KiB) Downloaded 517 times

User avatar
andrew
Site Admin
Posts: 9037
Joined: Fri Mar 30, 2007 6:07 am

Re: My first CAD file it is too slow, and had to stop.

Post by andrew » Thu Apr 08, 2021 1:34 pm

The file contains some blocks with extremely dense hatches (essentially creating ten thousands of lines). Changing these to solid fills will help (see attached).
Attachments
din_a3_m_landscape_B-Front-beds-002_R_solid.dxf
(325.4 KiB) Downloaded 426 times

MarkMcC
Junior Member
Posts: 14
Joined: Thu Apr 08, 2021 9:33 am

Re: My first CAD file it is too slow, and had to stop.

Post by MarkMcC » Thu Apr 08, 2021 3:29 pm

Hi Andrew,
Thanks for look at the file and explaining.

Not quite sure what you did, as it looks the same,
so I cannot replicate your method.

Have looked up "Changing these to solid fills", from [Draw], [Hatch].
But I cannot see any sign of "dense hatch" elements being changed to "solid fills".

Is there a screenshot example or video I can follow ?

Thanks

CVH
Premier Member
Posts: 3416
Joined: Wed Sep 27, 2017 4:17 pm

Re: My first CAD file it is too slow, and had to stop.

Post by CVH » Fri Apr 09, 2021 5:10 am

Hi,
The most demanding culprits are in block 'plant8'.

The major problem is that the file is very slow as it comes .... :wink:
... extremely slow with a maxed out timeout for hatches as I am used to. :roll:
The original file will handle better every change we are going to make. :)

First, reduced the timeout for hatches to the minimum.
Application Preferences (Cntrl+,) .. Graphics View .. Appearance .. Timeout for hatch rendering > 125(ms).

Then, edit block 'plant8', double click on the block in the Block List.
Selection Filter (GF) .. Hatches .. Solid is false .. Replace current selection.
What finds and selects 11 hatches 'ANSI31'. (The leaves and the inside of the flowers)
Set the current selection to Solid=Yes in the Property Editor.

Now the hatches are in front of the other plant details ...
Selection Filter (GF) .. Hatches (All) .. Replace current selection.
Send to back (MB)

Next is a bit harder to understand ... Hatching stuff e_geek ... Same easy fix. :)
Block 'plant11' uses a herringbone pattern called 'AR-HBONE,_O'

Code: Select all

*AR-HBONE,_O, No brief description
; Extracted by:    QCAD3 Pro                 Tile2Hatch beta v0.17 © CVH 2020-21
; Metric source drawing: C:/Users/Admin/Desktop/Temp/din_a3_m_landscape_B-Front-beds-002_R.dxf
; Hatch Angle: 0 = 0° | Hatch Scale: 3e-7
; Hatch Origin: 0 | 0
; Definitions:  Angle , StartPointX , Y , dXshift , dYoffset , Dashes(1-6)
;  = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
45,-152237.03792707805,-123844.68430849486,101.59999999992472,101.59999999992473,304.8,-101.60000000000001
135,-152165.19592707805,-123772.84230849528,101.59999999992473,-101.59999999992472,304.8,-101.60000000000001
1) I doubt that the naming is correct but then again QCAD is extremely tolerant. [A-Za-z0-9_-$]
2) The definition of this pattern sits about at minus 150-125.000 units (meters) in X&Y away from the origin.
3) It consists of stones 203.2 x 101.6 units large, the hatching scale is 3e-7.
This all, while your plant blocks are defined as hardly 1mm large!

Edit block 'plant11'.
Selection Filter (GF) .. Hatches .. Solid is false .. Replace current selection.
What finds and selects 8 hatches.
Replace these in the Property Editor with the standard 'AR-HBONE' pattern.
What is exactly the same apart from the odd startpoints:

Code: Select all

*AR-HBONE,AR-HBONE
45, 0,0, 101.6,101.6, 304.8,-101.6
135, 71.842,71.842, 101.6,-101.6, 304.8,-101.6
On the other hand, I see no reason why this should be 8 separate hatches.
One could remove them and create one new hatch between the two concentric circles.
Pattern 'AR-HBONE', scale 3e-7.
The problem here is that R=0.000096 & 0.000211 doesn't hatch correct. :shock:

Plant11_NewHatch.png
Hatching fails, set apart on purpose
Plant11_NewHatch.png (5.14 KiB) Viewed 8028 times

Even with these changes, block 'plant11' induces a certain lag at some zoom states.
I would not expect any lag from this very simple and stable pattern.
I expected it to render them at block level and then scales/rotates them as line art .... What is not :!:
It seems that QCAD re-renders hatches in blocks back in Model_Space.
And then it hits the large definition and the infinite small hatch scale times the quite larger block scale ... :shock:



A word on the used scales in general:
The plant blocks are declared so tiny that you hit the lower error margin.
See indicated below:

Plant8.png
Plant8.png (16.34 KiB) Viewed 8028 times

They are then used in Model_Space at scales x1200, x2997.598547 and x720.
I would advise to insert these over new in a useful and larger scale.
And also to use Block Z scale = 1.

Re-scaling them up as they are does the trick for the line art but doesn't resolve the flaws with the hatches.
It only makes things much worser. :roll:
Re-scaled the 25 solid colored hatches in the example below needs to be made over new from the scaled boundaries.

Plant8_ScaledUp.png
Block entities scaled up x100
Plant8_ScaledUp.png (23.57 KiB) Viewed 8028 times

We can't help you there as we don't have the original source of those blocks.

Finally reset your hatching timeout preference back.

Remark also that there is an empty text @(386.873812, 34.308061), one you can't select individually ...
Type 'TH', enter handle 0x445 and enter some (dummy) text in the Property Editor.

Regards,
CVH

MarkMcC
Junior Member
Posts: 14
Joined: Thu Apr 08, 2021 9:33 am

Re: My first CAD file it is too slow, and had to stop.

Post by MarkMcC » Fri Apr 09, 2021 12:59 pm

Hi CVH,

Thanks so much for that detailed explanation,
and I could follow all until where you mention: "Replace these in the Property Editor with the standard 'AR-HBONE' pattern."

QCAD is definitely running at better performance now, and now usable, (as it had grinded me to a halt !).

This is the origin of the troublesome CAD blocks I used, and you examined are from:
https://cad-block.com/638-potted-plants-plan.html

Is there a way I can just turn those cad blocks into simplified grouped entities first, and then copy across into my
main CAD file ?

I do not need to edit these complex blocks, and was only to use them, for optical/graphical/symbolic-effect/reference,
and if not as if I have a critical aircraft wing section, and need to make a slight but critical modification.

I did not realise that there were internal name references, and so that they could be screwed up with poor
naming choices references.

Can QCAD pick this up on import filter, and give an opportunity for user, to rename, and save with safer names ?

Thanks again.

User avatar
Husky
Moderator/Drawing Help/Testing
Posts: 4935
Joined: Wed May 11, 2011 9:25 am
Location: USA

Re: My first CAD file it is too slow, and had to stop.

Post by Husky » Fri Apr 09, 2021 11:00 pm

MarkMcC wrote:
Fri Apr 09, 2021 12:59 pm
I do not need to edit these complex blocks, and was only to use them, for optical/graphical/symbolic-effect/reference ...
It is always helpful to keep in mind what the purpose is of any action. QCAD isn't designed to do a graphical design and frankly no CAD system is built to do that. Bottom line - even if you are able to tweak a software to do something which isn't designed for that task doesn't mean it make sense to do so.

In your case I would recommend to think outside the box. If you need something like a flower in a graphical fashion then just use a ... bitmap picture. My example shows a screenshot of the plant, with white background, used in a block. Even if I use 20000 bitmaps for "optical/graphical/symbolic-effect/reference" reasons the performance of the software/drawing is still acceptable.

Proof with 20 thousand plant blocks:

QCAD flower block test.gif
QCAD flower block test.gif (6.1 MiB) Viewed 7960 times
Work smart, not hard: QCad Pro
Win10/64, QcadPro, QcadCam version: Current.
If a thread is considered as "solved" please change the title of the first post to "[solved] Title..."

CVH
Premier Member
Posts: 3416
Joined: Wed Sep 27, 2017 4:17 pm

Re: My first CAD file it is too slow, and had to stop.

Post by CVH » Sat Apr 10, 2021 8:04 am

@ MarkMcC,

Thanks for the source.
MarkMcC wrote:
Fri Apr 09, 2021 12:59 pm
I could follow all until where you mention: "Replace these in the Property Editor with the standard 'AR-HBONE' pattern."
What didn't you understand there?
The full text was:
  • Edit block 'plant11'.
    Selection Filter (GF) .. Hatches .. Solid is false .. Replace current selection.
    What finds and selects 8 hatches.
    Replace these in the Property Editor with the standard 'AR-HBONE' pattern.
With those 8 hatches 'AR-HBONE,_O' in selection change their pattern in the Property Editor.
Property Editor .. Specific Properties .. Pattern .. Name > dropdown and select the standard pattern 'AR-HBONE'.

Used patterns are stored in the dxf with there definitions.
Once such a pattern is stored, QCAD will use the included pattern even if the name would match with a native installed pattern.

Here it even doesn't match in name but it is in general about the same pattern.
'AR-HBONE,_O' is a wrong pattern name and as stated also a bad pattern definition.
Naming is restricted to [A-Za-z0-9_-$] not starting with the last 3 'special' characters.
Under QCAD the general advise is to keep the pattern origin near where the pattern is used.
What is (0,0) and seems OK apart from that the extraction shows that the startpoints of this odd named pattern are way off.
MarkMcC wrote:
Fri Apr 09, 2021 12:59 pm
Can QCAD pick this up on import filter, and give an opportunity for user, to rename, and save with safer names ?
NOT at all, the general idea is that one can distribute a dxf without the need to distribute all the pattern files used in it.
All to ensure that the patterns of the designer side are used and the patterns native to the receiver side are disregarded.

- - - - - -

Now about the source .... >potted-plants-plan.dwg<
The file is metric, in mm, handles with no lag at all, in Model_Space the plants are about 1000mm wide but not all look OK.
Apart from some, the plants blocks are rather tiny, mostly 0.2-0.3mm wide, hence the quite large block reference scales.

Let's say we are copying only reference 'plant8' from >potted-plants-plan.dwg< Model_Space to a new drawing in meters.
We expect the block to be copied over and to be scaled from mm to meters.
Paste ...
QCAD goes in a stall .. huge CPU load .. nothing after 15 minutes and more :shock:
There is something buggy with this approach, I had to kill the process.

Trial2:
Open >potted-plants-plan.dwg<
Drawing Preferences .. General .. Drawing Unit > Change to meters (This doesn't do anything to a dxf what is in fact unitless)
Start a new drawing in meters.
Copying reference 'plant8' to the new file works out, no scaling is involved as both drawings are in meters.
The plant will be huge (x3000), the plant block is about 20cm in diameter what is perfect. :P
Select the block reference in Model_Space and set scale to x1.
All OK. :wink:
>potted-plants-plan.dwg< 'plant6' looks OK in the block but not at all in Model_Space ... :shock:
Copy over with the same method ... Set block reference scale = 1
All OK. :P
MarkMcC wrote:
Fri Apr 09, 2021 12:59 pm
Is there a way I can just turn those cad blocks into simplified grouped entities first, and then copy across into my
main CAD file ?
It seems that this last method solves an suits the import of the very tiny blocks the best.
For 'fl1' and 'palm' set the unit of >potted-plants-plan.dwg< back to mm.

Regards,
CVH

MarkMcC
Junior Member
Posts: 14
Joined: Thu Apr 08, 2021 9:33 am

Re: My first CAD file it is too slow, and had to stop.

Post by MarkMcC » Thu Apr 29, 2021 7:49 am

Thanks guys for all the well thought replies on this !

Post Reply

Return to “QCAD Troubleshooting and Problems”