'iTunes'에 해당되는 글 1건

  1. 2007.01.31 [번역] iTunes RSS Extension 1


iTunes의 Podcast를 위한 RSS extension에 대한 규격을 번역해보았습니다.
(사실 번역의 대상이 되는 문장은 많지 않군요.)

정확히는 RSS 2.0에서 확장 태그를 필요로 하는 경우를 위하여 XML namespace를 이용한 확장을 허용하고 있으며 Apple에서 iTunes RSS 라는 이름으로 몇가지 태그를 정의하고 있습니다.

대략 iTunes Application의 UI 상에서 보여질 필드들을 정의하고 있다고 보면 됩니다.
미국의 대부분의 뉴스 사이트들이 Podcast를 위한 피드를 제공하고 있고 미국내 가장 유명한 DVR 서비스인 Tivo에서도 iTunes를 지원한다고 합니다.

RSS를 활용한 미디어 데이터의 배포는 이제 거의 표준화의 단계에 들어서나 봅니다.

삼성전자가 최근에 야심차게 내놓은 SMS (Samsung Multimedia Studio) 서비스는 다른 모습은 거의 iTunes를 따라잡았다고 보입니다만, 조금은 아쉬운 것이 Podcast는 iPod의 전유물이 아님에도 불구하고 SMS에서 지원하지 않는다는 것입니다.
국내는 모르겠지만 북미 시장에서는 Podcast가 없는 MP3 지원 소프트웨어는 얼마나 경쟁력이 있을까 걱정입니다...

본 스펙의 원 출처는 Apple입니다.

http://phobos.apple.com/static/iTunesRSS.html

===================================================================================================

How To Publish a Podcast on the iTunes Music Store

Last Modified: 2005-07-07

iTunes RSS Tags

iTunes는 RSS 2.0 규격에 몇가지 추가 태그를 확장하여 사용하며, iTunes 태그를 사용하기 위해서는 아래와 같은 namespace 선언을 RSS Feed에 명시하여야 한다.

<rss xmlns:itunes="http://www.itunes.com/DTDs/Podcast-1.0.dtd" version="2.0">

UTF-8 인코딩을 사용하여야 하며, 다른 인코딩을 사용할 경우 iTunes 내에서 올바르게 보여질 것을 보장할 수 없다.

모든 태그 값들은 플레인 텍스트(마크업 혹은 HTML이 아닌)이어야 한다. 4000자까지 사용가능한 <itunes:summary> 태그를 제외하고는 모든 태그 값은 255자를 넘길 수 없다. 공백(whitespace)는 iTunes 내에서 그대로 보여지기 때문에 태그 값 앞이나 뒤에 필요없는 공백을 넣지 말아야 한다.

다음은 태그별로 channel(podcast)에 적용되는 것과 각 item별로 적용되는 것에 대한 구분 및 각 태그가 iTunes 어플리케이션 내에서 어떻게 보여지는가를 설명한다:

xml tag

channel

item

where content appears in iTunes

<title>

Y

Y

Name column

<link>

Y


website link and arrow in Name column

<copyright>

Y


in the iTunes Music Store

<pubDate>


Y

Release Date column

<itunes:author>


Y

Artist column

<itunes:block>

Y

Y

prevent an episode or podcast from appearing

<itunes:category>

Y

Y

Category column and in iTunes Music Store Browse

<itunes:duration>


Y

Time column

<itunes:explicit>

Y

Y

parental advisory graphic in Name column

<itunes:keywords>

Y

Y

not visible but can be searched

<itunes:owner>

Y


not visible, used for contact only

<itunes:subtitle>

Y

Y

Description column

<itunes:summary>

Y

Y

when (circled i) in Description column is clicked


Details for tags used by iTunes
<enclosure>이 태그의 url 속성 내에 있는 파일 확장자는 이 item이 Podcast 디렉토리에 보여져야하는 item인가를 결정하는데 사용된다. 지원하는 확장자는 "m4a", "mp3", "mov", "mp4", "pdf"이다.

<guid>모든 <item>은 guid(globally unique identifier)를 가지며 이 값은 절대 변하지 않아야 한다. Feed에 새로운 에피소드를 추가할 때 guid를 넣어줌으로써 해당 에피소드가 새로운 것인가를 결정할 수 있게 해준다. guid의 비교는 대소문자를 구분한다. 만약 에피소드에 대한 guid가 주어지지 않는 경우 에피소드의 url이 guid로 대신 사용된다.

<itunes:author>이 태그의 값은 iTunes 안에서 Artist 컬럼에 보여진다.

<itunes:block><item> element 안에 이 태그가 사용되면 해당 에피소드가 iTunes Podcast 디렉토리에 보여지지 않으며, <channel> element 안에 이 태그가 있는 경우 해당 전체 podcast가 iTunes Podcast 디렉토리에서 보여지지 않는다.

