I downloaded a JMF sample code from http://topic.youkuaiyun.com/u/20090413/21/b730a64d-5a06-4b81-8abb-fec6bc472623.html and used eclipse to compile. But eclipse refused to compile it and reported errors: Access restriction: The type JPEGImageEncoder is not accessible due to restriction on required library C:/Program Files/Java/jre6/lib/rt.jar
"Projects using classes from rt.jar, such as com.sun.* (and some others) can have compilation errors like: "Access restriction: The type RE is not accessible due to restriction on required library <jre_path>/lib/rt.jar". Such errors indicate use of non-API classes and those access rules are defined by Eclipse JDT.
You can change compiler settings to not fail on those restrictions in workspace settings in Window // Preferences // Java // Compiler // Errors/Warnings // Deprecated and restricted API // Forbidden reference (access rules) // Warnings; or per-project from Project // Properties // Java Compiler // Errors//Warnings // Deprecated and restricted API // Forbidden reference (access rules) // Warnings"(http://docs.codehaus.org/display/M2ECLIPSE/Project+FAQ#ProjectFAQ-Compilationerrorsonrestrictedclasses )