Skip to main content

I'm doing a CAD to CAD conversion, but my final file, is constantly losing the hatches, in most cases do not show the hatches in the output file. Could someone help me and tell you what's going on? Follow my template

 

Thank´s

Hi @maccabi,

The hatch patterns from the source file may not be defined in your Template.dwg file. Please try using your source DWG file as the template file for the RealDWG writer instead - only the definitions will be copied, not the data.


Hi @maccabi,

The hatch patterns from the source file may not be defined in your Template.dwg file. Please try using your source DWG file as the template file for the RealDWG writer instead - only the definitions will be copied, not the data.

Hi @DaveAtSafe

I finished my tests. Using the input file as a template, but the result was the same ... without hatches.

 


Hi @maccabi,

The hatch patterns from the source file may not be defined in your Template.dwg file. Please try using your source DWG file as the template file for the RealDWG writer instead - only the definitions will be copied, not the data.

Hi @DaveAtSafe,

I have already tried that and the result is still not OK after checking the result in a DWG Viewer. I wonder if it has to do with the lack of AutoCAD patterns that are not available with the FME installation.


Hi @maccabi,

The hatch patterns from the source file may not be defined in your Template.dwg file. Please try using your source DWG file as the template file for the RealDWG writer instead - only the definitions will be copied, not the data.

Attached is a template reading a singel (problematic) feature type, filtering on format attributes and using the those values in a DWGStyler.

The source file is used as a template in the writer and DWGStyler transformer.

The warning in the log shows the following:

AutoCAD Writer: The combination of pattern type 'Pre-defined' and pattern name 'GOST_GLASS' was found to be invalid. Using a default predefined hatch pattern of value of 'SOLID'

what is the pattern type 'Pre-defined' ?

Created using FME 2018.1.1.1 (20181203 - Build 18578)

acad2acad2.fmwt


Hi,

I have exactly the same problem. Do you find a solution?

In my case, the hatche is invisible but, with a "ctrl + a" in AutoCad, we can see them!

Thank´s

 

Chris


@maccabi

 

Seems limited to (at least) the GHOST_GLASS pattern. (maybe some others, but did not check myself)

 

I tried different patterns and they all appear in AutoCAD...but GHOST_GLASS refuses.

 

According to some autocad forums the problem would be the driver of the graphic card(?!)

I have not checked that, but I seem not able to apply it (ghost_glass) using fme

Earlier post on this forum concerning the same problem (Did you search the forum?) indicate fme not performing well with associative hatches. (like Donald says: I dunno, maybe it is, maybe not!)

Not a template issue either, afaik.

 


@maccabi

@daveatsafe

@itay

Hi,

I checked again, because i have some scripts that do that and they all work.

 

So, looking at @maccabi workspace and comparing it to mine, i found that it does work if you use a AUTOCAD_OD or REALDWG writer.

Only ACAD writer fails.

(You don not even need a template.)

And "pattern type 'Pre-defined'" dissapears.

Change the writertype.

Hatch_and_ACAD_writertype.fmw


@maccabi

@daveatsafe

@itay

Hi,

I checked again, because i have some scripts that do that and they all work.

 

So, looking at @maccabi workspace and comparing it to mine, i found that it does work if you use a AUTOCAD_OD or REALDWG writer.

Only ACAD writer fails.

(You don not even need a template.)

And "pattern type 'Pre-defined'" dissapears.

Change the writertype.

Hatch_and_ACAD_writertype.fmw

Nice one @gio


Hi,

My problem is with Solid hatches. I did a lot of research and this is the only post identical to my problem. Attached Test_Hachure.zip is the input AutoCad file, the FME script, and the DWG output.

I tried all types of Writer. My hatch is not associative and besides, it has no outline. The only difference found is the absence of the surface value in the properties of the entity in AutoCad.

Thank's

Chris

 


@chriscool

 

Hi Chris,

 

There is nothing wrong with the "Test_Hachure.dwg" file.

I open it and see the solid hatch.

 

I presume it is your draw setting in autocad.

 

You need to enter FILLMODE on the command line in autocad.

You must chnge 0 (off) to 1 (on).

(sometimes you must zoom to extents or give it a chance to redraw for it to take effect. )

 

Autocad has some settings that prevent continues work by your graphics card, so one can smoothly do some work. Fillmode is one of them.

In early Autocad on pc's from yesteryear, automatic graphical updating was like...arrghhh..soo slow.

 


Hi Gio

In fact, "Test_Hachure.dwg" is the input file of the FME script and "Test_Hachure_New.dwg" is the result.

It is in this last file that the problem arises and the variable "Fillmode" is at 1. It can be found with a "ctrl + A", we can see that it has no surface property.

If we move a vertex of the object, at that moment, the hatch appears!

Bye

Chris


Hi Gio

In fact, "Test_Hachure.dwg" is the input file of the FME script and "Test_Hachure_New.dwg" is the result.

It is in this last file that the problem arises and the variable "Fillmode" is at 1. It can be found with a "ctrl + A", we can see that it has no surface property.

If we move a vertex of the object, at that moment, the hatch appears!

Bye

Chris

@chriscool

I see the problem (more or less).

 

If you change the reader settings on "Test_Hachure.dwg" you get 2 objects.

In your reader it is 1. Seems like just hatchdefinition is passed, its border definition.

Don't know how t.b.h.

 

But, i found that if you just stick a dwg styler between the exposer and the feature writer, slect the pattern you want, it works fine.

Setting the pattern attribute manualy (atributecreator) did not succeed, using dwg styler did work...

 

 

 

 


Hi @maccabi,

 

I recently had the same problem, but only when the hatches already exist from an input drawing. I found out that FME reads the autocad_hatch_style attribute as a number while a DWG writer expects a name (i.e. "acid").

So, the workaround is to expose the attribute autocad_hatch_style and overwrite it with the correct style name or (in my case even better): simply remove the attibute!

Call for Safe: please resolve this tiny but annoying bug;)


Reply