<itunes:category>iTunes Music Store에서 Podcast를 브라우징할 때 Category는 두번째 컬럼에 보여지며, Subcategory는 세번째 컬럼에 보여진다. 모든 Category가 Subcategory를 가지지는 않는다.

최상위 <itunes:category>는 컨텐츠 카테고리(Browse Category)를, 그 내부에 다시 나타나는(nested) <itunes:category>는 섭 카테고리(SUb Category)를 나타내는데 사용된다. Category의 값은 현재 iTunes Music Store에서 제공되는 카테고리와 서브 카테고리 중에서 선택한다.

서브 카테고리인 <itunes:category>가 명시된 경우, iTunes는 Category 컬럼에 이 서브 카테고리를 보여주며, 그렇지 않은 경우에는 최상위 <itunes:category> 값을 Category 컬럼에 보여준다.

<itunes:duration>이 태그의 값은 iTunes의 Time 컬럼에 보여진다.
태그 값의 형식은 HH:MM:SS, H:MM:SS, MM:SS, 혹은 M:SS 가 될 수 있다. (H = hours, M = minutes, S = seconds)

<itunes:explicit>이 태그는 이 Podcast가 'explicit material'을 포함하고 있는가의 여부를 명시한다.(역자주: explicit material의 의미??)

이 태그가 가질 수 있는 값은 “yes”와 “no” 두가지다.
태그 값이 "yes"의 경우, iTuns Music Store에서 해당 Podcast의 artwork 뒤에 'parental advisory graphic'이 나타나며, 또한 iTunes의 Name 컬럼에도 나타난다.

(역자주: iTunes의 화면 구성을 이해해야 알 수 있는 내용인 듯 합니다..--;;)

<itunes:keywords>이 태그는 텍스트 키워드 검색 시 검색 대상이 되는 값이다.
키워드간에는 공백을 사용하여 구분한다.

<itunes:image>이 태그는 해당 Podcast의 대표 이미지(artwork)를 나타내며, href 속성에 해당 이미지에 대한 url을 명시한다.

iTunes에서는 최소 300 x 300 픽셀의 사각형 이미지를 선호한다.
이것이 표준 RSS image 태그의 정의와 다른 점이며, 이에 별도의 커스텀 태그를 정의하는 것이다.

iTunes는 JPEG과 PNG 포맷의 이미지를 지원하며, 이미지에 대한 url은 반드시 “.jpg” 혹은 “.png” 로 끝나야 한다.

<itunes:owner>이 태그는 해당 Podcast의 오너와의 커뮤니케이션을 위해 필요한 정보를 포함하며, 공개적으로 보여지지는 않는다.

이 태그 내부(nested)의 <itunes:email> element에는 email 주소를, <itunes:name> element에는 owner의 이름을 넣는다.

<itunes:subtitle>이 태그의 값은 iTunes의 Description 컬럼에 보여진다.

<itunes:summary>이 태그의 값은 iTunes의 Description 컬럼에 있는  (circled i)를 클릭하였을 때 나타나는 팝업 윈도우에서 보여진다. 또한 해당 postcast에 대한 iTunes Music Store 페이지에서도 보여진다. 이 필드의 값은 최대 4000자까지 가능하다.

Sample RSS 2.0 feed that includes the iTunes tags
<?xml version="1.0" encoding="UTF-8"?>
<!-- must include xmlns:itunes tag -->
<rss xmlns:itunes="http://example.com/DTDs/Podcast-1.0.dtd" version="2.0">
<channel>

<title>All About Everything</title>
<itunes:author>John Doe</itunes:author>
<link>http://example.com/podcasts/everything/index.html</link>
<itunes:subtitle>A show about everything</itunes:subtitle>
<itunes:summary>All About Everything is a show about everything. Each week we dive into any subject known to man and talk about it as much as we can. Look for our Podcast in the iTunes Music Store</itunes:summary>
<language>en-us</language>
<copyright>&#x2117; &amp; &#xA9; 2005 John Doe &amp; Family</copyright>
<itunes:owner>
    <itunes:name>John Doe</itunes:name>
    <itunes:email>john.doe@example.com</itunes:email>
</itunes:owner>

<!-- iTunes prefers square images 300x300 pixels or larger -->
<itunes:image href="http://example.com/podcasts/everything/AllAboutEverything.jpg" />

<!-- iTunes Browse Podcasts Category -->
<itunes:category text="Technology">
    <!-- iTunes Browse Podcasts Subcategory -->
    <itunes:category text="Gadgets"/>
</itunes:category>

<item>
    <title>Shake Shake Shake Your Spices</title>
    <itunes:author>John Doe</itunes:author>
    <itunes:subtitle>A short primer on table spices</itunes:subtitle>
    <itunes:summary>This week we talk about salt and pepper shakers, comparing and contrasting pour rates, construction materials, and overall aesthetics. Come and join the party!</itunes:summary>
    <enclosure url="http://example.com/podcasts/everything/AllAboutEverythingEpisode3.m4a" length="8727310" type="audio/x-m4a" />
    <guid>http://example.com/podcasts/archive/aae20050615.m4a</guid>
    <pubDate>Wed, 15 Jun 2005 19:00:00 GMT</pubDate>
    <itunes:category text="Food">
    <itunes:duration>7:04</itunes:duration>
    <itunes:keywords>salt pepper shaker exciting</itunes:keywords>
</item>

<item>
    <title>Socket Wrench Shootout</title>
    <itunes:author>Jane Doe</itunes:author>
    <itunes:subtitle>Comparing socket wrenches is fun!</itunes:subtitle>
    <itunes:summary>This week we talk about metric vs. old english socket wrenches. Which one is better? Do you really need both? Get all of your answers here.</itunes:summary>
    <enclosure url="http://example.com/podcasts/everything/AllAboutEverythingEpisode2.mp3" length="5650889" type="audio/mpeg" />
    <guid>http://example.com/podcasts/archive/aae20050608.mp3</guid>
    <pubDate>Wed, 8 Jun 2005 19:00:00 GMT</pubDate>
    <itunes:category text="Technology">
        <itunes:category text="Gadgets"/>
    </itunes:category>
    <itunes:duration>4:34</itunes:duration>
    <itunes:keywords>metric socket wrenches tool</itunes:keywords>
</item>

<item>
    <title>Red, Whine, &amp; Blue</title>
    <itunes:author>Various</itunes:author>
    <itunes:subtitle>Red + Blue != Purple</itunes:subtitle>
    <itunes:summary>This week we talk about surviving in a Red state if you're a Blue person. Or vice versa.</itunes:summary>
    <enclosure url="http://example.com/podcasts/everything/AllAboutEverythingEpisode1.mp3" length="4989537" type="audio/mpeg" />
    <guid>http://example.com/podcasts/archive/aae20050601.mp3</guid>
    <pubDate>Wed, 1 Jun 2005 19:00:00 GMT</pubDate>
    <itunes:category text="Politics">
    <itunes:duration>3:59</itunes:duration>
    <itunes:keywords>politics red blue state</itunes:keywords>
</item>

</channel>
</rss>

자주 하는 실수들(Common Mistakes)
* <pubDate> 태그에 사용되는 'date'나 'time'의 포맷이 RFC 2822를 따르지 않는 실수.

'date' 포맷은 반드시 "day-of-week, day month year"이어야 한다.
'time' 포맷은 반드시 24 시간 포맷으로서 AM이나 PM을 포함하지 않으며, 또한 타임존(time zone)에 대한 오프셋(offset)을 포함하여야 한다.

<!-- date and time not in RFC 2822 format -->
<pubDate>7/6/2005 1:00:00 PM</pubDate>

<!-- valid date and time format -->
<pubDate>Wed, 6 Jul 2005 13:00:00 PDT</pubDate>
<pubDate>Wed, 6 Jul 2005 13:00:00 -0700</pubDate>

* 엠퍼샌드(ampersand)에 대한 Escape를 빠뜨리는 실수

<!-- illegal xml -->
<title>Food & Wine</title>

<!-- valid xml -->
<title>Food &amp; Wine</title>

* HTML의 "named character"를 사용하는 실수

<!-- illegal xml -->
<copyright>&copy; 2005 John Doe</copyright>

<!-- valid xml -->
<copyright>&#xA9; 2005 John Doe</copyright>

HTML과는 달리 XML은 단지 다섯개의 "named character entities"만을 지원한다.

character

name

xml

&

ampersand

&amp;

<

less-than sign

&lt;

>

greater-than sign

&gt;

'

apostrophe

&apos;

"

quotation

&quot;


XML에서는 위의 다섯개의 문자에 대해서만 escape 처리가 필요하다. 이외의 모든 문자는 UTF-8을 지원하는 에디터에서 직접 입력하여 사용할 수 있다. 또한 해당 문자에 대한 Unicode를 카리키는 숫자로 된 참조값(numeric character reference)를 사용할 수 있다. 다음은 그 예이다:

character

name

xml

copyright sign

&#xA9;

?

sound recording copyright

&#x2117;

trade mark sign

&#x2122;


이런 방식의 참조에 대한 더 많은 내용은 다음을 참고한다: XML Character and Entity References

Posted by Golmong
: