LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 02-13-2006, 04:32 PM   #1
microsoft/linux
Senior Member
 
Registered: May 2004
Location: Sebec, ME, USA
Distribution: Debian Etch, Windows XP Home, FreeBSD
Posts: 1,445
Blog Entries: 9

Rep: Reputation: 48
C programming, learning more advanced stuff


I'd like to implement photo transfer support in libgpod for a Computer Projects class in school. The thing is, the code is written in C, and while I've done some C programming, I'm more familiar w/ C++. I'm at functions in both, and I'm pretty sure I can refresh my memory. My question is, where should I start? I've read some of the source code, and i'm not sure how this works exactly. My understanding is that the library provides the functions available, and then the program calls the functions? Are there any resources out there that teach library stuff? Do I need to know gtk(since gtkpod is in gtk, and libgpod is for gtkpod)? Is there something else I should be looking at?
 
Old 02-13-2006, 05:13 PM   #2
Lazy Foo'
Member
 
Registered: Dec 2005
Location: LA
Distribution: SuSE 9.3 Pro
Posts: 32

Rep: Reputation: 15
Well what do you want to learn to do with your C programming?

'cause if it's game programming I can help you out
 
Old 02-13-2006, 05:37 PM   #3
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Quote:
Originally Posted by microsoft/linux
. My question is, where should I start? I've read some of the source code, and i'm not sure how this works exactly.
The general idea how it works should be the first thing you look into. Try to trace one single function (initialization etc), then move to another etc. Should be easier this way.
Quote:
My understanding is that the library provides the functions available, and then the program calls the functions?
Exactly.
Quote:
Are there any resources out there that teach library stuff?
I don't think you need them. Library is just a set of functions. There are special issues when you compile it etc, but not when just using it.
Quote:
Do I need to know gtk(since gtkpod is in gtk, and libgpod is for gtkpod)? Is there something else I should be looking at?
Probably, at a basic level (I guess so, haven't downloaded the source). My guess is that it'll be more about lists and such things than about GTK gui. You don't need to know it well. Just browsing GTK reference (not in detail, just what does a certain function do) should be enough.
 
Old 02-13-2006, 06:26 PM   #4
microsoft/linux
Senior Member
 
Registered: May 2004
Location: Sebec, ME, USA
Distribution: Debian Etch, Windows XP Home, FreeBSD
Posts: 1,445

Original Poster
Blog Entries: 9

Rep: Reputation: 48
Is there any way to trace a function easily? The developer I talked to said to implement this in the library first, and then potentially it'll be brought into gktpod. Do you mean read the function source code? or do you mean look at how it's used in gtkpod, and then read the function? Or am I completely missing the meaning.
 
Old 02-14-2006, 02:55 PM   #5
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
You can try both ways and see what's easier for you. I guess the gtkpod code is not that simple, so learning what it realy does may be tricky. Reading the library function may be much easier. For all GTK (and GTK-related) functions used, just have GTK reference open, see what arguments a certain function needs, what it returns, don't look into the details.
 
Old 02-15-2006, 07:36 AM   #6
xhi
Senior Member
 
Registered: Mar 2005
Location: USA::Pennsylvania
Distribution: Slackware
Posts: 1,065

Rep: Reputation: 45
i took a look at the source and you should be prepared to sit down with a pen and piece of paper and track what does what to get started.. it is definately not simple..

one thing i did notice is that there are functions in the lib for thumbnails. transfer, storage, removal.. i would start there and learn how those work.. maybe you could even implement some of the existing code..

hth
 
Old 02-15-2006, 05:06 PM   #7
microsoft/linux
Senior Member
 
Registered: May 2004
Location: Sebec, ME, USA
Distribution: Debian Etch, Windows XP Home, FreeBSD
Posts: 1,445

Original Poster
Blog Entries: 9

Rep: Reputation: 48
yes, I was thinking that some of those functions could be reimplemented. The thing is, it looked to me as though a lot of functions call other functions. It sounds like it's going to be a pretty big task. Does it look that way to those of you who have looked at the code?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
learning programming nin881 Programming 13 10-19-2005 12:17 AM
C programming learning introuble Programming 7 01-03-2005 11:55 AM
learning programming properly antken Programming 8 03-17-2004 10:18 PM
Help with learning drivers programming! fbarre Linux - General 6 09-13-2003 06:50 PM
Where can I learn more advanced programming concepts? OrganicX Programming 8 03-01-2003 08:08 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 08:52 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration