daid / LegacyCura

Read this, it's important! NEW CURA DEVELOPMENT IS HAPPENING AT https://github.com/Ultimaker/Cura, this is the Cura 15.04 archive. Cura 2.1 and newer is on the Ultimaker github.
https://www.ultimaker.com/pages/our-software
584 stars 429 forks source link

varying layer heights (feature) #447

Open Fantiki7 opened 11 years ago

Fantiki7 commented 11 years ago

is it possible to make diferent thickness for different layers? (like Slic3r 0.9.9 has)

daid commented 11 years ago

You mean different thickness for infill and perimeters?

plasmasolutions commented 11 years ago

Hi Daid, I think he means that you have several very thin layers at difficult to print spots, while you have a larger layer size on easy to print areas.

daid commented 11 years ago

Ah, wasn't hat patented somewhere?

plasmasolutions commented 11 years ago

Hi David, not that I knew... Slic3er implemented this option since a bit more than a month..

http://www.soliforum.com/topic/2323/slicer-099-different-layer-height-on-same-print/

ahmetcemturan commented 11 years ago

Hi Daid I have some documentation about the implementation of variable thickness slicing... https://dl.dropboxusercontent.com/u/38819298/Adaptive%20Slicing.zip

Fantiki7 commented 11 years ago

yeah, Daid, i mean exactly this (thanks to plasmasolutions) http://www.soliforum.com/topic/2323/slicer-099-different-layer-height-on-same-print/

daid commented 11 years ago

I do think I've seen a patent about it somewhere. Not 100% sure. Also not sure why you need 4 papers to describe "make the layer thickness depend on the surface angle" But then again, I'm not an academic idiot, I'm a practical idiot.

ahmetcemturan commented 11 years ago

"I'm not an academic idiot, I'm a practical idiot." Yeah thats probably it... We all are...

Fantiki7 commented 11 years ago

Im sorry, Daid, what do You mean "patent" ? Do You think somebody has any copyrights about "different layer thickness slicing" ?? I think it is nonsense.

All I asked about is very simple: I want to have plugin (or option), where I can MANUALLY set up any intervals of layer height slicing, depending on model height. For example, i want : from 0 to 3 mm - layer height=0,1 mm from 3 to 20 mm - layer height=0,3 mm from 20 to 22 mm - layer height=0,06 mm Because my model has very light curved surfaces on top and bottom, and simple cube in the middle.

daid commented 11 years ago

Tada: http://www.google.com/patents/US6505089

Fantiki7 commented 11 years ago

Ok, let' see.. It's just a method for manufacturing a 3D model with using of SPECIFIED apparatus. In fact, this is a some sort of 3d-printer, and know-how of it is "using any compatible material, melting, controlling of slope, thickness of material ejection" etc. This patent have common words, no concrete details, and seems like any "sewing machine" patent. No any "specific slicing algorythm" is provided. I can find many similarity and distinction of this patent and any other 3D-print technology,beginning from user interface and finishing by thermal bed, or fan:)

Fantiki7 commented 11 years ago

But, if You afraid violating, then, following Your logic, any 3D printers (repRap, Ultimaker, MakerBot and so on) are violating some fields of this mighty patent :)) So, folks, please, close your manufacturing, stop programming and get out :)

ghost commented 8 years ago

Add my 2 cents, I think this would be a good idea. That patent is not for just differing layer heights - it's for a whole setup. You won't get into legal difficulties over adding this algorithm to some software. Slicing at different heights is already done by other packages such as Slic3r anyway.

daid commented 8 years ago

You won't get into legal difficulties over adding this algorithm to some software.

I don't think any of us are lawyers or patent experts. Implementing this and regarding the patent as "not applicable" is a risk. Not directly for Cura, but for Ultimaker. For Slic3r it is easier to get a way with it. It's not in the market where owner of the patent is operating. And Ultimaker is. So sadly, this is something we have to decide internally at Ultimaker first. (With all the perks of being with a larger company also come the downsides)

Fantiki7 commented 8 years ago

ok, but think about a thing like "plugin". A possibility of violation some rights is not a real violation, actually, isn't 'it? :) It's just possibility. You may apply it, as final user, or may not :) Especially when this plugin is made by 3rd person, especially fo free )

