[mythtv] mythrecipe

Christopher Flynn flynnguy at gmail.com
Tue Nov 9 04:45:08 UTC 2004

I'm moving the discussion that was over on the MythTV user mailing
list over here...

Summary for those of you just joining us, due to the disappearance of
mythrecipe we decided it would be best to rewrite it. I have a little
coding experience but I would appreciate it if anyone with c++ and
mythtv plugin experience would be willing to help me.

Chris Petersen: 
>> Now for the ingredients:
>> qty, amt, des, recID, ingID
>way too simplistic.  This is part of the problem I ran into with my own
>stuff.  There are a LOT of recipes out there that have ingredients like:

> 1 cup plus 2 tbsp flour
for this scenario I would have either split this up into 2 ingredients or done:
1 | cup | plus 2 tbsp flour

> 1 squeeze of lemon or lime
for this scenario I would have squeeze be the amount and then lemon or
lime as the ingredient.

Of course I would be open to other suggestions because if we have some
sort of scale function it would probably get messed up. Of course I
don't know if there would be a way to make something that would scale
in all cases.

Now on to the categories, you suggested:
> Dinner -> Entree -> Rice -> Risotto
> Region -> Italy  -> Dinner -> Entree -> Risotto
here I see two different categories, the first one has a main category
with two subcategories and the second would be a search by region. So
perhaps a search by region which would filter the results by whatever
region they selected (in this case Italy) and then continue to search
by category but filter out anything not matching said region. That
shouldn't be too hard to do with sql.

For the category but, I guess have a main category and then a
subcategory field. Sound good?

>I've already offered my help, along with the fact that I'm going to
>write a web-based recipe database, anyway.  Though I also know that what
>I want may be overkill for most people.
Thanks, I read your offer after I wrote what I did. I like what you've
done with mythweb and I'm glad to hear you're interested in this.

Your list:
- table of ingredients, complete with descriptions, images and
    nutritional info
Do we really need images of ingredients? 

- table of recipes, linked with recipe-ingredients
So like a lookup table that has a recipeID and an ingredient?

- indexes for keywords, author/source, contributor (someone who posts
    someone else's recipe) and ingredients.
sounds good.

- a category tree not directly linked to recipes (trust me, it's easier
    to manage this way), but assigned keywords.  Recipes matching those
    keywords will show up under that category.
This may be easier in terms of data entry but invites a whole lot of
other complications. First the queries would take longer than if we
have to search through keywords rather than just pull out the

- each recipe/ingredient gets a unique identifier, like a wiki.
Yeah, that way you can delete an individual item

>My recipe parsing engine is mostly functional (nothing to show -- I was
>in the middle of a rewrite of some data structures before I moved, and
>it's nonfunctional at the ment).  It allows you to take something like:

>100 ml + 1 tsp ginger or cinnamon
>100 grams whole black peppercorns
>1/2 nutmeg, crushed
>2 cups water

>and will split out measurements and identify ingredients.  It will also
>allow for unit conversions (between metric and US -- figured that no one
>would be using imperial measurements anymore) and automatic scaling.
so do you have an existing database setup? If you get a chance I would
like to see how your data structures are laid out and if you don't
already have a database setup then we'll see what we can do.

I understand you are busy moving into your new house, I too will be
closing on my first house soon so this may be a little slow going.

You must be the change you wish to see in the world. - Gandhi

More information about the mythtv-dev mailing list