I am currently developing a D-app for Ethereum, usable with the Metamask extension. I use the truffle framework and testrpc to test locally my app.
When the user has to make a transaction to execute a function of smart contracts, the Gas Limit for the transactions in the Metamask window is always already set to a (variable) certain amount. As this amount is enough for most of my transactions, except a few for which I have to set manually the gas limit, I was wondering myself how is this amount for the gas limit calculated/estimated.
Where could I find some good information about this matter?
Any help would be greatly appreciated