Thanks for posting your query.
It might be soft tissue injury
or infrapatellar bursitis
Examination of swelling and knee is necessary to reach the diagnosis.
I suggest you to consult an orthopaedician nearby for a detailed examination and treatment plan according to that.
Dr Saurabh Gupta