At the last, look again into Your link http://www.google.com/patents/US6505089

"24 feb 2015 FP Expired due to failure to pay maintenance fee"

It's expired! :)

Fantiki7 commented 8 years ago

By the way, where can I learn how to make a plugins for Cura?

sdjmchattie commented 8 years ago

Patents only last 10 years and it was filed in 2000. The fee status tells you that it's lapsed - the patent doesn't apply.

daid commented 8 years ago

Awesome.

sdjmchattie commented 8 years ago

@Fantiki7 Not wanting to get too far off topic here, but take a look at an existing plugin - something like this: http://wiki.ultimaker.com/images/BedTempAtZ.py

You'll have to understand Python first and note that the comment lines at the top actually interact with Cura to get parameter values set by the user and to label the plugin correctly in the interface.

I've not tried to write any plugins, but it also looks like the filename variable is set for you to point at the gcode file that was created.

The plugin I've linked to reads in the gcode file then opens the file again for writing. It goes through the file, looking for a change in Z. When it finds a change in Z that is greater than or equal to the user specified Z-height, it adds three lines of gcode to change the temperature, and for every line it always outputs the existing gcode to the file.

BagelOrb commented 8 years ago

I actually think making the layer height depend on the angles of faces in a layer is a bad idea. It would require different Bowden pressure at each layer, which would cause under and overextrusion at layer starts.

I think it would be a better idea to have a user specify at which height he wants a change of layer thickness.

daid commented 8 years ago

@BagelOrb I disagree. You look at the angle of the faces, calculate the height for each layer, and then smooth those so you get smooth layer height changes. This means you do not get the effects of large pressure changes, and you have an automatic system instead of more manual configuration.

BagelOrb commented 8 years ago

Another problem is that the optimal speeds we currently have in the profiles depend on the layer height a.o.

I can only imagine the quality of there print going down (since we cannot extract a formula for the speeds with our current knowledge)

Above some of the cons, what are pros?? Op 4 mei 2016 09:46 schreef "daid" notifications@github.com:

@BagelOrb https://github.com/BagelOrb I disagree. You look at the angle of the faces, calculate the height for each layer, and then smooth those so you get smooth layer height changes. This means you do not get the effects of large pressure changes, and you have an automatic system instead of more manual configuration.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/daid/Cura/issues/447#issuecomment-216768654

Fantiki7 commented 8 years ago

It's not a problem (theoretically, of cource). We can offer for the user to specify:

And automatically calculate the height of each transitional layer for a smooth transition

nallath commented 8 years ago

Patents last for 20 years. Not 10.

Fantiki7 commented 8 years ago

@nallath, In general, the validity of the patent depends on the country of patenting, the patenting of an object and ranges from 5 to 25 years. In addition, the patent must be regularly paid. Otherwise the patent expires, as in our case.

nallath commented 8 years ago

I know. But the average of patents (EU & US) is definately not 10 years. That was the statement I was responding to. In this case the patent seems to have expired, but that does not mean that there are other patents out there that could still influence this.

sdjmchattie commented 8 years ago

I don't know where I got 10 years from - that was mentioned at patents training I once did. It seems unlikely there would be other patents out there for this since patents can only be filed where there is no "prior art" and clearly there was in the patent which has now expired.

nallath commented 8 years ago

There can be patents that were filed -after- this that "expand" on this. Patents are by far not as clear cut that if one patent expires that suddenly we can do something with this. It could also be that there was a prior patent but it was simply not found by the office. There are companies that dilberately miscategorise patents to make them harder to find in order to "trap" other companies.

BagelOrb commented 8 years ago

I still haven't heard any arguments for why we would want variable layer height depending on features of the 3D model.

Fantiki7 commented 8 years ago

@BagelOrb I asked about this "option" for users. I wanted to manually set a height for some layers. No need automatic calculation.

for example, it may be required on curved surfaces, or angle surfaces. It can significally reduce the time of printing, while improving the quality in important areas

If you have a cubic model of the house with a curved roof, a cubic wall will be normal with 0,5 mm layer height while curved roof with 0,2 mm (my nozzle diameter=1mm)

BagelOrb commented 7 years ago

With VariSlice being released this feature has gotten a whole lot of attention again.

What's the status on the patent? I heard something about autodesk releasing the patent or something?

@nallath What is the verdict of our legal department? ^^

goatzillax commented 7 years ago

This has got to be some of the most inane reasoning for not implementing something I've seen.

It makes you wonder what other egregious thinking is waiting for us under the covers of Cura.

If you're really afraid of running afoul of the patent, then nut up and remove the "initial layer thickness" setting, which essentially allows the user to control the layer thickness of one layer. If you're that damn afraid of the patent, then you're probably already running afoul of it.

ahmetcemturan commented 7 years ago

Patent was filed in 99, the academic paper i posted was published in 98, so it was public before, so it cant be patented..

nallath commented 7 years ago

That's all fine and well, but it does open you up to lawsuits. So yes, there is a good chance that you win the case (say ~80%), but it will still cost a lot of money & effort. It's not only about being right, it's also about it being acknowledged.

BagelOrb commented 7 years ago

It's not all about the patent, though. This feature is very hard to implement in CuraEngine. Cura wasn't built with variable layer height in mind and it will be very difficult to retrofit some algorithms back onto layers with variable heights.

Fantiki commented 7 years ago

I think its a question of laziness ;) I can manually cut the model into pieces, prepare each of them into separate piece of gcode with Cura, and then manually put them together with a text editor. But I'm lazy, so asking You not to be as lazy as me, and make a nice upgrade :)

Fantiki commented 7 years ago

Guys, thanks for correctly understanding of my poor English :) I didn't mean to offend or bother you)

Labern2 commented 7 years ago

Varislice algorithm is free and open: licensed with Creative Commons Attribution 3.0

BagelOrb commented 7 years ago

The varislice algorithm isn't the difficult part, it's all the other stuff in Cura which needs to be adjusted.

Labern2 commented 7 years ago

Then it comes down to if it's worth the effort to implement it into Cura and what else could you do with the added features. Not only the Increased print quality on domes and curved surfaces and reduced print times that come with varislice.

NicoloParolini commented 7 years ago

I've got an actual use case for this (a feature I wished for for a couple years). You see, I print small figures for roleplaying/tabletop games, and they are composed by the figure itself and its base. Now, to achieve an acceptable level of detail these I print at 0.005mm (trying to go lower now, 0.001 by 0.001), which means an awfully long printing time. But if you look at it, half of it is spent printing the base, which is just a thick rectangle. Now I would like to print the base at like 0.02, then the figure at 0.005 or 0.004. I can't afford to print them separately as the figure's "feet" are sometimes very small parts which no glue (no, not even dichlo) could keep attached to the base itself. And yes, I'm not sure why it should be that difficult considered that you already got the "first layer thickness" setting. One could make that "first layer" configurable at least, as in "how many layers is that first layer whose thickness is different". That would be a huge improvement.

BagelOrb commented 7 years ago

Interesting use case.

May I ask what type of printer you have which allows such low layer heights? I thought this want possible on an Ultimaker..

Currently the first layer thickness is overlooked by a lot of algorithms, like support and infill, because it doesn't matter that much for one layer. Just having more initial layers already exposes this problems.

PS: try Cura 2.5!

NicoloParolini commented 7 years ago

After re-reading my comment I just realized how stupid I am :) sorry of course there's an extra 0 there, I print at 50 microns, not 5. So everything should be multiplied by 10.

z3099644 commented 7 years ago

I'm a massive fan of Cura and I would also love this feature! It would allow me to print objects that have a very gentle slope (eg. the top of an igloo or the top of someone's head) at very low layer heights (only limited by my printer's accuracy) and therefore maintaining smoothness, while being able to complete the entire print in a reasonable amount of time.

Something similar to Varislice by Autodesk: https://www.youtube.com/watch?v=HAmneiL5-jQ

Please please please implement this! It makes so much sense!

ChrisTerBeke commented 7 years ago

You're in luck: https://github.com/ChrisTerBeke/CuraVariSlicePlugin.

BagelOrb commented 7 years ago

Varying layer heights is the smallest piece of the puzzle. The actual challenge is making the Engine support varying layer heights.

daid commented 7 years ago

Well, got to start somewhere to finish the puzzle one day.

BagelOrb commented 7 years ago

True. I just don't want the people in this thread to get their hopes up too high.

NGB2 commented 6 years ago

Hi guys, I found the topic, because I need the very same feature. I design machine parts often. Many of these parts have functional surfaces. These need to have different properties. Often the functional surface needs to be smooth and a thin layer height would be advantageous, While the body usually just needs to be strong and quick to print. Often the functional surface is made of a different material. For that application it would be nice to be able to process different layer heights. I use the feature of different heights for the infill a lot. The restriction that the infill height needs to be a multiple of the wall layer height does not cause a lot of difficulties for me. As far as my programming know how allows me to judge (without knowing the internal structure of cura), that restriction might allow easier implementation. My parts are spiral shaped, often. Very much like the Z-axis lead screw on many printers. So I have a very small area that would benefit from higher resolution (to get a smooth top surface of the spiral rather than a staircase). The rest of the cross section could well be printed with less resolution. But I have that small high resolution section in every layer.

One more reason why I felt I need to write an answer is that I actually am a patent expert. I can say a few words, but patent regulations are very complex and difficult to cover completely. Patents were introduced to increase the knowledge of humanity. The inventor is given up to 20 years of protection for his invention. In return he has to describe and publish the description and allow free use after 20 years. Everything published is free to use after the patent is expired. If not patented and only published it can be used right away. As a result, it is safe to use anything that has been published more than 20 years ago. The only risk you run is, if you improve anything over the 20 year old publication, you do not know if anyone has filed a patent on the very same improvement. But patent procedures help you to find these improvements, as when you file a patent you are required to list which other patents you improved (may be an incomplete list, though) and that data is electronically searchable. If you have any patent numbers on that issue, please post them and I will take a look. The other way to go is this: Patents do not restrict research. Patents only restrict commercial use. If you program anything and you publish it and you allow people to use this for research, nobody can start a lawsuit against you. If you sell the software this is different. If someone uses the software you published commercially, that guy might get trouble, but not you. Most countries have additional restrictions for patenting software and algorithms, but this is a long and difficult subject. Unless you make very much money with the feature, it is unlikely anyone will start a law suit. A lawsuit is expensive for both sides and hardly ever results in advantages for the conflicting parties. The idea of lawsuits is to pay for the living expenses of lawyers and judges and not to generate advantages for any of the conflicting parties. This is well known to industry, which is why all that will typically happen if you violate a patent is that you get a letter to please stop what you are doing. Exceptions to this rule are where you already made a few million dollars of profit.

Now the results of a quick patent search: I briefly searched and found only US6505089 B1 as relevant prior art. This patent is expired and is free to use. The patent system is deliberately designed so that expired patents are safe to use by everyone. Also partial use of the described invention is allowed. Given the fact that this is almost 20 years old adds to making it risk free to use. The patent describes to slice an object. It also describes to take a look at the accuracy generated by the choice of the layer thickness. It allows you to decide if you are happy with the accuracy and print that layer with the thickness you have. It also allows you to divide it into two thinner layers to improve accuracy. It also allows you to do that recursively until you are happy with the accuracy.

I consider slicing a model like that being no violation of any patent. I have to add that a legally binding statement can only be made by a patent attourney.

I think this method could be implemented into cura. I also want to mention several alternatives of implementation. As writing them down here is a publication and will make these methods safely free to use over time. In addition these improvements can not be patented any more, if they are not patented already: It would be a good method to be able to slice two models. One in a layer heigth that is different (e.g. a multiple) of another and combine these to one print. It would also be a good method if the method described in the patent above was slightly improved. The improvement is that not the whole layer is divided into thinner layers, but only the sections that requires improved accuracy. The rest of the layer can be printed with the thick layer height.

One more thing: Does anyone know of a public discussion or publication of adapting layer thickness that is 15 or more years old? If so, it might be considered a publication and would add to removing potential threat of patent violations for more detail aspects. If you do, please post a link.

sorry for writing that much.

ChrisTerBeke commented 6 years ago

Cura 3.2 will have this feature in experimental. Adding the variable layer heights to the engine turned out to be pretty doable. It's not perfect (e.g. no varying in temperature, line width, etc. yet), but it's a good start that some Ultimaker employees and contributors already are experimenting with. So let's see where it goes from here.

@daid not sure about the issue in this repo as legacy Cura probably won't incorporate this?...